/* Auth Pages CSS - Tailwind CSS Custom Styles */

/* Dark mode colors */
:root {
    --dark-900: #111827;
    --dark-850: #1f2937;
    --dark-800: #374151;
    --dark-700: #4b5563;
    --dark-600: #6b7280;
    --dark-500: #9ca3af;
    --dark-50: #f9fafb;
}

/* Base styles */
body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
}

/* Gradient text */
.gradient-text {
    background: linear-gradient(to right, #3b82f6, #8b5cf6, #ec4899);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* Card styles */
.auth-card {
    background: white;
    border-radius: 0.75rem;
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
}

.dark .auth-card {
    background: var(--dark-800);
}

/* Form input styles */
.form-input {
    width: 100%;
    padding: 0.5rem 1rem;
    border: 1px solid #d1d5db;
    border-radius: 0.5rem;
    transition: all 0.2s;
}

    .form-input:focus {
        outline: none;
        border-color: #3b82f6;
        box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1);
    }

.dark .form-input {
    background-color: var(--dark-700);
    border-color: var(--dark-600);
    color: white;
}

    .dark .form-input:focus {
        border-color: #3b82f6;
        box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1);
    }

/* Button styles */
.btn-primary {
    background-color: #3b82f6;
    color: white;
    padding: 0.5rem 1rem;
    border-radius: 0.5rem;
    transition: all 0.2s;
}

    .btn-primary:hover {
        background-color: #2563eb;
    }

.btn-secondary {
    background-color: #e5e7eb;
    color: #374151;
    padding: 0.5rem 1rem;
    border-radius: 0.5rem;
    transition: all 0.2s;
}

    .btn-secondary:hover {
        background-color: #d1d5db;
    }

.dark .btn-secondary {
    background-color: var(--dark-700);
    color: white;
}

    .dark .btn-secondary:hover {
        background-color: var(--dark-600);
    }

.btn-danger {
    background-color: #ef4444;
    color: white;
    padding: 0.5rem 1rem;
    border-radius: 0.5rem;
    transition: all 0.2s;
}

    .btn-danger:hover {
        background-color: #dc2626;
    }

/* Checkbox styles */
.input-check {
    width: 1rem;
    height: 1rem;
    accent-color: #3b82f6;
}

.input-check-label {
    margin-left: 0.5rem;
    font-size: 0.875rem;
    color: #374151;
}

.dark .input-check-label {
    color: var(--dark-300);
}

/* Link styles */
.link-primary {
    color: #3b82f6;
    text-decoration: none;
    transition: color 0.2s;
}

    .link-primary:hover {
        color: #2563eb;
        text-decoration: underline;
    }

/* Divider */
.divider {
    position: relative;
    text-align: center;
    margin: 1.25rem 0;
}

    .divider::before {
        content: '';
        position: absolute;
        top: 50%;
        left: 0;
        right: 0;
        height: 1px;
        background: #e5e7eb;
        border-style: dashed;
    }

.dark .divider::before {
    background: var(--dark-600);
}

.divider span {
    position: relative;
    display: inline-block;
    padding: 0 0.5rem;
    background: white;
    color: #6b7280;
}

.dark .divider span {
    background: var(--dark-800);
    color: var(--dark-500);
}

/* Social buttons */
.social-btn {
    width: 100%;
    padding: 0.5rem 1rem;
    border: 1px solid #e5e7eb;
    border-radius: 0.5rem;
    background: white;
    color: #374151;
    transition: all 0.2s;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
}

    .social-btn:hover {
        background-color: #f9fafb;
        color: #3b82f6;
    }

.dark .social-btn {
    border-color: var(--dark-600);
    background: var(--dark-800);
    color: var(--dark-300);
}

    .dark .social-btn:hover {
        background-color: var(--dark-700);
        color: #3b82f6;
    }

/* OTP input styles */
.otp-input {
    width: 2.25rem;
    height: 2.25rem;
    font-size: 1.5rem;
    font-weight: 800;
    text-align: center;
    background-color: #f3f4f6;
    border: 1px solid transparent;
    border-radius: 0.125rem;
    appearance: none;
    outline: none;
    color: #0f172a;
    transition: all 0.2s;
}

    .otp-input:hover {
        border-color: #e5e7eb;
    }

    .otp-input:focus {
        background-color: white;
        border-color: #3b82f6;
        box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.15);
    }

.dark .otp-input {
    background-color: var(--dark-850);
    color: var(--dark-50);
}

    .dark .otp-input:hover {
        border-color: var(--dark-600);
    }

    .dark .otp-input:focus {
        background-color: var(--dark-900);
        border-color: #3b82f6;
    }

/* Responsive OTP inputs */
@media (min-width: 640px) {
    .otp-input {
        width: 3rem;
        height: 3rem;
    }
}

@media (min-width: 768px) {
    .otp-input {
        width: 3.5rem;
        height: 3.5rem;
    }
}

/* Alert styles */
.alert {
    padding: 0.75rem 1rem;
    border-radius: 0.5rem;
    font-size: 0.875rem;
    position: relative;
    border: 1px solid transparent;
    display: flex;
    align-items: flex-start;
    gap: 0.5rem;
}

    .alert .alert-icon {
        flex-shrink: 0;
        margin-top: 0.1rem;
    }

    /* Close button inside alert */
    .alert .btn-close {
        position: absolute;
        top: 0.625rem;
        right: 0.75rem;
        display: flex;
        align-items: center;
        justify-content: center;
        background: transparent;
        border: none;
        cursor: pointer;
        opacity: 0.6;
        transition: opacity 0.15s ease;
        line-height: 1;
        padding: 0;
    }

        .alert .btn-close:hover {
            opacity: 1;
        }

/* Semantic color aliases */
.alert-success {
    background-color: #d1fae5;
    color: #065f46;
    border-color: #a7f3d0;
}

.alert-error {
    background-color: #fee2e2;
    color: #991b1b;
    border-color: #fecaca;
}

.alert-warning {
    background-color: #fef3c7;
    color: #92400e;
    border-color: #fde68a;
}

.alert-info {
    background-color: #dbeafe;
    color: #1e40af;
    border-color: #bfdbfe;
}

/* Short-name color variants (used in templates) */
.alert-red {
    background-color: #fee2e2;
    color: #991b1b;
    border-color: #fecaca;
}

    .alert-red .btn-close {
        color: #f87171;
    }

        .alert-red .btn-close:hover {
            color: #ef4444;
        }

.alert-green {
    background-color: #d1fae5;
    color: #065f46;
    border-color: #a7f3d0;
}

    .alert-green .btn-close {
        color: #34d399;
    }

        .alert-green .btn-close:hover {
            color: #10b981;
        }

.alert-yellow {
    background-color: #fef3c7;
    color: #92400e;
    border-color: #fde68a;
}

    .alert-yellow .btn-close {
        color: #fbbf24;
    }

        .alert-yellow .btn-close:hover {
            color: #f59e0b;
        }

.alert-blue {
    background-color: #dbeafe;
    color: #1e40af;
    border-color: #bfdbfe;
}

    .alert-blue .btn-close {
        color: #60a5fa;
    }

        .alert-blue .btn-close:hover {
            color: #3b82f6;
        }

/* Dark mode */
.dark .alert-success,
.dark .alert-green {
    background-color: rgba(16, 185, 129, 0.1);
    color: #34d399;
    border-color: rgba(52, 211, 153, 0.2);
}

.dark .alert-error,
.dark .alert-red {
    background-color: rgba(239, 68, 68, 0.1);
    color: #f87171;
    border-color: rgba(248, 113, 113, 0.2);
}

.dark .alert-warning,
.dark .alert-yellow {
    background-color: rgba(245, 158, 11, 0.1);
    color: #fbbf24;
    border-color: rgba(251, 191, 36, 0.2);
}

.dark .alert-info,
.dark .alert-blue {
    background-color: rgba(59, 130, 246, 0.1);
    color: #60a5fa;
    border-color: rgba(96, 165, 250, 0.2);
}

/* Error message styles */
.error-message {
    font-size: 0.875rem;
    color: #ef4444;
    margin-top: 0.25rem;
}

.dark .error-message {
    color: #f87171;
}

/* Icon container */
.icon-container {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 3.5rem;
    height: 3.5rem;
    margin: 0 auto;
}

/* Success icon */
.success-icon {
    color: #10b981;
}

/* Info icon */
.info-icon {
    color: #6b7280;
}

.dark .info-icon {
    color: var(--dark-500);
}

/* Custom scrollbar */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: #f1f1f1;
}

::-webkit-scrollbar-thumb {
    background: #c1c1c1;
    border-radius: 4px;
}

    ::-webkit-scrollbar-thumb:hover {
        background: #a1a1a1;
    }

.dark ::-webkit-scrollbar-track {
    background: var(--dark-800);
}

.dark ::-webkit-scrollbar-thumb {
    background: var(--dark-600);
}

    .dark ::-webkit-scrollbar-thumb:hover {
        background: var(--dark-500);
    }