/* ══════════════════════════════════
   DESIGN TOKENS
══════════════════════════════════ */
:root {
  /* Dark (default) */
  --bg:      #0e1117;
  --bg2:     #161b27;
  --bg3:     #1c2333;
  --panel:   #1e2438;
  --surface: #252d42;
  --border:  rgba(255,255,255,0.07);
  --border2: rgba(255,255,255,0.12);
  --text:    #f0f2f8;
  --text2:   #8b93b0;
  --text3:   #454f6a;

  /* Brand */
  --pri:     #2dd4a0;
  --pri2:    #5eecc0;
  --pri-dim: rgba(45,212,160,0.12);
  --pri-glow:rgba(45,212,160,0.25);
  --pri-btn: linear-gradient(135deg,#22c55e,#2dd4a0);

  --sec:     #6d8aff;
  --sec-dim: rgba(109,138,255,0.12);

  --acc:     #f472b6;
  --acc-dim: rgba(244,114,182,0.12);

  --warn:    #fbbf24;
  --warn-dim:rgba(251,191,36,0.12);

  --red:     #f87171;
  --red-dim: rgba(248,113,113,0.10);

  --cyan:    #38bdf8;
  --cyan-dim:rgba(56,189,248,0.10);

  --purple:  #a78bfa;
  --purple-dim:rgba(167,139,250,0.10);

  --green:   #34d399;
  --green-dim:rgba(52,211,153,0.10);

  /* Timer gradient (Blitzit-style) */
  --timer-grad: linear-gradient(135deg,#22c55e,#2dd4a0,#38bdf8);

  --font:    'Prompt',sans-serif;
  --r:       12px;
  --r-lg:    18px;
  --r-xl:    24px;
  --nav-h:   54px;
  --bot-h:   66px;
  --sidebar: 240px;
  --shadow:  0 4px 20px rgba(0,0,0,0.35);
  --shadow2: 0 8px 40px rgba(0,0,0,0.5);
}

/* Light mode */
body.light {
  --bg:      #f0f4f9;
  --bg2:     #ffffff;
  --bg3:     #e8eef7;
  --panel:   #ffffff;
  --surface: #dce5f0;
  --border:  rgba(0,0,0,0.07);
  --border2: rgba(0,0,0,0.12);
  --text:    #0f172a;
  --text2:   #3d4d6e;
  --text3:   #94a3b8;
  --pri:     #16a34a;
  --pri2:    #22c55e;
  --pri-dim: rgba(22,163,74,0.09);
  --pri-glow:rgba(22,163,74,0.18);
  --pri-btn: linear-gradient(135deg,#16a34a,#0d9488);
  --sec:     #4f6ef7;
  --sec-dim: rgba(79,110,247,0.09);
  --acc:     #db2777;
  --acc-dim: rgba(219,39,119,0.09);
  --warn:    #d97706;
  --warn-dim:rgba(217,119,6,0.10);
  --red:     #dc2626;
  --red-dim: rgba(220,38,38,0.09);
  --shadow:  0 4px 20px rgba(0,0,0,0.08);
  --shadow2: 0 8px 40px rgba(0,0,0,0.14);
}

/* ══════════════════════════════════
   RESET
══════════════════════════════════ */
*,*::before,*::after{margin:0;padding:0;box-sizing:border-box;-webkit-tap-highlight-color:transparent;}
html,body{height:100%;overflow:hidden;}
body{font-family:var(--font);background:var(--bg);color:var(--text);font-size:14px;transition:background .3s,color .3s;}
::-webkit-scrollbar{width:3px;height:3px;}
::-webkit-scrollbar-thumb{background:var(--border2);border-radius:4px;}

/* ══════════════════════════════════
   SHELL LAYOUT
══════════════════════════════════ */
.shell{display:flex;height:100vh;height:100svh;overflow:hidden;}

/* ══════════════════════════════════
   SIDEBAR (desktop)
══════════════════════════════════ */
.sidebar{
  width:var(--sidebar);flex-shrink:0;
  background:var(--bg2);
  border-right:1px solid var(--border);
  display:flex;flex-direction:column;
  transition:background .3s;
}
@media(max-width:900px){
  .sidebar{
    position:fixed;inset:0 auto 0 0;z-index:300;
    transform:translateX(-100%);
    transition:transform .3s cubic-bezier(.4,0,.2,1),background .3s;
    box-shadow:6px 0 32px rgba(0,0,0,.3);
    width:260px;
  }
  .sidebar.open{transform:translateX(0);}
}

.sb-overlay{
  display:none;position:fixed;inset:0;
  background:rgba(0,0,0,.55);z-index:299;
  opacity:0;transition:opacity .3s;
}
.sb-overlay.show{display:block;opacity:1;}

/* Brand */
.sb-brand{
  padding:16px 14px 13px;
  border-bottom:1px solid var(--border);
  display:flex;align-items:center;gap:10px;
  background:linear-gradient(135deg,rgba(45,212,160,.06),rgba(109,138,255,.04));
}
.sb-logo{
  width:38px;height:38px;border-radius:11px;
  background:var(--pri-btn);
  display:flex;align-items:center;justify-content:center;
  color:#fff;font-size:18px;flex-shrink:0;
}
.sb-name{font-size:13px;font-weight:700;line-height:1.3;}
.sb-tagline{font-size:9px;color:var(--text3);letter-spacing:.6px;text-transform:uppercase;}

/* Nav */
.sb-nav{flex:1;overflow-y:auto;padding:8px;}
.sb-section{
  font-size:9px;font-weight:700;color:var(--text3);
  letter-spacing:1.5px;text-transform:uppercase;
  padding:14px 8px 4px;
}
.sb-item{
  display:flex;align-items:center;gap:9px;
  padding:8px 10px;border-radius:var(--r);
  cursor:pointer;font-size:12.5px;color:var(--text2);
  transition:all .15s;border:none;background:none;
  width:100%;text-align:left;font-family:var(--font);
  position:relative;
}
.sb-item:hover{background:linear-gradient(90deg,var(--si-color,var(--bg3)),transparent);color:var(--text);}
.sb-item.active{
  background:linear-gradient(90deg,var(--si-color,var(--pri-dim)),transparent);
  color:var(--si-icon,var(--pri));font-weight:600;
}
.sb-item.active::before{
  content:'';position:absolute;left:0;top:20%;bottom:20%;
  width:3px;background:var(--si-icon,var(--pri));border-radius:0 3px 3px 0;
}
.sb-ico{
  width:32px;height:32px;border-radius:9px;
  background:var(--bg3);
  display:flex;align-items:center;justify-content:center;
  font-size:14px;color:var(--text3);flex-shrink:0;
  transition:all .2s;
}
.sb-item.active .sb-ico{background:var(--si-color,var(--pri-dim));color:var(--si-icon,var(--pri));}
.sb-item:hover .sb-ico{background:var(--surface);color:var(--text);}
/* Per-item icon colors */
.si-home{--si-color:rgba(45,212,160,.15);--si-icon:#2dd4a0;}
.si-members{--si-color:rgba(109,138,255,.15);--si-icon:#6d8aff;}
.si-map{--si-color:rgba(56,189,248,.15);--si-icon:#38bdf8;}
.si-products{--si-color:rgba(251,191,36,.15);--si-icon:#fbbf24;}
.si-tools{--si-color:rgba(248,113,113,.15);--si-icon:#f87171;}
.si-knowledge{--si-color:rgba(167,139,250,.15);--si-icon:#a78bfa;}
.si-planner{--si-color:rgba(244,114,182,.15);--si-icon:#f472b6;}
.si-ai{--si-color:rgba(45,212,160,.15);--si-icon:#2dd4a0;}
.si-dash{--si-color:rgba(109,138,255,.15);--si-icon:#6d8aff;}
.si-admin{--si-color:rgba(251,191,36,.15);--si-icon:#fbbf24;}
/* Active always shows icon color */
.sb-item.active .si-home,.sb-item.active .si-members,.sb-item.active .si-map,
.sb-item.active .si-products,.sb-item.active .si-tools,.sb-item.active .si-knowledge,
.sb-item.active .si-planner,.sb-item.active .si-ai,.sb-item.active .si-dash,
.sb-item.active .si-admin{background:var(--si-color);color:var(--si-icon);}
.sb-chip{
  margin-left:auto;font-size:9px;font-weight:700;
  padding:2px 6px;border-radius:20px;
}
.chip-g{background:var(--pri);color:#000;}
.chip-r{background:var(--red);color:#fff;}
.chip-b{background:var(--sec);color:#fff;}
.chip-new{background:var(--sec-dim);color:var(--sec);}

/* Footer */
.sb-footer{
  padding:10px;border-top:1px solid var(--border);
}
.sb-user{
  display:flex;align-items:center;gap:9px;
  padding:8px 10px;border-radius:var(--r);
  background:var(--bg3);cursor:pointer;
  transition:background .15s;
}
.sb-user:hover{background:var(--surface);}
.sb-av{
  width:30px;height:30px;border-radius:50%;
  background:var(--pri-btn);
  display:flex;align-items:center;justify-content:center;
  font-size:12px;font-weight:700;color:#fff;flex-shrink:0;
}
.sb-uname{font-size:11.5px;font-weight:600;}
.sb-urole{font-size:9px;color:var(--text3);}
.sb-login{
  display:flex;align-items:center;gap:8px;width:100%;
  margin-top:8px;padding:9px 12px;border-radius:var(--r);
  background:var(--pri-dim);border:1px solid var(--pri-glow);
  color:var(--pri);font-weight:600;font-size:12.5px;
  cursor:pointer;font-family:var(--font);transition:all .15s;
}
.sb-login:hover{background:var(--green-dim);}
.sb-logout{
  display:none;align-items:center;gap:8px;width:100%;
  margin-top:6px;padding:7px 12px;border-radius:var(--r);
  background:var(--red-dim);border:1px solid rgba(248,113,113,.2);
  color:var(--red);font-weight:600;font-size:12px;
  cursor:pointer;font-family:var(--font);transition:all .15s;
}
body.is-admin .sb-logout,
body.is-staff .sb-logout{display:flex;}
body.is-admin .sb-login,
body.is-staff .sb-login{display:none;}

/* ══════════════════════════════════
   MAIN AREA
══════════════════════════════════ */
.main{flex:1;display:flex;flex-direction:column;overflow:hidden;min-width:0;}

/* ── TOP NAV ── */
.topnav{
  height:var(--nav-h);flex-shrink:0;
  background:var(--bg2);border-bottom:1px solid var(--border);
  display:flex;align-items:center;padding:0 14px;gap:8px;
  transition:background .3s;
  position:relative;
}
/* Gradient line bottom */
.topnav::after{
  content:'';position:absolute;bottom:0;left:0;right:0;height:1.5px;
  background:linear-gradient(90deg,var(--pri),var(--sec),var(--acc));
  opacity:.5;
}
.menu-btn{
  display:none;width:34px;height:34px;border-radius:var(--r);
  background:var(--bg3);border:1px solid var(--border);
  align-items:center;justify-content:center;
  font-size:14px;cursor:pointer;color:var(--text2);flex-shrink:0;
}
@media(max-width:900px){.menu-btn{display:flex;}}

.nav-info{flex:1;min-width:0;}
.nav-title{font-size:15px;font-weight:700;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;}
.nav-sub{font-size:9.5px;color:var(--text3);}

.nav-right{display:flex;align-items:center;gap:6px;flex-shrink:0;}
.nav-btn{
  width:34px;height:34px;border-radius:var(--r);
  background:var(--bg3);border:1px solid var(--border);
  display:flex;align-items:center;justify-content:center;
  font-size:14px;cursor:pointer;color:var(--text2);
  transition:all .15s;position:relative;
}
.nav-btn:hover{background:var(--surface);color:var(--text);}
.notif-pip{
  position:absolute;top:-3px;right:-3px;
  min-width:15px;height:15px;border-radius:8px;
  background:var(--red);color:#fff;font-size:8px;font-weight:700;
  display:flex;align-items:center;justify-content:center;
  padding:0 3px;font-family:var(--font);
}
.admin-pill{
  display:none;align-items:center;gap:4px;
  background:var(--pri-dim);border:1px solid var(--pri-glow);
  border-radius:20px;padding:4px 10px;
  font-size:10px;font-weight:700;color:var(--pri);
}
body.is-admin .admin-pill{display:flex;}
body.is-staff .admin-pill{
  display:flex;background:var(--sec-dim);
  border-color:rgba(109,138,255,.25);color:var(--sec);
}

/* Theme toggle */
.theme-toggle{
  display:flex;align-items:center;gap:5px;
  background:var(--bg3);border:1px solid var(--border2);
  border-radius:30px;padding:4px 9px;cursor:pointer;
  font-size:10px;font-weight:600;color:var(--text2);
  transition:all .15s;user-select:none;
}
.theme-toggle:hover{background:var(--surface);}
.t-track{
  width:32px;height:17px;border-radius:20px;
  background:var(--bg);border:1px solid var(--border2);
  position:relative;transition:background .3s;
}
body.light .t-track{background:var(--pri);}
.t-thumb{
  position:absolute;top:2px;left:2px;
  width:11px;height:11px;border-radius:50%;
  background:#fff;transition:transform .3s;
  box-shadow:0 1px 4px rgba(0,0,0,.3);
}
body.light .t-thumb{transform:translateX(15px);}

/* ── BODY (2-column on desktop) ── */
.body-wrap{
  flex:1;display:flex;overflow:hidden;min-height:0;
}

/* ── LEFT PANEL (Blitzit task panel style) — desktop only ── */
/* ── RIGHT / MAIN PAGE AREA ── */
.page-wrap{
  flex:1;overflow-y:auto;overflow-x:hidden;
  background:var(--bg);min-height:0;
  -webkit-overflow-scrolling:touch;
  transition:background .3s;
}
.page{
  display:none;padding:20px 18px;
  max-width:1000px;margin:0 auto;
}
.page.active{display:block;}
@media(max-width:900px){
  .page{padding:14px 12px 16px;}
  .page-wrap{
    padding-bottom:calc(var(--bot-h) + env(safe-area-inset-bottom,0px));
  }
}

/* ══════════════════════════════════
   BOTTOM NAV (mobile)
══════════════════════════════════ */
.bottom-nav{display:none;}
@media(max-width:900px){
  .bottom-nav{
    display:flex !important;
    position:fixed;bottom:0;left:0;right:0;
    height:var(--bot-h);
    background:var(--bg2);
    border-top:1px solid var(--border);
    z-index:200;
    padding-bottom:env(safe-area-inset-bottom,0px);
    box-shadow:0 -6px 24px rgba(0,0,0,.25);
    transition:background .3s;
  }
}
.bn{
  flex:1;display:flex;flex-direction:column;
  align-items:center;justify-content:center;
  gap:3px;border:none;background:none;
  color:var(--text3);font-family:var(--font);
  cursor:pointer;padding:6px 2px;
  position:relative;transition:color .15s;
  -webkit-appearance:none;outline:none;
}
.bn.active{color:var(--pri);}
.bn.active::before{
  content:'';position:absolute;top:0;
  left:50%;transform:translateX(-50%);
  width:22px;height:3px;
  background:var(--pri-btn);
  border-radius:0 0 4px 4px;
}
.bn i{font-size:18px;line-height:1;}
.bn span{font-size:9px;font-weight:500;}
.bn-more-dot{
  position:absolute;top:4px;right:calc(50% - 17px);
  width:14px;height:14px;border-radius:50%;
  background:var(--red);color:#fff;
  font-size:7px;font-weight:700;
  display:flex;align-items:center;justify-content:center;
  font-family:var(--font);
}

/* ══════════════════════════════════
   COMPONENTS
══════════════════════════════════ */

/* Cards */
.card{
  background:var(--bg2);border:1px solid var(--border);
  border-radius:var(--r-lg);padding:16px;
  box-shadow:var(--shadow);
  transition:background .3s,border-color .15s;
}
.card:hover{border-color:var(--border2);}
.card-sm{background:var(--bg2);border:1px solid var(--border);border-radius:var(--r);padding:12px;box-shadow:var(--shadow);}

/* Stats Grid */
.stat-grid{display:grid;grid-template-columns:repeat(2,1fr);gap:10px;margin-bottom:16px;}
@media(min-width:500px){.stat-grid{grid-template-columns:repeat(4,1fr);}}
.stat-card{
  background:var(--bg2);border:1px solid var(--border);
  border-radius:var(--r-lg);padding:14px 12px;
  display:flex;flex-direction:column;gap:6px;
  box-shadow:var(--shadow);position:relative;overflow:hidden;
  transition:all .2s;
}
.stat-card:hover{transform:translateY(-2px);box-shadow:var(--shadow2);}
.stat-card::after{
  content:'';position:absolute;top:0;left:0;right:0;height:3px;
}
.sc-g::after{background:var(--pri-btn);}
.sc-b::after{background:linear-gradient(90deg,var(--sec),var(--cyan));}
.sc-v::after{background:linear-gradient(90deg,var(--purple),var(--acc));}
.sc-w::after{background:linear-gradient(90deg,var(--warn),#fb923c);}
.stat-ico{
  width:34px;height:34px;border-radius:9px;
  display:flex;align-items:center;justify-content:center;
  font-size:15px;
}
.si-g{background:var(--pri-dim);color:var(--pri);}
.si-b{background:var(--sec-dim);color:var(--sec);}
.si-v{background:var(--purple-dim);color:var(--purple);}
.si-w{background:var(--warn-dim);color:var(--warn);}
.stat-val{font-size:22px;font-weight:800;line-height:1;}
.stat-label{font-size:11px;color:var(--text2);}
.stat-sub{font-size:10px;color:var(--text3);}
.stat-badge{
  display:inline-flex;align-items:center;gap:3px;
  font-size:9px;font-weight:700;
  padding:2px 6px;border-radius:20px;width:fit-content;
}
.sb-up{background:var(--pri-dim);color:var(--pri);}
.sb-dn{background:var(--red-dim);color:var(--red);}

/* Progress bar */
.progress{height:4px;background:var(--bg3);border-radius:4px;overflow:hidden;}
.pb-fill{height:100%;border-radius:4px;}
.pb-g{background:var(--pri-btn);}
.pb-b{background:linear-gradient(90deg,var(--sec),var(--cyan));}
.pb-v{background:linear-gradient(90deg,var(--purple),var(--acc));}
.pb-w{background:linear-gradient(90deg,var(--warn),#fb923c);}

/* Section headers */
.sec-head{display:flex;align-items:center;gap:8px;margin-bottom:14px;flex-wrap:wrap;}
.sec-title{
  font-size:14px;font-weight:700;
  display:flex;align-items:center;gap:7px;
}
.sec-title i{color:var(--pri);font-size:13px;}
.sec-sub{font-size:11px;color:var(--text3);}
.sec-spacer{flex:1;}

/* Badges */
.badge{display:inline-flex;align-items:center;font-size:10px;font-weight:700;padding:3px 8px;border-radius:20px;}
.b-g{background:var(--pri-dim);color:var(--pri);}
.b-b{background:var(--sec-dim);color:var(--sec);}
.b-r{background:var(--red-dim);color:var(--red);}
.b-w{background:var(--warn-dim);color:var(--warn);}
.b-v{background:var(--purple-dim);color:var(--purple);}
.b-c{background:var(--cyan-dim);color:var(--cyan);}

/* Buttons */
.btn{
  display:inline-flex;align-items:center;gap:6px;
  padding:8px 14px;border-radius:var(--r);
  font-size:12.5px;font-weight:600;cursor:pointer;
  border:1px solid var(--border2);background:var(--bg3);color:var(--text);
  font-family:var(--font);transition:all .15s;
}
.btn:hover{background:var(--surface);}
.btn:active{transform:scale(.97);}
.btn-sm{padding:5px 11px;font-size:11.5px;}
.btn-pri{background:var(--pri-btn);color:#fff;border-color:transparent;box-shadow:0 2px 12px var(--pri-glow);}
.btn-pri:hover{opacity:.9;background:var(--pri-btn);}
.btn-ghost{background:transparent;border-color:var(--border);color:var(--text2);}
.btn-ghost:hover{background:var(--bg3);color:var(--text);}
.btn-red{background:var(--red-dim);color:var(--red);border-color:rgba(248,113,113,.2);}

/* Inputs */
.label{display:block;font-size:11px;font-weight:600;color:var(--text2);margin-bottom:4px;}
.inp{
  width:100%;padding:9px 12px;border-radius:var(--r);
  background:var(--bg3);border:1px solid var(--border2);
  color:var(--text);font-size:13px;font-family:var(--font);
  outline:none;transition:border-color .15s,box-shadow .15s;
}
.inp:focus{border-color:var(--pri);box-shadow:0 0 0 3px var(--pri-dim);}
.select{
  width:100%;padding:9px 12px;border-radius:var(--r);
  background:var(--bg3);border:1px solid var(--border2);
  color:var(--text);font-size:13px;font-family:var(--font);outline:none;
}

/* Tables */
.tbl-wrap{overflow-x:auto;border-radius:var(--r);border:1px solid var(--border);}
table{width:100%;border-collapse:collapse;font-size:12.5px;}
thead th{
  background:var(--bg3);padding:9px 12px;
  text-align:left;font-size:10.5px;font-weight:700;color:var(--text2);
  white-space:nowrap;border-bottom:1px solid var(--border);
}
tbody td{padding:9px 12px;border-top:1px solid var(--border);}
tbody tr:hover td{background:var(--bg3);}

/* Grid utils */
.g2{display:grid;grid-template-columns:repeat(2,1fr);gap:10px;}
.g4{display:grid;grid-template-columns:repeat(2,1fr);gap:10px;}
@media(min-width:500px){.g4{grid-template-columns:repeat(4,1fr);}}

/* ══════════════════════════════════
   SLIDESHOW
══════════════════════════════════ */
.slideshow{
  position:relative;width:100%;height:210px;
  border-radius:var(--r-xl);overflow:hidden;
  margin-bottom:16px;box-shadow:var(--shadow2);
}
@media(min-width:500px){.slideshow{height:250px;}}
.slide{position:absolute;inset:0;opacity:0;transition:opacity .8s;}
.slide.active{opacity:1;}
.slide img{width:100%;height:100%;object-fit:cover;}
.slide-ov{
  position:absolute;inset:0;
  background:linear-gradient(to top,rgba(0,0,0,.72) 0%,rgba(0,0,0,.15) 55%,transparent 100%);
  display:flex;flex-direction:column;justify-content:flex-end;
  padding:18px 20px 18px 54px;
}
.s-tag{font-size:9px;font-weight:700;letter-spacing:2px;text-transform:uppercase;color:var(--pri);margin-bottom:4px;}
.s-h1{font-size:clamp(16px,3vw,24px);font-weight:900;color:#fff;line-height:1.2;margin-bottom:4px;}
.s-desc{font-size:11px;color:rgba(255,255,255,.7);max-width:360px;line-height:1.5;}
.s-dots{position:absolute;bottom:10px;right:12px;display:flex;gap:4px;}
.sdot{width:5px;height:5px;border-radius:50%;background:rgba(255,255,255,.35);cursor:pointer;transition:all .3s;}
.sdot.active{width:16px;border-radius:4px;background:var(--pri);}
.s-btn{
  position:absolute;top:50%;transform:translateY(-50%);
  width:28px;height:28px;border-radius:50%;
  background:rgba(0,0,0,.45);backdrop-filter:blur(4px);
  display:flex;align-items:center;justify-content:center;
  cursor:pointer;color:#fff;font-size:11px;border:none;
  transition:background .2s;
}
.s-btn:hover{background:rgba(0,0,0,.65);}
.s-prev{left:8px;} .s-next{right:8px;}

/* ══════════════════════════════════
   HOME QUICK ACTIONS
══════════════════════════════════ */
.quick-grid{
  display:grid;grid-template-columns:repeat(4,1fr);
  gap:8px;margin-bottom:18px;
}
@media(min-width:600px){.quick-grid{grid-template-columns:repeat(5,1fr);}}
.qi{
  display:flex;flex-direction:column;align-items:center;gap:7px;
  padding:12px 6px;border-radius:var(--r-lg);
  background:var(--bg2);border:1px solid var(--border);
  cursor:pointer;transition:all .15s;box-shadow:var(--shadow);
}
.qi:hover{transform:translateY(-2px);box-shadow:var(--shadow2);border-color:var(--pri);}
.qi:active{transform:scale(.96);}
.qi-ico{
  width:42px;height:42px;border-radius:12px;
  display:flex;align-items:center;justify-content:center;
  font-size:18px;transition:transform .15s;
}
.qi:hover .qi-ico{transform:scale(1.1);}
.qi-lbl{font-size:10px;font-weight:600;color:var(--text2);text-align:center;line-height:1.3;}

/* ══════════════════════════════════
   NEWS FEED
══════════════════════════════════ */
.feed-item{
  background:var(--bg2);border:1px solid var(--border);
  border-radius:var(--r-lg);overflow:hidden;margin-bottom:12px;
  box-shadow:var(--shadow);transition:border-color .15s;
}
.feed-item:hover{border-color:var(--border2);}
.feed-img{width:100%;height:170px;object-fit:cover;cursor:pointer;display:block;}
.feed-body{padding:12px 14px;}
.feed-meta{display:flex;align-items:center;gap:7px;margin-bottom:7px;font-size:11.5px;flex-wrap:wrap;}
.feed-caption{font-size:12.5px;color:var(--text2);line-height:1.6;margin-bottom:8px;}
.feed-tags{display:flex;flex-wrap:wrap;gap:5px;margin-bottom:8px;}
.feed-tag{font-size:10px;color:var(--sec);background:var(--sec-dim);padding:2px 8px;border-radius:20px;}
.feed-acts{display:flex;gap:6px;flex-wrap:wrap;}
.fa-btn{
  display:flex;align-items:center;gap:5px;
  font-size:11.5px;font-weight:600;color:var(--text2);
  padding:5px 11px;border-radius:8px;background:var(--bg3);
  border:1px solid var(--border);cursor:pointer;
  font-family:var(--font);transition:all .15s;
}
.fa-btn:hover{background:var(--surface);color:var(--text);}
.fa-btn.pri{background:var(--pri-dim);color:var(--pri);border-color:var(--pri-glow);}
.feed-detail{
  display:none;padding:12px 14px;border-top:1px solid var(--border);
  font-size:12px;color:var(--text2);line-height:1.7;background:var(--bg3);
}
.feed-detail.open{display:block;}

/* Products */
.prod-grid{display:grid;grid-template-columns:repeat(2,1fr);gap:10px;}
@media(min-width:550px){.prod-grid{grid-template-columns:repeat(3,1fr);}}
.prod-card{
  background:var(--bg2);border:1px solid var(--border);
  border-radius:var(--r-lg);overflow:hidden;cursor:pointer;
  transition:all .2s;box-shadow:var(--shadow);
}
.prod-card:hover{transform:translateY(-3px);box-shadow:var(--shadow2);border-color:var(--pri);}
.pc-img{width:100%;height:110px;object-fit:cover;}
.pc-ph{width:100%;height:110px;display:flex;align-items:center;justify-content:center;font-size:34px;}
.pc-body{padding:9px 11px;}
.pc-brand{font-size:9.5px;font-weight:700;color:var(--pri);margin-bottom:2px;}
.pc-name{font-size:12px;font-weight:600;line-height:1.3;margin-bottom:4px;}
.pc-price{font-size:14px;font-weight:800;color:var(--pri);}
.pc-old{font-size:11px;color:var(--text3);text-decoration:line-through;margin-left:4px;}

/* Notif items */
.notif-item{
  display:flex;align-items:flex-start;gap:10px;
  padding:11px 0;border-bottom:1px solid var(--border);
}
.notif-item:last-child{border:none;padding-bottom:0;}
.ni-ico{
  width:36px;height:36px;border-radius:10px;
  display:flex;align-items:center;justify-content:center;
  font-size:15px;flex-shrink:0;
}
.ni-title{font-size:13px;font-weight:600;margin-bottom:2px;}
.ni-desc{font-size:11px;color:var(--text2);}
.ni-time{font-size:10px;color:var(--text3);margin-top:2px;}

/* Chat */
.chat-wrap{
  display:flex;flex-direction:column;
  height:calc(100svh - var(--nav-h) - var(--bot-h) - 32px);
  min-height:380px;
}
@media(min-width:901px){
  .chat-wrap{height:calc(100svh - var(--nav-h) - 32px);}
}
.chat-msgs{flex:1;overflow-y:auto;padding:10px 0;display:flex;flex-direction:column;gap:10px;}
.msg{display:flex;align-items:flex-end;gap:7px;}
.msg.user{flex-direction:row-reverse;}
.msg-av{
  width:26px;height:26px;border-radius:50%;flex-shrink:0;
  background:var(--pri-btn);display:flex;align-items:center;
  justify-content:center;font-size:12px;color:#fff;
}
.msg-bubble{
  max-width:80%;padding:9px 12px;border-radius:14px;
  font-size:12.5px;line-height:1.6;
  background:var(--bg2);border:1px solid var(--border);
  border-bottom-left-radius:4px;
}
.msg.user .msg-bubble{
  background:var(--pri-dim);border-color:var(--pri-glow);
  border-bottom-right-radius:4px;border-bottom-left-radius:14px;
}
.chat-sugg{display:flex;gap:6px;overflow-x:auto;padding:8px 0;flex-wrap:wrap;}
.sugg-btn{
  white-space:nowrap;padding:6px 12px;border-radius:20px;
  background:var(--bg2);border:1px solid var(--border);
  font-size:11.5px;color:var(--text2);font-family:var(--font);
  cursor:pointer;transition:all .15s;
}
.sugg-btn:hover{background:var(--pri-dim);color:var(--pri);border-color:var(--pri-glow);}
.chat-input-row{
  display:flex;gap:8px;padding:8px 0 0;
  border-top:1px solid var(--border);
}

/* Map */
.map-mock{
  height:230px;border-radius:var(--r-lg);
  background:linear-gradient(135deg,#0f2010,#0f1a20);
  display:flex;flex-direction:column;
  align-items:center;justify-content:center;
  gap:8px;border:1px solid var(--border);
  margin-bottom:14px;
  box-shadow:var(--shadow);
}

/* Alert */
.alert{
  display:flex;align-items:flex-start;gap:10px;
  padding:11px 13px;border-radius:var(--r);
  font-size:12.5px;margin-bottom:12px;
  border-width:1px;border-style:solid;
}
.alert-g{background:var(--pri-dim);border-color:var(--pri-glow);color:var(--pri);}
.alert-b{background:var(--sec-dim);border-color:rgba(109,138,255,.2);color:var(--sec);}

/* ══════════════════════════════════
   AUTH
══════════════════════════════════ */
.admin-only{display:none;}
body.is-admin .admin-only{display:flex;}
body.is-staff .admin-only.staff-ok{display:flex;}
.admin-content-wrap{display:none;}
body.is-admin .admin-content-wrap,
body.is-staff .admin-content-wrap{display:block;}
body.is-admin #admin-lock,
body.is-staff #admin-lock{display:none!important;}
.page-locked{
  display:flex;flex-direction:column;align-items:center;
  justify-content:center;min-height:300px;
  gap:12px;text-align:center;padding:32px;
}
.lock-ico{font-size:50px;margin-bottom:4px;}
.lock-title{font-size:18px;font-weight:800;}
.lock-sub{font-size:13px;color:var(--text2);max-width:270px;line-height:1.6;}
.lock-btn{
  padding:11px 26px;border-radius:var(--r);
  background:var(--pri-btn);color:#fff;font-weight:700;
  font-size:14px;border:none;cursor:pointer;font-family:var(--font);
  box-shadow:0 4px 16px var(--pri-glow);transition:opacity .15s;margin-top:6px;
}
.lock-btn:hover{opacity:.9;}
.admin-tab-panel{display:none;}

/* ══════════════════════════════════
   MASCOT FLOAT
══════════════════════════════════ */
.mascot{
  position:fixed;
  bottom:calc(var(--bot-h) + env(safe-area-inset-bottom,0px) + 12px);
  right:14px;width:48px;height:48px;border-radius:50%;
  background:var(--pri-btn);
  display:flex;align-items:center;justify-content:center;
  font-size:22px;cursor:pointer;
  box-shadow:0 4px 20px var(--pri-glow);
  z-index:50;transition:all .2s;
  border:2px solid rgba(255,255,255,.15);
}
.mascot:hover{transform:scale(1.1);}
.mascot:active{transform:scale(.95);}
@media(min-width:901px){.mascot{bottom:18px;right:20px;}}

/* ══════════════════════════════════
   MORE SHEET
══════════════════════════════════ */
.more-overlay{display:none;position:fixed;inset:0;background:rgba(0,0,0,.55);z-index:400;}
.more-overlay.open{display:block;}
.more-sheet{
  position:fixed;bottom:0;left:0;right:0;
  background:var(--bg2);border-radius:20px 20px 0 0;
  padding:12px 14px calc(var(--bot-h) + env(safe-area-inset-bottom,0px) + 8px);
  z-index:401;box-shadow:0 -8px 40px rgba(0,0,0,.4);
  transform:translateY(100%);
  transition:transform .35s cubic-bezier(.4,0,.2,1),background .3s;
}
.more-sheet.open{transform:translateY(0);}
.more-handle{width:36px;height:3px;border-radius:2px;background:var(--border2);margin:0 auto 14px;}
.more-grid{display:grid;grid-template-columns:repeat(4,1fr);gap:8px;}
.mi{
  display:flex;flex-direction:column;align-items:center;gap:7px;
  padding:12px 6px;border-radius:var(--r-lg);
  background:var(--bg3);cursor:pointer;transition:all .15s;
  border:1px solid var(--border);
}
.mi:hover{background:var(--surface);border-color:var(--pri);}
.mi:active{transform:scale(.95);}
.mi-ico{
  width:40px;height:40px;border-radius:11px;
  display:flex;align-items:center;justify-content:center;font-size:17px;
}
.mi-lbl{font-size:10px;font-weight:600;color:var(--text2);text-align:center;}

/* ══════════════════════════════════
   LOGIN MODAL
══════════════════════════════════ */
.login-overlay{
  display:none;position:fixed;inset:0;
  background:rgba(0,0,0,.6);backdrop-filter:blur(6px);
  z-index:500;align-items:center;justify-content:center;padding:16px;
}
.login-overlay.open{display:flex;}
.login-box{
  background:var(--bg2);border:1px solid var(--border2);
  border-radius:var(--r-xl);padding:26px 22px;
  width:100%;max-width:340px;
  box-shadow:0 20px 60px rgba(0,0,0,.5);
  position:relative;
}
.login-close{
  position:absolute;top:12px;right:12px;
  width:26px;height:26px;border-radius:50%;
  background:var(--bg3);border:none;cursor:pointer;
  color:var(--text2);font-size:13px;
  display:flex;align-items:center;justify-content:center;
}
.login-logo{
  width:52px;height:52px;border-radius:14px;
  background:var(--pri-btn);
  display:flex;align-items:center;justify-content:center;
  font-size:24px;color:#fff;margin:0 auto 12px;
}
.login-title{font-size:17px;font-weight:800;text-align:center;margin-bottom:3px;}
.login-sub{font-size:11.5px;color:var(--text3);text-align:center;margin-bottom:18px;}
.login-fld{margin-bottom:12px;}
.login-lbl{display:block;font-size:11px;font-weight:600;color:var(--text2);margin-bottom:4px;}
.login-inp{
  width:100%;padding:10px 13px;border-radius:var(--r);
  background:var(--bg3);border:1.5px solid var(--border2);
  color:var(--text);font-size:13.5px;font-family:var(--font);outline:none;
  transition:border-color .15s,box-shadow .15s;
}
.login-inp:focus{border-color:var(--pri);box-shadow:0 0 0 3px var(--pri-dim);}
.login-btn{
  width:100%;padding:11px;border-radius:var(--r);
  background:var(--pri-btn);color:#fff;font-weight:700;
  font-size:13.5px;border:none;cursor:pointer;
  font-family:var(--font);
  box-shadow:0 4px 16px var(--pri-glow);
  transition:opacity .15s;margin-top:4px;
}
.login-btn:hover{opacity:.9;}
.login-err{
  display:none;padding:8px 12px;border-radius:var(--r);
  background:var(--red-dim);border:1px solid rgba(248,113,113,.2);
  color:var(--red);font-size:12px;font-weight:600;margin-bottom:10px;
}
.login-err.show{display:block;}
.login-hint{
  margin-top:12px;padding:9px 11px;border-radius:var(--r);
  background:var(--bg3);font-size:11px;color:var(--text3);
  line-height:1.7;border:1px solid var(--border);
}
.login-hint code{
  background:var(--surface);padding:1px 5px;
  border-radius:4px;color:var(--text2);font-size:10.5px;
}

/* ══════════════════════════════════
   TOAST
══════════════════════════════════ */
#toast{
  position:fixed;top:62px;left:50%;transform:translateX(-50%) translateY(-8px);
  padding:8px 16px;border-radius:var(--r);font-size:12.5px;font-weight:600;
  color:var(--text);z-index:600;white-space:nowrap;pointer-events:none;
  font-family:var(--font);opacity:0;transition:all .3s;
  border:1px solid transparent;
}
#toast.show{opacity:1;transform:translateX(-50%) translateY(0);}

/* ══════════════════════════════════
   RESPONSIVE
══════════════════════════════════ */
@media(max-width:900px){
  .sidebar.open{display:flex;}
  .menu-btn{display:flex;}
}
@media(min-width:901px){
  .sidebar{display:flex;}
  .bottom-nav{display:none!important;}
  .mascot{bottom:18px;}
}
/* ══ PHONE MOCKUP SECTION ══ */
.phone-section{
  background:var(--bg2);border:1px solid var(--border);border-radius:16px;
  padding:36px 28px;margin-bottom:20px;overflow:hidden;
  position:relative;
}
.phone-section-bg{
  position:absolute;inset:0;opacity:.04;
  background:radial-gradient(ellipse 80% 60% at 70% 50%,var(--gold) 0%,transparent 60%);
  pointer-events:none;
}
.phone-section-inner{display:flex;align-items:center;gap:32px;flex-wrap:wrap;}
.phone-section-text{flex:1;min-width:260px;}
.phone-section-title{font-size:clamp(20px,3vw,30px);font-weight:900;line-height:1.2;margin-bottom:10px;}
.phone-section-title span{color:var(--gold);}
.phone-section-desc{font-size:13px;color:var(--text2);line-height:1.6;margin-bottom:18px;}
.phone-features{display:flex;flex-direction:column;gap:10px;margin-bottom:20px;}
.phone-feat{display:flex;align-items:flex-start;gap:10px;}
.phone-feat-icon{width:34px;height:34px;border-radius:9px;display:flex;align-items:center;justify-content:center;font-size:16px;flex-shrink:0;}
.phone-feat-text{font-size:12.5px;line-height:1.4;}
.phone-feat-title{font-weight:700;margin-bottom:1px;}
.phone-feat-sub{color:var(--text2);font-size:11.5px;}

.phone-mockup-wrap{display:flex;gap:16px;align-items:flex-end;flex-shrink:0;}
.phone-mockup{
  width:160px;border-radius:28px;overflow:hidden;
  border:3px solid var(--border2);
  box-shadow:0 16px 48px rgba(0,0,0,.4);
  background:var(--bg3);
  position:relative;
}
.phone-mockup.tall{width:180px;}
.phone-notch{
  position:absolute;top:0;left:50%;transform:translateX(-50%);
  width:60px;height:20px;background:var(--bg3);border-radius:0 0 14px 14px;
  z-index:2;
}
.phone-screen{width:100%;aspect-ratio:9/19;object-fit:cover;}
.phone-screen-placeholder{
  width:100%;aspect-ratio:9/19;
  display:flex;flex-direction:column;align-items:center;justify-content:center;
  gap:8px;font-size:11px;color:var(--text3);padding:16px;text-align:center;
}


/* ══ AR MODAL ══ */
.ar-modal{
  display:none;position:fixed;inset:0;z-index:400;
  background:rgba(0,0,0,.95);
  flex-direction:column;align-items:center;justify-content:center;
}
.ar-modal.open{display:flex;}
.ar-viewport{
  width:100%;max-width:500px;height:60vh;
  border-radius:20px;overflow:hidden;position:relative;
  background:#000;border:2px solid var(--gold);
}
.ar-cam-placeholder{
  width:100%;height:100%;
  background:linear-gradient(135deg,#0a1628,#0d2a10,#1a0a28);
  display:flex;align-items:center;justify-content:center;
  position:relative;overflow:hidden;
}
.ar-grid{
  position:absolute;inset:0;opacity:.15;
  background-image:linear-gradient(var(--gold) 1px,transparent 1px),linear-gradient(90deg,var(--gold) 1px,transparent 1px);
  background-size:50px 50px;
}
.ar-scan-line{
  position:absolute;top:0;left:0;right:0;height:2px;
  background:linear-gradient(90deg,transparent,var(--gold),transparent);
  animation:scan 2.5s ease-in-out infinite;
}
@keyframes scan{0%{top:0%;}50%{top:95%;}100%{top:0%;}}
.ar-mascot-3d{
  position:absolute;bottom:20%;left:50%;transform:translateX(-50%);
  font-size:80px;
  animation:arFloat 3s ease-in-out infinite;
  filter:drop-shadow(0 0 20px rgba(240,180,41,.6));
}
@keyframes arFloat{0%,100%{transform:translateX(-50%) translateY(0) scale(1);}50%{transform:translateX(-50%) translateY(-12px) scale(1.05);}}
.ar-shadow{
  position:absolute;bottom:18%;left:50%;transform:translateX(-50%);
  width:80px;height:14px;border-radius:50%;
  background:rgba(240,180,41,.3);
  filter:blur(8px);
  animation:arShadow 3s ease-in-out infinite;
}
@keyframes arShadow{0%,100%{transform:translateX(-50%) scale(1);opacity:.5;}50%{transform:translateX(-50%) scale(.7);opacity:.2;}}
.ar-corner{position:absolute;width:20px;height:20px;border-color:var(--gold);border-style:solid;}
.ar-corner.tl{top:12px;left:12px;border-width:2px 0 0 2px;}
.ar-corner.tr{top:12px;right:12px;border-width:2px 2px 0 0;}
.ar-corner.bl{bottom:12px;left:12px;border-width:0 0 2px 2px;}
.ar-corner.br{bottom:12px;right:12px;border-width:0 2px 2px 0;}
.ar-info{
  text-align:center;padding:16px;color:#fff;
}
.ar-title{font-size:18px;font-weight:800;margin-bottom:4px;}
.ar-sub{font-size:12px;color:rgba(255,255,255,.6);}
.ar-controls{display:flex;gap:10px;margin-top:14px;flex-wrap:wrap;justify-content:center;}
.ar-char-btn{
  background:var(--bg3);border:1px solid var(--border2);border-radius:12px;
  padding:8px 14px;cursor:pointer;font-family:var(--font);
  font-size:12px;color:var(--text);transition:all .15s;
  display:flex;flex-direction:column;align-items:center;gap:3px;
}
.ar-char-btn.selected{border-color:var(--gold);background:var(--gold-dim);color:var(--gold);}
.ar-char-btn span{font-size:22px;}


/* ══ ART GALLERY ══ */
.art-newsfeed{display:flex;flex-direction:column;gap:0;}
.art-feed-item{
  background:var(--bg2);border:1px solid var(--border);border-radius:16px;
  overflow:hidden;margin-bottom:16px;transition:all .2s;
}
.art-feed-item:hover{border-color:var(--border2);}
/* Hero (first) card — big image */
.art-feed-hero .art-img-wrap{height:340px;}
.art-img-wrap{
  width:100%;height:220px;overflow:hidden;position:relative;cursor:pointer;
}
.art-img-wrap img{
  width:100%;height:100%;object-fit:cover;transition:transform .5s ease;
}
.art-img-wrap:hover img{transform:scale(1.04);}
.art-img-overlay{
  position:absolute;inset:0;
  background:linear-gradient(to top,rgba(0,0,0,.75) 0%,rgba(0,0,0,.1) 50%,transparent 100%);
  display:flex;flex-direction:column;justify-content:flex-end;padding:16px;
}
.art-season-badge{
  display:inline-flex;align-items:center;gap:5px;
  background:rgba(240,180,41,.9);color:#000;
  font-size:10px;font-weight:800;padding:3px 10px;border-radius:20px;
  margin-bottom:6px;width:fit-content;
}
.art-img-title{font-size:17px;font-weight:900;color:#fff;line-height:1.2;margin-bottom:4px;}
.art-img-sub{font-size:11px;color:rgba(255,255,255,.75);}
.art-feed-body{padding:16px;}
.art-feed-meta{display:flex;align-items:center;gap:8px;margin-bottom:10px;flex-wrap:wrap;}
.art-avatar-group{display:flex;}
.art-av{width:28px;height:28px;border-radius:50%;border:2px solid var(--bg2);background:var(--bg3);display:flex;align-items:center;justify-content:center;font-size:11px;margin-left:-6px;}
.art-av:first-child{margin-left:0;}
.art-feed-caption{font-size:13px;line-height:1.6;color:var(--text);margin-bottom:10px;}
.art-feed-caption .read-more{color:var(--gold);cursor:pointer;font-weight:600;}
.art-feed-tags{display:flex;gap:5px;flex-wrap:wrap;margin-bottom:12px;}
.art-tag{background:var(--bg3);border:1px solid var(--border);border-radius:20px;padding:3px 10px;font-size:10px;color:var(--text2);}
.art-feed-actions{display:flex;gap:8px;padding-top:10px;border-top:1px solid var(--border);}
.art-action{display:flex;align-items:center;gap:5px;font-size:11.5px;color:var(--text3);cursor:pointer;transition:color .15s;border:none;background:none;font-family:var(--font);padding:4px 8px;border-radius:7px;}
.art-action:hover{color:var(--gold);background:var(--gold-dim);}

/* Detail panel */
.art-detail-panel{
  display:none;background:var(--bg3);border-top:1px solid var(--border);padding:16px;
}
.art-detail-panel.open{display:block;}
.art-detail-title{font-size:14px;font-weight:700;margin-bottom:10px;color:var(--gold);}

/* Season timeline */
.season-timeline{display:flex;gap:0;overflow-x:auto;padding-bottom:6px;}
.season-node{
  display:flex;flex-direction:column;align-items:center;
  min-width:100px;position:relative;
}
.season-node::before{
  content:'';position:absolute;top:16px;left:50%;right:-50%;
  height:2px;background:var(--border2);z-index:0;
}
.season-node:last-child::before{display:none;}
.season-icon{
  width:34px;height:34px;border-radius:50%;
  display:flex;align-items:center;justify-content:center;
  font-size:14px;z-index:1;border:2px solid var(--border2);
  background:var(--bg2);margin-bottom:5px;
}
.season-node.done .season-icon{background:var(--green-dim);border-color:var(--green);}
.season-node.active .season-icon{background:var(--gold-dim);border-color:var(--gold);animation:pulse 2s infinite;}
@keyframes pulse{0%,100%{box-shadow:0 0 0 0 rgba(240,180,41,.4);}50%{box-shadow:0 0 0 6px rgba(240,180,41,0);}}
.season-label{font-size:9px;font-weight:600;color:var(--text2);text-align:center;line-height:1.3;}
.season-month{font-size:8px;color:var(--text3);text-align:center;margin-top:2px;}

/* Annual calendar table */
.annual-table{width:100%;border-collapse:collapse;font-size:11.5px;}
.annual-table th{
  background:var(--bg3);padding:8px 12px;text-align:left;
  font-weight:700;color:var(--text2);border-bottom:2px solid var(--border2);
  white-space:nowrap;
}
.annual-table td{padding:9px 12px;border-bottom:1px solid var(--border);vertical-align:top;}
.annual-table tr:last-child td{border-bottom:none;}
.annual-table tr:hover td{background:var(--surface);}
.step-num{
  width:24px;height:24px;border-radius:50%;background:var(--gold);
  color:#000;font-weight:800;font-size:10px;
  display:inline-flex;align-items:center;justify-content:center;
  flex-shrink:0;margin-right:6px;
}

/* Gallery seasons grid */
.seasons-overview{display:grid;grid-template-columns:repeat(auto-fill,minmax(200px,1fr));gap:12px;margin-bottom:16px;}
.season-card{
  background:var(--bg2);border:1px solid var(--border);border-radius:12px;overflow:hidden;
  cursor:pointer;transition:all .2s;
}
.season-card:hover{border-color:var(--gold);transform:translateY(-2px);}
.season-card-img{width:100%;height:120px;object-fit:cover;}
.season-card-img-placeholder{
  width:100%;height:120px;
  display:flex;align-items:center;justify-content:center;font-size:32px;
}
.season-card-body{padding:10px 12px;}
.season-card-year{font-size:10px;font-weight:700;color:var(--gold);margin-bottom:2px;}
.season-card-title{font-size:12.5px;font-weight:700;margin-bottom:3px;}
.season-card-sub{font-size:10.5px;color:var(--text2);}


/* VIDEO CARD */
.video-card{background:var(--bg2);border:1px solid var(--border);border-radius:14px;overflow:hidden;cursor:pointer;transition:all .2s;}
.video-card:hover{border-color:var(--gold);transform:translateY(-2px);}
.video-thumb{width:100%;height:140px;object-fit:cover;position:relative;background:var(--bg3);}
.video-thumb-placeholder{width:100%;height:140px;background:linear-gradient(135deg,#1a2535,#0d1f17);display:flex;align-items:center;justify-content:center;position:relative;}
.play-btn{width:44px;height:44px;border-radius:50%;background:rgba(240,180,41,.9);display:flex;align-items:center;justify-content:center;font-size:16px;}
.video-body{padding:12px;}
.video-title{font-size:12.5px;font-weight:600;line-height:1.3;margin-bottom:4px;}
.video-meta{font-size:10px;color:var(--text3);}

/* CALENDAR/SCHEDULE */
/* ══ PROMO SECTION ══ */
.promo-grid{display:grid;grid-template-columns:repeat(auto-fill,minmax(240px,1fr));gap:14px;}
.promo-card{
  border-radius:14px;overflow:hidden;cursor:pointer;
  transition:all .2s;border:1px solid var(--border);
  background:var(--bg2);
}
.promo-card:hover{transform:translateY(-3px);box-shadow:0 10px 32px rgba(0,0,0,.2);border-color:var(--gold);}
.promo-banner{width:100%;height:140px;object-fit:cover;display:block;}
.promo-banner-placeholder{
  width:100%;height:140px;
  display:flex;align-items:center;justify-content:center;
  font-size:13px;font-weight:700;color:#fff;
  position:relative;overflow:hidden;
}
.promo-body{padding:12px 14px;}
.promo-brand{font-size:11.5px;font-weight:800;color:var(--gold);margin-bottom:2px;}
.promo-title{font-size:12.5px;font-weight:600;color:var(--text);line-height:1.3;margin-bottom:4px;}
.promo-date{font-size:10.5px;color:var(--text3);}
.promo-badge{position:absolute;top:8px;right:8px;background:var(--gold);color:#000;font-size:9px;font-weight:800;padding:3px 8px;border-radius:20px;}


/* ══ LIGHT MODE OVERRIDES ══ */
body.light .card{background:var(--bg2);}
body.light .stat-card{background:var(--bg2);}
body.light .sidebar{background:var(--bg2);}
body.light .topnav{background:var(--bg2);}
body.light .bottom-nav{background:var(--bg2);}
body.light .msg-bubble{background:var(--surface);}
body.light .product-card{background:var(--bg2);}
body.light .tool-card{background:var(--bg2);}
body.light .inp{background:var(--bg3);color:var(--text);}
body.light .select{background:var(--bg3);color:var(--text);}
body.light table thead th{background:var(--bg3);}
body.light .map-mock{background:linear-gradient(135deg,#c8d8e8,#c8dac8);}
body.light .sb-ico{background:var(--bg3);}
body.light .sb-item.active .sb-ico{background:var(--gold-dim);}
body.light .promo-card{background:var(--bg2);}
body.light .phone-section{background:var(--bg2);}
body.light .phone-mockup{border-color:rgba(0,0,0,.2);background:var(--bg3);}
body.light .phone-section-bg{opacity:.06;}
*,*::before,*::after{margin:0;padding:0;box-sizing:border-box;-webkit-tap-highlight-color:transparent;}
html,body{height:100%;margin:0;padding:0;}
body{overflow:hidden;font-family:var(--font);background:var(--bg);color:var(--text);font-size:14px;}

/* ── SCROLLBAR ── */
::-webkit-scrollbar{width:4px;height:4px;}
::-webkit-scrollbar-track{background:transparent;}
::-webkit-scrollbar-thumb{background:var(--border2);border-radius:4px;}




/* ── app15 compat ── */
.btn-gold{background:var(--pri-btn);color:#fff;border-color:transparent;}
.btn-gold:hover{opacity:.9;}
.btn-green{background:var(--pri-dim);color:var(--pri);border:1px solid var(--pri-glow);}
.btn-outline,.btn-ghost2{background:transparent;color:var(--text2);border:1px solid var(--border2);}
.badge-gold{background:var(--warn-dim);color:var(--warn);display:inline-flex;align-items:center;font-size:10px;font-weight:700;padding:3px 8px;border-radius:20px;}
.badge-green{background:var(--pri-dim);color:var(--pri);display:inline-flex;align-items:center;font-size:10px;font-weight:700;padding:3px 8px;border-radius:20px;}
.badge-red{background:var(--red-dim);color:var(--red);display:inline-flex;align-items:center;font-size:10px;font-weight:700;padding:3px 8px;border-radius:20px;}
.badge-purple{background:var(--purple-dim);color:var(--purple);display:inline-flex;align-items:center;font-size:10px;font-weight:700;padding:3px 8px;border-radius:20px;}
.badge-cyan{background:var(--cyan-dim);color:var(--cyan);display:inline-flex;align-items:center;font-size:10px;font-weight:700;padding:3px 8px;border-radius:20px;}
.grid-2{display:grid;grid-template-columns:repeat(2,1fr);gap:12px;}
.grid-3{display:grid;grid-template-columns:repeat(3,1fr);gap:12px;}
@media(max-width:600px){.grid-3{grid-template-columns:repeat(2,1fr);}}
.grid-4{display:grid;grid-template-columns:repeat(2,1fr);gap:10px;}
@media(min-width:500px){.grid-4{grid-template-columns:repeat(4,1fr);}}


/* ══ NETFLIX-STYLE KNOWLEDGE ══ */
.nf-hero{
  position:relative;height:220px;border-radius:var(--r-xl);
  overflow:hidden;margin-bottom:20px;
  background:#000;
}
@media(min-width:600px){.nf-hero{height:280px;}}
.nf-hero-bg{
  display:none;
}
.nf-hero-overlay{
  position:absolute;inset:0;
  background:linear-gradient(to right,rgba(0,0,0,.65) 35%,rgba(0,0,0,.05));
  display:flex;flex-direction:column;justify-content:flex-end;
  padding:24px 24px;
}
.nf-hero-tag{font-size:9px;font-weight:700;letter-spacing:2px;text-transform:uppercase;color:var(--pri);margin-bottom:6px;}
.nf-hero-title{font-size:clamp(18px,3vw,28px);font-weight:900;color:#fff;line-height:1.2;margin-bottom:6px;}
.nf-hero-desc{font-size:12px;color:rgba(255,255,255,.65);max-width:360px;line-height:1.5;margin-bottom:12px;}
.nf-hero-btns{display:flex;gap:8px;}
.nf-play-btn{
  display:flex;align-items:center;gap:7px;
  padding:9px 18px;border-radius:var(--r);
  background:#fff;color:#000;font-weight:700;font-size:13px;
  border:none;cursor:pointer;font-family:var(--font);
  transition:opacity .15s;
}
.nf-play-btn:hover{opacity:.85;}
.nf-info-btn{
  display:flex;align-items:center;gap:6px;
  padding:9px 16px;border-radius:var(--r);
  background:rgba(255,255,255,.25);color:#fff;font-weight:600;font-size:12px;
  border:1px solid rgba(255,255,255,.3);cursor:pointer;font-family:var(--font);
  backdrop-filter:blur(4px);
}
/* Row / Rail */
.nf-section{margin-bottom:24px;}
.nf-rail-head{
  display:flex;align-items:center;gap:8px;
  margin-bottom:10px;
}
.nf-rail-title{font-size:14px;font-weight:700;color:var(--text);}
.nf-rail-more{
  font-size:11px;color:var(--pri);cursor:pointer;margin-left:auto;
  display:flex;align-items:center;gap:3px;
}
.nf-rail{
  display:flex;gap:8px;overflow-x:auto;padding-bottom:6px;
  -webkit-overflow-scrolling:touch;scrollbar-width:none;
}
.nf-rail::-webkit-scrollbar{display:none;}
/* Cards */
.nf-card{
  flex-shrink:0;width:160px;border-radius:var(--r);
  overflow:hidden;cursor:pointer;
  background:var(--bg2);border:1px solid var(--border);
  transition:all .2s;
  position:relative;
}
@media(min-width:500px){.nf-card{width:190px;}}
.nf-card:hover{transform:scale(1.04);box-shadow:var(--shadow2);border-color:var(--pri);z-index:2;}
.nf-card-thumb{
  width:100%;height:95px;object-fit:cover;
  display:flex;align-items:center;justify-content:center;
  position:relative;
}
@media(min-width:500px){.nf-card-thumb{height:110px;}}
.nf-card-play{
  position:absolute;inset:0;
  display:flex;align-items:center;justify-content:center;
  background:rgba(0,0,0,.35);opacity:0;
  transition:opacity .2s;
}
.nf-card:hover .nf-card-play{opacity:1;}
.nf-card-play i{font-size:28px;color:#fff;}
.nf-card-body{padding:8px 10px;}
.nf-card-title{font-size:11.5px;font-weight:600;line-height:1.3;margin-bottom:3px;color:var(--text);}
.nf-card-meta{font-size:9.5px;color:var(--text3);display:flex;align-items:center;gap:5px;}
.nf-card-ep{
  position:absolute;top:6px;left:6px;
  padding:2px 6px;border-radius:4px;
  font-size:9px;font-weight:700;
}
/* Wide card for featured */
.nf-card-wide{
  flex-shrink:0;width:240px;border-radius:var(--r);
  overflow:hidden;cursor:pointer;
  background:var(--bg2);border:1px solid var(--border);
  transition:all .2s;position:relative;
}
@media(min-width:500px){.nf-card-wide{width:280px;}}
.nf-card-wide:hover{transform:scale(1.03);box-shadow:var(--shadow2);border-color:var(--pri);}
.nf-card-wide-thumb{
  width:100%;height:130px;
  display:flex;align-items:center;justify-content:center;position:relative;
}
.nf-card-wide .nf-card-play{border-radius:0;}
.nf-card-wide-body{padding:9px 11px;}
.nf-card-wide-title{font-size:12.5px;font-weight:700;margin-bottom:3px;color:var(--text);}
.nf-card-wide-desc{font-size:10.5px;color:var(--text2);line-height:1.4;}
/* Category pills */
.nf-cats{display:flex;gap:6px;overflow-x:auto;padding-bottom:4px;margin-bottom:16px;scrollbar-width:none;}
.nf-cats::-webkit-scrollbar{display:none;}
.nf-cat{
  white-space:nowrap;padding:6px 14px;border-radius:20px;
  font-size:11.5px;font-weight:600;cursor:pointer;
  background:var(--bg2);border:1px solid var(--border);color:var(--text2);
  transition:all .15s;flex-shrink:0;
}
.nf-cat.active{background:var(--pri-btn);color:#fff;border-color:transparent;}
.nf-cat:hover:not(.active){background:var(--surface);color:var(--text);}



/* ── PLAN ROWS (working planner CSS) ── */
.plan-row{display:flex;align-items:center;gap:10px;padding:10px 14px;background:var(--bg3);border-radius:10px;margin-bottom:7px;}
.plan-step{width:28px;height:28px;border-radius:50%;background:var(--pri);color:#000;font-weight:800;font-size:11px;display:flex;align-items:center;justify-content:center;flex-shrink:0;}
.plan-date{font-size:13px;font-weight:700;color:var(--pri);min-width:100px;}
.plan-act{font-size:12.5px;flex:1;font-weight:600;}
.plan-note{font-size:11px;color:var(--text3);}
/* ── ALERT ── */
.alert-green-plan{background:var(--pri-dim);border:1px solid var(--pri-glow);border-radius:var(--r);padding:11px 14px;color:var(--pri);font-size:12.5px;}
/* ── CHAT (working CSS) ── */
.chat-wrap{display:flex;flex-direction:column;height:calc(100svh - var(--nav-h) - var(--bot-h,0px) - 20px);}
@media(min-width:901px){.chat-wrap{height:calc(100svh - var(--nav-h) - 20px);}}
.chat-messages{flex:1;overflow-y:auto;padding:14px;display:flex;flex-direction:column;gap:12px;}
.msg-bot-icon{width:30px;height:30px;border-radius:50%;background:var(--pri-btn);display:flex;align-items:center;justify-content:center;font-size:13px;flex-shrink:0;}
.chat-suggestions{display:flex;gap:6px;flex-wrap:wrap;padding:8px 12px;}
.suggestion-btn{background:var(--bg2);border:1px solid var(--border);border-radius:20px;padding:6px 13px;font-size:11.5px;color:var(--text2);cursor:pointer;transition:all .15s;font-family:var(--font);}
.suggestion-btn:hover{border-color:var(--pri);color:var(--pri);background:var(--pri-dim);}
.chat-input-row{display:flex;gap:8px;padding:10px 12px;border-top:1px solid var(--border);}

/* ── chat-messages fix (HTML uses chat-messages not chat-msgs) ── */
.chat-messages{flex:1;overflow-y:auto;padding:12px;display:flex;flex-direction:column;gap:10px;}
.chat-suggestions{display:flex;gap:6px;flex-wrap:wrap;padding:8px 12px;border-top:1px solid var(--border);}
.suggestion-btn{background:var(--surface);border:1px solid var(--border);border-radius:20px;padding:5px 13px;font-size:11.5px;color:var(--text2);cursor:pointer;transition:all .15s;font-family:var(--font);}
.suggestion-btn:hover{border-color:var(--pri);color:var(--pri);}
.chat-input-row{display:flex;gap:8px;padding:10px 12px;border-top:1px solid var(--border);}
.msg-bot-icon{width:30px;height:30px;border-radius:50%;background:var(--pri-btn);display:flex;align-items:center;justify-content:center;font-size:14px;flex-shrink:0;}

/* ── AR SMART FARM SECTION ── */
.ar-smart-section{background:linear-gradient(135deg,#0a1a0f 0%,#0d2010 40%,#1a2a10 100%);border:1px solid rgba(45,212,160,.2);border-radius:var(--r-xl);padding:32px 24px;margin-bottom:20px;overflow:hidden;position:relative;}
body.light .ar-smart-section{background:linear-gradient(135deg,#f0faf4,#e8f5e9,#f5f9e8);border-color:rgba(22,163,74,.2);}
.ar-smart-bg{position:absolute;inset:0;opacity:.06;background:radial-gradient(ellipse 80% 60% at 70% 50%,var(--pri) 0%,transparent 60%);pointer-events:none;}
.ar-smart-inner{display:flex;align-items:center;gap:28px;flex-wrap:wrap;}
.ar-smart-text{flex:1;min-width:240px;}
.ar-smart-tag{font-size:10px;font-weight:700;color:var(--pri);letter-spacing:2px;text-transform:uppercase;margin-bottom:10px;display:flex;align-items:center;gap:6px;}
.ar-smart-title{font-size:clamp(22px,4vw,32px);font-weight:900;line-height:1.2;margin-bottom:10px;color:var(--text);}
.ar-smart-title span{color:var(--pri);}
.ar-smart-desc{font-size:13px;color:var(--text2);line-height:1.7;margin-bottom:16px;}
.ar-feat-list{display:flex;flex-direction:column;gap:10px;margin-bottom:20px;}
.ar-feat{display:flex;align-items:flex-start;gap:10px;}
.ar-feat-icon{width:34px;height:34px;border-radius:9px;display:flex;align-items:center;justify-content:center;font-size:16px;flex-shrink:0;}
.ar-feat-body{}
.ar-feat-title{font-weight:700;font-size:12.5px;margin-bottom:1px;}
.ar-feat-sub{font-size:11.5px;color:var(--text2);}
/* Phone mockup group */
.ar-phones{display:flex;gap:14px;align-items:flex-end;flex-shrink:0;}
.ar-phone{border-radius:26px;overflow:hidden;border:2.5px solid rgba(255,255,255,.15);box-shadow:0 16px 48px rgba(0,0,0,.45);position:relative;flex-shrink:0;}
.ar-phone.p1{width:140px;transform:rotate(-5deg);margin-bottom:20px;}
.ar-phone.p2{width:160px;transform:rotate(1deg);}
.ar-phone.p3{width:140px;transform:rotate(5deg);margin-bottom:20px;}
.ar-phone img{width:100%;aspect-ratio:9/19;object-fit:cover;display:block;}
.ar-phone-notch{position:absolute;top:0;left:50%;transform:translateX(-50%);width:50px;height:16px;background:rgba(0,0,0,.8);border-radius:0 0 12px 12px;z-index:2;}
@media(max-width:700px){.ar-phones{display:none;}}

}

/* ── CHAT (from working source) ── */
.chat-wrap{display:flex;flex-direction:column;height:calc(100svh - var(--nav-h) - 40px);}
@media(min-width:500px){.chat-wrap{height:calc(100svh - var(--nav-h) - var(--bot-h) - 28px);}}
.chat-messages{flex:1;overflow-y:auto;padding:16px;display:flex;flex-direction:column;gap:12px;}
.msg{display:flex;gap:10px;max-width:85%;}
.msg.user{flex-direction:row-reverse;align-self:flex-end;}
.msg-bubble{background:var(--surface);border-radius:14px;padding:10px 14px;font-size:13px;line-height:1.5;border:1px solid var(--border);}
.msg.user .msg-bubble{background:var(--pri-dim);border-color:var(--pri-glow);}
.msg-bot-icon{width:32px;height:32px;border-radius:50%;background:var(--pri-btn);display:flex;align-items:center;justify-content:center;font-size:14px;flex-shrink:0;}
.chat-input-row{display:flex;gap:8px;padding:10px 0 0;border-top:1px solid var(--border);flex-shrink:0;}
.chat-suggestions{display:flex;gap:6px;flex-wrap:wrap;padding:8px 0;flex-shrink:0;}
.suggestion-btn{background:var(--surface);border:1px solid var(--border);border-radius:20px;padding:5px 12px;font-size:11.5px;color:var(--text2);cursor:pointer;transition:all .15s;font-family:var(--font);}
.suggestion-btn:hover,.suggestion-btn:active{border-color:var(--pri);color:var(--pri);background:var(--pri-dim);}
body.light .msg-bubble{background:var(--surface);}

/* typing indicator */
.typing-dot{
  width:7px;height:7px;border-radius:50%;
  background:var(--pri);display:inline-block;
  animation:typingBounce .9s infinite ease-in-out;
}
@keyframes typingBounce{
  0%,60%,100%{transform:translateY(0);}
  30%{transform:translateY(-6px);}
}

/* ── AR QR Modal ── */
#arQRModal{
  display:none;position:fixed;inset:0;background:rgba(0,0,0,.85);z-index:500;
  align-items:center;justify-content:center;padding:20px;
}
#arQRModal.open{display:flex;}
.ar-qr-box{
  background:var(--bg2);border-radius:var(--r-xl);padding:28px 24px;
  max-width:340px;width:100%;text-align:center;border:1px solid var(--border2);
}
.ar-qr-title{font-size:16px;font-weight:800;margin-bottom:6px;}
.ar-qr-sub{font-size:12px;color:var(--text2);margin-bottom:18px;line-height:1.6;}
.ar-qr-img{width:180px;height:180px;margin:0 auto 16px;border-radius:12px;overflow:hidden;background:#fff;padding:10px;}
.ar-qr-img img{width:100%;height:100%;object-fit:contain;}
.ar-qr-url{font-size:11px;color:var(--text3);word-break:break-all;margin-bottom:18px;}
.ar-qr-os{display:flex;gap:10px;justify-content:center;margin-bottom:18px;}
.ar-qr-os-item{flex:1;background:var(--bg3);border:1px solid var(--border);border-radius:12px;padding:10px 6px;text-align:center;}
.ar-qr-os-icon{font-size:20px;margin-bottom:3px;}
.ar-qr-os-label{font-size:10px;color:var(--text2);}
