/* JobPortal - Indeed-inspired theme.
   Primary: #2557a7 (Indeed blue), Hover: #164081, Bg: #f3f2f1.
   Designed to be easily tweakable: change CSS vars below to re-skin. */

:root {
    --jp-primary: #2557a7;
    --jp-primary-dark: #164081;
    --jp-primary-50: #e8f0fe;
    --jp-primary-100: #d2e3fc;
    --jp-bg: #f3f2f1;
    --jp-card: #ffffff;
    --jp-text: #2d2d2d;
    --jp-muted: #6b6b6b;
    --jp-border: #e3e2e0;
    --jp-border-strong: #d4d2d0;
    --jp-shadow: 0 1px 3px rgba(0,0,0,.04), 0 1px 2px rgba(0,0,0,.06);
    --jp-shadow-lg: 0 4px 6px -1px rgba(0,0,0,.06), 0 2px 4px -1px rgba(0,0,0,.04);
    --jp-radius: 10px;
}

* { box-sizing: border-box; }
html, body { height: 100%; }
body {
    background: var(--jp-bg);
    color: var(--jp-text);
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    font-size: 15px;
    line-height: 1.5;
}
a { color: var(--jp-primary); text-decoration: none; }
a:hover { color: var(--jp-primary-dark); text-decoration: underline; }

/* ---------- Navbar ---------- */
.navbar {
    background: var(--jp-card) !important;
    border-bottom: 1px solid var(--jp-border);
    box-shadow: var(--jp-shadow);
    padding: 0.5rem 0;
}
.navbar-brand {
    font-weight: 800;
    color: var(--jp-primary) !important;
    font-size: 1.4rem;
    letter-spacing: -0.5px;
}
.navbar-brand i { margin-right: 4px; }
.nav-link {
    color: var(--jp-text) !important;
    font-weight: 500;
    padding: 0.5rem 1rem !important;
    border-radius: 6px;
    transition: background 0.15s;
}
.nav-link:hover { background: var(--jp-primary-50); color: var(--jp-primary) !important; }
.nav-link.active-link { background: var(--jp-primary-50); color: var(--jp-primary) !important; }

/* User avatar (initials) */
.user-avatar {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 32px; height: 32px;
    border-radius: 50%;
    background: var(--jp-primary);
    color: #fff;
    font-weight: 600;
    font-size: 0.85rem;
    margin-right: 6px;
}
.user-avatar.lg { width: 48px; height: 48px; font-size: 1.2rem; }

/* ---------- Buttons ---------- */
.btn { border-radius: 6px; font-weight: 600; padding: 0.5rem 1.25rem; transition: all 0.15s; }
.btn-primary {
    background-color: var(--jp-primary);
    border-color: var(--jp-primary);
}
.btn-primary:hover, .btn-primary:focus {
    background-color: var(--jp-primary-dark);
    border-color: var(--jp-primary-dark);
    transform: translateY(-1px);
    box-shadow: 0 4px 8px rgba(37, 87, 167, .25);
}
.btn-outline-primary { color: var(--jp-primary); border-color: var(--jp-primary); }
.btn-outline-primary:hover { background-color: var(--jp-primary); border-color: var(--jp-primary); }
.btn-sm { padding: 0.35rem 0.75rem; font-size: 0.85rem; }
.btn-lg { padding: 0.75rem 2rem; font-size: 1rem; }
.btn-pill { border-radius: 999px; }

/* ---------- Cards ---------- */
.card {
    border: 1px solid var(--jp-border);
    border-radius: var(--jp-radius);
    box-shadow: var(--jp-shadow);
    background: var(--jp-card);
}
.card-header {
    background-color: var(--jp-card);
    border-bottom: 1px solid var(--jp-border);
    font-weight: 600;
    padding: 1rem 1.25rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
}
.card-body { padding: 1.25rem; }

/* ---------- Job cards (Indeed-style list) ---------- */
.job-card {
    cursor: pointer;
    transition: all 0.15s ease;
    background: var(--jp-card);
    border: 1px solid var(--jp-border);
    border-radius: var(--jp-radius);
    padding: 16px 18px;
}
.job-card:hover {
    border-color: var(--jp-primary);
    box-shadow: var(--jp-shadow-lg);
    transform: translateY(-1px);
}
.job-title { color: var(--jp-primary); font-weight: 700; font-size: 1.1rem; margin-bottom: 4px; }
.job-card:hover .job-title { text-decoration: underline; }
.company-name { font-size: 0.92rem; color: var(--jp-text); font-weight: 500; }
.job-meta { font-size: 0.85rem; color: var(--jp-muted); }
.job-meta i { color: var(--jp-primary); margin-right: 3px; }
.job-snippet { font-size: 0.9rem; color: var(--jp-muted); margin-top: 10px; }

/* Company logo placeholder */
.company-logo {
    width: 48px; height: 48px; border-radius: 8px;
    background: var(--jp-primary-50);
    color: var(--jp-primary);
    display: inline-flex; align-items: center; justify-content: center;
    font-weight: 700; font-size: 1.2rem;
    flex-shrink: 0;
}

/* ---------- Search bar (Indeed-style) ---------- */
.search-bar {
    background: var(--jp-card);
    border: 1px solid var(--jp-border);
    border-radius: var(--jp-radius);
    padding: 16px;
    box-shadow: var(--jp-shadow);
}
.search-bar .form-control {
    border: 1px solid var(--jp-border-strong);
    border-radius: 6px;
    padding: 0.6rem 0.9rem;
}
.search-bar .form-control:focus {
    box-shadow: 0 0 0 3px rgba(37, 87, 167, .15);
    border-color: var(--jp-primary);
}

/* ---------- Sidebar ---------- */
.sidebar {
    background: var(--jp-card);
    border: 1px solid var(--jp-border);
    border-radius: var(--jp-radius);
    box-shadow: var(--jp-shadow);
    padding: 8px 0;
    position: sticky;
    top: 80px;
}
.sidebar-header {
    padding: 12px 18px 8px;
    font-size: 0.7rem;
    font-weight: 700;
    color: var(--jp-muted);
    text-transform: uppercase;
    letter-spacing: 1px;
    border-bottom: 1px solid var(--jp-border);
    margin-bottom: 6px;
}
.sidebar a {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 18px;
    color: var(--jp-text);
    text-decoration: none;
    font-weight: 500;
    font-size: 0.92rem;
    border-left: 3px solid transparent;
    transition: all 0.15s;
}
.sidebar a:hover { background: var(--jp-primary-50); color: var(--jp-primary); text-decoration: none; }
.sidebar a.active {
    background: var(--jp-primary-50);
    color: var(--jp-primary);
    border-left-color: var(--jp-primary);
    font-weight: 600;
}
.sidebar a i { width: 18px; font-size: 1rem; }

/* ---------- Stat cards ---------- */
.stat-card {
    background: var(--jp-card);
    border: 1px solid var(--jp-border);
    border-radius: var(--jp-radius);
    padding: 20px 22px;
    box-shadow: var(--jp-shadow);
    display: flex;
    justify-content: space-between;
    align-items: center;
    transition: all 0.15s;
}
.stat-card:hover { box-shadow: var(--jp-shadow-lg); transform: translateY(-2px); }
.stat-card .stat-value {
    font-size: 1.9rem;
    font-weight: 700;
    color: var(--jp-text);
    line-height: 1;
}
.stat-card .stat-label {
    font-size: 0.78rem;
    color: var(--jp-muted);
    text-transform: uppercase;
    letter-spacing: 0.6px;
    font-weight: 600;
    margin-bottom: 8px;
}
.stat-icon {
    width: 48px; height: 48px;
    border-radius: 12px;
    display: inline-flex; align-items: center; justify-content: center;
    background: var(--jp-primary-50);
    color: var(--jp-primary);
    font-size: 1.5rem;
}

/* ---------- Status Badges ---------- */
.badge-status {
    display: inline-block;
    padding: 4px 12px;
    border-radius: 999px;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: capitalize;
    line-height: 1.4;
}
.badge-active      { background: #e8f5e9; color: #2e7d32; }
.badge-pending     { background: #fff8e1; color: #f57c00; }
.badge-rejected    { background: #ffebee; color: #c62828; }
.badge-closed      { background: #f5f5f5; color: #555; }
.badge-draft       { background: #e3f2fd; color: #1565c0; }
.badge-applied     { background: #e3f2fd; color: #1565c0; }
.badge-reviewed    { background: #fff3e0; color: #e65100; }
.badge-shortlisted { background: #f3e5f5; color: #7b1fa2; }
.badge-hired       { background: #e8f5e9; color: #2e7d32; }
.badge-approved    { background: #e8f5e9; color: #2e7d32; }

/* ---------- Job detail panel ---------- */
.job-detail {
    background: var(--jp-card);
    border: 1px solid var(--jp-border);
    border-radius: var(--jp-radius);
    padding: 28px;
    box-shadow: var(--jp-shadow);
}
.job-detail h1 { font-size: 1.7rem; font-weight: 700; margin-bottom: 6px; }
.job-detail .company-line { font-size: 1rem; color: var(--jp-muted); }
.job-detail .section-title {
    font-weight: 700;
    margin-top: 28px;
    margin-bottom: 12px;
    font-size: 1.1rem;
    color: var(--jp-text);
    border-bottom: 1px solid var(--jp-border);
    padding-bottom: 6px;
}
.meta-pill {
    display: inline-block;
    background: var(--jp-bg);
    padding: 6px 14px;
    border-radius: 999px;
    margin-right: 6px;
    margin-bottom: 6px;
    font-size: 0.85rem;
    color: var(--jp-text);
    border: 1px solid var(--jp-border);
}
.meta-pill i { color: var(--jp-primary); margin-right: 4px; }

/* ---------- Tables ---------- */
.table { background: var(--jp-card); margin-bottom: 0; }
.table thead th {
    background: var(--jp-bg);
    font-weight: 600;
    font-size: 0.78rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: var(--jp-muted);
    border-bottom: 1px solid var(--jp-border);
    padding: 12px 16px;
}
.table tbody td {
    padding: 14px 16px;
    vertical-align: middle;
    border-bottom: 1px solid var(--jp-border);
}
.table tbody tr:hover { background: rgba(37, 87, 167, 0.025); }
.table tbody tr:last-child td { border-bottom: none; }

/* ---------- Auth / forms ---------- */
.auth-card {
    max-width: 460px;
    margin: 60px auto;
    background: var(--jp-card);
    border: 1px solid var(--jp-border);
    border-radius: var(--jp-radius);
    padding: 36px;
    box-shadow: var(--jp-shadow-lg);
}
.auth-card.lg { max-width: 760px; }
.auth-card h2 {
    font-weight: 700;
    color: var(--jp-text);
    margin-bottom: 8px;
    font-size: 1.6rem;
}
.auth-card .subtitle { color: var(--jp-muted); margin-bottom: 24px; }
.form-label { font-weight: 600; font-size: 0.88rem; margin-bottom: 4px; color: var(--jp-text); }
.form-control, .form-select {
    border: 1px solid var(--jp-border-strong);
    border-radius: 6px;
    padding: 0.55rem 0.8rem;
}
.form-control:focus, .form-select:focus {
    border-color: var(--jp-primary);
    box-shadow: 0 0 0 3px rgba(37, 87, 167, .12);
}

/* ---------- Hero ---------- */
.hero {
    background: linear-gradient(135deg, #2557a7 0%, #164081 100%);
    color: #fff;
    padding: 70px 0 50px;
    border-radius: var(--jp-radius);
    margin-bottom: 32px;
    position: relative;
    overflow: hidden;
}
.hero::before {
    content: '';
    position: absolute;
    inset: 0;
    background: radial-gradient(circle at top right, rgba(255,255,255,.08), transparent 60%);
}
.hero h1 { font-weight: 800; font-size: 2.4rem; letter-spacing: -1px; position: relative; }
.hero p { opacity: 0.92; font-size: 1.05rem; position: relative; }
.hero .search-bar { color: var(--jp-text); position: relative; }

/* ---------- Footer ---------- */
.site-footer {
    background: var(--jp-card);
    border-top: 1px solid var(--jp-border);
    padding: 24px 0;
    margin-top: 60px;
    color: var(--jp-muted);
    font-size: 0.9rem;
}

/* ---------- Message thread (application page) ---------- */
.thread { display: flex; flex-direction: column; gap: 14px; padding: 8px 0; }
.thread-msg { display: flex; gap: 10px; max-width: 80%; }
.thread-msg.me { align-self: flex-end; flex-direction: row-reverse; }
.thread-bubble {
    background: var(--jp-bg);
    padding: 10px 14px;
    border-radius: 14px;
    border: 1px solid var(--jp-border);
}
.thread-msg.me .thread-bubble {
    background: var(--jp-primary);
    color: #fff;
    border-color: var(--jp-primary);
}
.thread-bubble .author {
    font-weight: 600;
    font-size: 0.8rem;
    margin-bottom: 4px;
    opacity: 0.85;
}
.thread-bubble .body { font-size: 0.95rem; line-height: 1.45; white-space: pre-wrap; }
.thread-bubble .time { font-size: 0.72rem; opacity: 0.7; margin-top: 4px; display: block; }

/* ---------- Alerts ---------- */
.alert {
    border: 1px solid transparent;
    border-radius: var(--jp-radius);
    padding: 12px 16px;
}
.alert-success { background: #e8f5e9; color: #1b5e20; border-color: #c8e6c9; }
.alert-danger  { background: #ffebee; color: #b71c1c; border-color: #ffcdd2; }

/* ---------- Empty state ---------- */
.empty-state {
    text-align: center;
    padding: 48px 24px;
    color: var(--jp-muted);
}
.empty-state i { font-size: 3rem; opacity: 0.5; }
.empty-state p { margin-top: 12px; margin-bottom: 0; font-size: 0.95rem; }

/* ---------- Page header ---------- */
.page-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    padding-bottom: 12px;
    border-bottom: 1px solid var(--jp-border);
}
.page-header h3 { margin: 0; font-weight: 700; }
.page-header .small-meta { color: var(--jp-muted); font-size: 0.9rem; margin-top: 4px; }

/* ---------- Pagination ---------- */
.page-link { color: var(--jp-primary); border-color: var(--jp-border); }
.page-item.active .page-link { background: var(--jp-primary); border-color: var(--jp-primary); }

/* Responsive */
@media (max-width: 768px) {
    .hero { padding: 40px 16px 30px; }
    .hero h1 { font-size: 1.8rem; }
    .sidebar { position: relative; top: 0; margin-bottom: 16px; }
    .stat-card { padding: 16px; }
    .stat-card .stat-value { font-size: 1.5rem; }
}

/* =====================================================================
   DASHBOARD SHELL — fixed dark sidebar + scrollable main area
   ===================================================================== */
:root {
    --jp-sidebar-bg: #1a1d2e;
    --jp-sidebar-bg-hover: #252a40;
    --jp-sidebar-text: #c9cdd9;
    --jp-sidebar-text-muted: #7c8298;
    --jp-sidebar-width: 260px;
    --jp-topbar-height: 60px;
}

body.dashboard-layout { background: var(--jp-bg); overflow-x: hidden; }

.dash-shell { display: flex; min-height: 100vh; }

/* ---------- Sidebar (fixed) ---------- */
.dash-sidebar {
    position: fixed;
    top: 0; left: 0;
    width: var(--jp-sidebar-width);
    height: 100vh;
    background: var(--jp-sidebar-bg);
    color: var(--jp-sidebar-text);
    display: flex;
    flex-direction: column;
    z-index: 1000;
    overflow-y: auto;
}
.dash-sidebar::-webkit-scrollbar { width: 6px; }
.dash-sidebar::-webkit-scrollbar-thumb { background: rgba(255,255,255,.1); border-radius: 3px; }

.dash-brand {
    padding: 24px 22px 18px;
    border-bottom: 1px solid rgba(255,255,255,.06);
}
.dash-brand a {
    color: var(--jp-primary);
    font-size: 1.4rem;
    font-weight: 800;
    text-decoration: none;
    letter-spacing: -0.5px;
}
.dash-brand a:hover { text-decoration: none; color: #4a7fd8; }
.dash-brand a i { margin-right: 6px; }
.dash-brand .dash-brand-sub {
    color: #fff;
    font-size: 1.05rem;
    font-weight: 600;
    margin-top: 4px;
}

.dash-nav { flex: 1; padding: 14px 0; }
.dash-nav-section {
    padding: 8px 22px 6px;
    font-size: 0.7rem;
    font-weight: 700;
    color: var(--jp-sidebar-text-muted);
    text-transform: uppercase;
    letter-spacing: 1px;
}
.dash-nav a {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 11px 22px;
    color: var(--jp-sidebar-text);
    text-decoration: none;
    font-size: 0.93rem;
    font-weight: 500;
    border-left: 3px solid transparent;
    transition: all 0.15s;
}
.dash-nav a i { width: 18px; font-size: 1.05rem; }
.dash-nav a:hover {
    background: var(--jp-sidebar-bg-hover);
    color: #fff;
    text-decoration: none;
}
.dash-nav a.active {
    background: var(--jp-primary);
    color: #fff;
    border-left-color: #fff;
    font-weight: 600;
}
.dash-nav a.active:hover { background: var(--jp-primary-dark); }

/* Sidebar user footer */
.dash-user {
    padding: 14px 18px;
    border-top: 1px solid rgba(255,255,255,.06);
    display: flex;
    align-items: center;
    gap: 10px;
}
.dash-user .user-info {
    flex: 1;
    overflow: hidden;
}
.dash-user .user-info .name {
    color: #fff;
    font-weight: 600;
    font-size: 0.9rem;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.dash-user .user-info .role {
    color: var(--jp-sidebar-text-muted);
    font-size: 0.78rem;
}
.dash-user .logout-btn {
    background: transparent;
    border: 1px solid rgba(255,255,255,.15);
    color: var(--jp-sidebar-text);
    width: 36px; height: 36px;
    border-radius: 8px;
    display: inline-flex; align-items: center; justify-content: center;
    cursor: pointer;
    transition: all 0.15s;
}
.dash-user .logout-btn:hover { background: #b71c1c; border-color: #b71c1c; color: #fff; }

/* ---------- Main area ---------- */
.dash-main {
    margin-left: var(--jp-sidebar-width);
    flex: 1;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}
.dash-topbar {
    height: var(--jp-topbar-height);
    background: var(--jp-card);
    border-bottom: 1px solid var(--jp-border);
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 28px;
    position: sticky;
    top: 0;
    z-index: 100;
    box-shadow: var(--jp-shadow);
}
.dash-topbar .topbar-title { font-weight: 600; color: var(--jp-text); }
.dash-topbar .topbar-actions { display: flex; align-items: center; gap: 14px; }
.dash-topbar .topbar-actions a {
    color: var(--jp-text);
    font-size: 0.9rem;
    text-decoration: none;
    font-weight: 500;
}
.dash-topbar .topbar-actions a:hover { color: var(--jp-primary); }

.dash-content { padding: 24px 28px; flex: 1; }

/* Mobile toggle */
.dash-toggle {
    display: none;
    background: transparent;
    border: 0;
    color: var(--jp-text);
    font-size: 1.4rem;
    margin-right: 12px;
}

@media (max-width: 992px) {
    .dash-sidebar {
        transform: translateX(-100%);
        transition: transform 0.25s ease;
    }
    .dash-sidebar.open { transform: translateX(0); }
    .dash-main { margin-left: 0; }
    .dash-toggle { display: inline-block; }
    .dash-content { padding: 16px; }
}

/* Backdrop when sidebar is open on mobile */
.dash-backdrop {
    display: none;
    position: fixed; inset: 0;
    background: rgba(0,0,0,.4);
    z-index: 999;
}
.dash-backdrop.show { display: block; }

/* =====================================================================
   PUBLIC PAGES — shine.com-inspired refresh
   ===================================================================== */
:root {
    --jp-accent: #ff6b35;        /* warm CTA accent */
    --jp-accent-dark: #e85420;
    --jp-ink: #1f2937;
    --jp-hero-from: #1e3a8a;
    --jp-hero-to: #2557a7;
}

/* ---- Section helpers ---- */
.section { padding: 56px 0; }
.section-tight { padding: 36px 0; }
.section-head { text-align: center; margin-bottom: 32px; }
.section-head h2 { font-weight: 800; font-size: 1.9rem; color: var(--jp-ink); letter-spacing: -0.5px; }
.section-head p { color: var(--jp-muted); margin: 0; }

/* ---- Home hero ---- */
.home-hero {
    background: linear-gradient(135deg, var(--jp-hero-from) 0%, var(--jp-hero-to) 100%);
    color: #fff;
    padding: 72px 0 64px;
    position: relative;
    overflow: hidden;
}
.home-hero::after {
    content: '';
    position: absolute; right: -120px; top: -120px;
    width: 380px; height: 380px; border-radius: 50%;
    background: rgba(255,255,255,.06);
}
.home-hero::before {
    content: '';
    position: absolute; left: -90px; bottom: -140px;
    width: 320px; height: 320px; border-radius: 50%;
    background: rgba(255,255,255,.05);
}
.home-hero .inner { position: relative; z-index: 1; }
.home-hero h1 { font-weight: 800; font-size: 2.7rem; letter-spacing: -1px; margin-bottom: 10px; }
.home-hero .lead { font-size: 1.1rem; opacity: .92; margin-bottom: 28px; }
.home-hero .stat-strip { display: flex; gap: 36px; flex-wrap: wrap; margin-top: 26px; }
.home-hero .stat-strip .num { font-size: 1.6rem; font-weight: 800; }
.home-hero .stat-strip .lbl { font-size: .85rem; opacity: .85; }

/* Big search card */
.hero-search {
    background: #fff;
    border-radius: 14px;
    padding: 7px;
    display: flex;
    align-items: stretch;
    gap: 4px;
    box-shadow: 0 20px 45px rgba(0,0,0,.25);
    max-width: 760px;
}
.hero-search .field {
    flex: 1;
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 0 16px;
    min-height: 58px;
    border-radius: 9px;
    position: relative;
    transition: background .15s;
}
.hero-search .field:focus-within { background: var(--jp-bg); }
.hero-search .field + .field::before {
    content: '';
    position: absolute; left: 0; top: 12px; bottom: 12px;
    width: 1px; background: var(--jp-border);
}
.hero-search .field i { color: var(--jp-primary); font-size: 1.25rem; flex-shrink: 0; }
.hero-search .field input {
    border: 0; outline: 0; width: 100%;
    font-size: 1rem; color: var(--jp-text);
    background: transparent;
}
.hero-search .field input::placeholder { color: #9aa0ab; }
.hero-search .search-btn {
    border: 0;
    border-radius: 9px;
    background: var(--jp-primary);
    color: #fff;
    font-weight: 700;
    font-size: 1rem;
    padding: 0 30px;
    display: flex;
    align-items: center;
    gap: 8px;
    white-space: nowrap;
    cursor: pointer;
    transition: background .15s, transform .15s;
}
.hero-search .search-btn:hover { background: var(--jp-primary-dark); transform: translateY(-1px); }

/* ---- Category cards ---- */
.cat-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; }
.cat-card {
    background: #fff;
    border: 1px solid var(--jp-border);
    border-radius: 12px;
    padding: 22px 18px;
    text-align: center;
    text-decoration: none;
    color: var(--jp-ink);
    transition: all .15s ease;
    display: block;
}
.cat-card:hover {
    border-color: var(--jp-primary);
    transform: translateY(-3px);
    box-shadow: 0 10px 24px rgba(37,87,167,.12);
    color: var(--jp-primary);
    text-decoration: none;
}
.cat-card .cat-icon {
    width: 56px; height: 56px; border-radius: 14px;
    display: inline-flex; align-items: center; justify-content: center;
    background: var(--jp-primary-50); color: var(--jp-primary);
    font-size: 1.5rem; margin-bottom: 12px;
}
.cat-card .cat-name { font-weight: 700; font-size: .98rem; }
.cat-card .cat-count { font-size: .82rem; color: var(--jp-muted); }

/* ---- How it works ---- */
.step-card { text-align: center; padding: 12px; }
.step-card .step-num {
    width: 52px; height: 52px; border-radius: 50%;
    background: var(--jp-accent); color: #fff;
    display: inline-flex; align-items: center; justify-content: center;
    font-weight: 800; font-size: 1.2rem; margin-bottom: 14px;
}
.step-card h5 { font-weight: 700; }
.step-card p { color: var(--jp-muted); font-size: .9rem; }

/* ---- CTA band ---- */
.cta-band {
    background: linear-gradient(135deg, var(--jp-accent) 0%, var(--jp-accent-dark) 100%);
    color: #fff;
    border-radius: 16px;
    padding: 40px;
    text-align: center;
}
.cta-band h3 { font-weight: 800; }
.cta-band .btn-light { font-weight: 700; border-radius: 10px; color: var(--jp-accent-dark); }

/* ---- Sub-page hero (blogs etc.) ---- */
.page-hero {
    background: linear-gradient(135deg, var(--jp-hero-from) 0%, var(--jp-hero-to) 100%);
    color: #fff;
    padding: 56px 0 48px;
}
.page-hero h1 { font-weight: 800; letter-spacing: -.5px; }
.page-hero p { opacity: .9; }

.blog-search {
    max-width: 540px;
    margin-top: 22px;
    background: #fff;
    border-radius: 12px;
    padding: 6px 6px 6px 16px;
    display: flex; align-items: center; gap: 10px;
    box-shadow: 0 12px 30px rgba(0,0,0,.18);
}
.blog-search i { color: var(--jp-primary); }
.blog-search input { border: 0; outline: 0; flex: 1; font-size: .95rem; }
.blog-search .btn { border-radius: 9px; }

/* ---- Chips ---- */
.chip {
    display: inline-block;
    padding: 7px 16px;
    border-radius: 999px;
    background: #fff;
    border: 1px solid var(--jp-border);
    color: var(--jp-text);
    font-size: .85rem;
    font-weight: 600;
    text-decoration: none;
    transition: all .15s;
}
.chip:hover { border-color: var(--jp-primary); color: var(--jp-primary); text-decoration: none; }
.chip-active { background: var(--jp-primary); border-color: var(--jp-primary); color: #fff; }
.chip-active:hover { color: #fff; }

/* ---- Blog cards ---- */
.blog-card {
    background: #fff;
    border: 1px solid var(--jp-border);
    border-radius: 12px;
    overflow: hidden;
    transition: all .15s ease;
}
.blog-card:hover { transform: translateY(-4px); box-shadow: 0 14px 30px rgba(0,0,0,.1); border-color: var(--jp-primary); }
.blog-card-cover { position: relative; height: 180px; background: var(--jp-primary-50); }
.blog-card-cover img { width: 100%; height: 100%; object-fit: cover; }
.blog-card-cover-fallback {
    width: 100%; height: 100%;
    display: flex; align-items: center; justify-content: center;
    color: var(--jp-primary); font-size: 2.6rem; opacity: .5;
}
.blog-card-cat {
    position: absolute; top: 12px; left: 12px;
    background: var(--jp-primary); color: #fff;
    font-size: .72rem; font-weight: 700;
    padding: 4px 12px; border-radius: 999px;
}
.blog-card-body { padding: 16px 18px 18px; }
.blog-card-title { font-size: 1.08rem; font-weight: 700; color: var(--jp-ink); margin-bottom: 8px; line-height: 1.35; }
.blog-card-excerpt { font-size: .89rem; color: var(--jp-muted); margin-bottom: 12px; }
.blog-card-meta { display: flex; gap: 14px; font-size: .8rem; color: var(--jp-muted); }
.blog-card-meta i { color: var(--jp-primary); }

/* ---- Blog post (detail) ---- */
.blog-post-title { font-weight: 800; font-size: 2.1rem; letter-spacing: -.5px; color: var(--jp-ink); margin: 6px 0 12px; }
.blog-post-meta { display: flex; flex-wrap: wrap; gap: 18px; color: var(--jp-muted); font-size: .88rem; margin-bottom: 22px; }
.blog-post-meta i { color: var(--jp-primary); margin-right: 4px; }
.blog-post-cover { width: 100%; border-radius: 14px; margin-bottom: 24px; max-height: 420px; object-fit: cover; }
.blog-post-body { font-size: 1.05rem; line-height: 1.8; color: #374151; }

/* ---- Rich footer ---- */
.site-footer-rich {
    background: #11203a;
    color: #c9d3e3;
    padding: 48px 0 24px;
    margin-top: 64px;
}
.site-footer-rich h6 { color: #fff; font-weight: 700; margin-bottom: 14px; font-size: .95rem; }
.site-footer-rich a { color: #c9d3e3; text-decoration: none; display: block; padding: 4px 0; font-size: .9rem; }
.site-footer-rich a:hover { color: #fff; }
.site-footer-rich .foot-brand { font-size: 1.4rem; font-weight: 800; color: #fff; }
.site-footer-rich .foot-bottom {
    border-top: 1px solid rgba(255,255,255,.1);
    margin-top: 32px; padding-top: 18px;
    font-size: .85rem; color: #8b97ad;
}

@media (max-width: 768px) {
    .home-hero h1 { font-size: 1.9rem; }
    .cat-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 640px) {
    .hero-search { flex-direction: column; padding: 10px; gap: 8px; }
    .hero-search .field { min-height: 52px; border: 1px solid var(--jp-border); }
    .hero-search .field + .field::before { display: none; }
    .hero-search .search-btn { padding: 14px; justify-content: center; }
}

/* =====================================================================
   HOME HERO — richer composition (floating cards + popular tags)
   ===================================================================== */
.hero-tags {
    display: flex; gap: 8px; flex-wrap: wrap; align-items: center;
    margin-top: 18px;
}
.hero-tags .lbl { font-size: .88rem; opacity: .85; margin-right: 2px; }
.hero-tags a {
    background: rgba(255,255,255,.12);
    border: 1px solid rgba(255,255,255,.28);
    color: #fff;
    border-radius: 999px;
    padding: 6px 15px;
    font-size: .83rem;
    font-weight: 600;
    text-decoration: none;
    transition: background .15s, transform .15s;
}
.hero-tags a:hover { background: rgba(255,255,255,.26); color: #fff; text-decoration: none; transform: translateY(-1px); }

/* Right-side floating visual */
.hero-visual { position: relative; height: 360px; }
.hero-card {
    position: absolute;
    background: #fff;
    border-radius: 16px;
    box-shadow: 0 22px 48px rgba(0,0,0,.28);
    color: var(--jp-text);
}
.hero-card-main {
    width: 310px;
    padding: 22px;
    top: 56px; left: 50%;
    transform: translateX(-50%);
    animation: heroFloat 5s ease-in-out infinite;
}
.hc-head { display: flex; gap: 12px; align-items: center; }
.hc-logo {
    width: 48px; height: 48px; border-radius: 12px;
    background: var(--jp-primary-50); color: var(--jp-primary);
    display: flex; align-items: center; justify-content: center;
    font-weight: 800; font-size: 1.3rem; flex-shrink: 0;
}
.hc-title { font-weight: 700; font-size: 1.05rem; line-height: 1.2; }
.hc-sub { font-size: .83rem; color: var(--jp-muted); }
.hc-tags { display: flex; gap: 6px; flex-wrap: wrap; margin-top: 14px; }
.hc-tags span {
    background: var(--jp-bg);
    border-radius: 999px;
    padding: 5px 11px;
    font-size: .72rem; font-weight: 600;
    color: var(--jp-text);
}
.hc-apply {
    margin-top: 16px;
    background: var(--jp-primary); color: #fff;
    border-radius: 9px; text-align: center;
    padding: 9px; font-weight: 700; font-size: .85rem;
}
.hero-card-float {
    padding: 12px 16px;
    font-weight: 600; font-size: .85rem;
    display: flex; align-items: center; gap: 9px;
}
.hero-card-float .ic {
    width: 30px; height: 30px; border-radius: 8px;
    display: flex; align-items: center; justify-content: center;
    font-size: 1rem;
}
.hero-card-float-1 { top: 0; right: 6px; animation: heroFloat 4s ease-in-out infinite; }
.hero-card-float-1 .ic { background: #fff3e0; color: #f57c00; }
.hero-card-float-2 { bottom: 8px; left: 0; animation: heroFloat 6s ease-in-out infinite; }
.hero-card-float-2 .ic { background: #e8f5e9; color: #2e7d32; }

@keyframes heroFloat {
    0%, 100% { transform: translateY(0); }
    50%      { transform: translateY(-12px); }
}
.hero-card-main { animation-name: heroFloatX; }
@keyframes heroFloatX {
    0%, 100% { transform: translateX(-50%) translateY(0); }
    50%      { transform: translateX(-50%) translateY(-12px); }
}

@media (max-width: 992px) {
    .hero-visual { display: none; }
}

/* =====================================================================
   HOME HERO — CENTERED variant
   ===================================================================== */
.home-hero-centered { padding: 80px 0 72px; text-align: center; }
.home-hero-centered .inner { max-width: 880px; margin: 0 auto; }
.home-hero-centered h1 { font-size: 3rem; margin-bottom: 12px; }
.home-hero-centered .lead { font-size: 1.15rem; margin-bottom: 30px; }
.home-hero-centered .hero-search { margin: 0 auto; max-width: 820px; }
.home-hero-centered .hero-tags { justify-content: center; margin-top: 20px; }
.home-hero-centered .stat-strip { justify-content: center; gap: 48px; margin-top: 30px; }
.home-hero-centered .stat-strip .num { font-size: 1.9rem; }

@media (max-width: 768px) {
    .home-hero-centered { padding: 48px 16px 44px; }
    .home-hero-centered h1 { font-size: 2rem; }
    .home-hero-centered .lead { font-size: 1rem; }
    .home-hero-centered .stat-strip { gap: 28px; }
}
