/* ============================================
   Shared Auth Form Styles
   Theme via CSS custom properties on .auth-theme-user / .auth-theme-business
   ============================================ */

/* --- Theme Tokens --- */
.auth-theme-user {
    --auth-gradient-start: #0d9488;
    --auth-gradient-end: #0891b2;
    --auth-sidebar-start: #0f172a;
    --auth-sidebar-mid: #134e4a;
    --auth-sidebar-end: #115e59;
    --auth-accent: #0d9488;
    --auth-focus-ring: rgba(13, 148, 136, 0.15);
}

.auth-theme-business {
    --auth-gradient-start: #667eea;
    --auth-gradient-end: #764ba2;
    --auth-sidebar-start: #1a1a2e;
    --auth-sidebar-mid: #16213e;
    --auth-sidebar-end: #0f3460;
    --auth-accent: #667eea;
    --auth-focus-ring: rgba(102, 126, 234, 0.15);
}

/* --- Layout --- */
.auth-container {
    min-height: calc(100vh - 200px);
    margin: -1.5rem -12px;
}

.auth-sidebar {
    background: linear-gradient(135deg, var(--auth-sidebar-start) 0%, var(--auth-sidebar-mid) 50%, var(--auth-sidebar-end) 100%);
    color: white;
    padding: 3rem;
    display: flex;
    flex-direction: column;
    justify-content: center;
    position: relative;
    overflow: hidden;
}

.auth-sidebar::before {
    content: '';
    position: absolute;
    top: -50%;
    right: -50%;
    width: 100%;
    height: 100%;
    background: radial-gradient(circle, rgba(255,255,255,0.05) 0%, transparent 70%);
    pointer-events: none;
}

.auth-sidebar h1,
.auth-sidebar h2,
.auth-sidebar h3,
.auth-sidebar p,
.auth-sidebar span,
.auth-sidebar li {
    color: white;
}

.auth-sidebar h1 {
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 1.5rem;
}

.auth-sidebar .lead {
    font-size: 1.1rem;
    opacity: 0.9;
    margin-bottom: 2rem;
}

/* --- Feature List --- */
.auth-feature-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.auth-feature-list li {
    display: flex;
    align-items: flex-start;
    margin-bottom: 1.25rem;
    font-size: 0.95rem;
}

.auth-feature-icon {
    width: 24px;
    height: 24px;
    min-width: 24px;
    background: rgba(255,255,255,0.15);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-right: 1rem;
}

.auth-feature-icon svg {
    width: 14px;
    height: 14px;
}

/* --- Stats Row --- */
.auth-stats-row {
    display: flex;
    justify-content: space-around;
    margin-top: 3rem;
    padding-top: 2rem;
    border-top: 1px solid rgba(255,255,255,0.1);
}

.auth-stat-item { text-align: center; }

.auth-stat-number {
    font-size: 1.75rem;
    font-weight: 700;
    color: var(--auth-accent);
}

.auth-stat-label {
    font-size: 0.8rem;
    opacity: 0.7;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* --- Form Container --- */
.auth-form-container {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 3rem;
    background: #f8f9fa;
}

.auth-form-card {
    width: 100%;
    max-width: 440px;
    background: white;
    border-radius: 16px;
    box-shadow: 0 10px 40px rgba(0,0,0,0.08);
    padding: 2.5rem;
}

/* Wider card for registration forms */
.auth-form-card--wide { max-width: 520px; }

.auth-form-header {
    text-align: center;
    margin-bottom: 2rem;
}

.auth-icon-wrapper {
    width: 64px;
    height: 64px;
    background: linear-gradient(135deg, var(--auth-gradient-start) 0%, var(--auth-gradient-end) 100%);
    border-radius: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1rem;
}

.auth-icon-wrapper svg {
    width: 32px;
    height: 32px;
    color: white;
}

.auth-form-card h2 {
    font-size: 1.5rem;
    font-weight: 600;
    color: #1a1a2e;
    margin-bottom: 0.5rem;
}

.auth-form-card .subtitle {
    color: #6c757d;
    font-size: 0.9rem;
}

/* --- Form Controls --- */
.auth-form-card .form-control,
.auth-form-card .form-select {
    border-radius: 10px;
    padding: 0.75rem 1rem;
    border: 1.5px solid #e0e0e0;
    transition: all 0.2s;
}

.auth-form-card .form-control:focus,
.auth-form-card .form-select:focus {
    border-color: var(--auth-accent);
    box-shadow: 0 0 0 3px var(--auth-focus-ring);
}

.auth-form-card .form-label {
    font-weight: 500;
    color: #333;
    font-size: 0.9rem;
}

/* --- Buttons --- */
.btn-auth {
    background: linear-gradient(135deg, var(--auth-gradient-start) 0%, var(--auth-gradient-end) 100%);
    border: none;
    border-radius: 10px;
    padding: 0.875rem;
    font-weight: 600;
    font-size: 1rem;
    color: white;
    transition: all 0.3s;
}

.btn-auth:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(0,0,0,0.2);
    color: white;
}

/* --- Divider --- */
.auth-divider {
    display: flex;
    align-items: center;
    margin: 1.5rem 0;
    color: #adb5bd;
    font-size: 0.85rem;
}

.auth-divider::before,
.auth-divider::after {
    content: '';
    flex: 1;
    height: 1px;
    background: #e0e0e0;
}

.auth-divider span { padding: 0 1rem; }

/* --- Section Title (registration forms) --- */
.auth-section-title {
    font-size: 0.8rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: var(--auth-accent);
    margin-bottom: 1rem;
    padding-bottom: 0.5rem;
    border-bottom: 2px solid var(--auth-accent);
    display: inline-block;
}

/* --- Pricing Card (business sidebar) --- */
.auth-pricing-card {
    background: rgba(255,255,255,0.08);
    border-radius: 16px;
    padding: 1.5rem;
    margin-bottom: 1.5rem;
    backdrop-filter: blur(10px);
}

.auth-pricing-card h3 {
    font-size: 1rem;
    font-weight: 600;
    margin-bottom: 1rem;
    color: var(--auth-accent);
}

.auth-pricing-tier {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.5rem 0;
    border-bottom: 1px solid rgba(255,255,255,0.1);
}

.auth-pricing-tier:last-child { border-bottom: none; }
.auth-pricing-tier .credits { font-weight: 600; }
.auth-pricing-tier .price { color: var(--auth-accent); font-weight: 500; }
.auth-pricing-tier .per-credit { font-size: 0.75rem; opacity: 0.7; }

/* --- Guarantee Badge --- */
.auth-guarantee-badge {
    display: flex;
    align-items: center;
    background: rgba(255,255,255,0.08);
    border-radius: 10px;
    padding: 1rem;
    margin-top: 1.5rem;
}

.auth-guarantee-badge svg {
    width: 32px;
    height: 32px;
    min-width: 32px;
    margin-right: 1rem;
    color: var(--auth-accent);
}

.auth-guarantee-badge .text { font-size: 0.9rem; }
.auth-guarantee-badge .text strong { display: block; margin-bottom: 0.25rem; }

/* --- Centered Card (no sidebar) --- */
.auth-centered {
    min-height: calc(100vh - 200px);
    display: flex;
    align-items: center;
    justify-content: center;
    background: #f8f9fa;
    margin: -1.5rem -12px;
    padding: 2rem;
}

/* ============================================
   Settings / Profile Page Layout
   ============================================ */
.settings-container {
    max-width: 1100px;
    margin: 0 auto;
}

.settings-sidebar {
    position: sticky;
    top: 100px;
}

.settings-nav {
    background: white;
    border-radius: 16px;
    box-shadow: 0 4px 20px rgba(0,0,0,0.06);
    overflow: hidden;
}

.settings-nav-header {
    padding: 1.5rem;
    border-bottom: 1px solid #f0f0f0;
}

.settings-avatar {
    width: 48px;
    height: 48px;
    background: linear-gradient(135deg, #0d9488, #0891b2);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-weight: 700;
    font-size: 1.2rem;
}

.settings-nav-header .user-name {
    font-weight: 600;
    color: #1a1a2e;
    font-size: 0.95rem;
}

.settings-nav-header .user-email {
    color: #6c757d;
    font-size: 0.8rem;
}

.settings-nav-links {
    list-style: none;
    padding: 0.5rem 0;
    margin: 0;
}

.settings-nav-links li a {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.75rem 1.5rem;
    color: #495057;
    text-decoration: none;
    font-size: 0.9rem;
    font-weight: 500;
    transition: all 0.15s;
    border-left: 3px solid transparent;
}

.settings-nav-links li a:hover {
    background: #f8f9fa;
    color: #0d9488;
}

.settings-nav-links li a.active {
    background: rgba(13, 148, 136, 0.06);
    color: #0d9488;
    border-left-color: #0d9488;
}

.settings-nav-links li a svg {
    width: 18px;
    height: 18px;
    opacity: 0.7;
}

.settings-nav-links li a.active svg { opacity: 1; }

.settings-nav-links .nav-divider {
    height: 1px;
    background: #f0f0f0;
    margin: 0.5rem 1.5rem;
}

.settings-nav-links li a.text-danger:hover {
    background: rgba(220, 53, 69, 0.06);
    color: #dc3545;
}

/* Settings content panels */
.settings-section {
    background: white;
    border-radius: 16px;
    box-shadow: 0 4px 20px rgba(0,0,0,0.06);
    padding: 2rem;
    margin-bottom: 1.5rem;
}

.settings-section h3 {
    font-size: 1.15rem;
    font-weight: 600;
    color: #1a1a2e;
    margin-bottom: 0.25rem;
}

.settings-section .section-desc {
    color: #6c757d;
    font-size: 0.85rem;
    margin-bottom: 1.5rem;
}

.settings-section .form-control,
.settings-section .form-select {
    border-radius: 10px;
    padding: 0.7rem 1rem;
    border: 1.5px solid #e0e0e0;
    transition: all 0.2s;
}

.settings-section .form-control:focus,
.settings-section .form-select:focus {
    border-color: #0d9488;
    box-shadow: 0 0 0 3px rgba(13, 148, 136, 0.15);
}

.settings-section .form-label {
    font-weight: 500;
    color: #333;
    font-size: 0.9rem;
}

.settings-section .btn-settings {
    background: linear-gradient(135deg, #0d9488, #0891b2);
    border: none;
    border-radius: 10px;
    padding: 0.7rem 2rem;
    font-weight: 600;
    color: white;
    transition: all 0.3s;
}

.settings-section .btn-settings:hover {
    transform: translateY(-1px);
    box-shadow: 0 6px 20px rgba(13, 148, 136, 0.3);
    color: white;
}

.settings-info-row {
    display: flex;
    padding: 0.75rem 0;
    border-bottom: 1px solid #f5f5f5;
}

.settings-info-row:last-child { border-bottom: none; }

.settings-info-label {
    width: 140px;
    min-width: 140px;
    color: #6c757d;
    font-size: 0.9rem;
}

.settings-info-value {
    color: #1a1a2e;
    font-size: 0.9rem;
}

/* Mobile: horizontal scrollable nav */
.settings-mobile-nav {
    display: none;
    overflow-x: auto;
    white-space: nowrap;
    background: white;
    border-radius: 12px;
    box-shadow: 0 4px 20px rgba(0,0,0,0.06);
    padding: 0.5rem;
    margin-bottom: 1.5rem;
    -webkit-overflow-scrolling: touch;
}

.settings-mobile-nav a {
    display: inline-block;
    padding: 0.5rem 1rem;
    color: #495057;
    text-decoration: none;
    font-size: 0.85rem;
    font-weight: 500;
    border-radius: 8px;
    transition: all 0.15s;
}

.settings-mobile-nav a.active {
    background: rgba(13, 148, 136, 0.1);
    color: #0d9488;
}

/* --- Responsive --- */
@media (max-width: 991px) {
    .auth-sidebar {
        padding: 2rem;
        min-height: auto;
    }
    .auth-sidebar h1 { font-size: 1.75rem; }
    .auth-stats-row { display: none; }
    .auth-form-container { padding: 2rem 1.5rem; }

    .settings-sidebar { display: none; }
    .settings-mobile-nav { display: block; }
}
