/* =============================================================
   S49Hub — Premium Main Stylesheet
   Ultra-modern dark theme, glassmorphism, smooth animations.
   ============================================================= */

/* ── CSS Custom Properties ─────────────────────────────── */
:root {
    /* Premium Color Palette */
    --bg-primary:     #030712; /* Deepest blue/black */
    --bg-secondary:   #0f172a; /* Slate 900 */
    --bg-card:        rgba(255, 255, 255, 0.03); /* Glass base */
    --bg-card-hover:  rgba(255, 255, 255, 0.06);
    
    /* Vibrant Accents */
    --accent:         #3b82f6; 
    --accent-hover:   #2563eb;
    --accent-purple:  #8b5cf6;
    --accent-gradient: linear-gradient(135deg, var(--accent), var(--accent-purple));
    --accent-glow:    rgba(59, 130, 246, 0.15);
    
    /* Typography */
    --text-primary:   #f8fafc;
    --text-secondary: #94a3b8;
    --text-muted:     #64748b;
    --border:         rgba(255, 255, 255, 0.08); /* Soft glass border */
    
    /* System Colors */
    --success:        #10b981;
    --warning:        #f59e0b;
    --danger:         #ef4444;

    /* Fonts & Shapes */
    --font-heading:   'Outfit', sans-serif;
    --font-body:      'Inter', -apple-system, sans-serif;
    
    --section-padding: 120px 0;
    --container-width: 1200px;
    --radius: 16px;
    --radius-sm: 8px;
    --shadow-glass:   0 8px 32px 0 rgba(0, 0, 0, 0.3);
}

/* ── Reset & Base ──────────────────────────────────────── */
*, *::before, *::after { margin: 0; padding: 0; box-sizing: border-box; }

html {
    scroll-behavior: smooth;
    scroll-padding-top: 90px;
}

body {
    font-family: var(--font-body);
    background-color: var(--bg-primary);
    color: var(--text-primary);
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
    overflow-x: hidden;
    position: relative;
}

/* Global Ambient Glow */
body::before {
    content: '';
    position: fixed;
    top: -20%; left: -10%;
    width: 50vw; height: 50vw;
    background: radial-gradient(circle, rgba(59,130,246,0.05) 0%, transparent 60%);
    z-index: -1;
    pointer-events: none;
}
body::after {
    content: '';
    position: fixed;
    bottom: -20%; right: -10%;
    width: 60vw; height: 60vw;
    background: radial-gradient(circle, rgba(139,92,246,0.05) 0%, transparent 60%);
    z-index: -1;
    pointer-events: none;
}

a { text-decoration: none; color: inherit; }
ul { list-style: none; }
img { max-width: 100%; display: block; }

h1, h2, h3, h4, h5, h6 {
    font-family: var(--font-heading);
    letter-spacing: -0.02em;
}

.container {
    max-width: var(--container-width);
    margin: 0 auto;
    padding: 0 24px;
    position: relative;
    z-index: 10;
}

/* ── Buttons ───────────────────────────────────────────── */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 14px 32px;
    border: none;
    border-radius: var(--radius-sm);
    font-family: var(--font-heading);
    font-size: 1rem;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    white-space: nowrap;
    position: relative;
    overflow: hidden;
}

.btn-primary {
    background: var(--accent-gradient);
    color: #fff;
    box-shadow: 0 4px 15px rgba(59, 130, 246, 0.2);
}
.btn-primary::before {
    content: ''; position: absolute; top: 0; left: 0; width: 100%; height: 100%;
    background: linear-gradient(135deg, rgba(255,255,255,0.1), transparent);
    opacity: 0; transition: opacity 0.3s;
}
.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(59, 130, 246, 0.4);
}
.btn-primary:hover::before { opacity: 1; }

.btn-ghost {
    background: rgba(255, 255, 255, 0.03);
    color: var(--text-primary);
    border: 1px solid var(--border);
    backdrop-filter: blur(10px);
}
.btn-ghost:hover {
    background: rgba(255, 255, 255, 0.08);
    border-color: rgba(255, 255, 255, 0.2);
    transform: translateY(-2px);
}

.btn-sm { padding: 8px 20px; font-size: 0.9rem; }

.btn-success { background: var(--success); color: #fff; }
.btn-warning { background: var(--warning); color: #000; }
.btn-danger { background: var(--danger); color: #fff; }
.btn-success:hover, .btn-warning:hover, .btn-danger:hover { filter: brightness(1.1); transform: translateY(-1px); }

/* ── Navbar ────────────────────────────────────────────── */
.navbar {
    position: fixed;
    top: 0; left: 0; right: 0;
    z-index: 1000;
    background: rgba(3, 7, 18, 0.6);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-bottom: 1px solid var(--border);
    transition: all 0.3s ease;
}

.nav-container {
    max-width: var(--container-width);
    margin: 0 auto;
    padding: 0 24px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 80px;
}

.nav-logo {
    font-size: 1.7rem;
    font-weight: 800;
    font-family: var(--font-heading);
    letter-spacing: -0.5px;
}
.logo-s24 {
    background: var(--accent-gradient);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}
.logo-hub { color: white; }

.nav-links { display: flex; gap: 40px; }
.nav-links a {
    color: var(--text-secondary);
    font-weight: 500;
    font-size: 0.95rem;
    transition: color 0.2s;
    position: relative;
}
.nav-links a::after {
    content: ''; position: absolute; bottom: -4px; left: 0; width: 0; height: 2px;
    background: var(--accent-gradient); transition: width 0.3s ease;
}
.nav-links a:hover { color: var(--text-primary); }
.nav-links a:hover::after { width: 100%; }

.nav-cta { padding: 10px 24px; font-size: 0.95rem; }

.nav-toggle {
    display: none; flex-direction: column; gap: 5px;
    background: none; border: none; cursor: pointer; padding: 4px; z-index: 1001;
}
.nav-toggle span {
    width: 24px; height: 2px; background: var(--text-primary);
    border-radius: 2px; transition: all 0.3s;
}

.lang-switcher {
    background: transparent;
    color: white;
    border: 1px solid var(--border);
    border-radius: 4px;
    padding: 4px 8px;
    cursor: pointer;
    font-family: inherit;
    font-weight: 500;
    font-size: 0.9rem;
}

.lang-switcher option {
    background: var(--bg-primary);
    color: white;
}

/* ── Hero Section ──────────────────────────────────────── */
.hero {
    padding: 200px 0 120px;
    text-align: center;
    position: relative;
}
.hero::before {
    content: ''; position: absolute; top: 0; left: 50%; transform: translateX(-50%);
    width: 80vw; height: 80vh;
    background: radial-gradient(ellipse at center, rgba(59, 130, 246, 0.15) 0%, rgba(139, 92, 246, 0.05) 40%, transparent 70%);
    pointer-events: none; z-index: -1;
}

.hero h1 {
    font-size: clamp(3rem, 6vw, 5rem);
    font-weight: 900;
    line-height: 1.05;
    margin-bottom: 24px;
}

.hero .highlight {
    background: var(--accent-gradient);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    display: inline-block;
}

.hero p {
    color: var(--text-secondary);
    font-size: 1.25rem;
    max-width: 600px;
    margin: 0 auto 48px;
    line-height: 1.8;
}

.hero-buttons { display: flex; gap: 20px; justify-content: center; flex-wrap: wrap; }

/* ── Section Titles ────────────────────────────────────── */
.section { padding: var(--section-padding); position: relative; }

.section-header { text-align: center; margin-bottom: 80px; }

.section-label {
    display: inline-block;
    color: var(--accent);
    background: rgba(59, 130, 246, 0.1);
    padding: 6px 16px;
    border-radius: 30px;
    font-size: 0.85rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 2px;
    margin-bottom: 16px;
    border: 1px solid rgba(59, 130, 246, 0.2);
}

.section-title {
    font-size: clamp(2rem, 4vw, 3rem);
    font-weight: 800;
    margin-bottom: 20px;
}

.section-subtitle {
    color: var(--text-secondary);
    font-size: 1.15rem;
    max-width: 640px;
    margin: 0 auto;
    line-height: 1.7;
}

/* ── Premium Glass Cards ───────────────────────────────── */
.card-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 32px;
}

.card {
    background: var(--bg-card);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 40px;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: var(--shadow-glass);
    position: relative;
    overflow: hidden;
    display: flex;
    flex-direction: column;
}
.card::before {
    content: ''; position: absolute; top: 0; left: 0; right: 0; height: 2px;
    background: var(--accent-gradient); opacity: 0; transition: opacity 0.4s;
}
.card:hover {
    transform: translateY(-8px);
    border-color: rgba(255, 255, 255, 0.15);
    background: var(--bg-card-hover);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.4);
}
.card:hover::before { opacity: 1; }

.card h3 {
    font-size: 1.3rem; font-weight: 700; margin-bottom: 12px;
}
.card p {
    color: var(--text-secondary); font-size: 1rem; line-height: 1.6; margin-bottom: 24px;
    flex-grow: 1;
}
.card .price {
    font-family: var(--font-heading); font-size: 1.5rem; font-weight: 800;
    color: var(--text-primary); margin-bottom: 20px;
}

/* ── Services Grid ─────────────────────────────────────── */
.services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
    gap: 24px;
}

.service-card {
    background: var(--bg-card);
    backdrop-filter: blur(12px);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 32px 24px;
    text-align: center;
    transition: all 0.3s ease;
}
.service-card:hover {
    transform: translateY(-5px);
    background: var(--bg-card-hover);
    border-color: rgba(59, 130, 246, 0.3);
    box-shadow: 0 10px 30px rgba(59, 130, 246, 0.1);
}

.service-icon { font-size: 2.2rem; margin-bottom: 16px; display: inline-block; filter: drop-shadow(0 4px 6px rgba(0,0,0,0.3)); }
.service-card h3 { font-size: 1.1rem; font-weight: 700; margin-bottom: 10px; }
.service-card p { color: var(--text-secondary); font-size: 0.9rem; line-height: 1.6; }

/* ── Steps ─────────────────────────────────────────────── */
.steps-grid {
    display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 32px; counter-reset: step;
}

.step-card {
    background: transparent;
    border-left: 2px solid var(--border);
    padding: 10px 0 10px 32px;
    position: relative;
    counter-increment: step;
}
.step-card:hover { border-color: var(--accent); }

.step-card::before {
    content: counter(step);
    position: absolute; left: -21px; top: 10px;
    width: 40px; height: 40px;
    background: var(--bg-primary);
    border: 2px solid var(--accent);
    color: var(--accent);
    border-radius: 50%;
    display: flex; align-items: center; justify-content: center;
    font-weight: 800; font-family: var(--font-heading);
    box-shadow: 0 0 15px rgba(59, 130, 246, 0.2);
    transition: all 0.3s;
}
.step-card:hover::before { background: var(--accent); color: #fff; }

.step-card h3 { font-size: 1.2rem; margin-bottom: 12px; }
.step-card p { color: var(--text-secondary); font-size: 1rem; }

/* ── Hiring Cards ──────────────────────────────────────── */
.hiring-grid {
    display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 32px;
}

.hiring-card {
    background: var(--bg-card); backdrop-filter: blur(12px); border: 1px solid var(--border);
    border-radius: var(--radius); padding: 36px; display: flex; flex-direction: column; justify-content: space-between;
    transition: all 0.3s ease;
}
.hiring-card:hover { transform: translateY(-5px); border-color: rgba(255,255,255,0.15); box-shadow: var(--shadow-glass); }
.hiring-card h3 { font-size: 1.25rem; margin-bottom: 10px; }
.hiring-card .tag {
    display: inline-block; background: rgba(59, 130, 246, 0.1); color: var(--accent);
    padding: 6px 16px; border-radius: 30px; font-size: 0.8rem; font-weight: 700; margin-bottom: 16px; width: fit-content;
}
.hiring-card p { color: var(--text-secondary); font-size: 0.95rem; margin-bottom: 24px; line-height: 1.6; }

/* ── Forms ─────────────────────────────────────────────── */
.form-section { max-width: 680px; margin: 0 auto; }
.form-group { margin-bottom: 24px; }
.form-group label { display: block; font-weight: 600; font-size: 0.95rem; margin-bottom: 10px; color: var(--text-primary); }

.form-group input, .form-group select, .form-group textarea {
    width: 100%; padding: 16px 20px;
    background: rgba(255, 255, 255, 0.03); backdrop-filter: blur(10px);
    border: 1px solid var(--border); border-radius: var(--radius-sm);
    color: var(--text-primary); font-family: var(--font-body); font-size: 1rem;
    transition: all 0.3s ease;
}
.form-group input:focus, .form-group select:focus, .form-group textarea:focus {
    outline: none; border-color: var(--accent); background: rgba(255, 255, 255, 0.05);
    box-shadow: 0 0 0 4px rgba(59, 130, 246, 0.15);
}
.form-group textarea { min-height: 140px; resize: vertical; }

/* Fix dropdown options visibility in dark mode */
.form-group select option {
    background: var(--bg-secondary);
    color: var(--text-primary);
}

/* ── Alerts ────────────────────────────────────────────── */
.alert { padding: 16px 24px; border-radius: var(--radius-sm); margin-bottom: 24px; font-size: 0.95rem; font-weight: 500; }
.alert-success { background: rgba(16, 185, 129, 0.1); border: 1px solid rgba(16, 185, 129, 0.2); color: var(--success); }
.alert-error { background: rgba(239, 68, 68, 0.1); border: 1px solid rgba(239, 68, 68, 0.2); color: var(--danger); }

/* ── Auth Page ─────────────────────────────────────────── */
.auth-wrapper {
    min-height: 100vh; display: flex; align-items: center; justify-content: center;
    padding: 120px 24px 60px;
    background: radial-gradient(circle at 50% 50%, rgba(59,130,246,0.1) 0%, transparent 60%);
}
.auth-card {
    background: rgba(15, 23, 42, 0.6); backdrop-filter: blur(24px); -webkit-backdrop-filter: blur(24px);
    border: 1px solid rgba(255,255,255,0.08); border-radius: var(--radius);
    padding: 56px 48px; width: 100%; max-width: 480px; box-shadow: 0 25px 50px -12px rgba(0,0,0,0.5);
}
.auth-card h1 { font-size: 2rem; margin-bottom: 12px; text-align: center; }
.auth-card .subtitle { color: var(--text-secondary); text-align: center; margin-bottom: 40px; font-size: 1.05rem; }

/* ── Store Filters ─────────────────────────────────────── */
.store-hero { padding: 180px 0 80px; text-align: center; }
.store-filters { display: flex; gap: 16px; justify-content: center; margin-bottom: 56px; flex-wrap: wrap; }
.filter-btn {
    padding: 10px 28px; border-radius: 30px; border: 1px solid var(--border);
    background: rgba(255,255,255,0.03); color: var(--text-secondary);
    font-family: var(--font-heading); font-size: 0.95rem; font-weight: 600;
    cursor: pointer; transition: all 0.3s; backdrop-filter: blur(10px);
}
.filter-btn:hover { background: rgba(255,255,255,0.08); color: white; }
.filter-btn.active { background: var(--accent-gradient); border-color: transparent; color: #fff; box-shadow: 0 4px 15px rgba(59,130,246,0.3); }

/* ── Admin Panel ───────────────────────────────────────── */
.panel-wrapper { padding: 120px 24px 60px; max-width: 1400px; margin: 0 auto; }
.panel-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 40px; }
.panel-header h1 { font-size: 2.2rem; }

.panel-tabs {
    display: flex; gap: 8px; margin-bottom: 40px; background: rgba(255,255,255,0.03);
    padding: 6px; border-radius: 12px; width: fit-content; border: 1px solid var(--border); backdrop-filter: blur(10px);
}
.panel-tab {
    padding: 12px 24px; border: none; background: transparent; color: var(--text-secondary);
    font-family: var(--font-heading); font-size: 0.95rem; font-weight: 600;
    cursor: pointer; border-radius: 8px; transition: all 0.3s;
}
.panel-tab:hover { color: var(--text-primary); background: rgba(255,255,255,0.05); }
.panel-tab.active { background: var(--accent); color: #fff; box-shadow: 0 4px 12px rgba(59,130,246,0.2); }

.panel-content { display: none; animation: fadeIn 0.4s ease; }
.panel-content.active { display: block; }

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

.stats-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 24px; margin-bottom: 40px; }
.stat-card {
    background: var(--bg-card); backdrop-filter: blur(12px); border: 1px solid var(--border);
    border-radius: var(--radius); padding: 32px; box-shadow: var(--shadow-glass);
}
.stat-card .label { color: var(--text-muted); font-size: 0.9rem; font-weight: 600; text-transform: uppercase; letter-spacing: 1.5px; margin-bottom: 12px; }
.stat-card .value { font-size: 2.5rem; font-weight: 800; font-family: var(--font-heading); background: var(--accent-gradient); -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent; }

.data-table {
    width: 100%; border-collapse: collapse; background: var(--bg-card); backdrop-filter: blur(12px);
    border-radius: var(--radius); overflow: hidden; border: 1px solid var(--border);
}
.data-table th, .data-table td { padding: 18px 24px; text-align: left; font-size: 0.95rem; }
.data-table th { background: rgba(0,0,0,0.2); color: var(--text-secondary); font-weight: 700; text-transform: uppercase; letter-spacing: 1px; font-size: 0.85rem; border-bottom: 1px solid var(--border); }
.data-table td { border-bottom: 1px solid rgba(255,255,255,0.05); color: var(--text-primary); }
.data-table tr:hover td { background: rgba(255,255,255,0.02); }

.badge { display: inline-block; padding: 6px 14px; border-radius: 30px; font-size: 0.8rem; font-weight: 700; text-transform: capitalize; }
.badge-new { background: rgba(59, 130, 246, 0.15); color: #60a5fa; border: 1px solid rgba(59,130,246,0.3); }
.badge-review { background: rgba(245, 158, 11, 0.15); color: #fbbf24; border: 1px solid rgba(245,158,11,0.3); }
.badge-sent { background: rgba(139, 92, 246, 0.15); color: #a78bfa; border: 1px solid rgba(139,92,246,0.3); }
.badge-done { background: rgba(16, 185, 129, 0.15); color: #34d399; border: 1px solid rgba(16,185,129,0.3); }

.kanban-board { display: grid; grid-template-columns: repeat(4, 1fr); gap: 24px; }
.kanban-column { background: rgba(255,255,255,0.02); border: 1px solid var(--border); border-radius: var(--radius); padding: 24px; min-height: 400px; backdrop-filter: blur(10px); }
.kanban-column h3 { font-size: 1rem; font-weight: 700; text-transform: uppercase; letter-spacing: 1.5px; color: var(--text-secondary); margin-bottom: 24px; border-bottom: 1px solid var(--border); padding-bottom: 16px; }
.kanban-item { background: var(--bg-primary); border: 1px solid rgba(255,255,255,0.08); border-radius: var(--radius-sm); padding: 18px; margin-bottom: 16px; box-shadow: 0 4px 12px rgba(0,0,0,0.2); transition: transform 0.2s; cursor: grab; }
.kanban-item:hover { transform: translateY(-3px); border-color: rgba(255,255,255,0.15); }
.kanban-item h4 { font-size: 1rem; margin-bottom: 8px; font-family: var(--font-heading); }
.kanban-item p { color: var(--text-secondary); font-size: 0.85rem; line-height: 1.5; }

.notes-area { width: 100%; min-height: 500px; padding: 24px; background: rgba(0,0,0,0.2); backdrop-filter: blur(12px); border: 1px solid var(--border); border-radius: var(--radius); color: var(--text-primary); font-family: var(--font-body); font-size: 1rem; line-height: 1.8; resize: vertical; transition: border-color 0.3s; }
.notes-area:focus { outline: none; border-color: var(--accent); box-shadow: 0 0 0 4px rgba(59,130,246,0.1); }

/* ── Footer ────────────────────────────────────────────── */
.footer { border-top: 1px solid var(--border); padding: 80px 0 40px; background: #010308; position: relative; overflow: hidden; }
.footer::before { content: ''; position: absolute; top: 0; left: 50%; transform: translateX(-50%); width: 100%; height: 1px; background: linear-gradient(90deg, transparent, rgba(59,130,246,0.5), transparent); }
.footer-grid { display: grid; grid-template-columns: 2fr 1fr 1fr 1fr; gap: 48px; margin-bottom: 60px; }
.footer-tagline { color: var(--text-secondary); font-size: 0.95rem; margin-top: 16px; max-width: 320px; line-height: 1.6; }
.footer-col h4 { font-size: 1.05rem; font-weight: 700; margin-bottom: 24px; color: var(--text-primary); }
.footer-col ul li { margin-bottom: 16px; }
.footer-col ul li a, .footer-col ul li { color: var(--text-muted); font-size: 0.95rem; transition: color 0.3s; }
.footer-col ul li a:hover { color: var(--accent); }
.footer-bottom { border-top: 1px solid rgba(255,255,255,0.05); padding-top: 32px; text-align: center; color: var(--text-muted); font-size: 0.9rem; }

/* ── Utilities ─────────────────────────────────────────── */
.bg-alt { background: var(--bg-secondary); }

/* ── Responsive ────────────────────────────────────────── */
@media (max-width: 1024px) {
    .kanban-board { grid-template-columns: repeat(2, 1fr); }
    .footer-grid { grid-template-columns: 1fr 1fr; gap: 40px; }
}

@media (max-width: 768px) {
    .nav-links { display: none; position: absolute; top: 80px; left: 0; right: 0; background: rgba(3,7,18,0.95); backdrop-filter: blur(20px); border-bottom: 1px solid var(--border); flex-direction: column; padding: 24px; gap: 20px; text-align: center; }
    .nav-links.open { display: flex; }
    .nav-cta { display: none; }
    .nav-toggle { display: flex; }
    .hero { padding: 160px 0 80px; }
    .hero h1 { font-size: 2.5rem; }
    .card-grid, .services-grid, .steps-grid, .hiring-grid, .stats-grid, .kanban-board { grid-template-columns: 1fr; }
    .footer-grid { grid-template-columns: 1fr; gap: 32px; text-align: center; }
    .footer-tagline { margin: 16px auto 0; }
    .auth-card { padding: 40px 24px; }
    .panel-wrapper { padding-top: 100px; }
    .panel-tabs { overflow-x: auto; width: 100%; white-space: nowrap; }
    .table-wrapper { overflow-x: auto; }
}

@media (max-width: 480px) {
    .hero-buttons { flex-direction: column; align-items: stretch; }
    .hero-buttons .btn { width: 100%; }
}
