/* Auth Sayfası Stilleri */

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    -webkit-tap-highlight-color: transparent;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    min-height: 100vh;
    min-height: 100dvh;
    padding: 0;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    overflow-x: hidden;
}

.container {
    max-width: 480px;
    width: 100%;
    margin: 0 auto;
    background: white;
    min-height: 100vh;
    min-height: 100dvh;
    height: 100vh;
    height: 100dvh;
    overflow-y: auto;
    overflow-x: hidden;
    position: relative;
    -webkit-overflow-scrolling: touch;
}

@media (min-width: 481px) {
    body {
        padding: 15px;
        display: flex;
        align-items: center;
        justify-content: center;
    }
    
    .container {
        border-radius: 20px;
        box-shadow: 0 10px 40px rgba(0, 0, 0, 0.2);
        min-height: auto;
        max-height: 95vh;
    }
}

header {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: max(30px, env(safe-area-inset-top) + 15px) 20px 30px;
    text-align: center;
    box-shadow: 0 4px 20px rgba(102, 126, 234, 0.3);
    position: relative;
    overflow: hidden;
}

header::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('data:image/svg+xml,<svg width="100" height="100" xmlns="http://www.w3.org/2000/svg"><defs><pattern id="grid" width="40" height="40" patternUnits="userSpaceOnUse"><path d="M 40 0 L 0 0 0 40" fill="none" stroke="rgba(255,255,255,0.05)" stroke-width="1"/></pattern></defs><rect width="100" height="100" fill="url(%23grid)"/></svg>');
    opacity: 0.3;
}

header h1 {
    font-size: 28px;
    font-weight: 700;
    margin: 0;
    position: relative;
    z-index: 1;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
}

header h1 i {
    font-size: 32px;
    opacity: 0.95;
}

.auth-container {
    padding: 40px 24px;
    padding-bottom: max(40px, env(safe-area-inset-bottom) + 20px);
}

.auth-form {
    max-width: 420px;
    margin: 0 auto;
    animation: fadeInUp 0.4s ease-out;
}

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

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

.auth-form h2 {
    font-size: 32px;
    font-weight: 700;
    color: #1a1a2e;
    margin-bottom: 12px;
    text-align: center;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.auth-form p {
    text-align: center;
    color: #666;
    font-size: 15px;
    line-height: 1.6;
    margin-bottom: 32px;
}

.form-group {
    margin-bottom: 24px;
}

.form-group label {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 15px;
    font-weight: 600;
    color: #1a1a2e;
    margin-bottom: 10px;
}

.form-group label i {
    color: #667eea;
    font-size: 16px;
}

.form-group input {
    width: 100%;
    padding: 16px 18px;
    border: 2px solid #e8e9ea;
    border-radius: 12px;
    font-size: 16px;
    transition: all 0.2s;
    background: #fafbfc;
    color: #1a1a2e;
    font-family: inherit;
}

/* Doğrulama kodu input özel stil */
.form-group input[type="tel"][id="code"] {
    background: linear-gradient(135deg, #f8f9fa 0%, #ffffff 100%);
    border: 2px solid #e0e0e0;
    font-weight: 700;
    letter-spacing: 12px;
    font-size: 28px;
    padding: 20px;
    text-align: center;
}

.form-group input[type="tel"][id="code"]:focus {
    border-color: #667eea;
    background: white;
    box-shadow: 0 0 0 4px rgba(102, 126, 234, 0.15);
    letter-spacing: 12px;
    text-align: center;
}

.form-group input::placeholder {
    color: #bbb;
}

.form-group input:focus {
    outline: none;
    border-color: #667eea;
    background: white;
    box-shadow: 0 0 0 4px rgba(102, 126, 234, 0.1);
    transform: translateY(-1px);
}

.form-group small {
    display: block;
    margin-top: 8px;
    color: #999;
    font-size: 13px;
    line-height: 1.5;
}

.password-input-wrapper {
    position: relative;
}

.password-input-wrapper input {
    padding-right: 50px;
}

.password-toggle {
    position: absolute;
    right: 12px;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    cursor: pointer;
    padding: 8px;
    font-size: 20px;
    color: #666;
    transition: all 0.2s;
}

.password-toggle:hover {
    color: #667eea;
}

.password-toggle:active {
    transform: translateY(-50%) scale(0.9);
}

.btn {
    width: 100%;
    padding: 16px 20px;
    border: none;
    border-radius: 12px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
    margin-top: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    position: relative;
    overflow: hidden;
}

.btn-primary {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.3);
}

.btn-primary::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: left 0.5s;
}

.btn-primary:hover::before {
    left: 100%;
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(102, 126, 234, 0.4);
}

.btn-primary:active {
    transform: translateY(0);
    box-shadow: 0 2px 8px rgba(102, 126, 234, 0.3);
}

.auth-link {
    text-align: center;
    margin-top: 20px;
    color: #666;
    font-size: 14px;
}

.auth-link a {
    color: #667eea;
    text-decoration: none;
    font-weight: 600;
}

.auth-link a:hover {
    text-decoration: underline;
}

.message {
    margin-top: 24px;
    padding: 14px 18px;
    border-radius: 12px;
    text-align: center;
    font-size: 14px;
    display: none;
    animation: slideDown 0.3s ease-out;
    font-weight: 500;
}

@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.message.error {
    background: linear-gradient(135deg, #fee 0%, #fdd 100%);
    color: #c33;
    border: 1px solid #fcc;
    box-shadow: 0 2px 8px rgba(204, 51, 51, 0.1);
}

.message.success {
    background: linear-gradient(135deg, #efe 0%, #dfd 100%);
    color: #3c3;
    border: 1px solid #cfc;
    box-shadow: 0 2px 8px rgba(60, 195, 60, 0.1);
}

.loader {
    display: inline-block;
    width: 16px;
    height: 16px;
    border: 2px solid #ffffff;
    border-radius: 50%;
    border-top-color: transparent;
    animation: spin 0.6s linear infinite;
}

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

.btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

.btn-secondary {
    background: #f0f0f0;
    color: #666;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
}

.btn-secondary:hover {
    background: #e8e8e8;
    color: #333;
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

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

