@import url('https://fonts.googleapis.com/css2?family=Cormorant+Garamond:wght@400;500;600;700&family=DM+Sans:wght@300;400;500;600&display=swap');

:root {
    --navy: #0f1c2e;
    --navy-mid: #1a2f4a;
    --navy-light: #243d5c;
    --gold: #c9a84c;
    --gold-light: #e8c97e;
    --gold-pale: #f5e9c8;
    --cream: #faf8f3;
    --slate: #6b7c93;
    --white: #ffffff;
    --error: #c0392b;
    --shadow-deep: 0 40px 80px rgba(15, 28, 46, 0.35), 0 8px 24px rgba(15, 28, 46, 0.2);
    --shadow-card: 0 2px 8px rgba(15, 28, 46, 0.08);
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    background: var(--navy);
    min-height: 100vh;
}

.login-page {
    min-height: 100vh;
    display: grid;
    grid-template-columns: 1fr 1fr;
    position: relative;
    overflow: hidden;
}

/* ── LEFT PANEL ────────────────────────────── */
.left-panel {
    background: linear-gradient(160deg, var(--navy) 0%, var(--navy-mid) 50%, #0d2340 100%);
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: 4rem 3.5rem;
    position: relative;
    overflow: hidden;
}

.left-panel::before {
    content: '';
    position: absolute;
    top: -120px;
    left: -120px;
    width: 480px;
    height: 480px;
    background: radial-gradient(circle, rgba(201, 168, 76, 0.12) 0%, transparent 70%);
    animation: pulse-glow 6s ease-in-out infinite;
}

.left-panel::after {
    content: '';
    position: absolute;
    bottom: -80px;
    right: -80px;
    width: 320px;
    height: 320px;
    background: radial-gradient(circle, rgba(201, 168, 76, 0.08) 0%, transparent 70%);
    animation: pulse-glow 8s ease-in-out infinite reverse;
}

@keyframes pulse-glow {

    0%,
    100% {
        transform: scale(1);
        opacity: 1;
    }

    50% {
        transform: scale(1.1);
        opacity: 0.7;
    }
}

/* Geometric lines */
.geo-lines {
    position: absolute;
    inset: 0;
    overflow: hidden;
    pointer-events: none;
}

.geo-lines svg {
    position: absolute;
    width: 100%;
    height: 100%;
    opacity: 0.07;
}

.brand-logo {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: 4rem;
    position: relative;
    z-index: 2;
    animation: fadeSlideRight 0.9s cubic-bezier(0.22, 1, 0.36, 1) both;
}

.logo-mark {
    width: 44px;
    height: 44px;
    background: linear-gradient(135deg, var(--gold), var(--gold-light));
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: 'Cormorant Garamond', serif;
    font-weight: 700;
    font-size: 1.4rem;
    color: var(--navy);
    box-shadow: 0 4px 16px rgba(201, 168, 76, 0.4);
}

.logo-name {
    font-family: 'Cormorant Garamond', serif;
    font-size: 1.4rem;
    font-weight: 600;
    color: var(--white);
    letter-spacing: 0.5px;
}

.panel-headline {
    position: relative;
    z-index: 2;
    animation: fadeSlideRight 0.9s cubic-bezier(0.22, 1, 0.36, 1) 0.15s both;
}

.panel-headline h1 {
    font-family: 'Cormorant Garamond', serif;
    font-size: clamp(2.2rem, 3.5vw, 3.2rem);
    font-weight: 600;
    color: var(--white);
    line-height: 1.2;
    margin-bottom: 1.25rem;
}

.panel-headline h1 span {
    color: var(--gold);
    display: block;
}

.panel-headline p {
    color: rgba(255, 255, 255, 0.55);
    font-size: 0.95rem;
    line-height: 1.75;
    max-width: 360px;
    font-weight: 300;
}

.divider-line {
    width: 60px;
    height: 2px;
    background: linear-gradient(90deg, var(--gold), transparent);
    margin: 1.75rem 0;
}

.feature-list {
    position: relative;
    z-index: 2;
    margin-top: 3rem;
    display: flex;
    flex-direction: column;
    gap: 1rem;
    animation: fadeSlideRight 0.9s cubic-bezier(0.22, 1, 0.36, 1) 0.3s both;
}

.feature-item {
    display: flex;
    align-items: center;
    gap: 0.875rem;
}

.feature-dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: var(--gold);
    flex-shrink: 0;
    box-shadow: 0 0 8px rgba(201, 168, 76, 0.6);
}

.feature-item span {
    color: rgba(255, 255, 255, 0.5);
    font-size: 0.88rem;
    font-weight: 400;
    letter-spacing: 0.3px;
}

/* ── RIGHT PANEL ────────────────────────────── */
.right-panel {
    background: var(--cream);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 3rem 2.5rem;
    position: relative;
}

.right-panel::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, var(--gold), var(--gold-light), var(--gold));
}

.login-card {
    width: 100%;
    max-width: 420px;
    animation: fadeSlideUp 0.9s cubic-bezier(0.22, 1, 0.36, 1) 0.1s both;
}

.card-header {
    margin-bottom: 2.5rem;
}

.card-header h2 {
    font-family: 'Cormorant Garamond', serif;
    font-size: 2.1rem;
    font-weight: 600;
    color: var(--navy);
    margin-bottom: 0.4rem;
    letter-spacing: -0.3px;
}

.card-header p {
    color: var(--slate);
    font-size: 0.88rem;
    font-weight: 400;
}

.card-header-rule {
    width: 40px;
    height: 2px;
    background: var(--gold);
    margin-top: 1rem;
}

/* Alert */
.alert-box {
    background: #fdf0ef;
    border-left: 3px solid var(--error);
    border-radius: 6px;
    padding: 0.75rem 1rem;
    margin-bottom: 1.5rem;
    font-size: 0.85rem;
    color: var(--error);
    display: none;
}

/* Form fields */
.field-group {
    margin-bottom: 1.4rem;
}

.field-label {
    display: block;
    font-size: 0.78rem;
    font-weight: 600;
    color: var(--navy);
    letter-spacing: 0.8px;
    text-transform: uppercase;
    margin-bottom: 0.5rem;
}

.field-wrap {
    position: relative;
}

.field-input {
    width: 100%;
    border: 1.5px solid #dde3ec;
    border-radius: 8px;
    padding: 0.78rem 2.8rem 0.78rem 1rem;
    font-family: 'DM Sans', sans-serif;
    font-size: 0.92rem;
    color: var(--navy);
    background: var(--white);
    outline: none;
    transition: border-color 0.25s, box-shadow 0.25s, background 0.25s;
    -webkit-appearance: none;
}

.field-input::placeholder {
    color: #b0bac8;
    font-weight: 300;
}

.field-input:hover {
    border-color: #b8c3d4;
}

.field-input:focus {
    border-color: var(--gold);
    box-shadow: 0 0 0 3px rgba(201, 168, 76, 0.14);
    background: #fffdf7;
}

.field-input.error {
    border-color: var(--error);
    box-shadow: 0 0 0 3px rgba(192, 57, 43, 0.1);
}

.field-icon {
    position: absolute;
    right: 0.875rem;
    top: 50%;
    transform: translateY(-50%);
    color: #b0bac8;
    font-size: 0.95rem;
    cursor: pointer;
    transition: color 0.2s;
    user-select: none;
}

.field-input:focus~.field-icon {
    color: var(--gold);
}

.field-error {
    font-size: 0.78rem;
    color: var(--error);
    margin-top: 0.35rem;
    display: none;
}

/* Forgot */
.forgot-row {
    display: flex;
    justify-content: flex-end;
    margin-bottom: 1.75rem;
}

.forgot-link {
    font-size: 0.82rem;
    color: #392a00;
    text-decoration: none;
    font-weight: 500;
    letter-spacing: 0.2px;
    transition: color 0.2s;
}

.forgot-link:hover {
    color: #a8872e;
    text-decoration: underline;
}

/* Submit button */
.submit-btn {
    width: 100%;
    padding: 0.9rem;
    background: var(--navy);
    color: var(--white);
    border: none;
    border-radius: 8px;
    font-family: 'DM Sans', sans-serif;
    font-size: 0.92rem;
    font-weight: 600;
    letter-spacing: 0.8px;
    text-transform: uppercase;
    cursor: pointer;
    position: relative;
    overflow: hidden;
    transition: background 0.3s, transform 0.2s, box-shadow 0.3s;
}

.submit-btn::after {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, transparent 40%, rgba(201, 168, 76, 0.15));
    opacity: 0;
    transition: opacity 0.3s;
}

.submit-btn:hover {
    background: var(--navy-mid);
    transform: translateY(-2px);
    box-shadow: 0 10px 28px rgba(15, 28, 46, 0.25);
}

.submit-btn:hover::after {
    opacity: 1;
}

.submit-btn:active {
    transform: translateY(0);
}

.submit-btn:disabled {
    opacity: 0.7;
    cursor: not-allowed;
    transform: none;
}

.btn-inner {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
}

/* Spinner */
.spinner {
    width: 16px;
    height: 16px;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-top-color: white;
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
    display: none;
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

/* Register link */
.register-row {
    text-align: center;
    margin-top: 1.75rem;
    padding-top: 1.5rem;
    border-top: 1px solid #e8edf4;
    font-size: 0.87rem;
    color: var(--slate);
}

.register-row a {
    color: var(--navy);
    font-weight: 600;
    text-decoration: none;
    border-bottom: 1.5px solid var(--gold);
    padding-bottom: 1px;
    transition: color 0.2s;
}

.register-row a:hover {
    color: var(--gold);
}

/* Security badge */
.security-badge {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.4rem;
    margin-top: 1.5rem;
    color: #aab4c2;
    font-size: 0.78rem;
}

.security-badge i {
    font-size: 0.7rem;
    color: #c6cdd8;
}

/* ── ANIMATIONS ────────────────────────────── */
@keyframes fadeSlideRight {
    from {
        opacity: 0;
        transform: translateX(-30px);
    }

    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes fadeSlideUp {
    from {
        opacity: 0;
        transform: translateY(24px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* ── RESPONSIVE ────────────────────────────── */
@media (max-width: 900px) {
    .login-page {
        grid-template-columns: 1fr;
        grid-template-rows: auto 1fr;
    }

    .left-panel {
        padding: 2.5rem 2rem;
        min-height: auto;
    }

    .panel-headline h1 {
        font-size: 2rem;
    }

    .feature-list {
        flex-direction: row;
        flex-wrap: wrap;
        gap: 0.75rem;
        margin-top: 1.75rem;
    }

    .brand-logo {
        margin-bottom: 2rem;
    }

    .right-panel {
        padding: 2.5rem 1.5rem;
    }
}

@media (max-width: 480px) {
    .left-panel {
        padding: 1rem 1.5rem;
        margin-top: 27px;
    }

    .right-panel {
        padding: 1.5rem 1.5rem;
    }

    .feature-list {
        display: none;
    }

    .panel-headline p {
        display: none;
    }

    .panel-headline h1 {
        margin-top: 12px;
    }
}