:root {
    --portal-navy: #062e5e;
    --portal-blue: #0877bd;
    --portal-cyan: #00a7d9;
    --portal-yellow: #ffd63f;
    --portal-text: #153553;
    --portal-muted: #60758a;
    --portal-line: rgba(30, 111, 171, .18);
    --portal-glass: rgba(255, 255, 255, .74);
    --portal-shadow: 0 24px 60px rgba(7, 48, 91, .12);
}

.portal-page {
    min-height: 70vh;
    color: var(--portal-text);
    background:
        radial-gradient(circle at 10% 10%, rgba(63, 153, 236, .16), transparent 30%),
        radial-gradient(circle at 92% 0%, rgba(255, 214, 63, .12), transparent 25%),
        linear-gradient(180deg, #f8fbff 0%, #eef6fc 100%);
    overflow: hidden;
}

.portal-page *,
.portal-page *::before,
.portal-page *::after {
    box-sizing: border-box;
}

.portal-hero {
    position: relative;
    isolation: isolate;
    overflow: hidden;
    padding: 72px 0 60px;
    color: #fff;
    background:
        linear-gradient(115deg, rgba(5, 35, 75, .98), rgba(4, 91, 153, .95)),
        radial-gradient(circle at 70% 20%, rgba(0, 179, 224, .4), transparent 34%);
}

.portal-hero.compact {
    padding: 58px 0 48px;
}

.portal-hero::after {
    content: "";
    position: absolute;
    inset: 0;
    z-index: -2;
    opacity: .18;
    background-image:
        linear-gradient(rgba(255,255,255,.16) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255,255,255,.16) 1px, transparent 1px);
    background-size: 42px 42px;
    mask-image: linear-gradient(to right, transparent, #000 35%, #000);
}

.portal-orb {
    position: absolute;
    z-index: -1;
    border-radius: 999px;
    filter: blur(1px);
    opacity: .55;
    animation: portal-orbit 8s ease-in-out infinite;
}

.portal-orb-a {
    width: 260px;
    height: 260px;
    right: 8%;
    top: -95px;
    background: radial-gradient(circle at 30% 30%, rgba(255, 225, 95, .65), rgba(255, 225, 95, .04));
}

.portal-orb-b {
    width: 180px;
    height: 180px;
    right: 28%;
    bottom: -90px;
    animation-delay: -3s;
    background: radial-gradient(circle at 30% 30%, rgba(74, 204, 255, .65), rgba(74, 204, 255, .03));
}

@keyframes portal-orbit {
    0%, 100% { transform: translate3d(0, 0, 0) scale(1); }
    50% { transform: translate3d(16px, -12px, 0) scale(1.06); }
}

.portal-hero-inner {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 32px;
}

.portal-hero h1 {
    margin: 10px 0 12px;
    max-width: 780px;
    color: #fff;
    font-size: clamp(2.1rem, 4.5vw, 4.1rem);
    line-height: .98;
    letter-spacing: -.045em;
}

.portal-hero p {
    max-width: 760px;
    margin: 0;
    color: rgba(255,255,255,.84);
    font-size: clamp(.98rem, 1.7vw, 1.15rem);
    line-height: 1.7;
}

.portal-kicker {
    display: inline-block;
    color: var(--portal-yellow);
    font-size: .75rem;
    font-weight: 900;
    letter-spacing: .14em;
    text-transform: uppercase;
}

.portal-language {
    display: inline-flex;
    flex: 0 0 auto;
    gap: 6px;
    padding: 5px;
    border: 1px solid rgba(255,255,255,.25);
    border-radius: 999px;
    background: rgba(255,255,255,.1);
    backdrop-filter: blur(12px);
}

.portal-language button {
    min-width: 44px;
    border: 0;
    border-radius: 999px;
    padding: 9px 12px;
    color: #fff;
    font: inherit;
    font-size: .78rem;
    font-weight: 900;
    cursor: pointer;
    background: transparent;
}

.portal-language button.is-active {
    color: var(--portal-navy);
    background: var(--portal-yellow);
    box-shadow: 0 8px 20px rgba(255, 214, 63, .28);
}

.portal-shell {
    padding-top: 42px;
    padding-bottom: 72px;
}

.glass-panel {
    position: relative;
    border: 1px solid rgba(104, 169, 216, .24);
    border-radius: 24px;
    background:
        linear-gradient(145deg, rgba(255,255,255,.86), rgba(246,251,255,.65));
    box-shadow: var(--portal-shadow);
    backdrop-filter: blur(18px) saturate(135%);
}

.payment-summary {
    display: grid;
    grid-template-columns: auto 1fr;
    align-items: center;
    gap: 22px;
    padding: 24px;
    margin-bottom: 28px;
}

.payment-code {
    min-width: 170px;
    padding: 18px 20px;
    border-radius: 18px;
    color: #fff;
    background: linear-gradient(135deg, var(--portal-navy), var(--portal-blue));
}

.payment-code span {
    display: block;
    margin-bottom: 4px;
    font-size: .72rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: .08em;
    opacity: .75;
}

.payment-code strong {
    display: block;
    font-size: 2rem;
    line-height: 1;
}

.payment-summary > div:last-child > strong {
    display: block;
    margin-bottom: 6px;
    font-size: 1.12rem;
}

.payment-summary p {
    margin: 0;
    color: var(--portal-muted);
    line-height: 1.6;
}

.payment-method-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 20px;
}

.payment-method {
    display: grid;
    grid-template-columns: auto 1fr;
    gap: 18px;
    padding: 26px;
    transition: border-color .2s ease, box-shadow .2s ease, transform .2s ease;
}

.payment-method:hover {
    transform: translateY(-4px);
    border-color: rgba(0, 135, 211, .5);
    box-shadow: 0 26px 65px rgba(7, 65, 112, .18);
}

.method-number {
    display: grid;
    place-items: center;
    width: 48px;
    height: 48px;
    border-radius: 16px;
    color: var(--portal-navy);
    font-size: 1.45rem;
    font-weight: 950;
    background: linear-gradient(135deg, var(--portal-yellow), #ffbd28);
    box-shadow: 0 10px 28px rgba(255, 194, 36, .26);
}

.payment-method h2 {
    margin: 4px 0 14px;
    color: var(--portal-navy);
    font-size: 1.12rem;
}

.payment-method ol {
    margin: 0;
    padding-left: 20px;
    color: var(--portal-muted);
    line-height: 1.65;
}

.payment-method li + li { margin-top: 7px; }

.payment-guide-image {
    margin: 28px 0 0;
    padding: 12px;
    overflow: hidden;
}

.payment-guide-image img {
    display: block;
    width: 100%;
    height: auto;
    border-radius: 17px;
}

.payment-guide-image figcaption {
    padding: 12px 8px 4px;
    color: var(--portal-muted);
    text-align: center;
    font-size: .88rem;
}

.portal-cta {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 28px;
    margin-top: 28px;
    padding: 28px;
    color: #fff;
    background: linear-gradient(120deg, rgba(4, 42, 86, .96), rgba(0, 123, 188, .94));
}

.portal-cta h2 {
    margin: 5px 0 0;
    color: #fff;
    font-size: clamp(1.25rem, 2.4vw, 2rem);
}

.portal-cta > div > span {
    color: var(--portal-yellow);
    font-weight: 900;
    text-transform: uppercase;
    font-size: .72rem;
    letter-spacing: .1em;
}

.portal-cta a,
.login-choice a,
.login-help a {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 46px;
    padding: 12px 18px;
    border-radius: 14px;
    color: var(--portal-navy);
    font-weight: 900;
    text-decoration: none;
    background: var(--portal-yellow);
    box-shadow: 0 12px 28px rgba(255, 205, 50, .24);
    transition: transform .2s ease, box-shadow .2s ease;
}

.portal-cta a:hover,
.login-choice a:hover,
.login-help a:hover {
    transform: translateY(-2px);
    box-shadow: 0 16px 34px rgba(255, 205, 50, .32);
}

.login-shell { max-width: 1040px; }

.login-choice-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 22px;
}

.login-choice {
    padding: 30px;
    overflow: hidden;
}

.login-choice::before {
    content: "";
    position: absolute;
    width: 180px;
    height: 180px;
    right: -78px;
    top: -86px;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(15, 145, 216, .18), transparent 70%);
}

.login-choice-icon,
.portal-form-icon {
    display: grid;
    place-items: center;
    width: 54px;
    height: 54px;
    margin-bottom: 18px;
    border-radius: 18px;
    color: var(--portal-blue);
    background: rgba(228, 243, 255, .9);
    box-shadow: inset 0 0 0 1px rgba(48, 139, 207, .16);
}

.login-choice-icon svg,
.portal-form-icon svg,
.status-empty svg,
.portal-submit svg {
    width: 25px;
    height: 25px;
    fill: none;
    stroke: currentColor;
    stroke-width: 1.8;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.login-choice h2 {
    margin: 8px 0 10px;
    color: var(--portal-navy);
    font-size: 1.5rem;
}

.login-choice p {
    min-height: 72px;
    margin: 0 0 22px;
    color: var(--portal-muted);
    line-height: 1.65;
}

.login-help {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
    margin-top: 22px;
    padding: 24px;
}

.login-help strong {
    display: block;
    margin-bottom: 5px;
    color: var(--portal-navy);
}

.login-help p {
    margin: 0;
    color: var(--portal-muted);
}

.status-shell { max-width: 1120px; }

.status-layout {
    display: grid;
    grid-template-columns: minmax(0, .92fr) minmax(0, 1.08fr);
    gap: 24px;
    align-items: stretch;
}

.status-form,
.status-result {
    min-height: 430px;
    padding: 30px;
}

.portal-form-heading {
    display: flex;
    gap: 16px;
    align-items: center;
    margin-bottom: 24px;
}

.portal-form-heading .portal-form-icon { margin: 0; flex: 0 0 auto; }
.portal-form-heading h2 { margin: 0 0 4px; color: var(--portal-navy); }
.portal-form-heading p { margin: 0; color: var(--portal-muted); font-size: .9rem; }

.portal-field {
    display: grid;
    gap: 8px;
    margin-bottom: 18px;
}

.portal-field > span {
    color: var(--portal-navy);
    font-size: .84rem;
    font-weight: 850;
}

.portal-field input {
    width: 100%;
    min-height: 50px;
    border: 1px solid rgba(85, 147, 194, .28);
    border-radius: 14px;
    padding: 0 15px;
    color: var(--portal-text);
    font: inherit;
    background: rgba(255,255,255,.84);
    outline: none;
    transition: border-color .2s ease, box-shadow .2s ease;
}

.portal-field input:focus {
    border-color: var(--portal-blue);
    box-shadow: 0 0 0 4px rgba(17, 132, 203, .12);
}

.portal-submit {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 9px;
    width: 100%;
    min-height: 52px;
    margin-top: 8px;
    border: 0;
    border-radius: 15px;
    color: #fff;
    font: inherit;
    font-weight: 900;
    cursor: pointer;
    background: linear-gradient(135deg, var(--portal-navy), var(--portal-blue));
    box-shadow: 0 14px 30px rgba(5, 80, 142, .23);
}

.portal-submit:disabled { cursor: wait; opacity: .72; }
.portal-submit svg { width: 20px; height: 20px; }

.portal-alert {
    margin: 6px 0 14px;
    border-radius: 13px;
    padding: 12px 14px;
    color: #8c2e2e;
    font-size: .88rem;
    background: #fff0f0;
    border: 1px solid #ffd0d0;
}

.status-result {
    display: grid;
    place-items: center;
    text-align: center;
}

.status-empty {
    max-width: 430px;
}

.status-empty > span {
    display: grid;
    place-items: center;
    width: 72px;
    height: 72px;
    margin: 0 auto 18px;
    border-radius: 24px;
    color: var(--portal-blue);
    background: rgba(226, 243, 255, .86);
}

.status-empty svg { width: 34px; height: 34px; }
.status-empty h2 { margin: 0 0 10px; color: var(--portal-navy); }
.status-empty p { margin: 0; color: var(--portal-muted); line-height: 1.65; }

.status-found { width: 100%; max-width: 460px; }
.status-found h2 { margin: 14px 0 22px; color: var(--portal-navy); font-size: 2rem; }

.status-badge {
    display: inline-flex;
    padding: 8px 12px;
    border-radius: 999px;
    font-size: .76rem;
    font-weight: 900;
    color: #0a5a92;
    background: #e6f4ff;
}

.status-found[data-tone="success"] .status-badge { color: #18623d; background: #e7f8ef; }
.status-found[data-tone="warning"] .status-badge { color: #785200; background: #fff5cd; }
.status-found[data-tone="danger"] .status-badge { color: #8e2c34; background: #ffeaed; }

.status-found dl {
    display: grid;
    gap: 10px;
    margin: 0 0 22px;
    text-align: left;
}

.status-found dl div {
    display: grid;
    grid-template-columns: 1fr 1.2fr;
    gap: 16px;
    padding: 14px 16px;
    border-radius: 14px;
    background: rgba(240, 247, 252, .82);
}

.status-found dt { color: var(--portal-muted); }
.status-found dd { margin: 0; color: var(--portal-navy); font-weight: 850; text-align: right; }
.status-found a {
    display: inline-flex;
    padding: 12px 18px;
    border-radius: 14px;
    color: #fff;
    font-weight: 900;
    text-decoration: none;
    background: linear-gradient(135deg, var(--portal-navy), var(--portal-blue));
}

@media (max-width: 860px) {
    .payment-method-grid,
    .login-choice-grid,
    .status-layout {
        grid-template-columns: 1fr;
    }

    .status-form,
    .status-result { min-height: auto; }
    .status-result { padding-top: 42px; padding-bottom: 42px; }
}

@media (max-width: 680px) {
    .portal-hero { padding: 48px 0 42px; }
    .portal-hero-inner { align-items: flex-start; flex-direction: column; }
    .portal-shell { padding-top: 26px; padding-bottom: 48px; }
    .payment-summary { grid-template-columns: 1fr; }
    .payment-code { min-width: 0; }
    .payment-method { grid-template-columns: 1fr; }
    .portal-cta,
    .login-help { align-items: stretch; flex-direction: column; }
    .portal-cta a,
    .login-help a { width: 100%; }
    .login-choice,
    .status-form,
    .status-result { padding: 22px; border-radius: 20px; }
    .status-found dl div { grid-template-columns: 1fr; gap: 5px; }
    .status-found dd { text-align: left; }
}

@media (prefers-reduced-motion: reduce) {
    .portal-orb { animation: none; }
    .payment-method,
    .portal-cta a,
    .login-choice a,
    .login-help a { transition: none; }
}
