/* =========================
   RESET
========================= */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: "Inter", "Segoe UI", sans-serif;
}

/* =========================
   PAGE
========================= */
.auth-page {
    min-height: 100vh;
    overflow-x: hidden;
    background: #f8fafc;
}

/* =========================
   LANDING PAGE
========================= */
.portal-page {
    min-height: 100vh;
    position: relative;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    padding: 90px 60px 40px;
}

/* =========================
   BACKGROUND
========================= */
.portal-page::before {
    content: "";
    position: absolute;
    inset: -24px;
    background:
        linear-gradient(125deg,
            rgba(5, 15, 34, 0.45),
            rgba(5, 15, 34, 0.82)),
        url("../images/bg-auth-scw.png") center center / cover no-repeat;
    animation: slowZoom 30s ease-in-out infinite alternate;
}

.portal-page::after {
    content: "";
    position: absolute;
    inset: 0;
    background:
        radial-gradient(circle at 20% 20%, rgba(37, 99, 235, .15), transparent 35%),
        radial-gradient(circle at 80% 80%, rgba(22, 163, 74, .15), transparent 35%);
}

/* =========================
   HEADER
========================= */
.portal-header {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    z-index: 10;
    padding: 32px 48px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.portal-brand {
    display: inline-flex;
    align-items: center;
    text-decoration: none;
}

/* =========================
   LOGO
========================= */
.portal-logo {
    position: absolute;
    top: 24px;
    left: 48px;
    width: 140px;
    z-index: 10;
}

/* =========================
   SHOWCASE
========================= */
.portal-showcase {
    position: relative;
    z-index: 2;
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
}

/* =========================
   HEADING
========================= */
.portal-heading {
    margin-bottom: 40px;
    text-align: center;
    color: #ffffff;
}

.portal-heading span {
    display: inline-flex;
    align-items: center;
    min-height: 30px;
    padding: 6px 14px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.16);
    border: 1px solid rgba(255, 255, 255, 0.28);
    backdrop-filter: blur(12px);
    font-size: 12px;
    font-weight: 800;
    letter-spacing: .08em;
    text-transform: uppercase;
}

.portal-heading h1 {
    margin-top: 16px;
    font-size: 42px;
    line-height: 1.15;
    font-weight: 800;
    color: #ffffff;
    text-shadow: 0 14px 34px rgba(0, 0, 0, .32);
}

.portal-subtitle {
    margin-top: 14px;
    color: rgba(255, 255, 255, .85);
    font-size: 15px;
    line-height: 1.7;
}

/* =========================
   GRID
========================= */
.portal-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 24px;
}

/* =========================
   ITEM MODUL
========================= */
.modul-item {
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 15px;
    min-height: 310px;
    padding: 24px;
    border-radius: 20px;
    overflow: hidden;
    background: rgba(255, 255, 255, .92);
    border: 1px solid rgba(255, 255, 255, .62);
    backdrop-filter: blur(18px);
    box-shadow: 0 24px 54px rgba(15, 23, 42, .32);
    cursor: pointer;
    transition:
        transform .28s ease,
        box-shadow .28s ease,
        background .28s ease,
        border-color .28s ease;
}

.modul-item::before {
    content: "";
    position: absolute;
    inset: 0 auto 0 0;
    width: 6px;
    background: var(--portal-accent);
}

.modul-item::after {
    content: "";
    position: absolute;
    right: -34px;
    top: -34px;
    width: 96px;
    height: 96px;
    border-radius: 50%;
    background: var(--portal-soft);
}

.modul-item:hover {
    transform: translateY(-10px);
    background: #ffffff;
    border-color: rgba(255, 255, 255, .88);
    box-shadow: 0 32px 70px rgba(15, 23, 42, .38);
}

.modul-item:active {
    transform: translateY(-5px) scale(.99);
}

/* =========================
   VARIAN MODUL
========================= */
.modul-finance {
    --portal-accent: #2563eb;
    --portal-soft: rgba(37, 99, 235, .14);
}

.modul-hr {
    --portal-accent: #16a34a;
    --portal-soft: rgba(22, 163, 74, .14);
}

.modul-logistics {
    --portal-accent: #f59e0b;
    --portal-soft: rgba(245, 158, 11, .16);
}

/* =========================
   BOX ICON
========================= */
.box-modul {
    position: relative;
    z-index: 1;
    width: 72px;
    height: 72px;
    border-radius: 16px;
    background-color: #f8fafc;
    background-position: center;
    background-repeat: no-repeat;
    background-size: 64%;
    border: 1px solid rgba(148, 163, 184, .24);
    box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .62);
    transition: transform .28s ease;
}

.modul-item:hover .box-modul {
    transform: scale(1.08);
}

/* =========================
   ICON MODUL
========================= */
.finance {
    background-image: url("../images/modul/finance.png");
}

.human-resource {
    background-image: url("../images/modul/human-resource.png");
}

.logistics {
    background-image: url("../images/modul/logistics.png");
}

/* =========================
   CONTENT
========================= */
.modul-content {
    position: relative;
    z-index: 1;
    width: 100%;
    min-width: 0;
}

.modul-label {
    display: block;
    margin-bottom: 6px;
    font-size: 11px;
    font-weight: 800;
    letter-spacing: .12em;
    text-transform: uppercase;
    color: var(--portal-accent);
}

.judul-modul {
    font-size: 22px;
    line-height: 1.25;
    font-weight: 800;
    color: #0f172a;
}

.modul-description {
    margin-top: 10px;
    min-height: 66px;
    font-size: 14px;
    line-height: 1.7;
    color: #475569;
    text-align: justify;
}

/* =========================
   FEATURES
========================= */
.modul-features {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 16px;
}

.modul-features span {
    display: inline-flex;
    align-items: center;
    min-height: 28px;
    padding: 6px 10px;
    border-radius: 999px;
    background: var(--portal-soft);
    border: 1px solid rgba(148, 163, 184, .20);
    color: #1e293b;
    font-size: 11px;
    font-weight: 800;
    line-height: 1.2;
}

/* =========================
   HERO ACTIONS
========================= */
.hero-actions {
    margin-top: 32px;
    display: flex;
    justify-content: center;
    gap: 14px;
    flex-wrap: wrap;
}

.btn-primary,
.btn-secondary {
    padding: 14px 28px;
    border-radius: 999px;
    text-decoration: none;
    font-weight: 700;
    transition: all .3s ease;
}

.btn-primary {
    background: linear-gradient(135deg, #2563eb, #1d4ed8);
    color: #ffffff;
    box-shadow: 0 12px 28px rgba(37, 99, 235, .35);
}

.btn-primary:hover {
    transform: translateY(-3px);
    box-shadow: 0 16px 36px rgba(37, 99, 235, .45);
}

.btn-secondary {
    color: #ffffff;
    border: 1px solid rgba(255, 255, 255, .35);
    background: rgba(255, 255, 255, .12);
    backdrop-filter: blur(12px);
}

.btn-secondary:hover {
    background: rgba(255, 255, 255, .22);
    transform: translateY(-3px);
}

/* =========================
   LOGIN BUTTON
========================= */
.portal-login-btn {
    position: absolute;
    top: 32px;
    right: 48px;
    z-index: 10;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 12px 24px;
    min-height: 46px;
    border-radius: 999px;
    background: linear-gradient(135deg, #2563eb, #1d4ed8);
    border: none;
    color: #ffffff;
    font-size: 14px;
    font-weight: 700;
    text-decoration: none;
    box-shadow: 0 12px 28px rgba(37, 99, 235, .35);
    transition: all .3s ease;
}

.portal-login-btn:hover {
    background: linear-gradient(135deg, #2563eb, #1d4ed8);
    color: #ffffff;
    transform: translateY(-2px);
    box-shadow: 0 16px 36px rgba(37, 99, 235, .45);
}

.portal-login-btn:active {
    transform: translateY(0);
}

/* =========================
   FOOTER
========================= */
.portal-footer {
    position: relative;
    z-index: 2;
    margin-top: 60px;
    text-align: center;
    color: rgba(255, 255, 255, .7);
    font-size: 14px;
}

/* =========================
   ANIMATIONS
========================= */
@keyframes slowZoom {
    from {
        transform: scale(1);
    }

    to {
        transform: scale(1.08);
    }
}

/* =========================
   RESPONSIVE
========================= */
@media (max-width: 1180px) {
    .portal-page {
        padding: 40px;
    }

    .portal-grid {
        grid-template-columns: 1fr;
        max-width: 480px;
        margin: auto;
    }

    .portal-heading h1 {
        font-size: 34px;
    }

    .modul-item {
        min-height: auto;
    }

    .modul-description {
        min-height: 0;
    }
}

@media (max-width: 768px) {
    .portal-page {
        padding: 100px 20px 30px;
    }

    .portal-header {
        padding: 24px;
    }

    .portal-logo {
        width: 120px;
    }

    .portal-login-btn {
        padding: 10px 18px;
        min-height: 40px;
        font-size: 13px;
        top: auto;
        right: auto;
        position: static;
    }

    .portal-heading h1 {
        font-size: 28px;
    }

    .portal-subtitle {
        font-size: 14px;
    }

    .portal-grid {
        grid-template-columns: 1fr;
    }

    .modul-item {
        padding: 20px;
    }

    .judul-modul {
        font-size: 20px;
    }

    .box-modul {
        width: 64px;
        height: 64px;
    }
}