/* ========================================
   Giriş Sayfası - Glassmorphism Tasarım
   ======================================== */

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

body, html {
    height: 100%;
    font-family: 'Inter', sans-serif;
}

body {
    -webkit-user-select: text;
    -moz-user-select: text;
    -ms-user-select: text;
    user-select: text;
}

/* ── Arka Plan ── */
.giris-bg {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #0a1f5c 0%, #103595 40%, #1a4cc0 100%);
    position: relative;
    overflow: hidden;
    padding: 20px;
}

/* Dekoratif floating circles */
.giris-bg .deko-1,
.giris-bg .deko-2,
.giris-bg .deko-3 {
    position: absolute;
    border-radius: 50%;
    pointer-events: none;
}

.giris-bg .deko-1 {
    width: 400px;
    height: 400px;
    background: rgba(255, 255, 255, 0.06);
    top: -120px;
    right: -80px;
    animation: dekoFloat 8s ease-in-out infinite;
}

.giris-bg .deko-2 {
    width: 250px;
    height: 250px;
    background: rgba(255, 255, 255, 0.04);
    bottom: -60px;
    left: -60px;
    animation: dekoFloat 10s ease-in-out infinite reverse;
}

.giris-bg .deko-3 {
    width: 180px;
    height: 180px;
    background: rgba(255, 255, 255, 0.05);
    top: 40%;
    left: 10%;
    animation: dekoFloat 12s ease-in-out infinite 2s;
}

@keyframes dekoFloat {
    0%, 100% { transform: translateY(0) rotate(0deg); }
    50% { transform: translateY(-30px) rotate(5deg); }
}

/* ── Cam Efektli Kart ── */
.giris-kart {
    position: relative;
    z-index: 1;
    width: 100%;
    max-width: 440px;
    background: rgba(255, 255, 255, 0.12);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 20px;
    padding: 48px 40px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.2);
}

/* ── Logo ── */
.giris-logo {
    text-align: center;
    margin-bottom: 36px;
}

.giris-logo img {
    max-width: 200px;
    filter: brightness(0) invert(1);
}

/* ── Adım Konteynerleri ── */
.giris-adim {
    display: none;
}

.giris-adim.aktif {
    display: block;
    animation: fadeInUp 0.4s ease;
}

.giris-adim.cikis {
    animation: fadeOutDown 0.3s ease forwards;
}

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

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

/* ── Başlık ── */
.giris-baslik {
    text-align: center;
    margin-bottom: 32px;
}

.giris-baslik h2 {
    color: #fff;
    font-size: 26px;
    font-weight: 700;
    margin-bottom: 8px;
}

.giris-baslik p {
    color: rgba(255, 255, 255, 0.7);
    font-size: 14px;
    line-height: 1.5;
}

/* ── Form Grup ── */
.giris-form-grup {
    margin-bottom: 20px;
}

.giris-form-grup label {
    display: block;
    color: rgba(255, 255, 255, 0.85);
    font-weight: 500;
    margin-bottom: 8px;
    font-size: 13px;
    text-transform: capitalize;
}

/* ── Genel Input ── */
.giris-input {
    width: 100%;
    height: 50px;
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 12px;
    padding: 0 16px;
    font-size: 15px;
    color: #fff;
    transition: all 0.3s ease;
    font-family: 'Inter', sans-serif;
}

.giris-input::placeholder {
    color: rgba(255, 255, 255, 0.4);
}

.giris-input:focus {
    outline: none;
    border-color: rgba(255, 255, 255, 0.5);
    background: rgba(255, 255, 255, 0.15);
    box-shadow: 0 0 0 3px rgba(255, 255, 255, 0.1);
}

/* ── Telefon Grubu ── */
.giris-telefon-grup {
    display: flex;
    align-items: center;
    gap: 0;
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 12px;
    transition: all 0.3s ease;
    overflow: hidden;
}

.giris-telefon-grup:focus-within {
    border-color: rgba(255, 255, 255, 0.5);
    background: rgba(255, 255, 255, 0.15);
    box-shadow: 0 0 0 3px rgba(255, 255, 255, 0.1);
}

.giris-telefon-prefix {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 0 12px 0 16px;
    color: rgba(255, 255, 255, 0.7);
    font-size: 14px;
    font-weight: 500;
    white-space: nowrap;
    border-right: 1px solid rgba(255, 255, 255, 0.15);
    height: 50px;
    user-select: none;
}

.giris-telefon-prefix .bayrak {
    font-size: 18px;
    line-height: 1;
}

.giris-telefon-input {
    flex: 1;
    height: 50px;
    background: transparent;
    border: none;
    padding: 0 16px;
    font-size: 16px;
    color: #fff;
    font-family: 'Inter', sans-serif;
    letter-spacing: 1px;
}

.giris-telefon-input::placeholder {
    color: rgba(255, 255, 255, 0.35);
    letter-spacing: 0.5px;
}

.giris-telefon-input:focus {
    outline: none;
}

/* ── Butonlar ── */
.giris-btn {
    width: 100%;
    height: 50px;
    border: none;
    border-radius: 12px;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    font-family: 'Inter', sans-serif;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

.giris-btn-birincil {
    background: #fff;
    color: #103595;
    margin-top: 8px;
}

.giris-btn-birincil:hover {
    background: rgba(255, 255, 255, 0.9);
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.15);
}

.giris-btn-birincil:active {
    transform: translateY(0);
}

.giris-btn-birincil:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none;
    box-shadow: none;
}

.giris-btn-birincil .spinner {
    display: none;
    width: 18px;
    height: 18px;
    border: 2px solid rgba(16, 53, 149, 0.3);
    border-top-color: #103595;
    border-radius: 50%;
    animation: spin 0.6s linear infinite;
}

.giris-btn-birincil.yuklemede .spinner {
    display: inline-block;
}

.giris-btn-birincil.yuklemede .btn-yazi {
    display: none;
}

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

/* ── Alt Link ── */
.giris-alt-link {
    text-align: center;
    margin-top: 20px;
}

.giris-alt-link a {
    color: rgba(255, 255, 255, 0.6);
    font-size: 13px;
    text-decoration: none;
    transition: color 0.2s ease;
}

.giris-alt-link a:hover {
    color: rgba(255, 255, 255, 0.9);
    text-decoration: underline;
}

/* ── Mesaj Kutusu ── */
.giris-mesaj {
    min-height: 0;
    margin-bottom: 0;
    transition: all 0.3s ease;
}

.giris-mesaj .mesaj-icerik {
    padding: 12px 16px;
    border-radius: 10px;
    font-size: 13px;
    margin-bottom: 16px;
    animation: fadeInUp 0.3s ease;
    line-height: 1.4;
}

.giris-mesaj .mesaj-hata {
    background: rgba(239, 68, 68, 0.2);
    color: #fca5a5;
    border: 1px solid rgba(239, 68, 68, 0.3);
}

.giris-mesaj .mesaj-basarili {
    background: rgba(34, 197, 94, 0.2);
    color: #86efac;
    border: 1px solid rgba(34, 197, 94, 0.3);
}

.giris-mesaj .mesaj-bilgi {
    background: rgba(59, 130, 246, 0.2);
    color: #93c5fd;
    border: 1px solid rgba(59, 130, 246, 0.3);
}

/* ── OTP Kutuları ── */
.giris-otp-container {
    display: flex;
    gap: 12px;
    justify-content: center;
    margin: 28px 0;
}

.giris-otp-input {
    width: 60px;
    height: 64px;
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.25);
    border-radius: 14px;
    text-align: center;
    font-size: 26px;
    font-weight: 700;
    color: #fff;
    caret-color: rgba(255, 255, 255, 0.6);
    transition: all 0.3s ease;
    font-family: 'Inter', sans-serif;
}

.giris-otp-input:focus {
    outline: none;
    border-color: rgba(255, 255, 255, 0.6);
    background: rgba(255, 255, 255, 0.18);
    box-shadow: 0 0 0 3px rgba(255, 255, 255, 0.1);
    transform: scale(1.05);
}

.giris-otp-input.dolu {
    background: rgba(255, 255, 255, 0.2);
    border-color: rgba(255, 255, 255, 0.4);
}

/* Number input spinner gizle */
.giris-otp-input::-webkit-inner-spin-button,
.giris-otp-input::-webkit-outer-spin-button {
    -webkit-appearance: none;
    margin: 0;
}

.giris-otp-input[type=number] {
    -moz-appearance: textfield;
    appearance: textfield;
}

/* ── Telefon Bilgi (OTP adımı) ── */
.giris-telefon-bilgi {
    text-align: center;
    margin-bottom: 8px;
    padding: 14px;
    background: rgba(255, 255, 255, 0.08);
    border-radius: 12px;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.giris-telefon-bilgi .etiket {
    color: rgba(255, 255, 255, 0.5);
    font-size: 12px;
    margin-bottom: 4px;
}

.giris-telefon-bilgi .numara {
    color: #fff;
    font-weight: 600;
    font-size: 16px;
    letter-spacing: 1px;
}

/* ── Geri Sayım ── */
.giris-geri-sayim {
    text-align: center;
    margin-bottom: 16px;
    font-size: 13px;
    color: rgba(255, 255, 255, 0.5);
    min-height: 20px;
}

.giris-geri-sayim .sure {
    font-weight: 600;
    color: rgba(255, 255, 255, 0.8);
}

.giris-yeniden-gonder {
    background: none;
    border: none;
    color: rgba(255, 255, 255, 0.6);
    font-size: 13px;
    cursor: pointer;
    text-decoration: underline;
    font-family: 'Inter', sans-serif;
    transition: color 0.2s ease;
    padding: 0;
}

.giris-yeniden-gonder:hover {
    color: #fff;
}

.giris-yeniden-gonder:disabled {
    cursor: not-allowed;
    opacity: 0.4;
    text-decoration: none;
}

/* ── Responsive ── */
@media (max-width: 768px) {
    .giris-kart {
        max-width: 95%;
        padding: 36px 28px;
    }

    .giris-logo img {
        max-width: 160px;
    }

    .giris-baslik h2 {
        font-size: 22px;
    }
}

@media (max-width: 480px) {
    .giris-bg {
        padding: 16px;
    }

    .giris-kart {
        padding: 32px 20px;
        border-radius: 16px;
    }

    .giris-otp-container {
        gap: 8px;
    }

    .giris-otp-input {
        width: 52px;
        height: 56px;
        font-size: 22px;
        border-radius: 10px;
    }

    .giris-telefon-prefix {
        padding: 0 8px 0 12px;
    }

    .giris-telefon-input {
        padding: 0 12px;
        font-size: 15px;
    }
}

/* ── Reduced Motion ── */
@media (prefers-reduced-motion: reduce) {
    .giris-bg .deko-1,
    .giris-bg .deko-2,
    .giris-bg .deko-3 {
        animation: none;
    }

    .giris-adim.aktif {
        animation: none;
    }

    .giris-adim.cikis {
        animation: none;
    }

    .giris-otp-input:focus {
        transform: none;
    }

    .giris-btn-birincil:hover {
        transform: none;
    }
}
