/* HRMS page styles - moved unchanged from the <style> block in Hrms.tsx */
/* HRMS Specific Styles - Homepage Blue/Purple Theme */
:root {
    --hrms-primary: #4f8ef7;
    --hrms-secondary: #8b5cf6;
    --hrms-accent: #06b6d4;
    --hrms-bg: #030712;
    --hrms-surface: #0d1117;
    --hrms-text: #e6edf3;
    --hrms-muted: #7d8590;
    --hrms-border: rgba(255,255,255,0.07);
}

body {
    background: var(--hrms-bg);
    color: var(--hrms-text);
}

body::before {
    content: '';
    position: fixed;
    inset: 0;
    pointer-events: none;
    z-index: 0;
}

/* Hero Section */
.hrms-hero {
    position: relative;
    padding: 120px 6% 80px;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 80px;
    align-items: center;
    max-width: 1300px;
    margin: 0 auto;
}

.hero-orb {
    position: absolute;
    border-radius: 50%;
    filter: blur(80px);
    pointer-events: none;
}

.orb1 {
    width: 400px; height: 400px;
    background: radial-gradient(circle, rgba(79,142,247,0.12) 0%, transparent 70%);
    top: 0; left: 0;
    animation: pulse 6s ease-in-out infinite;
}

@keyframes pulse {
    0%, 100% { opacity: 0.6; }
    50% { opacity: 1; }
}

.hero-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: rgba(79,142,247,0.08);
    border: 1px solid rgba(79,142,247,0.2);
    border-radius: 100px;
    padding: 6px 14px;
    font-size: 0.78rem;
    color: var(--hrms-primary);
    font-weight: 500;
    margin-bottom: 22px;
}

.badge-dot {
    width: 6px; height: 6px;
    background: var(--hrms-primary);
    border-radius: 50%;
    animation: blink 1.5s infinite;
}

@keyframes blink {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.2; }
}

.hrms-hero h1 {
    font-size: clamp(2.6rem, 5vw, 4.2rem);
    font-weight: 800;
    line-height: 1.1;
    letter-spacing: -1.5px;
    margin-bottom: 20px;
}

.gradient {
    background: linear-gradient(135deg, var(--hrms-primary), var(--hrms-secondary));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.hero-desc {
    font-size: 1.05rem;
    color: var(--hrms-muted);
    line-height: 1.75;
    margin-bottom: 36px;
}

.hero-actions {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
}

.btn-hrms-primary {
    background: linear-gradient(135deg, var(--hrms-primary), var(--hrms-secondary));
    color: #fff !important;
    font-weight: 600;
    padding: 13px 28px;
    border-radius: 10px;
    text-decoration: none;
    box-shadow: 0 0 30px rgba(79,142,247,0.2);
    transition: all 0.25s;
    -webkit-text-fill-color: #fff !important;
}

.btn-hrms-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 0 50px rgba(79,142,247,0.35);
}

.btn-hrms-secondary {
    background: transparent;
    color: var(--hrms-text);
    font-weight: 500;
    padding: 13px 28px;
    border-radius: 10px;
    border: 1px solid var(--hrms-border);
    text-decoration: none;
    transition: all 0.25s;
}

.btn-hrms-secondary:hover {
    border-color: rgba(79,142,247,0.3);
    background: rgba(79,142,247,0.05);
}

/* Dashboard Mockup */
.dashboard {
    background: var(--hrms-surface);
    border: 1px solid var(--hrms-border);
    border-radius: 20px;
    overflow: hidden;
    box-shadow: 0 12px 40px rgba(0,0,0,0.18);
    animation: dashboardFloat 4s ease-in-out infinite;
}

@keyframes dashboardFloat {
    0%   { transform: translateY(0px);    box-shadow: 0 12px 40px rgba(0,0,0,0.18); }
    50%  { transform: translateY(-16px);  box-shadow: 0 20px 50px rgba(0,0,0,0.14); }
    100% { transform: translateY(0px);    box-shadow: 0 12px 40px rgba(0,0,0,0.18); }
}

.dash-header {
    background: #161b22;
    padding: 14px 20px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    border-bottom: 1px solid var(--hrms-border);
}

.dash-dots { display: flex; gap: 6px; }
.dash-dot { width: 10px; height: 10px; border-radius: 50%; }
.dd-red { background: #ff5f57; }
.dd-yellow { background: #febc2e; }
.dd-green { background: #28c840; }

.dash-title {
    font-size: 0.78rem;
    font-weight: 600;
    color: var(--hrms-muted);
}

.dash-body {
    padding: 20px;
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.dash-kpi-row {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 10px;
}

.kpi-card {
    background: #161b22;
    border: 1px solid var(--hrms-border);
    border-radius: 12px;
    padding: 14px;
}

.kpi-label {
    font-size: 0.7rem;
    color: var(--hrms-muted);
    margin-bottom: 6px;
}

.kpi-value {
    font-size: 1.4rem;
    font-weight: 800;
}

.kpi-value.teal { color: var(--hrms-primary); }
.kpi-value.blue { color: var(--hrms-secondary); }
.kpi-value.purple { color: var(--hrms-accent); }

.kpi-trend {
    font-size: 0.68rem;
    color: #22c55e;
    margin-top: 4px;
}

/* Stats Section */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
    max-width: 1000px;
    margin: 56px auto 0;
}

.stat-card {
    background: var(--hrms-surface);
    border: 1px solid var(--hrms-border);
    border-radius: 16px;
    padding: 32px 20px;
    text-align: center;
    transition: all 0.3s;
}

.stat-card:hover {
    border-color: rgba(79,142,247,0.2);
    transform: translateY(-4px);
}

.stat-num {
    font-size: 2.2rem;
    font-weight: 800;
    background: linear-gradient(135deg, var(--hrms-primary), var(--hrms-secondary));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    margin-bottom: 8px;
}

.stat-label {
    font-size: 0.82rem;
    color: var(--hrms-muted);
}

/* Section Styles */
.hrms-section {
    padding: 90px 6%;
    position: relative;
}

.section-tag {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    font-size: 0.75rem;
    font-weight: 600;
    letter-spacing: 2px;
    text-transform: uppercase;
    color: var(--hrms-primary);
    margin-bottom: 14px;
}

.section-tag::before {
    content: '';
    width: 30px;
    height: 2px;
    background: linear-gradient(90deg, var(--hrms-primary), transparent);
    border-radius: 2px;
    flex-shrink: 0;
}

.section-title {
    font-size: clamp(1.85rem, 3vw, 2.8rem);
    font-weight: 800;
    letter-spacing: -1px;
    line-height: 1.15;
    margin-bottom: 14px;
}

.section-sub {
    font-size: 1rem;
    color: var(--hrms-muted);
    max-width: 560px;
    line-height: 1.7;
}

/* Features Grid */
.features-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 18px;
    max-width: 1200px;
    margin: 56px auto 0;
}

.feat-card {
    background: var(--hrms-surface);
    border: 1px solid var(--hrms-border);
    border-radius: 16px;
    padding: 28px;
    transition: all 0.3s;
}

.feat-card:hover {
    border-color: rgba(79,142,247,0.2);
    transform: translateY(-4px);
    box-shadow: 0 16px 50px rgba(0,0,0,0.3);
}

.feat-icon {
    width: 48px;
    height: 48px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.4rem;
    margin-bottom: 18px;
    background: rgba(79,142,247,0.1);
    border: 1px solid rgba(79,142,247,0.2);
}

/* Icon color variants */
.feat-icon.fi-teal   { background: rgba(79,142,247,0.12);  border-color: rgba(79,142,247,0.3); }
.feat-icon.fi-blue   { background: rgba(139,92,246,0.12);  border-color: rgba(139,92,246,0.3); }
.feat-icon.fi-purple { background: rgba(168,85,247,0.12); border-color: rgba(168,85,247,0.3); }
.feat-icon.fi-orange { background: rgba(245,158,11,0.12); border-color: rgba(245,158,11,0.3); }
.feat-icon.fi-green  { background: rgba(34,197,94,0.12);  border-color: rgba(34,197,94,0.3); }
.feat-icon.fi-pink   { background: rgba(236,72,153,0.12); border-color: rgba(236,72,153,0.3); }

.feat-name {
    font-size: 1rem;
    font-weight: 700;
    margin-bottom: 8px;
}

.feat-desc {
    font-size: 0.87rem;
    color: var(--hrms-muted);
    line-height: 1.65;
}

/* Responsive */
@media (max-width: 900px) {
    .hrms-hero { grid-template-columns: 1fr; gap: 40px; }
    .features-grid { grid-template-columns: 1fr; }
    .stats-grid { grid-template-columns: 1fr 1fr; }
}

/* Highlights Section */
.highlights-inner {
    max-width: 1100px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 60px;
    align-items: start;
}

.hl-list { display: flex; flex-direction: column; gap: 12px; margin-top: 28px; }

.hl-item {
    display: flex;
    align-items: flex-start;
    gap: 14px;
    padding: 16px;
    border-radius: 12px;
    background: rgba(255,255,255,0.02);
    border: 1px solid var(--hrms-border);
}

.hl-icon { font-size: 1.2rem; flex-shrink: 0; margin-top: 2px; }

.hl-text { display: flex; flex-direction: column; gap: 4px; }
.hl-text strong { font-size: 0.9rem; font-weight: 700; color: var(--hrms-text); }
.hl-text p { font-size: 0.82rem; color: var(--hrms-muted); line-height: 1.6; margin: 0; }

/* Flow / How It Works — LMS style */
.flow-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 16px;
    max-width: 1100px;
    margin: 0 auto;
    position: relative;
}

.flow-step-card {
    text-align: center;
    padding: 28px 20px;
    border-radius: 20px;
    background: rgba(255,255,255,0.05);
    border: 1px solid rgba(255,255,255,0.15);
    transition: all 0.3s ease;
    position: relative;
    z-index: 1;
    box-shadow: 0 4px 16px rgba(0,0,0,0.3);
}
.flow-step-card:hover {
    background: rgba(79,142,247,0.1);
    border-color: rgba(79,142,247,0.4);
    transform: translateY(-4px);
    box-shadow: 0 8px 24px rgba(79,142,247,0.2);
}

.flow-connector {
    display: none;
}
@media (min-width: 768px) {
    .flow-connector {
        display: block;
        position: absolute;
        top: 64px;
        left: 12.5%; right: 12.5%;
        height: 2px;
        z-index: 0;
        border-radius: 2px;
        background: linear-gradient(90deg, #4f8ef7 0%, #8b5cf6 33%, #f59e0b 66%, #10b981 100%);
        opacity: 0.5;
    }
}

@media (max-width: 900px) {
    .flow-grid { grid-template-columns: 1fr 1fr; gap: 16px; }
}
@media (max-width: 480px) {
    .flow-grid { grid-template-columns: 1fr; }
}

/* Dashboard extra elements */
.dash-section-title {
    font-size: 0.68rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: rgba(255,255,255,0.35);
    margin-bottom: 8px;
}

.emp-list { display: flex; flex-direction: column; gap: 6px; }

.emp-row {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px 10px;
    border-radius: 10px;
    background: rgba(255,255,255,0.03);
    border: 1px solid rgba(255,255,255,0.06);
}

.emp-avatar {
    width: 32px; height: 32px;
    border-radius: 50%;
    display: flex; align-items: center; justify-content: center;
    font-size: 0.68rem;
    font-weight: 700;
    flex-shrink: 0;
}

.ea-a { background: rgba(79,142,247,0.2); color: #4f8ef7; border: 1px solid rgba(79,142,247,0.3); }
.ea-b { background: rgba(139,92,246,0.2); color: #8b5cf6; border: 1px solid rgba(139,92,246,0.3); }
.ea-c { background: rgba(239,68,68,0.2);  color: #ef4444; border: 1px solid rgba(239,68,68,0.3); }

.emp-info { flex: 1; min-width: 0; }

.emp-name {
    font-size: 0.75rem;
    font-weight: 600;
    color: rgba(255,255,255,0.85);
}

.emp-role {
    font-size: 0.67rem;
    color: rgba(255,255,255,0.4);
}

.ai-badge {
    font-size: 0.67rem;
    font-weight: 700;
    padding: 3px 10px;
    border-radius: 100px;
    flex-shrink: 0;
}

.ai-badge.green  { background: rgba(34,197,94,0.15);  color: #22c55e; border: 1px solid rgba(34,197,94,0.3); }
.ai-badge.yellow { background: rgba(251,191,36,0.15); color: #fbbf24; border: 1px solid rgba(251,191,36,0.3); }
.ai-badge.red    { background: rgba(239,68,68,0.15);  color: #ef4444; border: 1px solid rgba(239,68,68,0.3); }

.ai-insight-bar {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    padding: 12px 14px;
    border-radius: 10px;
    background: rgba(79,142,247,0.06);
    border: 1px solid rgba(79,142,247,0.2);
}

.insight-icon { font-size: 1rem; flex-shrink: 0; margin-top: 1px; }

.insight-text {
    display: flex;
    flex-direction: column;
    gap: 3px;
}

.insight-text strong {
    font-size: 0.75rem;
    font-weight: 700;
    color: var(--hrms-primary);
}

.insight-text span {
    font-size: 0.68rem;
    color: rgba(255,255,255,0.5);
    line-height: 1.4;
}

    /* Metrics Bar — LMS style */
    .hrms-metric-item {
      display: flex;
      align-items: center;
      gap: 16px;
      padding: 20px 24px;
      border-radius: 16px;
      background: rgba(255,255,255,0.025);
      border: 1px solid rgba(255,255,255,0.07);
      transition: all 0.3s ease;
    }
    .hrms-metric-item:hover {
      background: rgba(79,142,247,0.08);
      border-color: rgba(79,142,247,0.25);
      transform: translateY(-3px);
    }
    .hrms-metric-num {
      font-size: 1.75rem;
      font-weight: 800;
      font-family: 'Poppins', sans-serif;
      background: linear-gradient(135deg, #fff, rgba(255,255,255,0.7));
      -webkit-background-clip: text;
      -webkit-text-fill-color: transparent;
      background-clip: text;
    }
    @media (max-width: 480px) {
      .hrms-metrics-bar .grid { grid-template-columns: 1fr !important; }
    }

    /* ============================================================
       LIGHT MODE OVERRIDES
    ============================================================ */
    [data-theme="light"] {
        --hrms-bg: #f8fafc;
        --hrms-surface: #ffffff;
        --hrms-text: #0f172a;
        --hrms-muted: #64748b;
        --hrms-border: rgba(0,0,0,0.08);
    }
    [data-theme="light"] body { background: #f8fafc; color: #0f172a; }

    /* Hero */
    [data-theme="light"] .hero-desc { color: #64748b; }
    [data-theme="light"] .btn-hrms-secondary { color: #0f172a; border-color: rgba(0,0,0,0.15); }
    [data-theme="light"] .btn-hrms-secondary:hover { border-color: rgba(79,142,247,0.4); background: rgba(79,142,247,0.06); }

    /* Dashboard mockup */
    [data-theme="light"] .dashboard { box-shadow: 0 8px 24px rgba(0,0,0,0.07); }
    [data-theme="light"] .dash-header { background: #f1f5f9; border-bottom-color: rgba(0,0,0,0.08); }
    [data-theme="light"] .kpi-card { background: #f8fafc; border-color: rgba(0,0,0,0.08); }
    [data-theme="light"] .dash-section-title { color: rgba(0,0,0,0.45); }
    [data-theme="light"] .emp-row { background: rgba(0,0,0,0.03); border-color: rgba(0,0,0,0.07); }
    [data-theme="light"] .emp-name { color: rgba(0,0,0,0.85); }
    [data-theme="light"] .emp-role { color: rgba(0,0,0,0.45); }
    [data-theme="light"] .insight-text span { color: rgba(0,0,0,0.55); }
    [data-theme="light"] .ai-insight-bar { background: rgba(79,142,247,0.08); border-color: rgba(79,142,247,0.25); }
    [data-theme="light"] .insight-text strong { color: #2563eb; }

    /* Metrics bar */
    [data-theme="light"] .hrms-metrics-bar { border-top-color: rgba(0,0,0,0.08) !important; border-bottom-color: rgba(0,0,0,0.08) !important; }
    [data-theme="light"] .hrms-metric-item { background: #ffffff; border-color: rgba(0,0,0,0.08); box-shadow: 0 2px 8px rgba(0,0,0,0.05); }
    [data-theme="light"] .hrms-metric-item:hover { background: rgba(79,142,247,0.06); border-color: rgba(79,142,247,0.25); }
    [data-theme="light"] .hrms-metric-num { background: linear-gradient(135deg,#1e293b,#334155); -webkit-background-clip:text; -webkit-text-fill-color:transparent; background-clip:text; }
    [data-theme="light"] .hrms-metric-item .text-xs { color: #64748b !important; }

    /* Features grid */
    [data-theme="light"] .feat-card { background: #ffffff; border-color: rgba(0,0,0,0.08); box-shadow: 0 2px 12px rgba(0,0,0,0.06); }
    [data-theme="light"] .feat-card:hover { box-shadow: 0 16px 50px rgba(0,0,0,0.1); border-color: rgba(79,142,247,0.25); }
    [data-theme="light"] .feat-name { color: #0f172a; }
    [data-theme="light"] .feat-desc { color: #64748b; }

    /* Stats */
    [data-theme="light"] .stat-card { background: #ffffff; border-color: rgba(0,0,0,0.08); box-shadow: 0 2px 12px rgba(0,0,0,0.06); }
    [data-theme="light"] .stat-label { color: #64748b; }

    /* Section headings & tags */
    [data-theme="light"] .section-title { color: #0f172a; }
    [data-theme="light"] .section-sub { color: #64748b; }
    [data-theme="light"] .section-tag { color: #2563eb; }
    [data-theme="light"] .section-tag::before { background: linear-gradient(90deg,#2563eb,transparent); }

    /* AI Highlights section */
    /* [data-theme="light"] .hrms-section[style*="rgba(13,17,23"] { background: #f1f5f9 !important; } */
    [data-theme="light"] .hl-item { background: #ffffff; border-color: rgba(0,0,0,0.08); box-shadow: 0 1px 4px rgba(0,0,0,0.05); }
    [data-theme="light"] .hl-text strong { color: #0f172a; }
    [data-theme="light"] .hl-text p { color: #64748b; }
    /* Performance chart panel */
    [data-theme="light"] .highlights-inner > div:last-child > div:first-child { background: #ffffff !important; border-color: rgba(0,0,0,0.08) !important; }
    [data-theme="light"] .highlights-inner [style*="rgba(255,255,255,0.8)"] { color: rgba(0,0,0,0.8) !important; }
    [data-theme="light"] .highlights-inner [style*="rgba(255,255,255,0.06)"][style*="border-radius:100px"] { background: rgba(0,0,0,0.08) !important; }
    [data-theme="light"] .highlights-inner [style*="font-size:0.72rem"][style*="color:var(--hrms-muted)"],
    [data-theme="light"] .highlights-inner [style*="text-transform:uppercase"] { color: #64748b !important; }

    /* How It Works — flow step cards */
    [data-theme="light"] .flow-step-card { background: #ffffff; border-color: rgba(0,0,0,0.08); box-shadow: 0 2px 8px rgba(0,0,0,0.05); }
    [data-theme="light"] .flow-step-card:hover { background: rgba(79,142,247,0.05); border-color: rgba(79,142,247,0.25); }
    [data-theme="light"] .flow-step-card .text-white { color: #0f172a !important; }
    [data-theme="light"] .flow-step-card [style*="rgba(255,255,255,0.45)"] { color: rgba(0,0,0,0.55) !important; }
    [data-theme="light"] .flow-connector { background: linear-gradient(90deg,#4f8ef7 0%,#8b5cf6 33%,#f59e0b 66%,#10b981 100%) !important; opacity: 0.4 !important; }

    /* Section borders */
    [data-theme="light"] .hrms-section { border-top-color: rgba(0,0,0,0.08) !important; }

    /* FAQ */
    [data-theme="light"] .faq-item-ui { background: #ffffff; border-color: rgba(0,0,0,0.08) !important; }
    [data-theme="light"] .faq-trigger span[itemprop="name"] { color: rgba(0,0,0,0.85) !important; }
    [data-theme="light"] .faq-icon { color: rgba(0,0,0,0.4) !important; }
    [data-theme="light"] .faq-body p { color: #64748b !important; }

    /* CTA section */
    /* [data-theme="light"] #cta { background: #f1f5f9 !important; } */
    [data-theme="light"] #cta h2 { color: #0f172a !important; }
    [data-theme="light"] #cta p { color: #475569 !important; }
    [data-theme="light"] #cta > div > div {
        background: linear-gradient(135deg,rgba(79,142,247,0.07),rgba(139,92,246,0.07)) !important;
        border-color: rgba(139,92,246,0.2) !important;
        box-shadow: 0 4px 24px rgba(0,0,0,0.06);
    }
