/* TacTraq – MilSim Clean (No Tailwind)
   ---------------------------------------------------------
   Structure:
   1) Tokens
   2) Base / Typography
   3) Layout (container, sections, grids)
   4) Utilities (spacing, flex helpers)
   5) Components (chips, buttons, cards, alerts, tables, forms)
   6) Navbar
   7) Page modules (Hero mock, Landing blocks, Account/License blocks)
*/

/* =========================================================
   1) TOKENS
   ========================================================= */
:root{
    --accent:#6C8C4A;
    --accentDark:#5C7554;
    --bg:#1E1E1E;
    --surface:#2B2B2B;
    --border:#444444;
    --text:#EAEAEA;
    --muted:#C2B280;
    --info:#3B83BD;
    --warn:#E7C03D;
    --error:#E94E4E;

    --radius:10px;
    --radiusLg:14px;
    --container:1120px;
}

/* =========================================================
   2) BASE / TYPOGRAPHY
   ========================================================= */
*{ box-sizing:border-box; }
html,body{ height:100%; }

body.page{
    margin:0;
    background:var(--bg);
    color:var(--text);
    font-family: Inter, "Segoe UI", Arial, sans-serif;
    line-height:1.45;
}

a{ color:inherit; text-decoration:none; }
a:hover{ text-decoration:underline; text-underline-offset:3px; }

.h1{ font-size: clamp(34px, 4vw, 48px); line-height:1.1; margin:0; font-weight:600; }
.h2{ font-size: 26px; margin:0; font-weight:600; }
.h3{ font-size: 18px; margin:0; font-weight:600; }
.lead{ font-size: 16px; color:var(--muted); max-width:60ch; margin:14px 0 0; }

.small{ font-size:12px; }
.muted{ color: var(--muted); opacity:.92; }

/* Subtle grid background */
.bg-grid{
    position:fixed;
    inset:0;
    pointer-events:none;
    opacity:.07;
    background: radial-gradient(circle at 1px 1px, #fff 1px, transparent 0) 0 0 / 22px 22px;
}

/* =========================================================
   3) LAYOUT
   ========================================================= */
.container{
    width: min(100% - 32px, var(--container));
    margin: 0 auto;
}

.section{
    padding: 72px 0;
    border-bottom:1px solid var(--border);
}
.section--hero{ padding: 76px 0; }
.section--cta{ padding: 64px 0; }

/* Generic “page-centered” section (Login/Register/Reset/etc.) */
.section--centered{
    min-height: calc(100vh - 120px); /* navbar + some space */
    display:flex;
    align-items:center;
}

/* Generic 2-col grid */
.grid-2{
    display:grid;
    grid-template-columns: 1.05fr .95fr;
    gap: 40px;
    align-items:center;
}
@media (max-width: 920px){
    .grid-2{ grid-template-columns:1fr; }
}

.maxw{ max-width: 60ch; }

/* =========================================================
   4) UTILITIES
   ========================================================= */
.row{ display:flex; }
.gap-8{ gap:8px; }
.gap-10{ gap:10px; }
.space-between{ justify-content:space-between; }
.align-end{ align-items:flex-end; }
.align-center{ align-items:center; }
.center{ justify-content:center; text-align:center; }
.w-100{ width:100%; }

.mt-6{ margin-top:6px; }
.mt-8{ margin-top:8px; }
.mt-10{ margin-top:10px; }
.mt-12{ margin-top:12px; }
.mt-16{ margin-top:16px; }
.mt-18{ margin-top:18px; }
.mt-24{ margin-top:24px; }

/* =========================================================
   5) COMPONENTS
   ========================================================= */

/* ----- Cards ----- */
.card{
    background:var(--surface);
    border:1px solid var(--border);
    border-radius: var(--radiusLg);
}
.card--padded{ padding:18px; }

/* ----- Chips ----- */
.chip{
    display:inline-flex;
    align-items:center;
    padding:6px 10px;
    border:1px solid var(--border);
    border-radius:999px;
    background:#222;
    color:var(--muted);
    font-size:12px;
}
.chip--ok{ color: var(--text); background: rgba(108,140,74,.16); }
.chip--warn{ color: var(--text); background: rgba(231,192,61,.16); }
.chip--danger{ color: var(--text); background: rgba(233,78,78,.14); }

/* ----- Buttons ----- */
.btn{
    display:inline-flex;
    align-items:center;
    justify-content:center;
    padding:10px 14px;
    border:1px solid var(--border);
    border-radius: var(--radius);
    cursor:pointer;
    text-decoration:none !important;
    user-select:none;
    transition: background .15s ease, opacity .15s ease, transform .05s ease;
}
.btn:active{ transform: translateY(1px); }

.btn--primary{ background:var(--accent); color:#1E1E1E; }
.btn--primary:hover{ background:var(--accentDark); }

.btn--ghost{ background:transparent; color:var(--text); }
.btn--ghost:hover{ background:rgba(255,255,255,.04); }

/* Used for destructive actions, keeps same base button style */
.btn--danger{ color: var(--text); }
.btn--danger:hover{ background: rgba(233,78,78,.08); border-color: var(--border); }

/* ----- Alerts ----- */
.alert{
    border: 1px solid var(--border);
    border-radius: 12px;
    padding: 10px 12px;
    font-size: 13px;
    background: rgba(0,0,0,.18);
}
.alert--info{ box-shadow: inset 0 0 0 1px rgba(59,131,189,.22); }
.alert--warn{ box-shadow: inset 0 0 0 1px rgba(231,192,61,.22); }

/* ----- Tables ----- */
.table-wrap{ overflow-x: auto; }
.table{
    width: 100%;
    border-collapse: collapse;
}
.table th, .table td{
    padding: 12px 14px;
    border-bottom: 1px solid var(--border);
    vertical-align: middle;
}
.table th{
    text-align: left;
    color: var(--muted);
    font-size: 12px;
    font-weight: 600;
    background: rgba(0,0,0,.12);
}
.table tbody tr:hover{ background: rgba(255,255,255,.03); }
.ta-right{ text-align: right; }

/* ----- Forms (shared across Login/Register/Reset/etc.) ----- */
.form{ display:flex; flex-direction:column; }

.field{
    display:flex;
    flex-direction:column;
    gap:6px;
    margin-top: 12px;
}
.field label{ font-size: 12px; color: var(--muted); }
.field input, .field select, .field textarea{
    padding:10px 12px;
    border-radius:10px;
    background: var(--surface);
    border:1px solid var(--border);
    color: var(--text);
    font-size: 14px;
}
.field input:focus, .field select:focus, .field textarea:focus{
    outline:none;
    border-color: var(--accent);
}
.field__error{ font-size: 12px; color: var(--error); }

/* Checkbox */
.checkbox{
    display:flex;
    align-items:center;
    gap:8px;
    font-size: 13px;
    color: var(--muted);
}
.checkbox input{ accent-color: var(--accent); }

/* Links (for auth pages etc.) */
.link{
    font-size: 13px;
    color: var(--accent);
    text-decoration:none;
}
.link:hover{ text-decoration:underline; }

/* =========================================================
   6) NAVBAR (Public + Account)
   ========================================================= */
.nav{
    position:sticky;
    top:0;
    z-index:40;
    border-bottom:1px solid var(--border);
    background: rgba(30,30,30,.85);
    backdrop-filter: blur(8px);
}

.nav__inner{
    display:flex;
    align-items:center;
    gap:18px;
    padding:14px 0;
}

.brand{ display:flex; align-items:center; gap:10px; }
.brand__logo{
    width:32px; height:32px;
    border-radius:10px;
    border:1px solid var(--border);
}
.brand__name{ font-weight:600; letter-spacing:.3px; }

/* Public links */
.nav__links{ margin-left:auto; display:flex; gap:18px; }
.nav__link{ color:var(--muted); font-size:13px; opacity:.95; text-decoration:none !important; }
.nav__link:hover{ color:var(--text); opacity:1; }

.nav__cta{ display:flex; gap:10px; margin-left:10px; }

/* Account links (icon + label) */
.nav__links--account{ margin-left:auto; display:flex; gap:8px; align-items:center; }

.nav__item{
    display:flex;
    align-items:center;
    gap:8px;
    padding:8px 10px;
    border-radius: 10px;
    text-decoration:none !important;
    color: var(--muted);
    border: 1px solid transparent;
}
.nav__item:hover{
    background: rgba(255,255,255,.04);
    border-color: var(--border);
    color: var(--text);
}
.nav__item--active{
    background: rgba(108,140,74,.10);
    border-color: var(--border);
    color: var(--text);
}

.nav__icon{
    width:18px;
    height:18px;
    color: var(--muted);
    transition: color .15s ease;
}
.nav__item:hover .nav__icon{ color: var(--accent); }
.nav__item--active .nav__icon{ color: var(--accent); }

.nav__text--truncate{
    max-width: 180px;
    overflow:hidden;
    text-overflow:ellipsis;
    white-space:nowrap;
}

/* User menu */
.nav__user{ margin-left: 10px; position: relative; }
.nav__userBtn{
    list-style:none;
    display:flex;
    align-items:center;
    gap:8px;
    padding:8px 10px;
    border-radius: 10px;
    cursor:pointer;
    border:1px solid var(--border);
    background: transparent;
    color: var(--text);
}
.nav__userBtn:hover{ background: rgba(255,255,255,.04); }
.nav__user summary::-webkit-details-marker{ display:none; }

.nav__userPanel{
    position:absolute;
    right:0;
    top: calc(100% + 10px);
    width: 220px;
    border:1px solid var(--border);
    background: var(--surface);
    border-radius: 12px;
    padding: 8px;
    z-index: 50;
}
.nav__menuItem{
    width:100%;
    display:flex;
    align-items:center;
    gap:10px;
    padding:10px 10px;
    border-radius: 10px;
    color: var(--text);
    text-decoration:none !important;
    background: transparent;
    border: 1px solid transparent;
    cursor: pointer;
    font: inherit;
    text-align:left;
}
.nav__menuItem:hover{
    background: rgba(255,255,255,.04);
    border-color: var(--border);
}
.nav__menuIcon{ width:18px; height:18px; color: var(--muted); }
.nav__menuItem:hover .nav__menuIcon{ color: var(--accent); }
.nav__menuItem--danger:hover .nav__menuIcon{ color: var(--error); }

/* Mobile menu */
.nav__mobile{ display:none; margin-left:auto; }
.nav__mobilePanel{
    margin-top:10px;
    padding:10px;
    border:1px solid var(--border);
    border-radius: 12px;
    background: var(--surface);
    display:flex;
    flex-direction:column;
    gap:8px;
}
.nav__mobileLink{
    display:flex;
    align-items:center;
    gap:10px;
    padding:10px 8px;
    border-radius: 10px;
    color: var(--muted);
    text-decoration:none !important;
    border: 1px solid transparent;
    background: transparent;
    cursor: pointer;
    font: inherit;
    width: 100%;
    text-align: left;
}
.nav__mobileIcon{ width:18px; height:18px; color: var(--muted); }
.nav__mobileLink:hover{ background: rgba(255,255,255,.04); border-color: var(--border); color: var(--text); }
.nav__mobileLink--active{ background: rgba(108,140,74,.10); border-color: var(--border); color: var(--text); }
.nav__mobileLink--danger:hover{ background: rgba(233,78,78,.08); border-color: var(--border); }
.nav__mobileLink--danger:hover .nav__mobileIcon{ color: var(--error); }

.nav__mobileDivider{
    height: 1px;
    background: var(--border);
    margin: 8px 0;
    opacity: .9;
}
.nav__mobileCta{ margin-top:6px; }

@media (max-width: 880px){
    .nav__links, .nav__cta, .nav__links--account, .nav__user{ display:none; }
    .nav__mobile{ display:block; }
}

/* =========================================================
   7) PAGE MODULES
   ========================================================= */

/* ----- Auth pages (Login/Register/Reset) ----- */
.auth{
    width: 100%;
    display: flex;
    justify-content: center;
}
.auth__card{ width: 100%; max-width: 420px; }
.auth__footer{
    margin-top: 16px;
    display:flex;
    gap:6px;
    justify-content:center;
    font-size: 13px;
}
.auth__status{
    padding:10px 12px;
    border-radius:10px;
    background: rgba(59,131,189,.15);
    border:1px solid var(--border);
    color: var(--text);
    font-size: 13px;
    margin-bottom: 14px;
}
@media (max-width: 520px){
    .auth__card{ padding:16px; }
}

/* ----- Landing bullets (generic list) ----- */
.bullets{
    list-style:none;
    padding:0;
    margin: 0;
    display:grid;
    grid-template-columns: 1fr 1fr;
    gap:10px 14px;
    color: var(--muted);
    font-size: 13px;
}
@media (max-width: 920px){
    .bullets{ grid-template-columns:1fr; }
}
.dot{
    display:inline-block;
    width:8px; height:8px;
    border-radius:999px;
    background: var(--accent);
    margin-right:10px;
}

/* ----- Hero mock (landing) ----- */
.mock{ position:relative; }
.mock__glow{
    position:absolute; inset:-10px;
    background: rgba(108,140,74,.10);
    filter: blur(24px);
    border-radius: 22px;
}
.mock__card{ position:relative; padding:12px; }
.mock__window{
    background: var(--bg);
    border:1px solid var(--border);
    border-radius: 12px;
    padding:12px;
    color: var(--muted);
    font-size: 13px;
}
.mock__top{
    display:flex;
    justify-content:space-between;
    align-items:center;
    margin-bottom:12px;
}
.traffic{ display:flex; gap:8px; }
.traffic__dot{ width:12px; height:12px; border-radius:999px; }
.traffic__dot--error{ background: var(--error); }
.traffic__dot--warn{ background: var(--warn); }
.traffic__dot--info{ background: var(--info); }

.mock__grid{
    display:grid;
    grid-template-columns: 1fr 3fr;
    gap:12px;
}
.mock__side{ display:flex; flex-direction:column; gap:10px; }
.mock__tile{
    border:1px solid var(--border);
    background: var(--surface);
    border-radius:10px;
    padding:10px;
}
.bar{
    height:8px;
    border-radius:999px;
    background: rgba(108,140,74,.40);
    margin-top:8px;
}
.mock__main{ display:flex; flex-direction:column; gap:12px; }
.mock__panel{
    border:1px solid var(--border);
    background: var(--surface);
    border-radius:10px;
    padding:12px;
}
.mock__panelTitle{ color: var(--text); font-weight:600; margin-bottom:10px; }
.placeholder{ height:48px; border-radius:10px; background: rgba(0,0,0,.28); }
.placeholder--lg{ height:92px; }
.mock__widgets{ display:grid; grid-template-columns: repeat(3, 1fr); gap:12px; }
.mock__widget{
    border:1px solid var(--border);
    background: var(--surface);
    border-radius:10px;
    padding:12px;
}
@media (max-width: 920px){
    .mock__widgets{ grid-template-columns:1fr; }
}

/* ----- Cards grids / Gallery / Integrations / Pricing / FAQ (landing) ----- */
.cards{ display:grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.gallery{ display:grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.integrations{ display:grid; grid-template-columns: repeat(4, 1fr); gap: 12px; }
.pricing{ display:grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.faq{ display:grid; grid-template-columns: 1fr 1fr; gap: 12px; }

@media (max-width: 980px){
    .cards, .gallery, .pricing{ grid-template-columns:1fr; }
    .integrations{ grid-template-columns: repeat(2, 1fr); }
    .faq{ grid-template-columns:1fr; }
}

.gallery__img{ display:block; width:100%; height:160px; object-fit:cover; }
.gallery__img--placeholder{ background: var(--surface); }
.gallery__cap{ border-top:1px solid var(--border); padding:14px; }

.integrations__item{ padding:14px; text-align:center; }

.price{ font-size: 34px; font-weight: 600; color: var(--text); }
.checklist{ list-style:none; padding:0; margin:0; color: var(--muted); }
.checklist li{ display:flex; align-items:center; padding:6px 0; }
.checklist li .dot{ margin-right:10px; }

.faq__q{ cursor:pointer; font-weight:600; list-style:none; }
details summary::-webkit-details-marker{ display:none; }

/* ----- Footer ----- */
.footer{ padding: 46px 0; }
.footer__grid{
    display:grid;
    grid-template-columns: 1.2fr 1fr 1fr 1fr;
    gap: 18px;
}
.footer__brand{ display:flex; align-items:center; gap:10px; }
.footer__logo{ width:26px; height:26px; border-radius:8px; border:1px solid var(--border); }
.footer__name{ font-weight:600; }
.footer__title{ color: var(--muted); font-size: 12px; margin-bottom:10px; }
.footer__list{ list-style:none; padding:0; margin:0; display:flex; flex-direction:column; gap:8px; }
.footer__list a{ color: var(--text); opacity:.92; }
.footer__list a:hover{ opacity:1; }
.footer__bottom{
    margin-top:24px;
    padding-top:16px;
    border-top: 1px solid var(--border);
    color: var(--muted);
    font-size: 12px;
}
@media (max-width: 980px){
    .footer__grid{ grid-template-columns:1fr; }
}

/* ----- Account / License module (generic + minimal) ----- */
.license-grid{
    display: grid;
    grid-template-columns: 1.4fr .6fr;
    gap: 16px;
}
@media (max-width: 980px){
    .license-grid{ grid-template-columns: 1fr; }
}

.license-key{
    font-size: 18px;
    font-weight: 600;
    letter-spacing: .6px;
}
.license-activations{ font-size: 22px; font-weight: 700; color: var(--text); }

.license-badges{
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
}
@media (max-width: 520px){
    .license-badges{ grid-template-columns: 1fr; }
}

.status-tile{
    border: 1px solid var(--border);
    border-radius: 12px;
    background: rgba(0,0,0,.18);
    padding: 12px;
}
.status-tile__title{ color: var(--muted); font-size: 12px; }
.status-tile__value{ margin-top: 6px; font-size: 16px; font-weight: 600; color: var(--text); }
.status-tile__hint{ margin-top: 6px; font-size: 12px; }
.status-tile--trial{ box-shadow: inset 0 0 0 1px rgba(231,192,61,.18); }
.status-tile--paid{ box-shadow: inset 0 0 0 1px rgba(108,140,74,.22); }
.status-tile--unpaid{ box-shadow: inset 0 0 0 1px rgba(233,78,78,.18); }
