/* ==========================================================================
   LOGIN & REGISTER — PAGE-SPECIFIC STYLES
   Shared project foundation: /assets/css/base.css
   ========================================================================== */

/* =========================================
   GLOBAL
   ========================================= */
body {
    background: #f0f2f8;
    overflow-x: hidden;
    min-height: 100vh;
}

/* Dot grid background */
body::before {
    content: '';
    position: fixed;
    inset: 0;
    background-image: radial-gradient(rgba(33, 40, 66, 0.18) 1px, transparent 1px);
    background-size: 28px 28px;
    opacity: 0.12;
    z-index: -1;
    pointer-events: none;
    mask-image: linear-gradient(to bottom, black 0%, transparent 70%);
    -webkit-mask-image: linear-gradient(to bottom, black 0%, transparent 70%);
}

/* =========================================
   DECORATIVE ORBS
   ========================================= */
.auth-orb {
    position: fixed;
    border-radius: 50%;
    filter: blur(80px);
    pointer-events: none;
    z-index: 0;
    animation: orbFloat 8s ease-in-out infinite;
}

.auth-orb-1 {
    width: 480px;
    height: 480px;
    background: radial-gradient(circle, rgba(33, 40, 66, 0.12) 0%, transparent 70%);
    top: -100px;
    left: -120px;
}

.auth-orb-2 {
    width: 360px;
    height: 360px;
    background: radial-gradient(circle, rgba(79, 93, 122, 0.1) 0%, transparent 70%);
    bottom: 80px;
    right: -80px;
    animation-delay: -4s;
}

@keyframes orbFloat {
    0%, 100% { transform: translateY(0) scale(1); }
    50% { transform: translateY(-30px) scale(1.05); }
}

/* =========================================
   WRAPPER
   ========================================= */
.auth-wrapper {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 120px 24px 60px;
    position: relative;
    z-index: 1;
}

/* =========================================
   CONTAINER — 2-COLUMN LAYOUT
   ========================================= */
.auth-container {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 32px;
    max-width: 1040px;
    width: 100%;
    align-items: stretch;
}

/* =========================================
   SHARED PANEL BASE
   ========================================= */
.auth-panel {
    border-radius: 28px;
    overflow: hidden;
}

/* =========================================
   INFO PANEL (left)
   ========================================= */
.auth-info {
    background: linear-gradient(145deg, #212842 0%, #1a2038 60%, #2d3654 100%);
    padding: 48px 44px;
    display: flex;
    flex-direction: column;
    gap: 36px;
    position: relative;
    overflow: hidden;
    box-shadow: 0 24px 60px rgba(33, 40, 66, 0.3), inset 0 1px 0 rgba(255, 255, 255, 0.06);
}

/* Subtle animated inner glow */
.auth-info::before {
    content: '';
    position: absolute;
    top: -40%;
    right: -30%;
    width: 500px;
    height: 500px;
    background: radial-gradient(circle, rgba(255, 255, 255, 0.04) 0%, transparent 60%);
    border-radius: 50%;
    animation: infoGlow 12s ease-in-out infinite;
}

.auth-info::after {
    content: '';
    position: absolute;
    bottom: -20%;
    left: -20%;
    width: 350px;
    height: 350px;
    background: radial-gradient(circle, rgba(79, 93, 122, 0.15) 0%, transparent 60%);
    border-radius: 50%;
    animation: infoGlow 12s ease-in-out infinite reverse;
}

@keyframes infoGlow {
    0%, 100% { transform: scale(1) translate(0, 0); }
    50% { transform: scale(1.1) translate(20px, -20px); }
}

/* Brand */
.auth-brand {
    display: flex;
    flex-direction: column;
    gap: 6px;
    position: relative;
    z-index: 1;
}

.auth-brand-logo {
    font-size: 1.6rem;
    font-weight: 800;
    color: #ffffff;
    letter-spacing: -0.5px;
}

.auth-brand-tag {
    font-size: 0.72rem;
    font-weight: 600;
    color: rgba(255, 255, 255, 0.45);
    text-transform: uppercase;
    letter-spacing: 1.2px;
}

/* Headline */
.auth-headline {
    position: relative;
    z-index: 1;
}

.auth-title {
    font-size: 2.8rem;
    font-weight: 800;
    color: #ffffff;
    line-height: 1.15;
    letter-spacing: -1.5px;
    margin-bottom: 16px;
}

.auth-title-accent {
    background: linear-gradient(135deg, #a8b4d4 0%, #ffffff 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.auth-subtitle {
    font-size: 0.95rem;
    color: rgba(255, 255, 255, 0.6);
    line-height: 1.7;
    max-width: 320px;
}

/* Stats row */
.auth-stats {
    display: flex;
    align-items: center;
    gap: 24px;
    position: relative;
    z-index: 1;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 18px;
    padding: 20px 24px;
    backdrop-filter: blur(10px);
}

.auth-stat {
    display: flex;
    flex-direction: column;
    gap: 4px;
    flex: 1;
    text-align: center;
}

.auth-stat-val {
    font-size: 1.6rem;
    font-weight: 800;
    color: #ffffff;
    letter-spacing: -1px;
    line-height: 1;
}

.auth-stat-lbl {
    font-size: 0.68rem;
    font-weight: 600;
    color: rgba(255, 255, 255, 0.4);
    text-transform: uppercase;
    letter-spacing: 0.8px;
}

.auth-stat-divider {
    width: 1px;
    height: 36px;
    background: rgba(255, 255, 255, 0.12);
}

/* Testimonial */
.auth-testimonial {
    display: flex;
    align-items: flex-start;
    gap: 14px;
    position: relative;
    z-index: 1;
    margin-top: auto;
}

.auth-test-avatar {
    width: 44px;
    height: 44px;
    border-radius: 14px;
    background: rgba(255, 255, 255, 0.12);
    border: 1px solid rgba(255, 255, 255, 0.2);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.78rem;
    font-weight: 800;
    color: #fff;
    flex-shrink: 0;
}

.auth-test-body {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.auth-test-text {
    font-size: 0.875rem;
    color: rgba(255, 255, 255, 0.8);
    line-height: 1.6;
    font-style: italic;
}

.auth-test-name {
    font-size: 0.7rem;
    font-weight: 600;
    color: rgba(255, 255, 255, 0.4);
    letter-spacing: 0.3px;
}

/* =========================================
   FORM PANEL (right)
   ========================================= */
.auth-form-panel {
    background: rgba(255, 255, 255, 0.92);
    backdrop-filter: blur(24px);
    -webkit-backdrop-filter: blur(24px);
    border: 1.5px solid rgba(255, 255, 255, 0.95);
    box-shadow: 0 16px 56px rgba(33, 40, 66, 0.12), inset 0 1px 0 rgba(255, 255, 255, 0.9);
    padding: 40px 44px;
    display: flex;
    flex-direction: column;
    gap: 0;
}

/* =========================================
   TABS
   ========================================= */
.auth-tabs {
    display: flex;
    align-items: center;
    gap: 4px;
    background: rgba(33, 40, 66, 0.05);
    border: 1px solid rgba(33, 40, 66, 0.08);
    border-radius: var(--radius-full);
    padding: 5px;
    margin-bottom: 32px;
    position: relative;
}

.auth-tab {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 11px 20px;
    border-radius: var(--radius-full);
    border: none;
    background: transparent;
    font-family: inherit;
    font-size: 0.9rem;
    font-weight: 600;
    color: rgba(33, 40, 66, 0.45);
    cursor: pointer;
    transition: color var(--transition-base);
    position: relative;
    z-index: 1;
}

.auth-tab.active {
    color: #ffffff;
}

.auth-tab i {
    font-size: 0.8rem;
}

.auth-tab-indicator {
    position: absolute;
    top: 5px;
    left: 5px;
    height: calc(100% - 10px);
    width: calc(50% - 5px);
    background: linear-gradient(135deg, #212842, #2d3654);
    border-radius: var(--radius-full);
    box-shadow: 0 4px 16px rgba(33, 40, 66, 0.3);
    transition: transform var(--transition-base);
    z-index: 0;
}

.auth-tab-indicator.right {
    transform: translateX(calc(100% + 10px));
}

/* =========================================
   FORM
   ========================================= */
.auth-form {
    display: flex;
    flex-direction: column;
    gap: 20px;
    animation: formFadeIn 0.35s ease;
}

.auth-form.hidden {
    display: none;
}

@keyframes formFadeIn {
    from { opacity: 0; transform: translateY(12px); }
    to { opacity: 1; transform: translateY(0); }
}

.auth-form-header {
    display: flex;
    flex-direction: column;
    gap: 6px;
    margin-bottom: 4px;
}

.auth-form-title {
    font-size: 1.5rem;
    font-weight: 800;
    color: #212842;
    letter-spacing: -0.5px;
}

.auth-form-sub {
    font-size: 0.875rem;
    color: rgba(33, 40, 66, 0.5);
    line-height: 1.5;
}

/* Field group */
.auth-field-group {
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.auth-fields-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
}

.auth-field {
    display: flex;
    flex-direction: column;
    gap: 7px;
}

.auth-label {
    font-size: 0.8rem;
    font-weight: 700;
    color: #212842;
    letter-spacing: 0.2px;
}

/* Input wrapper */
.auth-input-wrap {
    position: relative;
    display: flex;
    align-items: center;
}

.auth-input-icon {
    position: absolute;
    left: 16px;
    color: rgba(33, 40, 66, 0.35);
    font-size: 0.85rem;
    pointer-events: none;
    transition: color var(--transition-fast);
    z-index: 1;
}

.auth-input {
    width: 100%;
    padding: 13px 44px 13px 42px;
    border: 1.5px solid rgba(33, 40, 66, 0.12);
    border-radius: 14px;
    background: rgba(248, 249, 255, 0.8);
    font-family: inherit;
    font-size: 0.9rem;
    font-weight: 500;
    color: #212842;
    outline: none;
    transition: all var(--transition-base);
}

.auth-input::placeholder {
    color: rgba(33, 40, 66, 0.3);
    font-weight: 400;
}

.auth-input:focus {
    border-color: #212842;
    background: rgba(255, 255, 255, 0.95);
    box-shadow: 0 0 0 4px rgba(33, 40, 66, 0.07), 0 4px 16px rgba(33, 40, 66, 0.06);
}

.auth-input:focus~.auth-input-icon,
.auth-input-wrap:focus-within .auth-input-icon {
    color: #212842;
}

/* Eye toggle btn */
.auth-eye-btn {
    position: absolute;
    right: 14px;
    background: none;
    border: none;
    padding: 4px;
    cursor: pointer;
    color: rgba(33, 40, 66, 0.3);
    font-size: 0.85rem;
    transition: color var(--transition-fast);
    display: flex;
    align-items: center;
    justify-content: center;
}

.auth-eye-btn:hover {
    color: #212842;
}

/* Password strength */
.auth-strength-bar {
    height: 4px;
    border-radius: 100px;
    background: rgba(33, 40, 66, 0.08);
    overflow: hidden;
    margin-top: 2px;
}

.auth-strength-fill {
    height: 100%;
    width: 0%;
    border-radius: 100px;
    transition: width 0.4s ease, background 0.4s ease;
}

.auth-strength-label {
    font-size: 0.7rem;
    font-weight: 600;
    color: rgba(33, 40, 66, 0.4);
    letter-spacing: 0.3px;
}

/* Row: remember / forgot */
.auth-row-between {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
}

/* Checkbox */
.auth-checkbox-wrap {
    display: flex;
    align-items: center;
    gap: 10px;
    cursor: pointer;
    user-select: none;
}

.auth-checkbox {
    display: none;
}

.auth-checkbox-custom {
    width: 18px;
    height: 18px;
    border: 1.5px solid rgba(33, 40, 66, 0.2);
    border-radius: 6px;
    background: rgba(248, 249, 255, 0.8);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    transition: all var(--transition-fast);
    position: relative;
}

.auth-checkbox:checked+.auth-checkbox-custom {
    background: #212842;
    border-color: #212842;
    box-shadow: 0 2px 8px rgba(33, 40, 66, 0.3);
}

.auth-checkbox:checked+.auth-checkbox-custom::after {
    content: '';
    width: 5px;
    height: 9px;
    border: 2px solid #fff;
    border-top: none;
    border-left: none;
    transform: rotate(42deg) translateY(-1px);
    position: absolute;
}

.auth-checkbox-label {
    font-size: 0.83rem;
    font-weight: 500;
    color: rgba(33, 40, 66, 0.6);
}

.auth-terms-wrap {
    margin-top: -4px;
}

/* Forgot link */
.auth-forgot {
    font-size: 0.83rem;
    font-weight: 600;
    color: #212842;
    text-decoration: none;
    transition: opacity var(--transition-fast);
}

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

/* Submit button */
.auth-submit-btn {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    width: 100%;
    padding: 15px 24px;
    border: none;
    border-radius: var(--radius-full);
    background: linear-gradient(135deg, #212842 0%, #2d3654 100%);
    color: #ffffff;
    font-family: inherit;
    font-size: 0.95rem;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 6px 24px rgba(33, 40, 66, 0.3);
    overflow: hidden;
    margin-top: 4px;
}

.auth-submit-btn::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.1), transparent);
    opacity: 0;
    transition: opacity var(--transition-fast);
}

.auth-submit-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 12px 36px rgba(33, 40, 66, 0.4);
}

.auth-submit-btn:hover::before {
    opacity: 1;
}

.auth-submit-btn:active {
    transform: translateY(0);
    box-shadow: 0 4px 16px rgba(33, 40, 66, 0.25);
}

.auth-btn-icon {
    font-size: 0.85rem;
    transition: transform var(--transition-base);
}

.auth-submit-btn:hover .auth-btn-icon {
    transform: translateX(3px);
}

/* Spinning loader inside button */
.auth-btn-loader {
    display: none;
    width: 18px;
    height: 18px;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-top-color: #fff;
    border-radius: 50%;
    animation: spin 0.7s linear infinite;
    position: absolute;
    right: 20px;
}

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

/* Switch hint */
.auth-switch-hint {
    text-align: center;
    font-size: 0.83rem;
    color: rgba(33, 40, 66, 0.5);
    margin-top: 4px;
}

.auth-switch-link {
    background: none;
    border: none;
    padding: 0;
    font-family: inherit;
    font-size: inherit;
    font-weight: 700;
    color: #212842;
    cursor: pointer;
    text-decoration: underline;
    text-underline-offset: 2px;
    transition: opacity var(--transition-fast);
}

.auth-switch-link:hover {
    opacity: 0.65;
}

/* Login/Register reveal timing; base.css owns the shared reveal states. */
.auth-panel.reveal {
    transition-duration: 0.65s;
}

.auth-form-panel.reveal {
    transition-delay: 0.12s;
}

/* =========================================
   RESPONSIVE (Burası Tam İstediğin Gibi Güncellendi)
   ========================================= */
@media (max-width: 900px) {
    .auth-container {
        grid-template-columns: 1fr;
        max-width: 420px; /* Kartı mobilde devasa olmaktan kurtarıp daralttık */
    }

    .auth-info {
        display: none; /* Bilgi panelini tamamen gizledik */
    }

    .auth-form-panel {
        padding: 32px 28px;
    }
}

@media (max-width: 560px) {
    .auth-wrapper {
        padding: 90px 16px 40px; /* Üst boşluğu telefona göre kıstık */
    }

    .auth-form-panel {
        padding: 24px 20px; /* İç boşlukları daralttık */
        border-radius: 20px; /* Mobilde kenarları biraz daha yumuşattık */
    }

    .auth-form-title {
        font-size: 1.35rem; /* Başlık boyutunu telefona uyarladık */
    }

    .auth-input {
        padding: 11px 36px 11px 38px; /* Inputları biraz daha ince yaptık */
        font-size: 0.85rem;
    }

    .auth-submit-btn {
        padding: 12px 20px; /* Butonu biraz daha derli toplu yaptık */
    }

    .auth-fields-row {
        grid-template-columns: 1fr;
    }

    .auth-tabs {
        margin-bottom: 20px;
        padding: 4px;
    }

    .auth-tab {
        padding: 9px 16px;
        font-size: 0.85rem;
    }
}

/* =========================================
   TOAST NOTIFICATIONS
   ========================================= */
.auth-toast {
    position: fixed;
    right: 32px;
    bottom: 32px;
    z-index: 9999;
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 14px 22px;
    border-radius: 14px;
    font-family: inherit;
    font-size: 0.9rem;
    font-weight: 600;
    box-shadow: 0 8px 32px rgba(33, 40, 66, 0.18);
    opacity: 0;
    transform: translateY(16px);
    transition: opacity 0.3s ease, transform 0.3s ease;
}

.auth-toast-success {
    color: #15803d;
    background: #fff;
    border: 1.5px solid rgba(22, 163, 74, 0.2);
}

.auth-toast-success i {
    color: #16a34a;
    font-size: 1.05rem;
}

.auth-toast-error {
    color: #b91c1c;
    background: #fff;
    border: 1.5px solid rgba(220, 38, 38, 0.2);
}

.auth-toast-error i {
    color: #dc2626;
    font-size: 1.05rem;
}

@keyframes shakeField {
    0%,
    100% {
        transform: translateX(0);
    }

    20% {
        transform: translateX(-6px);
    }

    40% {
        transform: translateX(6px);
    }

    60% {
        transform: translateX(-4px);
    }

    80% {
        transform: translateX(4px);
    }
}

@media (max-width: 560px) {
    .auth-toast {
        left: 16px;
        right: 16px;
        bottom: 18px;
        justify-content: center;
    }
}
