@import url('https://fonts.googleapis.com/css2?family=Noto+Sans+Thai:wght@400;500;600;700&family=Noto+Serif+Thai:wght@500;600;700&display=swap');

/* Shared layout for the Thai-culture sites; each site sets its palette in :root (theme.css part). */
* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { margin: 0; line-height: 1.75; font-family: "Noto Sans Thai", system-ui, -apple-system, "Segoe UI", sans-serif; color: var(--ink); background: var(--paper); }
a { color: inherit; }
img, svg { max-width: 100%; }
.wrap { max-width: 1120px; margin: 0 auto; padding: 0 24px; }
.skip { position: absolute; left: -9999px; }
.skip:focus { left: 12px; top: 12px; z-index: 10; background: #fff; padding: 8px 12px; border-radius: 6px; }
:focus-visible { outline: 3px solid var(--accent); outline-offset: 3px; }

.site-header { position: absolute; inset: 0 0 auto; z-index: 3; }
.nav { display: flex; align-items: center; justify-content: space-between; gap: 16px; height: 76px; }
.logo { display: flex; align-items: center; gap: 10px; color: var(--hero-strong); text-decoration: none; font-family: "Noto Serif Thai", serif; font-weight: 700; font-size: 20px; }
.logo svg { width: 30px; height: 30px; }
.nav-links { display: flex; gap: 24px; font-size: 14px; }
.nav-links a { color: var(--hero-muted); text-decoration: none; }
.nav-links a:hover { color: var(--hero-strong); }
.lang-switch { display: inline-flex; align-items: center; gap: 7px; white-space: nowrap; font-size: 12px; font-weight: 700; color: var(--hero-text); text-decoration: none;
  border: 1px solid var(--hero-line); border-radius: 999px; padding: 8px 12px; background: var(--hero-chip); }
.lang-switch:hover { border-color: var(--accent); }
.lang-switch .flag { width: 21px; height: auto; aspect-ratio: 3 / 2; object-fit: cover; border-radius: 2px; box-shadow: 0 0 0 1px #ffffff40; }

.hero { position: relative; min-height: 100vh; min-height: 100svh; display: flex; align-items: center; overflow: hidden; color: var(--hero-text); background: var(--hero-bg); }
.hero > .wrap { width: 100%; position: relative; z-index: 2; }
.hero-content { padding: 120px 0 90px; max-width: 600px; }
.hero-panel { background: var(--hero-panel, transparent); border-radius: 22px; padding: var(--hero-pad, 0); backdrop-filter: var(--hero-blur, none); }
.kicker { color: var(--accent); font-weight: 600; font-size: 14px; margin: 0 0 12px; }
.hero h1 { font-family: "Noto Serif Thai", serif; font-weight: 700; font-size: clamp(44px, 7vw, 82px); line-height: 1.15; margin: 0 0 18px; color: var(--hero-strong); }
.hero h1 span { display: block; font-size: .42em; font-weight: 500; color: var(--hero-sub); margin-top: 8px; }
.hero p.lead { font-size: clamp(16px, 1.6vw, 19px); color: var(--hero-muted); margin: 0 0 28px; }
.btn { display: inline-flex; align-items: center; gap: 8px; padding: 12px 20px; border-radius: 999px; font-weight: 600; text-decoration: none; }
.btn-main { background: var(--accent); color: var(--accent-ink); }
.btn-ghost { border: 1px solid var(--hero-line); color: var(--hero-text); margin-left: 8px; }
.art { position: absolute; z-index: 1; pointer-events: none; }

section.block { padding: 88px 0; }
.eyebrow { color: var(--eyebrow); font-weight: 700; font-size: 13px; margin: 0 0 6px; }
h2 { font-family: "Noto Serif Thai", serif; font-size: clamp(30px, 3.6vw, 44px); line-height: 1.25; margin: 0 0 16px; }
.intro { color: var(--ink-muted); max-width: 720px; font-size: 17px; margin: 0 0 34px; }
.grid { display: grid; gap: 18px; }
.g2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.g3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.g4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.card { background: var(--card); border: 1px solid var(--card-line); border-radius: 16px; padding: 24px; }
.card h3 { font-size: 19px; margin: 6px 0 8px; }
.card p { margin: 0; color: var(--ink-muted); font-size: 15px; }
.card .icon { font-size: 30px; line-height: 1.2; }
.card .tag { font-size: 13px; color: var(--eyebrow); font-weight: 600; }
.note { font-size: 14px; color: var(--ink-muted); border-left: 3px solid var(--accent); padding: 8px 14px; background: var(--note); border-radius: 0 10px 10px 0; margin-top: 22px; }

.alt { background: var(--alt-bg); color: var(--alt-text); }
.alt h2 { color: var(--alt-strong); }
.alt .intro, .alt .card p { color: var(--alt-muted); }
.alt .eyebrow { color: var(--accent); }
.alt .card { background: rgb(255 255 255 / .06); border-color: rgb(255 255 255 / .12); }
.alt .card .tag { color: var(--accent); }
.alt .note { background: rgb(255 255 255 / .06); color: var(--alt-muted); }

.steps { counter-reset: s; list-style: none; padding: 0; margin: 0; display: grid; gap: 14px; grid-template-columns: repeat(2, minmax(0, 1fr)); }
.steps li { counter-increment: s; background: var(--card); border: 1px solid var(--card-line); border-radius: 14px; padding: 18px 18px 18px 64px; position: relative; color: var(--ink-muted); }
.steps li::before { content: counter(s); position: absolute; left: 18px; top: 18px; width: 32px; height: 32px; border-radius: 50%; display: grid; place-items: center;
  background: var(--step); color: #fff; font-weight: 700; }
.steps b { color: var(--ink); display: block; }
.list-card ul { margin: 8px 0 0; padding-left: 20px; color: var(--ink-muted); }

.footer { background: var(--foot-bg); color: var(--foot-muted); padding: 40px 0; font-size: 14px; }
.footer-inner { display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap; }
.footer b { color: var(--foot-strong); font-family: "Noto Serif Thai", serif; }

@media (prefers-reduced-motion: reduce) { .art, .art * { animation: none !important; } }
@media (max-width: 900px) { .g3, .g4 { grid-template-columns: repeat(2, minmax(0, 1fr)); } .nav-links { display: none; } }
@media (max-width: 620px) {
  .g2, .g3, .g4, .steps { grid-template-columns: 1fr; }
  section.block { padding: 64px 0; }
  .btn-ghost { margin: 10px 0 0; }
}

/* Thai script must never be letter-spaced (skill web-lang-switch) */
html[lang="th"] h1, html[lang="th"] h1 span, html[lang="th"] .eyebrow, html[lang="th"] .kicker { letter-spacing: 0; }

/* ---- theme: phakhaoma.org ---- */

:root { --paper: #f7f3ea; --ink: #23201c; --ink-muted: #5f5850; --accent: #f6c445; --accent-ink: #2a1a00; --eyebrow: #a3262e;
  --card: #fff; --card-line: #eadfcb; --note: #fff6df; --step: #1c3a8c;
  --hero-bg: repeating-linear-gradient(90deg, rgb(255 255 255 / 0) 0 26px, rgb(28 58 140 / .55) 26px 52px, rgb(255 255 255 / 0) 52px 78px, rgb(246 196 69 / .55) 78px 86px, rgb(255 255 255 / 0) 86px 112px, rgb(32 110 72 / .5) 112px 130px, rgb(255 255 255 / 0) 130px 156px),
  repeating-linear-gradient(0deg, rgb(255 255 255 / 0) 0 26px, rgb(28 58 140 / .55) 26px 52px, rgb(255 255 255 / 0) 52px 78px, rgb(246 196 69 / .55) 78px 86px, rgb(255 255 255 / 0) 86px 112px, rgb(32 110 72 / .5) 112px 130px, rgb(255 255 255 / 0) 130px 156px),
  linear-gradient(#b3262e, #b3262e);
  --hero-text: #fff8ee; --hero-strong: #fffaf2; --hero-sub: #ffe4a3; --hero-muted: #f1e4d4; --hero-line: rgb(255 255 255 / .35); --hero-chip: rgb(20 12 10 / .45);
  --hero-panel: rgb(26 14 12 / .74); --hero-pad: 36px; --hero-blur: blur(3px);
  --alt-bg: #1c2a57; --alt-text: #eef1fb; --alt-strong: #fff; --alt-muted: #c3cbe3;
  --foot-bg: #14152b; --foot-muted: #b9bdd6; --foot-strong: #f6c445; }
.hero { background-size: 156px 156px, 156px 156px, auto; }
.hero::after { content: ""; position: absolute; inset: 0; background: repeating-linear-gradient(45deg, rgb(0 0 0 / .05) 0 2px, transparent 2px 4px); pointer-events: none; }
.logo { text-shadow: 0 1px 6px rgb(0 0 0 / .5); }
.alt { background-image: repeating-linear-gradient(90deg, rgb(255 255 255 / .025) 0 40px, transparent 40px 80px), repeating-linear-gradient(0deg, rgb(255 255 255 / .025) 0 40px, transparent 40px 80px); }
@media (max-width: 620px) { .hero-panel { --hero-pad: 24px; } }
