:root {
    --green: #2E865F;
    --green-d: #256E4E;
    --green-glow: rgba(46, 134, 95, 0.25);
    --mint: #C6F4D6;
    --bg: #F2FFF8;
    --ink: #13281F;
    --soft: #4A6358;
    --line: rgba(19, 40, 31, .12);
    --card-border: rgba(19, 40, 31, .08);
    --ease: cubic-bezier(.22, .8, .24, 1);
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html, body {
    height: 100%;
}

body {
    font-family: 'Inter', system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    color: var(--ink);
    background: #fff;
    display: grid;
    grid-template-columns: 1.15fr 1fr;
    min-height: 100vh;
    -webkit-font-smoothing: antialiased;
}

/* ---------- Left: visual panel ---------- */
.gw-visual {
    position: relative;
    overflow: hidden;
    color: #fff;
    background: var(--ink) url('/assets/finance-bg.jpg') center/cover no-repeat;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    padding: 48px 56px;
}

.gw-visual::before {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(160deg, rgba(19,40,31,.25) 0%, rgba(19,40,31,.45) 45%, rgba(15,46,33,.92) 100%);
}

.gw-visual > * {
    position: relative;
    z-index: 1;
}

.visual-header {
    display: flex;
    align-items: center;
}

.portal-badge {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    font-size: 0.85rem;
    font-weight: 500;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: var(--mint);
    padding: 8px 16px;
    background: rgba(19, 40, 31, 0.45);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    border: 1px solid rgba(198, 244, 214, 0.2);
    border-radius: 999px;
}

.gw-tagline {
    max-width: 480px;
    animation: rise .9s var(--ease) both .1s;
}

.gw-tagline h2 {
    font-family: 'Inter Tight', sans-serif;
    font-weight: 500;
    font-size: clamp(2rem, 3.4vw, 3rem);
    line-height: 1.05;
    letter-spacing: -.04em;
    margin-bottom: 16px;
}

.gw-tagline h2 em {
    font-style: normal;
    color: var(--mint);
}

.gw-tagline p {
    color: rgba(255,255,255,.82);
    font-size: 1rem;
    line-height: 1.6;
}

.gw-points {
    display: flex;
    gap: 28px;
    margin-top: 34px;
    font-size: .84rem;
    color: rgba(255,255,255,.85);
    flex-wrap: wrap;
}

.gw-points span {
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.gw-points svg {
    color: var(--mint);
    flex-shrink: 0;
}

/* ---------- Right: form panel ---------- */
.gw-panel {
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    padding: 48px 64px;
    background: #fff;
}

.gw-panel-top {
    display: flex;
    justify-content: flex-end;
    align-items: center;
}

.top-indicator {
    display: flex;
    align-items: center;
}

.gw-lock {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-size: .78rem;
    color: var(--soft);
    padding: 7px 15px;
    border: 1px solid var(--line);
    border-radius: 999px;
    background: #fafcfb;
}

.gw-lock i {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: var(--green);
    box-shadow: 0 0 0 4px rgba(46,134,95,.15);
    display: inline-block;
    animation: pulse-dot 2.5s infinite ease-in-out;
}

@keyframes pulse-dot {
    0%, 100% { transform: scale(1); opacity: 1; }
    50% { transform: scale(1.3); opacity: 0.75; }
}

.gw-form-wrap {
    max-width: 480px;
    width: 100%;
    animation: rise .9s var(--ease) both .2s;
}

.gateway-icon-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 56px;
    height: 56px;
    border-radius: 16px;
    background: var(--bg);
    color: var(--green);
    border: 1px solid rgba(46, 134, 95, 0.18);
    margin-bottom: 28px;
    box-shadow: 0 4px 12px rgba(46, 134, 95, 0.08);
}

.gw-eyebrow {
    font-size: .72rem;
    letter-spacing: .14em;
    text-transform: uppercase;
    color: var(--green);
    font-weight: 600;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 12px;
}

.gw-eyebrow::before {
    content: "";
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: currentColor;
}

h1 {
    font-family: 'Inter Tight', sans-serif;
    font-weight: 500;
    font-size: clamp(2rem, 3vw, 2.5rem);
    letter-spacing: -.04em;
    line-height: 1.1;
    margin-bottom: 12px;
}

.gw-lead {
    color: var(--soft);
    font-size: 1rem;
    line-height: 1.6;
    margin-bottom: 28px;
}

/* Verification Card */
.verification-box {
    background: #ffffff;
    border: 1px solid var(--line);
    border-radius: 20px;
    padding: 24px;
    box-shadow: 0 4px 20px -2px rgba(19, 40, 31, 0.05);
    transition: all 0.3s var(--ease);
}

.verification-box:focus-within {
    border-color: var(--green);
    box-shadow: 0 8px 30px -4px rgba(46, 134, 95, 0.12);
}

.turnstile-container {
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 65px;
    margin-bottom: 16px;
}

/* Status indicator */
.status-box {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: .84rem;
    padding: 10px 14px;
    border-radius: 12px;
    margin-bottom: 20px;
    transition: all .3s var(--ease);
}

.status-box.pending {
    background: #f6f8f7;
    color: var(--soft);
    border: 1px solid rgba(19, 40, 31, 0.06);
}

.status-box.success {
    background: var(--bg);
    color: var(--green-d);
    border: 1px solid rgba(46, 134, 95, 0.2);
    font-weight: 500;
}

.status-box.error {
    background: #fff2f2;
    color: #c0392b;
    border: 1px solid rgba(192, 57, 43, 0.2);
}

.status-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.spinner {
    animation: spin 1s linear infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* Action button */
.btn-wrap {
    display: flex;
    flex-direction: column;
}

.gw-btn {
    width: 100%;
    border: 0;
    cursor: pointer;
    font: inherit;
    font-weight: 600;
    font-size: 1rem;
    color: #fff;
    background: var(--green);
    padding: 16px 28px;
    border-radius: 999px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    transition: all .25s var(--ease);
    text-decoration: none;
    box-shadow: 0 4px 14px rgba(46, 134, 95, 0.28);
}

.gw-btn:not(.is-disabled):hover {
    background: var(--green-d);
    transform: translateY(-1px);
    box-shadow: 0 6px 20px rgba(46, 134, 95, 0.38);
}

.gw-btn svg.arrow-icon {
    transition: transform .3s var(--ease);
}

.gw-btn:not(.is-disabled):hover svg.arrow-icon {
    transform: translateX(4px);
}

.gw-btn.is-disabled {
    background: #d8e2dc;
    color: #83978e;
    cursor: not-allowed;
    box-shadow: none;
}

.gw-btn.is-redirecting {
    background: var(--green-d);
    pointer-events: none;
}

.gw-help {
    margin-top: 24px;
    font-size: .84rem;
    color: var(--soft);
}

.gw-foot {
    display: flex;
    justify-content: space-between;
    gap: 20px;
    font-size: .76rem;
    color: var(--soft);
    opacity: .85;
    flex-wrap: wrap;
    padding-top: 20px;
    border-top: 1px solid rgba(19, 40, 31, .06);
}

@keyframes rise {
    from { opacity: 0; transform: translateY(14px); }
    to { opacity: 1; transform: none; }
}

/* ---------- Responsive ---------- */
@media (max-width: 960px) {
    body {
        grid-template-columns: 1fr;
        grid-template-rows: auto 1fr;
    }
    .gw-visual {
        min-height: 200px;
        padding: 28px 24px;
    }
    .gw-tagline h2 {
        font-size: 1.6rem;
    }
    .gw-tagline p, .gw-points {
        display: none;
    }
    .gw-panel {
        padding: 32px 24px;
        gap: 32px;
    }
}

@media (max-width: 480px) {
    .gw-visual {
        min-height: 160px;
        padding: 20px 18px;
    }
    .gw-panel {
        padding: 24px 16px;
    }
    .verification-box {
        padding: 18px 14px;
    }
    .gw-lock {
        font-size: .72rem;
        padding: 5px 10px;
    }
}

@media (prefers-reduced-motion: reduce) {
    * { animation: none !important; }
}
