/* ==========================================================================
   오라클마크 (OracleMark) — 문화권별 안료(Pigment) 및 판본(Edition) 테마 토큰
   컨셉: 비장각 판각소 (고판화 목판 인쇄물 + 박물관 비술 아카이브 + 필사본)
   ========================================================================== */

/* ── 1. 기본 5대 문화권 판각 테마 (묵각본 · Dark Woodblock Matrix) ── */
body[data-culture='korea'] {
  --bg1: #110d09;
  --bg2: #18120c;
  --surface: #1d160f;
  --surface-raised: #251c13;
  --surface-inset: #130e09;
  --text: #f2e5c9;
  --muted: #b5a282;
  --accent: #d49b38;       /* 유기 황동 · 괴황 */
  --accent2: #c4281c;      /* 경면주사(鏡面朱砂) 인장 적색 */
  --seal-ink: #b82216;
  --seal-text: #fbf3e4;
  --border-strong: rgba(212, 155, 56, 0.42);
  --border-fine: rgba(212, 155, 56, 0.18);
  --line: rgba(212, 155, 56, 0.24);
  --ink-shadow: rgba(0, 0, 0, 0.78);
  --header-bg: #140f0a;
  --header-border: rgba(212, 155, 56, 0.35);
  --wheel-plate: #15100b;
  --wheel-core-inner: #261a10;
  --wheel-core-outer: #130d08;
  --pattern: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='64' height='64'%3E%3Cpath d='M0 32h64M32 0v64M16 16h32v32H16z' fill='none' stroke='%23d49b38' stroke-opacity='.045' stroke-width='1'/%3E%3C/svg%3E");
  --pattern-size: 64px;
}

body[data-culture='china'] {
  --bg1: #130807;
  --bg2: #1c0c0a;
  --surface: #22100d;
  --surface-raised: #2b1511;
  --surface-inset: #140806;
  --text: #f6e7c8;
  --muted: #bfa382;
  --accent: #e5b344;       /* 황실 니금(泥金) */
  --accent2: #d62d20;      /* 도교 진사(辰砂) */
  --seal-ink: #c92418;
  --seal-text: #fff5e4;
  --border-strong: rgba(229, 179, 68, 0.45);
  --border-fine: rgba(229, 179, 68, 0.20);
  --line: rgba(229, 179, 68, 0.25);
  --ink-shadow: rgba(0, 0, 0, 0.82);
  --header-bg: #160908;
  --header-border: rgba(229, 179, 68, 0.36);
  --wheel-plate: #180a08;
  --wheel-core-inner: #2b110d;
  --wheel-core-outer: #150806;
  --pattern: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='48' height='48'%3E%3Cpath d='M6 42V6H42V30H18V18H30' fill='none' stroke='%23e5b344' stroke-opacity='.055' stroke-width='1.5'/%3E%3C/svg%3E");
  --pattern-size: 48px;
}

body[data-culture='japan'] {
  --bg1: #0c1017;
  --bg2: #121822;
  --surface: #171f2c;
  --surface-raised: #1e2838;
  --surface-inset: #0d121a;
  --text: #efe8d8;
  --muted: #9da8b8;
  --accent: #d8b467;       /* 금박(金箔) */
  --accent2: #cf3a2b;      /* 고슈인(御朱印) 주홍 */
  --seal-ink: #c43224;
  --seal-text: #f9f3e8;
  --border-strong: rgba(216, 180, 103, 0.40);
  --border-fine: rgba(216, 180, 103, 0.18);
  --line: rgba(216, 180, 103, 0.22);
  --ink-shadow: rgba(0, 0, 0, 0.80);
  --header-bg: #0e131b;
  --header-border: rgba(216, 180, 103, 0.32);
  --wheel-plate: #101620;
  --wheel-core-inner: #1d2636;
  --wheel-core-outer: #0d121a;
  --pattern: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='60' height='30'%3E%3Cg fill='none' stroke='%23d8b467' stroke-opacity='.06'%3E%3Ccircle cx='30' cy='30' r='28'/%3E%3Ccircle cx='30' cy='30' r='20'/%3E%3Ccircle cx='30' cy='30' r='12'/%3E%3Ccircle cx='0' cy='0' r='28'/%3E%3Ccircle cx='60' cy='0' r='28'/%3E%3C/g%3E%3C/svg%3E");
  --pattern-size: 60px 30px;
}

body[data-culture='india'] {
  --bg1: #140c07;
  --bg2: #1d110a;
  --surface: #24160d;
  --surface-raised: #2e1c11;
  --surface-inset: #150c07;
  --text: #f5e6cf;
  --muted: #bda082;
  --accent: #e6952e;       /* 동판·강황 금색 */
  --accent2: #c82542;      /* 신두르(Sindoor) 진홍 */
  --seal-ink: #b81d38;
  --seal-text: #fff3e6;
  --border-strong: rgba(230, 149, 46, 0.44);
  --border-fine: rgba(230, 149, 46, 0.19);
  --line: rgba(230, 149, 46, 0.24);
  --ink-shadow: rgba(0, 0, 0, 0.80);
  --header-bg: #170e08;
  --header-border: rgba(230, 149, 46, 0.34);
  --wheel-plate: #190f09;
  --wheel-core-inner: #2d1a0f;
  --wheel-core-outer: #150c07;
  --pattern: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='72' height='72'%3E%3Cg fill='none' stroke='%23e6952e' stroke-opacity='.065'%3E%3Ccircle cx='36' cy='36' r='6'/%3E%3Cpolygon points='36,8 62,54 10,54'/%3E%3Cpolygon points='36,64 62,18 10,18'/%3E%3C/g%3E%3C/svg%3E");
  --pattern-size: 72px;
}

body[data-culture='europe'] {
  --bg1: #100f0c;
  --bg2: #171510;
  --surface: #1d1a14;
  --surface-raised: #26221a;
  --surface-inset: #110f0b;
  --text: #ede3ce;
  --muted: #a99d86;
  --accent: #c9a44c;       /* 수도원 필사본 금박 */
  --accent2: #9e2a2b;      /* 루브리케이션(Rubrication) 적갈색 */
  --seal-ink: #942222;
  --seal-text: #f7efe0;
  --border-strong: rgba(201, 164, 76, 0.42);
  --border-fine: rgba(201, 164, 76, 0.18);
  --line: rgba(201, 164, 76, 0.24);
  --ink-shadow: rgba(0, 0, 0, 0.82);
  --header-bg: #13110d;
  --header-border: rgba(201, 164, 76, 0.34);
  --wheel-plate: #14120e;
  --wheel-core-inner: #242017;
  --wheel-core-outer: #110f0b;
  --pattern: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='64' height='64'%3E%3Cg fill='none' stroke='%23c9a44c' stroke-opacity='.06'%3E%3Cpath d='M32 6L37 27L58 32L37 37L32 58L27 37L6 32L27 27Z'/%3E%3Ccircle cx='32' cy='32' r='22'/%3E%3C/g%3E%3C/svg%3E");
  --pattern-size: 64px;
}

/* ── 2. 판본(Edition) 전환 테마: 황지본 (고서 닥종이 · 목판 송연묵 인출본) ── */
body[data-theme='antiquarian'] {
  --bg1: #e6d7b8;
  --bg2: #efe3c8;
  --surface: #f6edd8;
  --surface-raised: #fbf5e6;
  --surface-inset: #e4d4b3;
  --text: #1c130b;
  --muted: #5e4933;
  --accent: #8c2519;       /* 주사 인장 포인트 */
  --accent2: #24180e;      /* 송연묵(松煙墨) 판각 먹색 */
  --seal-ink: #b52315;
  --seal-text: #fdf7eb;
  --border-strong: #2c1e12;
  --border-fine: rgba(44, 30, 18, 0.35);
  --line: rgba(44, 30, 18, 0.25);
  --ink-shadow: rgba(36, 22, 10, 0.18);
  --header-bg: #ebe0c5;
  --header-border: #2c1e12;
  --wheel-plate: #efe4ca;
  --wheel-core-inner: #f9f2e1;
  --wheel-core-outer: #e2d1ae;
  --pattern: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='64' height='64'%3E%3Cpath d='M0 32h64M32 0v64' fill='none' stroke='%232c1e12' stroke-opacity='.05' stroke-width='1'/%3E%3C/svg%3E");
}

/* ── 3. 판본(Edition) 전환 테마: 비장고 (박물관 아카이브 서류 · 분류 스탬프) ── */
body[data-theme='archive'],
body[data-theme='whitecube'] {
  --bg1: #dcd8ce;
  --bg2: #e5e1d8;
  --surface: #f2efe8;
  --surface-raised: #f8f6f0;
  --surface-inset: #d5d0c5;
  --text: #141413;
  --muted: #57554f;
  --accent: #c41e24;       /* 분류 스탬프 단색 적색 */
  --accent2: #141413;      /* 아카이브 먹색 */
  --seal-ink: #c41e24;
  --seal-text: #ffffff;
  --border-strong: #141413;
  --border-fine: rgba(20, 20, 19, 0.32);
  --line: rgba(20, 20, 19, 0.22);
  --ink-shadow: rgba(20, 20, 19, 0.14);
  --header-bg: #e8e4db;
  --header-border: #141413;
  --wheel-plate: #eae6dd;
  --wheel-core-inner: #f7f5ef;
  --wheel-core-outer: #dad5c9;
  --pattern: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='40' height='40'%3E%3Cpath d='M0 39.5h40M39.5 0v40' fill='none' stroke='%23141413' stroke-opacity='.05' stroke-width='0.75'/%3E%3C/svg%3E");
  --pattern-size: 40px;
}

/* ── 4. 관리자 패널 호환 서브 테마 (admin/index.html om_admin_theme 연동) ── */
body[data-theme='ink'] {
  --bg1: #070605; --bg2: #0d0b09; --surface: #14100c; --surface-raised: #1c1610; --surface-inset: #090705;
  --text: #f2e6cf; --muted: #a89678; --accent: #d4a030; --accent2: #b82820;
  --border-strong: rgba(212, 160, 48, 0.45); --border-fine: rgba(212, 160, 48, 0.20); --line: rgba(212, 160, 48, 0.24);
}
body[data-theme='ember'] {
  --bg1: #120606; --bg2: #1b0909; --surface: #240d0d; --surface-raised: #2e1212; --surface-inset: #100505;
  --text: #f7e6d4; --muted: #bf9b82; --accent: #e8a020; --accent2: #c82010;
  --border-strong: rgba(232, 160, 32, 0.45); --border-fine: rgba(232, 160, 32, 0.20); --line: rgba(232, 160, 32, 0.24);
}
body[data-theme='celadon'] {
  --bg1: #071010; --bg2: #0c1a1a; --surface: #112323; --surface-raised: #172e2e; --surface-inset: #060d0d;
  --text: #e4f0ec; --muted: #8fb0a8; --accent: #68b8a8; --accent2: #d4a030;
  --border-strong: rgba(104, 184, 168, 0.42); --border-fine: rgba(104, 184, 168, 0.18); --line: rgba(104, 184, 168, 0.22);
}
body[data-theme='violet'],
body[data-theme='cobalt'] {
  --bg1: #0b0e17; --bg2: #111624; --surface: #171e30; --surface-raised: #1f2840; --surface-inset: #090c14;
  --text: #ece6d8; --muted: #9aa2b8; --accent: #d4a030; --accent2: #c0321c;
  --border-strong: rgba(212, 160, 48, 0.42); --border-fine: rgba(212, 160, 48, 0.18); --line: rgba(212, 160, 48, 0.22);
}
body[data-theme='zen'],
body[data-theme='zine'],
body[data-theme='stationery'],
body[data-theme='snow'],
body[data-theme='gold-light'],
body[data-theme='cherry'],
body[data-theme='bamboo'],
body[data-theme='lotus'] {
  --bg1: #ebe3d2; --bg2: #f2ebdc; --surface: #f8f3e8; --surface-raised: #fdfbf5; --surface-inset: #dfd5c0;
  --text: #1e1812; --muted: #635444; --accent: #9e2a1e; --accent2: #2b2118;
  --seal-ink: #b52315; --seal-text: #fdf7eb;
  --border-strong: #2b2118; --border-fine: rgba(43, 33, 24, 0.30); --line: rgba(43, 33, 24, 0.22);
  --ink-shadow: rgba(36, 22, 10, 0.15);
  --header-bg: #efe7d6; --header-border: #2b2118;
  --wheel-plate: #efe7d6; --wheel-core-inner: #faf5ea; --wheel-core-outer: #dfd4be;
}
