/* =====================================================
   LabelCheck.eu — Design System CSS v3
   Navy slate #0f172a + lime #cffe25
   ===================================================== */

/* ── CSS Variables ─────────────────────────────────── */
:root {
    /* Backgrounds — navy slate */
    --bg:          #0f172a;
    --bg-2:        #1e293b;
    --bg-3:        #334155;
    --bg-card:     rgba(255,255,255,0.04);

    /* Borders */
    --border:      rgba(255,255,255,0.08);
    --border-hi:   rgba(207,254,37,0.22);
    --border-dim:  rgba(255,255,255,0.05);

    /* Accent lime */
    --accent:      #cffe25;
    --accent-dim:  rgba(207,254,37,0.10);
    --accent-dark: #a8d118;
    --accent-hover:#d9ff40;

    /* Status colors */
    --green:       #22c55e;
    --red:         #ef4444;
    --amber:       #fcbb40;
    --blue:        #3b82f6;

    /* Text */
    --text:        #f1f5f9;
    --text-2:      rgba(226,232,240,0.88);
    --text-3:      #94a3b8;

    /* Typography */
    --font-sans:    'Inter', system-ui, -apple-system, sans-serif;
    --font-display: 'Inter', system-ui, sans-serif;
    --font-mono:    'JetBrains Mono', monospace;

    /* Radii */
    --r-sm:   8px;
    --r-md:   14px;
    --r-lg:   20px;
    --r-xl:   28px;

    /* Shadows */
    --shadow-accent:  0 0 40px rgba(207,254,37,0.12);
    --shadow-glow:    0 0 60px rgba(207,254,37,0.08), 0 0 120px rgba(207,254,37,0.04);
    --shadow-card:    0 8px 32px rgba(0,0,0,0.4);

    /* Transitions */
    --transition: all 0.2s cubic-bezier(0.4,0,0.2,1);
}

/* ── Reset ─────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
    font-family: var(--font-sans);
    background: var(--bg);
    color: var(--text);
    line-height: 1.6;
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    text-rendering: optimizeLegibility;
}
/* Noise texture */
body::before {
    content: '';
    position: fixed; inset: 0; z-index: 0; pointer-events: none;
    background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noise'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noise)' opacity='1'/%3E%3C/svg%3E");
    opacity: 0.02;
    background-size: 160px 160px;
}
a { text-decoration: none; color: inherit; }
img { max-width: 100%; display: block; }
button { cursor: pointer; font-family: inherit; border: none; }
input, select, textarea { font-family: inherit; }

/* ── Scrollbar ─────────────────────────────────────── */
::-webkit-scrollbar { width: 6px; }
::-webkit-scrollbar-track { background: var(--bg); }
::-webkit-scrollbar-thumb { background: rgba(207,254,37,0.2); border-radius: 3px; }
::-webkit-scrollbar-thumb:hover { background: rgba(207,254,37,0.35); }

/* ── Page animation ────────────────────────────────── */
.page-fade-in { opacity: 0; animation: lcPageIn 0.4s ease forwards; }
@keyframes lcPageIn { to { opacity: 1; } }

/* ── Logo ──────────────────────────────────────────── */
.lc-logo {
    font-family: var(--font-sans);
    font-size: 1.25rem; font-weight: 800; letter-spacing: -0.04em;
    color: var(--text);
    text-decoration: none;
}
.lc-logo span { color: var(--accent); }

/* ── Buttons ───────────────────────────────────────── */
.btn {
    display: inline-flex; align-items: center; justify-content: center;
    gap: 8px; padding: 11px 22px; border-radius: var(--r-md);
    font-size: 0.875rem; font-weight: 600; transition: var(--transition);
    cursor: pointer; border: none; font-family: inherit;
    letter-spacing: -0.01em; text-decoration: none;
}
.btn-primary {
    background: var(--accent);
    color: var(--bg);
    font-weight: 700;
}
.btn-primary:hover {
    background: var(--accent-hover);
    transform: translateY(-1px);
    box-shadow: 0 6px 24px rgba(207,254,37,0.2);
}
.btn-ghost {
    background: transparent;
    color: var(--text-2);
    border: 1px solid var(--border);
}
.btn-ghost:hover {
    border-color: var(--border-hi);
    color: var(--accent);
    background: var(--accent-dim);
}
.btn-secondary {
    background: var(--bg-2);
    color: var(--text-2);
    border: 1px solid var(--border);
}
.btn-secondary:hover { color: var(--text); border-color: rgba(207,254,37,0.2); }
.btn-danger { background: rgba(239,68,68,0.12); color: var(--red); border: 1px solid rgba(239,68,68,0.2); }
.btn-danger:hover { background: rgba(239,68,68,0.2); }
.btn-sm { padding: 6px 14px; font-size: 0.8rem; border-radius: var(--r-sm); }
.btn-lg { padding: 14px 28px; font-size: 1rem; }

/* ── Cards ─────────────────────────────────────────── */
.lc-card {
    background: var(--bg-2);
    border: 1px solid var(--border);
    border-radius: var(--r-lg);
    padding: 1.5rem;
    backdrop-filter: blur(12px);
}
.lc-card-sm {
    background: var(--bg-2);
    border: 1px solid var(--border);
    border-radius: var(--r-md);
    padding: 1rem;
}
.lc-card:hover { border-color: rgba(207,254,37,0.12); }

/* ── Badges ────────────────────────────────────────── */
.badge {
    display: inline-flex; align-items: center; gap: 4px;
    padding: 3px 10px; border-radius: 100px;
    font-size: 0.72rem; font-weight: 600; letter-spacing: 0.03em;
    text-transform: uppercase;
}
.badge-green  { background: rgba(34,197,94,0.12);  color: #4ade80;   border: 1px solid rgba(34,197,94,0.2); }
.badge-red    { background: rgba(239,68,68,0.12);  color: #f87171;   border: 1px solid rgba(239,68,68,0.2); }
.badge-amber  { background: rgba(252,187,64,0.12); color: var(--amber); border: 1px solid rgba(252,187,64,0.2); }
.badge-lime   { background: var(--accent-dim);     color: var(--accent); border: 1px solid var(--border-hi); }
.badge-gray   { background: rgba(148,163,184,0.1); color: var(--text-3); border: 1px solid rgba(148,163,184,0.15); }

/* ── Forms ─────────────────────────────────────────── */
.form-group { display: flex; flex-direction: column; gap: 6px; }
.form-label { font-size: 0.875rem; font-weight: 500; color: var(--text-2); }
.form-input {
    width: 100%; padding: 10px 14px;
    background: rgba(255,255,255,0.04);
    border: 1px solid var(--border);
    border-radius: var(--r-md);
    color: var(--text); font-size: 0.9rem; font-family: inherit;
    transition: var(--transition); outline: none;
}
.form-input:focus { border-color: rgba(207,254,37,0.35); box-shadow: 0 0 0 3px rgba(207,254,37,0.08); }
.form-input::placeholder { color: var(--text-3); }
.form-error { font-size: 0.8rem; color: var(--red); margin-top: 2px; }
.form-hint  { font-size: 0.8rem; color: var(--text-3); margin-top: 2px; }

/* ── Sidebar ──────────────────────────────────────── */
.lc-sidebar {
    position: fixed; left: 0; top: 0;
    width: 240px; height: 100vh;
    background: rgba(15,23,42,0.97);
    border-right: 1px solid var(--border);
    display: flex; flex-direction: column;
    z-index: 1000; overflow-y: auto;
    backdrop-filter: blur(20px);
}
.lc-sidebar-logo {
    padding: 22px 20px 18px;
    border-bottom: 1px solid var(--border);
    font-size: 1.1rem; font-weight: 800;
    color: var(--text); letter-spacing: -0.03em;
}
.lc-sidebar-logo span { color: var(--accent); }
.lc-sidebar-nav { flex: 1; padding: 12px 0; }
.lc-sidebar-item {
    display: flex; align-items: center; gap: 10px;
    padding: 9px 20px; margin: 1px 8px;
    font-size: 0.85rem; font-weight: 500; color: var(--text-3);
    transition: var(--transition); cursor: pointer;
    border-radius: var(--r-sm); border: 1px solid transparent;
}
.lc-sidebar-item:hover { color: var(--text); background: var(--bg-card); }
.lc-sidebar-item.active {
    color: var(--accent);
    background: var(--accent-dim);
    border-color: rgba(207,254,37,0.12);
}

/* ── Alerts ─────────────────────────────────────────── */
.alert { padding: 12px 16px; border-radius: var(--r-md); font-size: 0.875rem; display: flex; align-items: flex-start; gap: 10px; }
.alert-success { background: rgba(34,197,94,0.08);  border: 1px solid rgba(34,197,94,0.15); color: #4ade80; }
.alert-error   { background: rgba(239,68,68,0.08);  border: 1px solid rgba(239,68,68,0.15); color: #f87171; }
.alert-warning { background: rgba(252,187,64,0.08); border: 1px solid rgba(252,187,64,0.15); color: var(--amber); }
.alert-info    { background: var(--accent-dim);     border: 1px solid var(--border-hi);     color: var(--accent); }

/* ── Tables ─────────────────────────────────────────── */
.lc-table { width: 100%; border-collapse: collapse; font-size: 0.875rem; }
.lc-table th {
    padding: 10px 14px; text-align: left;
    font-size: 0.7rem; font-weight: 600; color: var(--text-3);
    text-transform: uppercase; letter-spacing: 0.06em;
    border-bottom: 1px solid var(--border);
}
.lc-table td { padding: 12px 14px; color: var(--text-2); border-bottom: 1px solid rgba(255,255,255,0.04); }
.lc-table tr:hover td { background: rgba(207,254,37,0.02); }
.lc-table tr:last-child td { border-bottom: none; }

/* ── Stats cards ────────────────────────────────────── */
.stats-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); gap: 16px; }
.stat-card {
    background: var(--bg-2); border: 1px solid var(--border);
    border-radius: var(--r-lg); padding: 20px;
    display: flex; flex-direction: column; gap: 8px;
    transition: var(--transition);
}
.stat-card:hover { border-color: rgba(207,254,37,0.12); }
.stat-card-label { font-size: 0.72rem; font-weight: 600; color: var(--text-3); text-transform: uppercase; letter-spacing: 0.06em; }
.stat-card-value { font-size: 1.75rem; font-weight: 800; letter-spacing: -0.04em; color: var(--text); }
.stat-card-sub   { font-size: 0.8rem; color: var(--text-3); }

/* ── Layout ─────────────────────────────────────────── */
.lc-app-layout { display: flex; min-height: 100vh; }
.lc-main-content { flex: 1; margin-left: 240px; padding: 2rem; min-width: 0; }

/* ── Utilities ──────────────────────────────────────── */
.text-accent { color: var(--accent); }
.text-green  { color: var(--green); }
.text-red    { color: var(--red); }
.text-muted  { color: var(--text-2); }
.text-dim    { color: var(--text-3); }
.sr-only     { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; }
.truncate    { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

/* ── Pulsing dot ──────────────────────────────────── */
@keyframes pulse {
    0%, 100% { opacity: 1; transform: scale(1); }
    50%       { opacity: 0.6; transform: scale(1.3); }
}
.dot-live {
    width: 8px; height: 8px; border-radius: 50%;
    background: var(--accent); display: inline-block;
    box-shadow: 0 0 8px rgba(207,254,37,0.7);
    animation: pulse 2s infinite;
}

/* ── Hamburger menu ────────────────────────────────── */
.lc-hamburger {
    display: none; position: fixed; top: 14px; right: 16px; z-index: 1100;
    width: 40px; height: 40px; border-radius: var(--r-sm);
    background: var(--bg-2); border: 1px solid var(--border);
    cursor: pointer; flex-direction: column; align-items: center; justify-content: center; gap: 5px;
    transition: var(--transition);
}
.lc-hamburger span {
    display: block; width: 20px; height: 2px; background: var(--text-2);
    border-radius: 2px; transition: all 0.3s ease;
}
.lc-hamburger.active span:nth-child(1) { transform: rotate(45deg) translate(5px, 5px); }
.lc-hamburger.active span:nth-child(2) { opacity: 0; }
.lc-hamburger.active span:nth-child(3) { transform: rotate(-45deg) translate(5px, -5px); }
.lc-overlay {
    display: none; position: fixed; inset: 0; z-index: 999;
    background: rgba(0,0,0,0.6); backdrop-filter: blur(4px);
}
.lc-overlay.active { display: block; }

/* ── Mobile nav panel ──────────────────────────────── */
.lc-mobile-nav {
    position: fixed; top: 0; right: -280px; z-index: 1050;
    width: 280px; height: 100vh; background: var(--bg-2);
    border-left: 1px solid var(--border);
    padding: 72px 20px 20px; overflow-y: auto;
    transition: right 0.3s ease;
    display: flex; flex-direction: column; gap: 4px;
}
.lc-mobile-nav.active { right: 0; }
.lc-mobile-nav a, .lc-mobile-nav button {
    display: flex; align-items: center; gap: 10px;
    padding: 12px 16px; border-radius: var(--r-sm);
    font-size: 0.9rem; font-weight: 500; color: var(--text-2);
    text-decoration: none; border: none; background: transparent;
    transition: var(--transition); cursor: pointer; width: 100%;
    font-family: inherit; text-align: left;
}
.lc-mobile-nav a:hover, .lc-mobile-nav button:hover { background: var(--bg-3); color: var(--accent); }
.lc-mobile-nav .lc-mobile-nav-cta {
    margin-top: auto; background: var(--accent); color: var(--bg);
    font-weight: 700; justify-content: center; border-radius: var(--r-md);
}

/* ── TABLET (768px–1024px) ─────────────────────────── */
@media (max-width: 1024px) {
    .lc-sidebar { width: 200px; }
    .lc-main-content { margin-left: 200px; padding: 1.5rem; }
    .stats-grid { grid-template-columns: repeat(2, 1fr); }
    .lc-table { font-size: 0.8rem; }
    .lc-table th, .lc-table td { padding: 8px 10px; }
}

/* ── MOBILE (<768px) ───────────────────────────────── */
@media (max-width: 768px) {
    .lc-hamburger { display: flex; }
    .lc-sidebar { transform: translateX(-100%); transition: transform 0.3s ease; position: fixed; width: 260px; z-index: 1050; }
    .lc-sidebar.open { transform: translateX(0); }
    .lc-main-content { margin-left: 0; padding: 1rem; }
    .stats-grid { grid-template-columns: 1fr; }
    .stat-card-value { font-size: 1.4rem; }
    .lc-card { padding: 1rem; }
    .btn { padding: 10px 18px; font-size: 0.82rem; }
    .btn-lg { padding: 12px 22px; font-size: 0.9rem; }
    body { font-size: 0.9rem; }
}

/* ── SMALL MOBILE (<480px) ─────────────────────────── */
@media (max-width: 480px) {
    .lc-main-content { padding: 0.75rem; }
    .lc-card { padding: 0.75rem; border-radius: var(--r-md); }
    .stat-card { padding: 14px; }
    .stat-card-value { font-size: 1.2rem; }
    .badge { font-size: 0.65rem; padding: 2px 8px; }
}
