/* =====================================================================
   에드에플릭스 (ADAFFLIX) · Design Tokens v3 — Fresh Emerald · Ivory · Watercolor
   라이트 :root / 다크 [data-theme="dark"].
   톤: 산뜻한 프레시 그린 + 미색(아이보리) 베이스 + 수채화 무드.
   ===================================================================== */

:root {
  /* ── Brand · Fresh Emerald ─────────────────────────────────────── */
  --brand-50:  #e9f8f0;
  --brand-100: #cdf0de;
  --brand-200: #9ee3c2;
  --brand-300: #63d2a0;
  --brand-400: #30bd82;
  --brand-500: #17ad72;
  --brand-600: #0f9a63;
  --brand-700: #0c7e51;
  --brand-800: #0b6342;
  --brand-900: #094c34;

  /* ── Money · Emerald ───────────────────────────────────────────── */
  --green-50:  #e9f8f0;
  --green-100: #cdf0de;
  --green-200: #9ee3c2;
  --green-400: #2cc488;
  --green-500: #14ad72;
  --green-600: #0f9a63;
  --green-700: #0c7e51;

  /* ── Accent · Clay (인기/활기) ─────────────────────────────────── */
  --pop-50:  #fcefe9;
  --pop-100: #f8ddd0;
  --pop-300: #eaa98a;
  --pop-400: #de8460;
  --pop-500: #d06440;
  --pop-600: #b54f30;
  --pop-700: #8f3e26;

  /* ── Warm · Gold ───────────────────────────────────────────────── */
  --amber-50:  #faf2dd;
  --amber-400: #dcb35f;
  --amber-500: #c2953f;
  --amber-600: #9d762d;

  /* ── Neutral · Warm Ivory (미색) ───────────────────────────────── */
  --gray-50:  #faf6ec;
  --gray-100: #f3eedf;
  --gray-200: #ebe4d2;
  --gray-300: #dbd2bd;
  --gray-400: #aaa088;
  --gray-500: #786f5a;
  --gray-600: #574e3d;
  --gray-700: #3d362a;
  --gray-800: #28221a;
  --gray-900: #17130d;
  --gray-950: #0c0a06;

  /* ── Semantic · Light (Ivory base) ─────────────────────────────── */
  --bg:           #f7f1e3;
  --surface:      #fffdf7;
  --surface-2:    #fbf6ea;
  --surface-sunk: #f0ead8;
  --bg-hover:     #f1ebda;
  --bg-active:    #e9e1cd;
  --overlay:      rgba(26, 22, 14, 0.45);

  --ink:          var(--gray-900);
  --ink-soft:     var(--gray-600);
  --ink-faint:    var(--gray-400);
  --ink-inverse:  #ffffff;

  --line:         #ece4d3;
  --line-strong:  #ddd3bd;

  --brand:        var(--brand-600);
  --brand-strong: var(--brand-700);
  --brand-hover:  var(--brand-700);
  --brand-soft:   var(--brand-50);
  --brand-ink:    var(--brand-700);

  --money:        var(--green-600);
  --money-bright: var(--green-500);
  --money-soft:   var(--green-50);
  --money-ink:    var(--green-700);

  --pop:          var(--pop-600);
  --pop-bright:   var(--pop-500);
  --pop-soft:     var(--pop-50);
  --pop-ink:      var(--pop-700);

  --reward:       var(--amber-500);
  --reward-soft:  var(--amber-50);
  --reward-ink:   var(--amber-600);

  --success-bg: var(--green-50);  --success-fg: var(--green-700);
  --warning-bg: var(--amber-50);  --warning-fg: var(--amber-600);
  --danger-bg:  var(--pop-50);    --danger-fg:  var(--pop-700);
  --info-bg:    var(--brand-50);  --info-fg:    var(--brand-700);
  --neutral-bg: var(--gray-100);  --neutral-fg: var(--gray-600);

  /* ── Type ──────────────────────────────────────────────────────── */
  --font-sans:    'Nanum Gothic', -apple-system, BlinkMacSystemFont, 'Apple SD Gothic Neo', sans-serif;
  --font-display: 'Nanum Gothic', -apple-system, 'Apple SD Gothic Neo', sans-serif;
  --font-num:     'Inter', var(--font-sans);

  --fs-12: 12px;  --fs-13: 13px;  --fs-14: 14px;  --fs-15: 15px;
  --fs-16: 16px;  --fs-17: 17px;  --fs-18: 18px;  --fs-20: 20px;
  --fs-22: 22px;  --fs-24: 24px;  --fs-28: 28px;  --fs-32: 32px;
  --fs-40: 40px;  --fs-48: 48px;  --fs-64: 64px;

  --lh-tight: 1.2;  --lh-snug: 1.35;  --lh-normal: 1.6;  --lh-relaxed: 1.75;

  --fw-regular: 400; --fw-medium: 500; --fw-semibold: 600; --fw-bold: 700; --fw-black: 900;

  --tracking-tight: -0.02em;
  --tracking-snug:  -0.01em;
  --tracking-wide:  0.04em;
  --tracking-wider: 0.1em;

  /* ── Spacing ───────────────────────────────────────────────────── */
  --space-1: 4px;   --space-2: 8px;   --space-3: 12px;  --space-4: 16px;
  --space-5: 20px;  --space-6: 24px;  --space-7: 32px;  --space-8: 40px;
  --space-9: 48px;  --space-10: 64px; --space-11: 80px; --space-12: 96px;

  /* ── Radius ────────────────────────────────────────────────────── */
  --radius-xs: 6px;  --radius-sm: 10px;  --radius-md: 14px;
  --radius-lg: 18px; --radius-xl: 22px; --radius-2xl: 30px; --radius-full: 9999px;

  /* ── Shadow ────────────────────────────────────────────────────── */
  --shadow-xs: 0 1px 2px rgba(40, 34, 26, 0.05);
  --shadow-sm: 0 1px 3px rgba(40, 34, 26, 0.06), 0 1px 2px rgba(40, 34, 26, 0.03);
  --shadow-md: 0 6px 18px rgba(40, 34, 26, 0.07), 0 2px 6px rgba(40, 34, 26, 0.04);
  --shadow-lg: 0 20px 46px rgba(40, 34, 26, 0.11), 0 6px 14px rgba(40, 34, 26, 0.05);
  --shadow-brand: 0 14px 32px rgba(15, 154, 99, 0.22);
  --shadow-focus: 0 0 0 4px rgba(23, 173, 114, 0.18);

  /* ── Layout ────────────────────────────────────────────────────── */
  --sidebar-w: 252px;
  --topbar-h: 68px;
  --content-max: 1240px;

  /* ── Motion ────────────────────────────────────────────────────── */
  --ease: cubic-bezier(0.2, 0, 0, 1);
  --ease-emph: cubic-bezier(0.34, 1.4, 0.64, 1);
  --dur-fast: 130ms; --dur: 220ms; --dur-slow: 360ms;

  --z-sticky: 100; --z-drawer: 200; --z-modal: 300; --z-toast: 400;
}

/* =====================================================================
   Dark theme — soft deep green
   ===================================================================== */
[data-theme="dark"] {
  --bg:           #14151a;
  --surface:      #1d1f26;
  --surface-2:    #24272f;
  --surface-sunk: #131419;
  --bg-hover:     #2a2d36;
  --bg-active:    #333642;
  --overlay:      rgba(0, 0, 0, 0.62);

  --ink:          #f1f2f5;
  --ink-soft:     #a4a8b2;
  --ink-faint:    #6c707a;
  --ink-inverse:  #14151a;

  --line:         #2b2e37;
  --line-strong:  #3a3e49;

  --brand:        #2cc488;
  --brand-strong: #4dd49d;
  --brand-hover:  #4dd49d;
  --brand-soft:   rgba(44, 196, 136, 0.18);
  --brand-ink:    #6fdfaf;

  --money:        #2cc488;
  --money-bright: #3dd095;
  --money-soft:   rgba(44, 196, 136, 0.16);
  --money-ink:    #84e3b6;

  --pop:          #de8460;
  --pop-bright:   #e8956f;
  --pop-soft:     rgba(208, 100, 64, 0.18);
  --pop-ink:      #eaa98a;

  --reward:       #dcb35f;
  --reward-soft:  rgba(194, 149, 63, 0.16);
  --reward-ink:   #dcb35f;

  --success-bg: rgba(44,196,136,0.16);  --success-fg: #84e3b6;
  --warning-bg: rgba(194,149,63,0.16);  --warning-fg: #e3c684;
  --danger-bg:  rgba(208,100,64,0.18);  --danger-fg:  #eaa98a;
  --info-bg:    rgba(44,196,136,0.16);  --info-fg:    #6fdfaf;
  --neutral-bg: #2a2d36;                --neutral-fg: #a4a8b2;

  --shadow-xs: none;
  --shadow-sm: 0 1px 0 rgba(255,255,255,0.03) inset;
  --shadow-md: 0 8px 22px rgba(0,0,0,0.45);
  --shadow-lg: 0 20px 46px rgba(0,0,0,0.6);
  --shadow-brand: 0 14px 32px rgba(0, 0, 0, 0.5);
}


/* =====================================================================
   요청서 사양 변수명 (별칭) — 기존 내부 토큰에 매핑. 화이트라벨 시 위 값만 교체.
   ===================================================================== */
:root {
  --color-brand:       var(--brand);
  --color-brand-hover: var(--brand-hover);
  --color-ink:         var(--ink);
  --color-ink-soft:    var(--ink-soft);
  --color-bg:          var(--bg);
  --color-surface:     var(--surface);
  --color-line:        var(--line);
  --color-success:     var(--money);   /* 수익 강조 */
  --color-warning:     var(--reward);
  --color-danger:      var(--pop);
  --font-base:         var(--font-sans);
  --shadow-card:       var(--shadow-sm);
}
