/* ═══════════════════════════════════════════════════════════════
   AI100x Academy — Design System
   Font: IBM Plex Sans Thai · Accent: Deep Indigo → Violet
   ═══════════════════════════════════════════════════════════════ */

:root{
  --bg:            #f5f6fb;
  --surface:       #ffffff;
  --ink:           #1a1c33;
  --ink-soft:      #40435e;
  --muted:         #6f7390;
  --line:          #e6e8f3;
  --line-soft:     #eef0f8;

  --brand:         #4f46e5;
  --brand-deep:    #3d34cf;
  --brand-soft:    #eceafd;
  --violet:        #8b5cf6;
  --grad:          linear-gradient(120deg,#4f46e5 0%,#7c4ff0 55%,#9d5cf6 100%);

  --green:         #0d9464;
  --green-soft:    #e2f6ee;
  --amber:         #b96e00;
  --amber-soft:    #fdf2df;
  --red:           #d63a55;
  --red-soft:      #fdeaee;

  --radius:        18px;
  --radius-sm:     12px;
  --shadow:        0 6px 24px rgba(41,37,120,.07), 0 1px 3px rgba(41,37,120,.05);
  --shadow-lg:     0 18px 50px rgba(41,37,120,.13);

  /* dark cinema (learn page) */
  --d-bg:          #0c0d19;
  --d-surface:     #14162a;
  --d-surface-2:   #1b1e38;
  --d-line:        #262a4a;
  --d-ink:         #eef0ff;
  --d-muted:       #8e93b8;
}

*{ box-sizing:border-box; margin:0; padding:0; }
html{ -webkit-text-size-adjust:100%; scroll-behavior:smooth; }
body{
  font-family:'IBM Plex Sans Thai',-apple-system,'Segoe UI',sans-serif;
  background:var(--bg); color:var(--ink);
  font-size:16px; line-height:1.65;
  min-height:100vh; display:flex; flex-direction:column;
}
img{ max-width:100%; display:block; }
a{ color:var(--brand); text-decoration:none; }
a:hover{ color:var(--brand-deep); }
main{ flex:1; }
.container{ width:100%; max-width:1120px; margin:0 auto; padding:0 20px; }
.container-sm{ width:100%; max-width:760px; margin:0 auto; padding:0 20px; }

/* ── Header ─────────────────────────────────────────── */
.site-header{
  position:sticky; top:0; z-index:50;
  background:rgba(255,255,255,.86); backdrop-filter:blur(14px);
  border-bottom:1px solid var(--line);
}
.header-inner{ display:flex; align-items:center; justify-content:space-between; gap:14px; height:66px; }
.brand{ display:flex; align-items:center; gap:10px; flex-shrink:0; }
.brand-mark{
  width:36px; height:36px; border-radius:11px; background:var(--grad);
  color:#fff; font-weight:700; font-size:17px;
  display:flex; align-items:center; justify-content:center;
  box-shadow:0 4px 12px rgba(79,70,229,.35);
}
.brand-name{ font-weight:700; font-size:18px; color:var(--ink); letter-spacing:-.01em; }
.brand-name em{ font-style:normal; background:var(--grad); -webkit-background-clip:text; background-clip:text; color:transparent; }
.nav{ display:flex; align-items:center; gap:6px; }
.nav-link{
  padding:8px 13px; border-radius:10px; color:var(--ink-soft);
  font-weight:500; font-size:15px; white-space:nowrap;
}
.nav-link:hover{ background:var(--line-soft); color:var(--ink); }
.nav-user{
  color:var(--muted); font-size:13.5px; max-width:150px;
  overflow:hidden; text-overflow:ellipsis; white-space:nowrap;
  padding:0 4px;
}
@media (max-width:640px){
  .nav-user{ display:none; }
  .brand-name{ font-size:16px; }
  .nav-link{ padding:7px 9px; font-size:14px; }
}

/* dark header variant (learn page) */
.theme-dark{ background:var(--d-bg); color:var(--d-ink); }
.theme-dark .site-header{ background:rgba(12,13,25,.82); border-bottom-color:var(--d-line); }
.theme-dark .brand-name{ color:var(--d-ink); }
.theme-dark .nav-link{ color:var(--d-muted); }
.theme-dark .nav-link:hover{ background:var(--d-surface-2); color:var(--d-ink); }
.theme-dark .nav-user{ color:var(--d-muted); }

/* ── Buttons ────────────────────────────────────────── */
.btn{
  display:inline-flex; align-items:center; justify-content:center; gap:8px;
  padding:12px 24px; border-radius:13px; border:0; cursor:pointer;
  font-family:inherit; font-size:15.5px; font-weight:600; line-height:1.3;
  transition:transform .12s ease, box-shadow .12s ease, background .12s ease;
  text-align:center;
}
.btn:active{ transform:translateY(1px); }
.btn-primary{ background:var(--grad); color:#fff !important; box-shadow:0 6px 18px rgba(79,70,229,.32); }
.btn-primary:hover{ box-shadow:0 8px 24px rgba(79,70,229,.42); filter:brightness(1.05); }
.btn-ghost{ background:var(--surface); color:var(--ink) !important; border:1.5px solid var(--line); }
.btn-ghost:hover{ border-color:var(--brand); color:var(--brand) !important; }
.btn-soft{ background:var(--brand-soft); color:var(--brand-deep) !important; }
.btn-soft:hover{ background:#e0dcfb; }
.btn-danger{ background:var(--red-soft); color:var(--red) !important; }
.btn-danger:hover{ background:#f9d8df; }
.btn-success{ background:var(--green); color:#fff !important; box-shadow:0 5px 15px rgba(13,148,100,.3); }
.btn-lg{ padding:15px 32px; font-size:17px; border-radius:15px; }
.btn-sm{ padding:8px 16px; font-size:14px; border-radius:10px; }
.btn-block{ width:100%; }
.btn[disabled]{ opacity:.6; cursor:not-allowed; }

/* ── Badges ─────────────────────────────────────────── */
.badge{
  display:inline-flex; align-items:center; gap:5px;
  padding:4px 11px; border-radius:99px; font-size:13px; font-weight:600; line-height:1.5;
  white-space:nowrap;
}
.badge-green{ background:var(--green-soft); color:var(--green); }
.badge-amber{ background:var(--amber-soft); color:var(--amber); }
.badge-red{ background:var(--red-soft); color:var(--red); }
.badge-brand{ background:var(--brand-soft); color:var(--brand-deep); }
.badge-gray{ background:var(--line-soft); color:var(--muted); }

/* ── Alerts / notices ───────────────────────────────── */
.notice{ padding:14px 18px; border-radius:var(--radius-sm); font-size:15px; line-height:1.6; }
.notice-error{ background:var(--red-soft); color:#a92742; border:1px solid #f5c2cd; }
.notice-success{ background:var(--green-soft); color:#0a6e4b; border:1px solid #bfe8d6; }
.notice-pending{ background:var(--amber-soft); color:#8a5200; border:1px solid #f3ddb4; }

/* ── Hero (landing) ─────────────────────────────────── */
.hero{
  background:var(--grad); color:#fff; position:relative; overflow:hidden;
}
.hero::before{
  content:''; position:absolute; inset:0;
  background:
    radial-gradient(ellipse 600px 400px at 85% -10%, rgba(255,255,255,.16), transparent 60%),
    radial-gradient(ellipse 500px 350px at 8% 110%, rgba(255,255,255,.10), transparent 60%);
}
.hero-inner{ position:relative; padding:76px 0 84px; text-align:center; }
.hero-eyebrow{
  display:inline-block; padding:6px 16px; border-radius:99px;
  background:rgba(255,255,255,.16); border:1px solid rgba(255,255,255,.28);
  font-size:14px; font-weight:600; margin-bottom:22px; letter-spacing:.01em;
}
.hero h1{
  font-size:clamp(30px,5.4vw,50px); font-weight:700; line-height:1.25;
  letter-spacing:-.02em; max-width:760px; margin:0 auto 18px;
}
.hero p{ font-size:clamp(16px,2.4vw,19px); opacity:.92; max-width:620px; margin:0 auto 34px; }
.hero-actions{ display:flex; gap:14px; justify-content:center; flex-wrap:wrap; }
.hero .btn-white{ background:#fff; color:var(--brand-deep) !important; box-shadow:0 8px 26px rgba(0,0,0,.18); }
.hero .btn-white:hover{ filter:none; box-shadow:0 10px 32px rgba(0,0,0,.25); }
.hero .btn-outline{ background:rgba(255,255,255,.12); color:#fff !important; border:1.5px solid rgba(255,255,255,.45); }
.hero .btn-outline:hover{ background:rgba(255,255,255,.2); }
.hero-points{
  position:relative; display:flex; gap:10px 30px; justify-content:center; flex-wrap:wrap;
  margin-top:38px; font-size:14.5px; font-weight:500; opacity:.94;
}
.hero-points span{ display:inline-flex; align-items:center; gap:7px; }

/* ── Section headings ───────────────────────────────── */
.section{ padding:56px 0 72px; }
.section-head{ margin-bottom:30px; }
.section-head h2{ font-size:clamp(23px,3.5vw,30px); font-weight:700; letter-spacing:-.015em; }
.section-head p{ color:var(--muted); margin-top:6px; font-size:16px; }

/* ── Course cards ───────────────────────────────────── */
.course-grid{
  display:grid; grid-template-columns:repeat(auto-fill,minmax(300px,1fr)); gap:26px;
}
@media (max-width:640px){ .course-grid{ grid-template-columns:1fr; gap:20px; } }
.course-card{
  background:var(--surface); border-radius:var(--radius); overflow:hidden;
  box-shadow:var(--shadow); border:1px solid var(--line-soft);
  display:flex; flex-direction:column;
  transition:transform .18s ease, box-shadow .18s ease;
}
a.course-card{ color:inherit; }
a.course-card:hover{ transform:translateY(-4px); box-shadow:var(--shadow-lg); color:inherit; }
.course-cover{ aspect-ratio:16/9; width:100%; object-fit:cover; background:var(--line-soft); }
.cover-placeholder{
  aspect-ratio:16/9; display:flex; align-items:center; justify-content:center;
  padding:22px; text-align:center; color:#fff; font-weight:700;
  font-size:clamp(17px,2.5vw,21px); line-height:1.4; letter-spacing:-.01em;
}
.cover-g0{ background:linear-gradient(130deg,#4f46e5,#9d5cf6); }
.cover-g1{ background:linear-gradient(130deg,#0e7490,#4f46e5); }
.cover-g2{ background:linear-gradient(130deg,#7c3aed,#db2777); }
.cover-g3{ background:linear-gradient(130deg,#1e3a8a,#7c4ff0); }
.course-body{ padding:20px 22px 22px; display:flex; flex-direction:column; gap:8px; flex:1; }
.course-body h3{ font-size:18.5px; font-weight:700; line-height:1.4; letter-spacing:-.01em; }
.course-sub{ color:var(--muted); font-size:14.5px; line-height:1.55; }
.course-meta{
  display:flex; align-items:center; justify-content:space-between; gap:10px;
  margin-top:auto; padding-top:14px; border-top:1px solid var(--line-soft);
}
.lesson-count{ color:var(--muted); font-size:13.5px; display:inline-flex; align-items:center; gap:6px; }
.price{ font-size:19px; font-weight:700; color:var(--brand-deep); }

/* empty state */
.empty-state{
  text-align:center; padding:70px 24px; background:var(--surface);
  border:1.5px dashed var(--line); border-radius:var(--radius); color:var(--muted);
}
.empty-state .emoji{ font-size:44px; display:block; margin-bottom:14px; }
.empty-state h3{ color:var(--ink); font-size:19px; margin-bottom:6px; }

/* ── Course detail page ─────────────────────────────── */
.course-hero{ background:var(--grad); color:#fff; position:relative; overflow:hidden; }
.course-hero::before{
  content:''; position:absolute; inset:0;
  background:radial-gradient(ellipse 500px 350px at 90% -20%, rgba(255,255,255,.15), transparent 60%);
}
.course-hero-inner{ position:relative; padding:52px 0 130px; }
.crumb{ font-size:14px; opacity:.85; margin-bottom:14px; display:inline-block; color:#fff; }
.crumb:hover{ color:#fff; opacity:1; }
.course-hero h1{ font-size:clamp(26px,4.5vw,40px); font-weight:700; line-height:1.3; letter-spacing:-.02em; max-width:720px; }
.course-hero .sub{ font-size:clamp(15.5px,2.2vw,18px); opacity:.92; margin-top:10px; max-width:640px; }
.detail-layout{
  display:grid; grid-template-columns:1fr 360px; gap:34px;
  margin-top:-86px; position:relative; padding-bottom:70px; align-items:start;
}
@media (max-width:900px){
  .detail-layout{ grid-template-columns:1fr; margin-top:-96px; }
}
.panel{
  background:var(--surface); border-radius:var(--radius);
  box-shadow:var(--shadow); border:1px solid var(--line-soft); padding:28px;
}
.panel h2{ font-size:20px; font-weight:700; margin-bottom:14px; letter-spacing:-.01em; }
.prose{ white-space:pre-line; color:var(--ink-soft); font-size:15.5px; line-height:1.8; }
.buy-card{ position:sticky; top:86px; }
.buy-card .course-cover, .buy-card .cover-placeholder{ border-radius:var(--radius-sm); margin-bottom:18px; }
.buy-price{ font-size:34px; font-weight:700; color:var(--ink); letter-spacing:-.02em; }
.buy-price small{ font-size:15px; color:var(--muted); font-weight:500; }
.buy-perks{ list-style:none; margin:16px 0 20px; display:grid; gap:9px; }
.buy-perks li{ display:flex; gap:9px; font-size:14.5px; color:var(--ink-soft); }
.buy-perks li::before{ content:'✓'; color:var(--green); font-weight:700; flex-shrink:0; }

/* curriculum */
.curriculum{ display:flex; flex-direction:column; }
.lesson-row{
  display:flex; align-items:center; gap:14px; padding:15px 6px;
  border-bottom:1px solid var(--line-soft); color:inherit;
}
.lesson-row:last-child{ border-bottom:0; }
a.lesson-row:hover{ background:var(--line-soft); border-radius:10px; color:inherit; }
.lesson-num{
  width:34px; height:34px; border-radius:10px; background:var(--brand-soft); color:var(--brand-deep);
  display:flex; align-items:center; justify-content:center; font-weight:700; font-size:14px; flex-shrink:0;
}
.lesson-num.locked{ background:var(--line-soft); color:var(--muted); }
.lesson-info{ flex:1; min-width:0; }
.lesson-info .t{ font-weight:600; font-size:15.5px; line-height:1.45; }
.lesson-info .d{ color:var(--muted); font-size:13.5px; margin-top:2px; overflow:hidden; text-overflow:ellipsis; display:-webkit-box; -webkit-line-clamp:1; -webkit-box-orient:vertical; }
.lesson-side{ display:flex; align-items:center; gap:10px; flex-shrink:0; }
.duration{ color:var(--muted); font-size:13.5px; font-variant-numeric:tabular-nums; }

/* ── Auth pages ─────────────────────────────────────── */
.auth-wrap{
  min-height:calc(100vh - 66px); display:flex; align-items:center; justify-content:center;
  padding:48px 20px;
  background:
    radial-gradient(ellipse 700px 480px at 100% 0%, rgba(124,79,240,.10), transparent 60%),
    radial-gradient(ellipse 620px 460px at 0% 100%, rgba(79,70,229,.09), transparent 60%),
    var(--bg);
}
.auth-card{
  width:100%; max-width:430px; background:var(--surface); border-radius:22px;
  box-shadow:var(--shadow-lg); border:1px solid var(--line-soft); padding:38px 34px;
}
@media (max-width:480px){ .auth-card{ padding:30px 22px; } }
.auth-card .auth-logo{
  width:52px; height:52px; border-radius:15px; background:var(--grad); color:#fff;
  font-weight:700; font-size:24px; display:flex; align-items:center; justify-content:center;
  margin:0 auto 18px; box-shadow:0 8px 20px rgba(79,70,229,.35);
}
.auth-card h1{ font-size:23px; font-weight:700; text-align:center; letter-spacing:-.01em; }
.auth-card .auth-sub{ color:var(--muted); text-align:center; font-size:14.5px; margin:6px 0 26px; }
.auth-alt{ text-align:center; margin-top:22px; font-size:14.5px; color:var(--muted); }

/* ── Forms ──────────────────────────────────────────── */
.field{ margin-bottom:16px; }
.field label{ display:block; font-weight:600; font-size:14px; margin-bottom:7px; color:var(--ink-soft); }
.field .hint{ font-size:12.5px; color:var(--muted); margin-top:5px; line-height:1.5; }
input[type=text], input[type=email], input[type=password], input[type=number], textarea, select{
  width:100%; padding:12px 15px; border-radius:12px; border:1.5px solid var(--line);
  background:#fbfbfe; font-family:inherit; font-size:15.5px; color:var(--ink);
  transition:border-color .12s, box-shadow .12s; -webkit-appearance:none; appearance:none;
}
select{
  background-image:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8'%3E%3Cpath d='M1 1l5 5 5-5' stroke='%236f7390' stroke-width='2' fill='none' stroke-linecap='round'/%3E%3C/svg%3E");
  background-repeat:no-repeat; background-position:right 14px center; padding-right:38px;
}
textarea{ min-height:120px; resize:vertical; line-height:1.6; }
input:focus, textarea:focus, select:focus{
  outline:none; border-color:var(--brand); background:#fff;
  box-shadow:0 0 0 3.5px rgba(79,70,229,.13);
}
input[type=file]{ font-size:14px; color:var(--ink-soft); width:100%; }
input[type=file]::file-selector-button{
  font-family:inherit; font-weight:600; font-size:13.5px; color:var(--brand-deep);
  background:var(--brand-soft); border:0; border-radius:9px; padding:8px 14px;
  margin-right:12px; cursor:pointer;
}
.check-row{ display:flex; align-items:center; gap:9px; font-size:15px; font-weight:500; color:var(--ink-soft); cursor:pointer; }
.check-row input{ width:18px; height:18px; accent-color:var(--brand); cursor:pointer; }
.form-grid{ display:grid; grid-template-columns:1fr 1fr; gap:0 16px; }
@media (max-width:560px){ .form-grid{ grid-template-columns:1fr; } }

/* ── Checkout ───────────────────────────────────────── */
.checkout-layout{ display:grid; grid-template-columns:1fr 1fr; gap:26px; align-items:start; padding:44px 0 70px; }
@media (max-width:820px){ .checkout-layout{ grid-template-columns:1fr; } }
.qr-box{ text-align:center; }
.qr-box img{
  width:min(290px,80%); margin:14px auto 12px; border-radius:14px;
  border:1px solid var(--line); box-shadow:var(--shadow);
}
.qr-name{ font-size:14px; color:var(--muted); }
.order-line{ display:flex; justify-content:space-between; gap:12px; padding:13px 0; border-bottom:1px solid var(--line-soft); font-size:15.5px; }
.order-line.total{ border-bottom:0; font-weight:700; font-size:18px; padding-top:16px; }
.order-line.total .price{ font-size:24px; }
.steps{ list-style:none; counter-reset:step; display:grid; gap:14px; margin:20px 0 4px; }
.steps li{ display:flex; gap:13px; align-items:flex-start; font-size:15px; color:var(--ink-soft); }
.steps li::before{
  counter-increment:step; content:counter(step);
  width:28px; height:28px; border-radius:9px; background:var(--brand-soft); color:var(--brand-deep);
  font-weight:700; font-size:14px; display:flex; align-items:center; justify-content:center; flex-shrink:0;
}
.slip-preview{ margin-top:12px; display:none; }
.slip-preview img{ max-height:230px; border-radius:12px; border:1px solid var(--line); margin:0 auto; }

/* ── Learn page (dark cinema) ───────────────────────── */
.learn-layout{
  display:grid; grid-template-columns:minmax(0,1fr) 350px; gap:26px;
  padding:26px 0 60px; align-items:start;
}
@media (max-width:960px){ .learn-layout{ grid-template-columns:1fr; } }
.player-shell{
  background:#000; border-radius:16px; overflow:hidden;
  box-shadow:0 20px 60px rgba(0,0,0,.55); border:1px solid var(--d-line);
}
.player-frame{ position:relative; aspect-ratio:16/9; width:100%; background:#000; }
.player-frame iframe, .player-frame video{
  position:absolute; inset:0; width:100%; height:100%; border:0; display:block;
}
.lesson-head{ margin-top:22px; }
.lesson-head .course-link{ color:var(--violet); font-size:14px; font-weight:600; }
.lesson-head .course-link:hover{ color:#a98bff; }
.lesson-head h1{ font-size:clamp(20px,3vw,26px); font-weight:700; letter-spacing:-.015em; margin-top:5px; line-height:1.4; color:var(--d-ink); }
.lesson-head .meta{ color:var(--d-muted); font-size:14px; margin-top:6px; display:flex; gap:14px; flex-wrap:wrap; align-items:center; }
.lesson-desc{ color:#bcc0dd; font-size:15px; line-height:1.75; margin-top:14px; white-space:pre-line; }
.learn-actions{ display:flex; gap:12px; flex-wrap:wrap; margin-top:22px; align-items:center; }
.btn-dark-ghost{ background:var(--d-surface-2); color:var(--d-ink) !important; border:1px solid var(--d-line); }
.btn-dark-ghost:hover{ background:#242848; }
.btn-complete{ background:var(--grad); color:#fff !important; box-shadow:0 6px 18px rgba(124,79,240,.35); }
.btn-complete.is-done{ background:var(--green); box-shadow:0 6px 18px rgba(13,148,100,.3); }
.nav-btns{ display:flex; gap:10px; margin-left:auto; }
@media (max-width:640px){ .nav-btns{ margin-left:0; width:100%; } .nav-btns .btn{ flex:1; } }

/* playlist */
.playlist{
  background:var(--d-surface); border:1px solid var(--d-line); border-radius:16px;
  overflow:hidden; position:sticky; top:86px; max-height:calc(100vh - 110px);
  display:flex; flex-direction:column;
}
@media (max-width:960px){ .playlist{ position:static; max-height:none; } }
.playlist-head{
  padding:16px 18px; border-bottom:1px solid var(--d-line);
  font-weight:700; font-size:15px; color:var(--d-ink);
}
.playlist-head .sub{ display:block; font-weight:500; font-size:12.5px; color:var(--d-muted); margin-top:3px; }
.playlist-items{ overflow-y:auto; }
.pl-item{
  display:flex; align-items:center; gap:12px; padding:13px 16px;
  border-bottom:1px solid rgba(38,42,74,.55); color:var(--d-ink); font-size:14px;
}
.pl-item:last-child{ border-bottom:0; }
a.pl-item:hover{ background:var(--d-surface-2); color:var(--d-ink); }
.pl-item.current{ background:linear-gradient(90deg,rgba(124,79,240,.22),rgba(124,79,240,.05)); box-shadow:inset 3px 0 0 var(--violet); }
.pl-item.locked{ color:var(--d-muted); cursor:not-allowed; }
.pl-idx{
  width:28px; height:28px; border-radius:9px; flex-shrink:0;
  background:var(--d-surface-2); color:var(--d-muted);
  display:flex; align-items:center; justify-content:center; font-size:12.5px; font-weight:700;
}
.pl-item.current .pl-idx{ background:var(--violet); color:#fff; }
.pl-idx.done{ background:rgba(13,148,100,.25); color:#4ade9d; }
.pl-info{ flex:1; min-width:0; }
.pl-info .t{ font-weight:600; line-height:1.4; overflow:hidden; display:-webkit-box; -webkit-line-clamp:2; -webkit-box-orient:vertical; }
.pl-info .d{ font-size:12px; color:var(--d-muted); margin-top:2px; }
.pl-tag{ flex-shrink:0; font-size:12px; }

/* ── Admin ──────────────────────────────────────────── */
.admin-bar{
  display:flex; align-items:center; justify-content:space-between; gap:14px;
  flex-wrap:wrap; padding:30px 0 22px;
}
.admin-bar h1{ font-size:25px; font-weight:700; letter-spacing:-.015em; }
.admin-bar .links{ display:flex; gap:8px; flex-wrap:wrap; }
.stat-grid{ display:grid; grid-template-columns:repeat(auto-fit,minmax(200px,1fr)); gap:18px; margin-bottom:30px; }
.stat-card{
  background:var(--surface); border-radius:var(--radius); border:1px solid var(--line-soft);
  box-shadow:var(--shadow); padding:20px 22px;
}
.stat-card .label{ color:var(--muted); font-size:13.5px; font-weight:600; }
.stat-card .value{ font-size:30px; font-weight:700; letter-spacing:-.02em; margin-top:4px; }
.stat-card .value.brand{ color:var(--brand-deep); }
.stat-card .value.green{ color:var(--green); }

.table-wrap{ overflow-x:auto; }
table.data{ width:100%; border-collapse:collapse; font-size:14.5px; min-width:560px; }
table.data th{
  text-align:left; font-size:12.5px; text-transform:uppercase; letter-spacing:.05em;
  color:var(--muted); font-weight:700; padding:10px 12px; border-bottom:1.5px solid var(--line);
  white-space:nowrap;
}
table.data td{ padding:13px 12px; border-bottom:1px solid var(--line-soft); vertical-align:middle; }
table.data tr:last-child td{ border-bottom:0; }
table.data .actions{ display:flex; gap:8px; flex-wrap:wrap; }

.pending-card{
  display:grid; grid-template-columns:150px 1fr; gap:20px;
  background:var(--surface); border:1px solid var(--line-soft); border-radius:var(--radius);
  box-shadow:var(--shadow); padding:20px; margin-bottom:16px;
}
@media (max-width:600px){ .pending-card{ grid-template-columns:1fr; } }
.pending-card .slip-thumb img{
  width:100%; border-radius:10px; border:1px solid var(--line); max-height:220px; object-fit:cover; object-position:top;
}
.verify-note{
  background:#f4f5fb; border:1px solid var(--line); border-radius:10px;
  font-family:'IBM Plex Mono',ui-monospace,monospace; font-size:12px; color:var(--ink-soft);
  padding:10px 12px; margin-top:10px; white-space:pre-wrap; word-break:break-word;
  max-height:130px; overflow-y:auto; line-height:1.55;
}
.admin-lesson{
  background:var(--surface); border:1px solid var(--line-soft); border-radius:var(--radius-sm);
  box-shadow:var(--shadow); margin-bottom:14px; overflow:hidden;
}
.admin-lesson summary{
  display:flex; align-items:center; gap:12px; padding:16px 20px; cursor:pointer; list-style:none;
  font-weight:600; font-size:15px; flex-wrap:wrap;
}
.admin-lesson summary::-webkit-details-marker{ display:none; }
.admin-lesson summary:hover{ background:var(--line-soft); }
.admin-lesson .lesson-form{ padding:6px 20px 20px; border-top:1px solid var(--line-soft); }
.cover-thumb{ width:190px; border-radius:10px; border:1px solid var(--line); margin-bottom:10px; }

/* ── Footer ─────────────────────────────────────────── */
.site-footer{ background:#12142a; color:#a3a7c8; margin-top:auto; }
.theme-dark .site-footer{ border-top:1px solid var(--d-line); }
.footer-inner{
  display:flex; align-items:center; justify-content:space-between; gap:16px;
  flex-wrap:wrap; padding:30px 0;
}
.footer-brand{ display:flex; align-items:center; gap:10px; color:#fff; font-weight:700; }
.footer-brand .brand-mark{ width:30px; height:30px; font-size:14px; border-radius:9px; box-shadow:none; }
.footer-inner .copy{ font-size:13.5px; }
.footer-inner .flinks{ display:flex; gap:18px; font-size:14px; }
.footer-inner .flinks a{ color:#a3a7c8; }
.footer-inner .flinks a:hover{ color:#fff; }

/* ── Utilities ──────────────────────────────────────── */
.mt-1{ margin-top:8px; } .mt-2{ margin-top:16px; } .mt-3{ margin-top:24px; } .mt-4{ margin-top:36px; }
.mb-2{ margin-bottom:16px; } .mb-3{ margin-bottom:24px; }
.muted{ color:var(--muted); }
.text-center{ text-align:center; }
.flex-between{ display:flex; align-items:center; justify-content:space-between; gap:12px; flex-wrap:wrap; }
