/* =============================================
   Auth (Login / Register) — CSS
   ============================================= */

/* ---------- CSS Custom Properties ---------- */
:root {
    --auth-primary:           #002046;
    --auth-secondary:         #775a19;
    --auth-secondary-fixed:   #ffdea5;
    --auth-surface:           #faf9fd;
    --auth-surface-lowest:    #ffffff;
    --auth-surface-low:       #f4f3f7;
    --auth-surface-container: #efedf1;
    --auth-surface-high:      #e9e7eb;
    --auth-surface-highest:   #e3e2e6;
    --auth-on-surface:        #1a1b1e;
    --auth-on-surface-var:    #44474e;
    --auth-outline-var:       #c4c6cf;
    --auth-outline:           #74777f;
    --auth-error:             #ba1a1a;
}

/* ---------- Base ---------- */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html, body {
    height: 100%;
    font-family: 'Manrope', sans-serif;
    background-color: var(--auth-surface);
    color: var(--auth-on-surface);
    -webkit-font-smoothing: antialiased;
}

/* ---------- Material Symbols ---------- */
.material-symbols-outlined {
    font-variation-settings: 'FILL' 0, 'wght' 400, 'GRAD' 0, 'opsz' 24;
}

/* ---------- Page Wrapper ---------- */
.auth-page {
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

/* ======================================================
   TOP NAVIGATION BAR
====================================================== */
.auth-topnav {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 50;
    background: rgba(250, 249, 253, 0.85);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-bottom: 1px solid var(--auth-surface-highest);
    box-shadow: 0 2px 24px -4px rgba(0, 32, 70, 0.06);
}

.auth-topnav__inner {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1.125rem 2rem;
    max-width: 100%;
}

/* Brand */
.auth-topnav__brand {
    font-size: 1.125rem;
    font-weight: 900;
    letter-spacing: -0.04em;
    color: var(--auth-primary);
    text-decoration: none;
    font-family: 'Manrope', sans-serif;
    flex-shrink: 0;
}

/* Middle links */
.auth-topnav__links {
    display: none;
    gap: 2rem;
    align-items: center;
}

@media (min-width: 768px) {
    .auth-topnav__links {
        display: flex;
    }
}

.auth-topnav__link {
    font-size: 0.625rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.15em;
    color: var(--auth-outline);
    text-decoration: none;
    padding-bottom: 0.125rem;
    border-bottom: 2px solid transparent;
    transition: color 0.2s ease, border-color 0.2s ease;
}

.auth-topnav__link:hover {
    color: var(--auth-secondary);
}

.auth-topnav__link--active {
    color: var(--auth-primary);
    font-weight: 800;
    border-bottom-color: var(--auth-secondary);
}

/* Right: icons */
.auth-topnav__actions {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.auth-topnav__icon-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    background: none;
    border: none;
    cursor: pointer;
    color: var(--auth-outline);
    padding: 0.375rem;
    border-radius: 50%;
    transition: color 0.2s ease, background-color 0.2s ease;
}

.auth-topnav__icon-btn:hover {
    color: var(--auth-secondary);
    background-color: var(--auth-surface-container);
}

/* Language dropdown */
.auth-topnav__lang {
    position: relative;
}

.auth-topnav__lang-menu {
    position: absolute;
    top: calc(100% + 0.5rem);
    right: 0;
    background: var(--auth-surface-lowest);
    border: 1px solid var(--auth-surface-highest);
    border-radius: 0.5rem;
    box-shadow: 0 8px 24px -4px rgba(0, 32, 70, 0.12);
    min-width: 9rem;
    overflow: hidden;
    z-index: 100;
}

.auth-topnav__lang-item {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.75rem 1rem;
    font-size: 0.75rem;
    font-weight: 600;
    color: var(--auth-on-surface-var);
    text-decoration: none;
    transition: background-color 0.15s ease, color 0.15s ease;
}

.auth-topnav__lang-item:hover {
    background-color: var(--auth-surface-container);
    color: var(--auth-primary);
}

.auth-topnav__lang-item--active {
    color: var(--auth-secondary);
    font-weight: 800;
    background-color: var(--auth-surface-low);
}

/* ---- Adjust main content below fixed nav ---- */
.auth-main {
    display: flex;
    flex-direction: column;
    flex: 1;
    overflow: hidden;
    padding-top: 3.5rem; /* nav height compensation */
}

@media (min-width: 768px) {
    .auth-main {
        flex-direction: row;
        height: 100vh;
        padding-top: 3.5rem;
    }
}

/* ======================================================
   LEFT PANEL — Form
====================================================== */
.auth-form-panel {
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 2rem;
    background-color: var(--auth-surface-lowest);
    position: relative;
    overflow-y: auto;
}

@media (min-width: 768px) {
    .auth-form-panel {
        width: 50%;
        padding: 3rem;
    }
}

/* Brand logo (top-left) */
.auth-brand {
    position: absolute;
    top: 3rem;
    left: 3rem;
    font-size: 1.5rem;
    font-weight: 900;
    letter-spacing: -0.05em;
    color: var(--auth-primary);
    text-decoration: none;
    font-family: 'Manrope', sans-serif;
}

/* Form container */
.auth-form-container {
    width: 100%;
    max-width: 26rem;
    display: flex;
    flex-direction: column;
    gap: 1.25rem;
}

/* Form header */
.auth-header__label {
    display: block;
    font-size: 0.625rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.15em;
    color: var(--auth-secondary);
    margin-bottom: 0.75rem;
}

.auth-header__title {
    font-size: 2.5rem;
    font-weight: 800;
    color: var(--auth-primary);
    letter-spacing: -0.04em;
    line-height: 1;
    font-family: 'Manrope', sans-serif;
}

.auth-header__subtitle {
    font-size: 1.125rem;
    font-weight: 500;
    color: var(--auth-on-surface-var);
    line-height: 1.6;
    margin-top: 0.75rem;
}

/* Form fields */
.auth-form {
    display: flex;
    flex-direction: column;
    gap: 2rem;
}

.auth-fields {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.auth-field__label {
    display: block;
    font-size: 0.625rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: var(--auth-on-surface-var);
    margin-bottom: 0.5rem;
    margin-left: 0.25rem;
}

/* .auth-field__input legacy — yeni .lp-field__input (inline _form.php)
   tarafından ezildi. Hiçbir şey tanımlamıyoruz, aksi halde pad-left ve
   border-bottom çakışıyor ve form alanlarındaki sol ikonları gizliyordu. */

/* Remember me + Forgot */
.auth-meta {
    display: flex;
    align-items: center;
    justify-content: space-between;
    font-size: 0.875rem;
}

.auth-remember {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    cursor: pointer;
}

.auth-remember__checkbox {
    position: relative;
    display: flex;
    align-items: center;
}

.auth-remember__checkbox input[type="checkbox"] {
    appearance: none;
    width: 1.25rem;
    height: 1.25rem;
    border: 2px solid var(--auth-surface-highest);
    border-radius: 0.375rem;
    background: transparent;
    cursor: pointer;
    transition: background-color 0.2s ease, border-color 0.2s ease;
}

.auth-remember__checkbox input:checked {
    background-color: var(--auth-primary);
    border-color: var(--auth-primary);
}

.auth-remember__check-icon {
    position: absolute;
    left: 0.25rem;
    font-size: 0.75rem;
    color: #ffffff;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.2s ease;
    font-variation-settings: 'FILL' 0, 'wght' 700, 'GRAD' 0, 'opsz' 20;
}

.auth-remember__checkbox input:checked ~ .auth-remember__check-icon {
    opacity: 1;
}

.auth-remember__text {
    font-weight: 500;
    color: var(--auth-on-surface-var);
    transition: color 0.2s ease;
}

.auth-remember:hover .auth-remember__text {
    color: var(--auth-primary);
}

.auth-forgot {
    font-weight: 700;
    color: var(--auth-secondary);
    text-decoration: none;
    text-underline-offset: 4px;
    text-decoration-thickness: 2px;
    transition: text-decoration 0.2s ease;
}

.auth-forgot:hover {
    text-decoration: underline;
}

/* Submit button */
.auth-submit-btn {
    width: 100%;
    padding: 1.25rem;
    background: linear-gradient(135deg, #775a19 0%, #a67c25 100%);
    color: #ffffff;
    font-family: 'Manrope', sans-serif;
    font-weight: 700;
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.15em;
    border: none;
    border-radius: 0.25rem;
    cursor: pointer;
    box-shadow: 0 20px 40px -10px rgba(119, 90, 25, 0.25);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.auth-submit-btn:hover {
    transform: scale(1.02);
    box-shadow: 0 24px 48px -10px rgba(119, 90, 25, 0.35);
}

.auth-submit-btn:active {
    transform: scale(0.95);
}

/* Form footer (register link) */
.auth-form-footer {
    padding-top: 2rem;
    text-align: center;
    border-top: 1px solid var(--auth-surface-container);
}

.auth-form-footer p {
    font-weight: 500;
    color: var(--auth-on-surface-var);
}

.auth-form-footer__link {
    font-weight: 800;
    color: var(--auth-primary);
    text-decoration: none;
    margin-left: 0.25rem;
    transition: color 0.2s ease;
}

.auth-form-footer__link:hover {
    color: var(--auth-secondary);
}

/* ======================================================
   RIGHT PANEL — Promo
====================================================== */
.auth-promo-panel {
    display: none;
    position: relative;
    overflow: hidden;
    background-color: var(--auth-primary);
}

@media (min-width: 768px) {
    .auth-promo-panel {
        display: flex;
        width: 50%;
    }
}

.auth-promo__image {
    position: absolute;
    inset: 0;
    z-index: 0;
    transform: scale(1.1);
}

.auth-promo__image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    mix-blend-mode: overlay;
    opacity: 0.6;
    filter: grayscale(1);
    transition: filter 2s ease;
}

.auth-promo__image img:hover {
    filter: grayscale(0);
}

.auth-promo__gradient {
    position: absolute;
    inset: 0;
    background: linear-gradient(to top right, var(--auth-primary), rgba(0, 32, 70, 0.8), transparent);
    z-index: 1;
}

.auth-promo__content {
    position: relative;
    z-index: 2;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    padding: 6rem;
    color: #ffffff;
    width: 100%;
    height: 100%;
    gap: 1.5rem;
}

.auth-promo__badge {
    display: inline-block;
    padding: 0.25rem 1rem;
    border: 1px solid rgba(255, 222, 164, 0.5);
    border-radius: 9999px;
    color: var(--auth-secondary-fixed);
    text-transform: uppercase;
    letter-spacing: 0.15em;
    font-size: 0.625rem;
    font-weight: 700;
    backdrop-filter: blur(12px);
    width: fit-content;
}

.auth-promo__title {
    font-size: clamp(3rem, 5vw, 4rem);
    font-weight: 900;
    letter-spacing: -0.05em;
    line-height: 0.9;
    font-family: 'Manrope', sans-serif;
}

.auth-promo__text {
    font-size: 1.125rem;
    color: rgba(219, 234, 254, 0.8);
    font-weight: 500;
    line-height: 1.6;
    max-width: 28rem;
}

/* Stats */
.auth-promo__stats {
    display: flex;
    gap: 3rem;
    padding-top: 3rem;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.auth-stat__value {
    font-weight: 900;
    font-size: 1.5rem;
    color: var(--auth-secondary-fixed);
    letter-spacing: -0.04em;
    line-height: 1;
    font-family: 'Manrope', sans-serif;
}

.auth-stat__label {
    font-size: 0.625rem;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: rgba(191, 219, 254, 0.6);
    font-weight: 700;
    margin-top: 0.25rem;
}

/* Premium badge (top-right circle) */
.auth-promo__premium-badge {
    position: absolute;
    top: 3rem;
    right: 3rem;
    z-index: 2;
}

.auth-promo__premium-outer {
    width: 8rem;
    height: 8rem;
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 9999px;
    display: flex;
    align-items: center;
    justify-content: center;
    backdrop-filter: blur(4px);
}

.auth-promo__premium-inner {
    width: 6rem;
    height: 6rem;
    border: 1px solid rgba(255, 222, 164, 0.3);
    border-radius: 9999px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.auth-promo__premium-inner .material-symbols-outlined {
    font-size: 2.5rem;
    color: var(--auth-secondary-fixed);
    font-variation-settings: 'FILL' 0, 'wght' 200, 'GRAD' 0, 'opsz' 48;
}

/* ======================================================
   BOTTOM FOOTER BAR
====================================================== */
.auth-footer-bar {
    background-color: var(--auth-surface-low);
    width: 100%;
    padding: 2rem 0;
    flex-shrink: 0;
}

.auth-footer-bar__inner {
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    align-items: center;
    padding: 0 3rem;
    max-width: 1536px;
    margin: 0 auto;
    gap: 1rem;
}

@media (min-width: 768px) {
    .auth-footer-bar__inner {
        flex-direction: row;
        gap: 0;
    }
}

.auth-footer-bar__copy {
    font-size: 0.625rem;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    font-weight: 500;
    color: rgba(0, 32, 70, 0.6);
}

.auth-footer-bar__links {
    display: flex;
    gap: 2rem;
}

.auth-footer-bar__link {
    font-size: 0.625rem;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    font-weight: 700;
    color: rgba(0, 32, 70, 0.6);
    text-decoration: none;
    transition: color 0.2s ease;
}

.auth-footer-bar__link:hover {
    color: var(--auth-secondary);
}

/* ======================================================
   Error / Alert
====================================================== */
.auth-alert {
    padding: 0.75rem 1rem;
    border-radius: 0.25rem;
    font-size: 0.875rem;
    font-weight: 600;
}

.auth-alert--error {
    background-color: #ffdad6;
    color: #93000a;
    border-left: 3px solid var(--auth-error);
}

.auth-alert--success {
    background-color: #c8f0ca;
    color: #003910;
    border-left: 3px solid #2d6a33;
}

/* ======================================================
   REGISTER — Glassmorphism Accent Card
====================================================== */
.register-glass-card {
    position: absolute;
    bottom: 3rem;
    right: 3rem;
    z-index: 3;
    padding: 1.5rem;
    background: rgba(255, 255, 255, 0.05);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 0.5rem;
    text-align: center;
    transition: transform 0.3s ease;
}

.register-glass-card:hover {
    transform: translateY(-4px);
}

/* Register promo — gold diagonal gradient */
.auth-promo-panel--register .auth-promo__gradient {
    background: linear-gradient(135deg, rgba(0,32,70,0.98) 0%, rgba(27,54,93,0.92) 50%, rgba(0,32,70,0.6) 100%);
}

/* Terms checkbox */
.auth-terms {
    display: flex;
    align-items: flex-start;
    gap: 0.75rem;
    margin-top: 2rem;
}

.auth-terms input[type="checkbox"] {
    appearance: none;
    -webkit-appearance: none;
    width: 1.25rem;
    height: 1.25rem;
    min-width: 1.25rem;
    border: 2px solid var(--auth-surface-highest);
    border-radius: 0.25rem;
    background: transparent;
    cursor: pointer;
    transition: background-color 0.2s ease, border-color 0.2s ease;
    margin-top: 0.125rem;
}

.auth-terms input[type="checkbox"]:checked {
    background-color: var(--auth-secondary);
    border-color: var(--auth-secondary);
}

.auth-terms .auth-remember__text {
    font-size: 0.875rem;
    line-height: 1.5;
}
