/*
 * DOITHAI Coffee — หน้าแรก (ตัวอย่างออกแบบ)
 * แนวทาง: editorial แบบ anthropic.com — พื้นกระดาษอุ่น, serif ใหญ่, เนื้อหานำ,
 * การ์ดดำตัดจังหวะหนึ่งช่วง, ไม่มีป้ายลดราคาแดง ไม่มีนับถอยหลัง
 * ตัวเลขทุกตัวบนหน้านี้มาจากฐานข้อมูลจริง
 */
:root {
  --paper: #F0EEE6;
  --card: #FAF9F5;
  --ink: #191919;
  --ink-soft: #5c5850;
  --ink-faint: #8f897b;
  --line: #DDD8CC;
  --brand: #C15F3C;
  --brand-deep: #9d4b2f;
  --roast: #191919;
  --accent-soft: #E6E1D3;
  --radius: 14px;
  --page: 1180px;
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: "Anuphan", "Noto Sans Thai", system-ui, sans-serif;
  font-size: clamp(15px, 0.55vw + 13px, 18px);
  line-height: 1.75;
  -webkit-font-smoothing: antialiased;
}
h1, h2, h3, .serif { font-family: "Anuphan", "Noto Sans Thai", sans-serif; font-weight: 650; line-height: 1.3; letter-spacing: -0.02em; }
a { color: inherit; }
.wrap { max-width: var(--page); margin: 0 auto; padding: 0 20px; }
.eyebrow {
  font-size: 0.78em; letter-spacing: .14em; text-transform: uppercase;
  color: var(--ink-faint); font-weight: 600;
}

/* ---------- แถบประกาศ + หัวเว็บ ---------- */
.topbar {
  background: var(--roast); color: #e8ded2;
  font-size: 0.82em; text-align: center; padding: 7px 16px; letter-spacing: .02em;
}
.topbar b { color: #fff; font-weight: 600; }

header {
  position: sticky; top: 0; z-index: 50;
  background: rgba(250,247,242,.88); backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line);
}
.nav { display: flex; align-items: center; gap: 28px; padding: 14px 20px; max-width: var(--page); margin: 0 auto; }
.logo { display: flex; align-items: center; gap: 10px; text-decoration: none; margin-right: auto; }
.logo .bean {
  width: 26px; height: 26px; border-radius: 50% 50% 50% 50% / 60% 60% 40% 40%;
  background: var(--brand); position: relative; transform: rotate(-18deg); flex: none;
}
.logo .bean::after {
  content: ""; position: absolute; inset: 4px 11px; border-radius: 2px;
  background: var(--paper);
}
.logo-text { font-weight: 700; letter-spacing: .16em; font-size: 0.95em; }
.logo-sub { display: block; font-size: 0.62em; letter-spacing: .1em; color: var(--ink-faint); font-weight: 500; }
.nav-links { display: none; gap: 26px; }
.nav-links a { text-decoration: none; font-size: 0.92em; color: var(--ink-soft); font-weight: 500; }
.nav-links a:hover { color: var(--ink); }
.nav-right { display: flex; align-items: center; gap: 14px; }
.lang { display: none; gap: 8px; font-size: 0.82em; color: var(--ink-faint); }
.lang b { color: var(--ink); font-weight: 600; }
.lang a { text-decoration: none; }
.cart {
  display: inline-flex; align-items: center; gap: 7px; text-decoration: none;
  border: 1px solid var(--line); background: var(--card);
  border-radius: 999px; padding: 7px 14px; font-size: 0.85em; font-weight: 500;
}
@media (min-width: 900px) { .nav-links, .lang { display: flex; } }

/* ---------- ปุ่ม ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  padding: 13px 24px; border-radius: 999px; text-decoration: none;
  font-weight: 600; font-size: 0.95em; border: 1px solid transparent;
  transition: transform .15s ease, opacity .15s ease;
}
.btn:active { transform: translateY(1px); }
.btn-primary { background: var(--roast); color: #fff; }
.btn-primary:hover { opacity: .88; }
.btn-ghost { border-color: var(--ink); color: var(--ink); }
.btn-ghost:hover { background: var(--accent-soft); }

/* ---------- HERO ---------- */
.hero { padding: clamp(48px, 7vw, 104px) 0 clamp(36px, 5vw, 64px); }
.hero-grid { display: grid; gap: clamp(28px, 4vw, 56px); grid-template-columns: 1fr; align-items: end; }
.hero h1 {
  font-size: clamp(2.1rem, 5.4vw, 4rem);
  letter-spacing: -0.01em; margin: 0;
}
.hero h1 u {
  text-decoration: none;
  border-bottom: 3px solid var(--brand);
  padding-bottom: 2px;
}
.hero p.lead { font-size: 1.06em; color: var(--ink-soft); margin: 0 0 22px; max-width: 46ch; }
.hero-cta { display: flex; flex-wrap: wrap; gap: 12px; }
@media (min-width: 940px) { .hero-grid { grid-template-columns: 1.25fr 1fr; } }

.stats {
  display: grid; grid-template-columns: repeat(3, 1fr);
  gap: 4px; margin-top: clamp(36px, 5vw, 60px);
  border-top: 1px solid var(--line); padding-top: 22px;
}
.stats div { text-align: left; }
.stats .n { font-family: "Anuphan", "Noto Sans Thai", sans-serif; font-size: clamp(1.3rem, 2.6vw, 2rem); font-weight: 600; display: block; line-height: 1.2; }
.stats .l { font-size: 0.8em; color: var(--ink-faint); }

/* ---------- ส่วนทั่วไป ---------- */
section { padding: clamp(44px, 6vw, 88px) 0; }
.section-head { max-width: 62ch; margin-bottom: clamp(24px, 3vw, 40px); }
.section-head h2 { font-size: clamp(1.55rem, 3.2vw, 2.5rem); margin: 8px 0 10px; }
.section-head p { color: var(--ink-soft); margin: 0; }

/* ---------- การ์ดเกรด ---------- */
.grades { display: grid; gap: 16px; grid-template-columns: 1fr; }
@media (min-width: 640px) { .grades { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1000px) { .grades { grid-template-columns: repeat(4, 1fr); } }
.grade {
  background: var(--card); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 22px; display: flex; flex-direction: column; position: relative;
  transition: border-color .18s ease, transform .18s ease;
}
.grade:hover { border-color: var(--brand); transform: translateY(-2px); }
.grade.featured { border-color: var(--brand); box-shadow: 0 1px 0 var(--brand) inset, 0 0 0 1px var(--brand); }
.grade .tag {
  position: absolute; top: -11px; left: 20px; background: var(--brand); color: #fff;
  font-size: 0.7em; font-weight: 600; padding: 3px 12px; border-radius: 999px; letter-spacing: .04em;
}
.grade h3 { margin: 4px 0 2px; font-size: 1.18rem; }
.grade .who { color: var(--ink-soft); font-size: 0.9em; margin: 8px 0 18px; flex: 1; }
.grade .price { font-family: "Anuphan", "Noto Sans Thai", sans-serif; font-size: 1.6rem; font-weight: 600; }
.grade .price span { font-family: "Noto Sans Thai", sans-serif; font-size: 0.5em; font-weight: 500; color: var(--ink-faint); }
.grade .opts { font-size: 0.8em; color: var(--ink-faint); border-top: 1px solid var(--line); margin-top: 14px; padding-top: 12px; }
.swatch { display: flex; gap: 3px; margin-bottom: 12px; }
.swatch i { width: 15px; height: 15px; border-radius: 50%; display: block; }

/* ---------- สเกลระดับคั่ว ---------- */
.roast-scale { margin-top: clamp(30px, 4vw, 52px); background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: clamp(20px, 3vw, 32px); }
.roast-bar { display: grid; grid-template-columns: repeat(5, 1fr); gap: 3px; margin: 18px 0 12px; }
.roast-bar i { height: 46px; border-radius: 4px; display: block; }
.roast-labels { display: grid; grid-template-columns: repeat(5, 1fr); gap: 3px; font-size: 0.72em; color: var(--ink-soft); text-align: center; line-height: 1.4; }
.roast-labels b { display: block; color: var(--brand); font-size: 0.9em; margin-top: 3px; }

/* ---------- ขายดี ---------- */
.sellers { display: grid; gap: 16px; grid-template-columns: 1fr; }
@media (min-width: 700px) { .sellers { grid-template-columns: repeat(3, 1fr); } }
.seller {
  background: var(--card); border: 1px solid var(--line); border-radius: var(--radius);
  overflow: hidden; display: flex; flex-direction: column;
}
.seller .visual {
  height: 150px; display: flex; align-items: center; justify-content: center;
  position: relative; overflow: hidden;
}
.seller .visual .bag {
  width: 78px; height: 100px; border-radius: 5px 5px 3px 3px;
  position: relative; box-shadow: 0 8px 24px rgba(36,28,23,.22);
}
.seller .visual .bag::before {
  content: ""; position: absolute; top: 0; left: 0; right: 0; height: 13px;
  background: rgba(255,255,255,.22); border-radius: 5px 5px 0 0;
}
.seller .visual .bag span {
  position: absolute; bottom: 16px; left: 0; right: 0; text-align: center;
  color: rgba(255,255,255,.92); font-size: 9px; letter-spacing: .18em; font-weight: 600;
}
.seller .body { padding: 18px 20px 20px; display: flex; flex-direction: column; flex: 1; }
.seller h3 { margin: 0 0 4px; font-size: 1.05rem; }
.seller .sub { font-size: 0.85em; color: var(--ink-soft); }
.seller .proof { font-size: 0.8em; color: var(--brand); font-weight: 600; margin-top: 10px; }
.seller .foot { display: flex; align-items: center; justify-content: space-between; margin-top: 16px; padding-top: 14px; border-top: 1px solid var(--line); }
.seller .p { font-family: "Anuphan", "Noto Sans Thai", sans-serif; font-size: 1.3rem; font-weight: 600; }
.seller .add { font-size: 0.85em; font-weight: 600; color: var(--brand); text-decoration: none; border: 1px solid var(--line); padding: 7px 14px; border-radius: 999px; }
.seller .add:hover { background: var(--accent-soft); border-color: var(--brand); }

/* ---------- แถบดำ (เรื่องของเรา) ---------- */
.dark {
  background: var(--roast); color: #efe6da; border-radius: clamp(16px, 2vw, 24px);
  padding: clamp(34px, 5vw, 72px) clamp(24px, 4vw, 60px); margin: 0 auto;
}
.dark h2 { color: #fff; font-size: clamp(1.6rem, 3.4vw, 2.6rem); margin: 0 0 14px; max-width: 20ch; }
.dark p.intro { color: #c6b8a8; max-width: 54ch; margin: 0 0 clamp(28px, 4vw, 46px); }
.pillars { display: grid; gap: 26px; grid-template-columns: 1fr; }
@media (min-width: 780px) { .pillars { grid-template-columns: repeat(3, 1fr); gap: 34px; } }
.pillar h3 { color: #fff; font-size: 1.1rem; margin: 0 0 6px; }
.pillar p { color: #b6a898; font-size: 0.92em; margin: 0; }
.pillar .num { font-family: "Anuphan", "Noto Sans Thai", sans-serif; color: var(--brand); font-size: 0.85em; font-weight: 600; letter-spacing: .1em; }

/* ---------- บทความ ---------- */
.posts { display: grid; gap: 2px; border-top: 1px solid var(--line); }
.post {
  display: grid; gap: 4px; padding: 20px 4px; border-bottom: 1px solid var(--line);
  text-decoration: none; grid-template-columns: 1fr; align-items: baseline;
  transition: padding-left .18s ease;
}
.post:hover { padding-left: 12px; }
.post h3 { font-size: 1.08rem; margin: 0; font-weight: 600; }
.post .meta { font-size: 0.8em; color: var(--ink-faint); }
@media (min-width: 760px) { .post { grid-template-columns: 130px 1fr auto; gap: 24px; } }
.post .arrow { color: var(--brand); font-size: 0.85em; }

/* ---------- footer ---------- */
footer { border-top: 1px solid var(--line); padding: clamp(36px, 5vw, 60px) 0 40px; margin-top: clamp(30px, 5vw, 60px); }
.foot-grid { display: grid; gap: 30px; grid-template-columns: 1fr; }
@media (min-width: 760px) { .foot-grid { grid-template-columns: 1.6fr 1fr 1fr; } }
footer h4 { font-size: 0.8em; letter-spacing: .1em; text-transform: uppercase; color: var(--ink-faint); margin: 0 0 12px; font-weight: 600; }
footer ul { list-style: none; margin: 0; padding: 0; }
footer li { margin-bottom: 8px; }
footer a { text-decoration: none; color: var(--ink-soft); font-size: 0.92em; }
footer a:hover { color: var(--ink); }
.legal { margin-top: 34px; padding-top: 20px; border-top: 1px solid var(--line); font-size: 0.8em; color: var(--ink-faint); display: flex; flex-wrap: wrap; gap: 6px 20px; justify-content: space-between; }

/* แถบล่างสำหรับมือถือ — ปุ่มสั่งซื้ออยู่ใต้หัวแม่มือเสมอ */
.mobile-bar {
  position: fixed; inset-inline: 0; bottom: 0; z-index: 60;
  background: rgba(255,253,250,.96); backdrop-filter: blur(10px);
  border-top: 1px solid var(--line);
  padding: 10px 16px calc(10px + env(safe-area-inset-bottom));
  display: flex; align-items: center; gap: 12px;
}
.mobile-bar .txt { font-size: 0.8em; color: var(--ink-soft); line-height: 1.3; }
.mobile-bar .btn { flex: none; padding: 11px 20px; }
@media (min-width: 900px) { .mobile-bar { display: none; } }
body { padding-bottom: 76px; }
@media (min-width: 900px) { body { padding-bottom: 0; } }

/* ==================== ส่วนเพิ่มสำหรับหน้าใน (ร้านค้า/สินค้า/บทความ) ==================== */

/* หัวหน้าใน + breadcrumb */
.page-hero { padding: clamp(30px, 4vw, 56px) 0 clamp(6px, 1vw, 10px); }
.page-hero h1 { font-size: clamp(1.7rem, 3.6vw, 2.7rem); margin: 6px 0 8px; }
.page-hero p.sub { color: var(--ink-soft); margin: 0; max-width: 60ch; }
.crumbs { font-size: 0.8em; color: var(--ink-faint); display: flex; flex-wrap: wrap; gap: 6px; }
.crumbs a { text-decoration: none; color: var(--ink-faint); }
.crumbs a:hover { color: var(--ink); }

/* แถวตัวกรองหน้าร้านค้า */
.filters { display: flex; flex-wrap: wrap; gap: 8px; margin: 18px 0 26px; }
.chip {
  border: 1px solid var(--line); background: var(--card); color: var(--ink-soft);
  border-radius: 999px; padding: 8px 16px; font-size: 0.85em; font-weight: 500;
  cursor: pointer; transition: all .15s ease; text-decoration: none;
}
.chip:hover { border-color: var(--brand); color: var(--ink); }
.chip.on { background: var(--roast); border-color: var(--roast); color: #fff; }

/* ตารางสินค้าหน้าร้านค้า */
.plist { display: grid; gap: 16px; grid-template-columns: 1fr; }
@media (min-width: 620px) { .plist { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 980px) { .plist { grid-template-columns: repeat(3, 1fr); } }
.family-head { display: flex; align-items: baseline; gap: 14px; margin: clamp(26px, 4vw, 44px) 0 14px; }
.family-head h2 { font-size: clamp(1.25rem, 2.4vw, 1.7rem); margin: 0; }
.family-head .cnt { font-size: 0.82em; color: var(--ink-faint); }

/* หน้าสินค้า */
.pdp { display: grid; gap: clamp(24px, 4vw, 56px); grid-template-columns: 1fr; align-items: start; padding-top: 18px; }
@media (min-width: 880px) { .pdp { grid-template-columns: 1.05fr 1fr; } }
.pdp-visual {
  border-radius: var(--radius); min-height: 320px; display: flex; align-items: center;
  justify-content: center; position: sticky; top: 90px;
}
.pdp-visual .bag { width: 150px; height: 195px; border-radius: 10px 10px 6px 6px; position: relative; box-shadow: 0 18px 48px rgba(36,28,23,.28); }
.pdp-visual .bag::before { content: ""; position: absolute; top: 0; left: 0; right: 0; height: 24px; background: rgba(255,255,255,.22); border-radius: 10px 10px 0 0; }
.pdp-visual .bag span { position: absolute; bottom: 34px; left: 0; right: 0; text-align: center; color: rgba(255,255,255,.95); font-size: 13px; letter-spacing: .2em; font-weight: 600; }
.pdp h1 { font-size: clamp(1.6rem, 3.2vw, 2.4rem); margin: 4px 0 8px; }
.pdp .desc { color: var(--ink-soft); margin: 0 0 6px; }
.pdp .proofline { color: var(--brand); font-weight: 600; font-size: 0.9em; margin: 10px 0 20px; }
.opt-group { margin-bottom: 18px; }
.opt-group .lbl { font-size: 0.82em; font-weight: 600; color: var(--ink-soft); margin-bottom: 8px; display: flex; gap: 8px; align-items: baseline; }
.opt-group .lbl small { color: var(--ink-faint); font-weight: 400; }
.opts-row { display: flex; flex-wrap: wrap; gap: 8px; }
.opt {
  border: 1px solid var(--line); background: var(--card); border-radius: 10px;
  padding: 10px 16px; font-size: 0.9em; cursor: pointer; transition: all .15s ease;
  display: flex; flex-direction: column; gap: 1px; min-width: 86px;
}
.opt small { color: var(--ink-faint); font-size: 0.78em; }
.opt:hover { border-color: var(--brand); }
.opt.on { border-color: var(--roast); box-shadow: 0 0 0 1px var(--roast); background: var(--accent-soft); }
.qty-row { display: flex; align-items: center; gap: 14px; margin: 22px 0; flex-wrap: wrap; }
.qty { display: inline-flex; align-items: center; border: 1px solid var(--line); border-radius: 999px; background: var(--card); }
.qty button { width: 44px; height: 44px; border: 0; background: none; font-size: 1.2em; cursor: pointer; color: var(--ink); }
.qty span { min-width: 34px; text-align: center; font-weight: 600; }
.pdp .total-price { font-family: "Anuphan", "Noto Sans Thai", sans-serif; font-size: 1.9rem; font-weight: 600; }
.freeship-note { font-size: 0.82em; color: var(--ink-soft); background: var(--accent-soft); border-radius: 8px; padding: 10px 14px; margin-top: 14px; }
.pdp-info { border-top: 1px solid var(--line); margin-top: 26px; padding-top: 20px; }
.pdp-info h2 { font-size: 1.15rem; margin: 0 0 10px; }
.pdp-info p { color: var(--ink-soft); font-size: 0.95em; }
.spec { width: 100%; font-size: 0.88em; border-collapse: collapse; margin-top: 8px; }
.spec td { padding: 8px 0; border-bottom: 1px solid var(--line); }
.spec td:first-child { color: var(--ink-faint); width: 42%; }

/* หน้ารายการบทความ */
.featured-post {
  background: var(--roast); color: #efe6da; border-radius: var(--radius);
  padding: clamp(26px, 4vw, 48px); display: block; text-decoration: none;
  margin-bottom: clamp(24px, 3vw, 40px);
}
.featured-post .eyebrow { color: #8c7c6c; }
.featured-post h2 { color: #fff; font-size: clamp(1.4rem, 3vw, 2.2rem); margin: 8px 0 10px; max-width: 30ch; }
.featured-post p { color: #c6b8a8; max-width: 62ch; margin: 0 0 14px; }
.featured-post .more { color: #fff; font-weight: 600; font-size: 0.9em; }

/* หน้าบทความเดี่ยว */
.article { max-width: 720px; margin: 0 auto; }
.article-head { text-align: left; margin-bottom: clamp(22px, 3vw, 36px); }
.article-head h1 { font-size: clamp(1.7rem, 3.6vw, 2.6rem); margin: 10px 0; }
.article-head .meta { color: var(--ink-faint); font-size: 0.85em; }
.article-body { font-size: 1.02em; }
.article-body p { margin: 0 0 1.2em; }
.article-body h2 { font-size: 1.35rem; margin: 1.8em 0 0.6em; }
.article-body h3 { font-size: 1.12rem; margin: 1.5em 0 0.5em; }
.article-body ul, .article-body ol { padding-left: 1.4em; color: var(--ink); }
.article-body li { margin-bottom: 0.4em; }
.article-cta {
  background: var(--accent-soft); border-radius: var(--radius);
  padding: 22px 24px; margin: clamp(28px, 4vw, 44px) 0; display: flex;
  flex-wrap: wrap; align-items: center; gap: 16px; justify-content: space-between;
}
.article-cta p { margin: 0; font-weight: 600; }
.article-cta small { display: block; color: var(--ink-soft); font-weight: 400; }

/* แบ่งหน้า */
.pager-nav { display: flex; gap: 6px; justify-content: center; margin-top: clamp(26px, 4vw, 40px); }
.pager-nav a {
  min-width: 40px; height: 40px; display: inline-flex; align-items: center; justify-content: center;
  border: 1px solid var(--line); border-radius: 10px; text-decoration: none; font-size: 0.9em;
  background: var(--card); color: var(--ink-soft);
}
.pager-nav a.on { background: var(--roast); border-color: var(--roast); color: #fff; }
.pager-nav a:hover:not(.on) { border-color: var(--brand); color: var(--ink); }

/* ==================== v2: ส่วนรูปภาพจริง ==================== */

/* HERO แบบมีรูป */
.hero-v2 { padding: clamp(40px, 6vw, 88px) 0 clamp(32px, 4vw, 56px); }
.hero-v2 .hero-grid { grid-template-columns: 1fr; align-items: center; }
@media (min-width: 900px) { .hero-v2 .hero-grid { grid-template-columns: 1.05fr 1fr; } }
.hero-photo { position: relative; }
.hero-photo .main {
  width: 100%; aspect-ratio: 4/3.4; object-fit: cover; display: block;
  border-radius: clamp(14px, 2vw, 22px); box-shadow: 0 22px 60px rgba(36,28,23,.18);
}
.hero-photo .float-card {
  position: absolute; left: -14px; bottom: 22px;
  background: var(--card); border: 1px solid var(--line); border-radius: 14px;
  padding: 12px 16px; box-shadow: 0 14px 40px rgba(36,28,23,.16);
  display: flex; gap: 12px; align-items: center; max-width: 78%;
}
@media (min-width: 900px) { .hero-photo .float-card { left: -34px; } }
.hero-photo .float-card img { width: 52px; height: 52px; object-fit: cover; border-radius: 9px; }
.hero-photo .float-card .t { font-size: 0.82em; line-height: 1.45; }
.hero-photo .float-card .t b { display: block; font-size: 1.05em; }
.hero-photo .float-card .t span { color: var(--ink-soft); }

/* แถวรูปบรรยากาศ */
.strip { display: grid; gap: 10px; grid-template-columns: repeat(3, 1fr); }
.strip img {
  width: 100%; aspect-ratio: 1/1; object-fit: cover; display: block;
  border-radius: var(--radius);
}
.strip figure { margin: 0; position: relative; overflow: hidden; border-radius: var(--radius); }
.strip figcaption {
  position: absolute; left: 0; right: 0; bottom: 0; padding: 26px 14px 10px;
  background: linear-gradient(transparent, rgba(30,22,19,.72));
  color: #fff; font-size: 0.78em; font-weight: 500;
}
@media (max-width: 640px) { .strip { grid-template-columns: 1fr; } .strip img { aspect-ratio: 16/9; } }

/* การ์ดสินค้าแบบรูปจริง */
.seller .visual.photo { padding: 0; height: auto; }
.seller .visual.photo img { width: 100%; aspect-ratio: 16/10; object-fit: cover; display: block; }
.seller .visual .roast-chip {
  position: absolute; top: 10px; left: 10px; border-radius: 999px;
  color: #fff; font-size: 0.72em; font-weight: 600; padding: 4px 12px;
  background: rgba(30,22,19,.78); backdrop-filter: blur(4px);
}

/* เรื่องของเรา แบบมีรูป */
.dark-grid { display: grid; gap: clamp(24px, 4vw, 48px); grid-template-columns: 1fr; align-items: center; }
@media (min-width: 880px) { .dark-grid { grid-template-columns: 1fr 1.15fr; } }
.dark-grid .photo-side img {
  width: 100%; aspect-ratio: 4/3; object-fit: cover; display: block; border-radius: 14px;
}
.dark-grid .photo-side figcaption { color: #8c7c6c; font-size: 0.78em; margin-top: 10px; }
.dark .pillars { grid-template-columns: 1fr; gap: 20px; }
@media (min-width: 880px) { .dark .pillars { gap: 24px; } }

/* การ์ดบทความแบบมีรูป */
.pcards { display: grid; gap: 18px; grid-template-columns: 1fr; }
@media (min-width: 640px) { .pcards { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 980px) { .pcards { grid-template-columns: repeat(3, 1fr); } }
.pcard {
  background: var(--card); border: 1px solid var(--line); border-radius: var(--radius);
  overflow: hidden; text-decoration: none; display: flex; flex-direction: column;
  transition: transform .18s ease, border-color .18s ease;
}
.pcard:hover { transform: translateY(-3px); border-color: var(--brand); }
.pcard img { width: 100%; aspect-ratio: 16/10; object-fit: cover; display: block; }
.pcard .body { padding: 16px 18px 18px; display: flex; flex-direction: column; gap: 6px; flex: 1; }
.pcard .meta { font-size: 0.78em; color: var(--ink-faint); }
.pcard h3 { margin: 0; font-size: 1.02rem; line-height: 1.5; flex: 1; }
.pcard .arrow { color: var(--brand); font-size: 0.85em; font-weight: 600; }

/* บทความเด่นแบบมีรูป */
.featured-post.with-img { padding: 0; overflow: hidden; display: grid; grid-template-columns: 1fr; }
@media (min-width: 820px) { .featured-post.with-img { grid-template-columns: 1.1fr 1fr; } }
.featured-post.with-img img { width: 100%; height: 100%; min-height: 230px; object-fit: cover; display: block; }
.featured-post.with-img .fp-body { padding: clamp(22px, 3.5vw, 44px); display: flex; flex-direction: column; justify-content: center; }

/* รูป hero ของหน้าบทความ */
.article-hero { margin: 0 0 clamp(20px, 3vw, 32px); }
.article-hero img {
  width: 100%; aspect-ratio: 16/8.5; object-fit: cover; display: block;
  border-radius: var(--radius);
}

/* ===== หน้าแรก v3 — "น้อยแต่มาก" ฉบับดอยไทย (2026-08-18) =====
 * หนึ่งจอหนึ่งความคิด: บทกวีเปิด → รูปจริงหนึ่งใบ → รายการกาแฟราคานำ →
 * ประโยคเดียวบนพื้นเข้ม → บทความ · อบอุ่นด้วย serif ไทย + ภาพถ่ายจริง
 * (คนละทางกับ KESIYA ที่เย็น-นิ่ง-ไร้ภาพถ่าย) · คลาสใหม่ทั้งหมดขึ้นต้น mn- */

.mn-hero { text-align: center; padding: clamp(64px, 11vw, 150px) 0 clamp(40px, 6vw, 80px); }
.mn-hero .eyebrow { color: var(--brand); }
.mn-hero h1 {
  font-size: clamp(2.1rem, 5.6vw, 4.2rem); margin: 18px auto 20px; max-width: 21ch;
  letter-spacing: -0.01em;
}
.mn-hero .lead { color: var(--ink-soft); max-width: 44ch; margin: 0 auto clamp(26px, 4vw, 38px); }
.mn-hero .hero-cta { justify-content: center; }
.mn-trust {
  margin-top: clamp(30px, 5vw, 48px); color: var(--ink-faint); font-size: 0.86em;
  display: flex; justify-content: center; gap: 10px; flex-wrap: wrap;
}
.mn-trust b { color: var(--ink-soft); font-weight: 600; }

/* รูปจริงหนึ่งใบ — จังหวะหายใจของหน้า */
.mn-photo { margin: 0; }
.mn-photo img {
  width: 100%; aspect-ratio: 21 / 9; object-fit: cover; display: block;
  border-radius: clamp(16px, 2.5vw, 26px);
}
.mn-photo figcaption { text-align: center; color: var(--ink-faint); font-size: 0.84em; margin-top: 12px; }
@media (max-width: 640px) { .mn-photo img { aspect-ratio: 4 / 3; } }

/* รายการกาแฟ — ราคานำ อ่านเหมือนเมนู ไม่ใช่แผงการ์ด */
.mn-menu { max-width: 760px; margin: 0 auto; }
.mn-menu-head { text-align: center; margin-bottom: clamp(26px, 4vw, 40px); }
.mn-menu-head h2 { font-size: clamp(1.6rem, 3.4vw, 2.4rem); margin: 10px 0 0; }
.mn-row {
  display: flex; align-items: baseline; gap: 16px; text-decoration: none;
  padding: clamp(18px, 2.6vw, 26px) 6px; border-bottom: 1px solid var(--line);
  transition: background .15s ease;
}
.mn-row:first-of-type { border-top: 1px solid var(--line); }
.mn-row:hover { background: var(--card); }
.mn-row .name { font-family: "Noto Serif Thai", Georgia, serif; font-weight: 600; font-size: clamp(1.05rem, 1.8vw, 1.35rem); white-space: nowrap; }
.mn-row .best {
  font-size: 0.62em; font-weight: 600; letter-spacing: .08em; color: var(--brand);
  border: 1px solid currentColor; border-radius: 999px; padding: 2px 9px;
  vertical-align: 3px; margin-left: 10px; white-space: nowrap;
}
.mn-row .who { color: var(--ink-soft); font-size: 0.88em; flex: 1; min-width: 0; }
.mn-row .price { font-weight: 700; white-space: nowrap; font-size: 1.05em; }
.mn-row .price small { color: var(--ink-faint); font-weight: 500; font-size: 0.72em; }
.mn-row .go { color: var(--brand); font-weight: 600; }
.mn-menu-foot { text-align: center; color: var(--ink-faint); font-size: 0.86em; margin-top: 20px; }
.mn-menu-foot a { color: var(--brand); font-weight: 600; text-decoration: none; }
@media (max-width: 640px) {
  .mn-row { flex-wrap: wrap; gap: 4px 12px; }
  .mn-row .who { flex-basis: 100%; order: 3; }
  .mn-row .price { margin-left: auto; }
  .mn-row .go { display: none; }
}

/* ประโยคเดียวบนพื้นเข้ม — เว้นที่ให้คำพูดทำงาน */
.mn-band {
  background: var(--roast); color: #efe6da; text-align: center;
  border-radius: clamp(18px, 3vw, 30px);
  padding: clamp(52px, 8vw, 110px) clamp(24px, 5vw, 60px);
}
.mn-band .eyebrow { color: #a8907a; }
.mn-band h2 { color: #fff; font-size: clamp(1.7rem, 4.2vw, 3rem); margin: 14px auto 16px; max-width: 24ch; }
.mn-band p { color: #c9bcae; max-width: 46ch; margin: 0 auto clamp(22px, 3.5vw, 32px); }
.mn-band a.more { color: #efe6da; font-weight: 600; text-decoration: underline; text-underline-offset: 4px; }

/* footer เรียบ — แถวเดียวจบ */
.mn-foot { border-top: 1px solid var(--line); margin-top: clamp(40px, 6vw, 80px); }
.mn-foot .inner {
  display: flex; flex-wrap: wrap; align-items: center; gap: 14px 28px;
  padding: clamp(24px, 4vw, 40px) 0;
}
.mn-foot .links { display: flex; flex-wrap: wrap; gap: 6px 22px; font-size: 0.88em; margin-left: auto; }
.mn-foot .links a { color: var(--ink-soft); text-decoration: none; }
.mn-foot .links a:hover { color: var(--ink); }
.mn-foot .legal-line { color: var(--ink-faint); font-size: 0.8em; padding-bottom: 22px; }

/* ===== ตะกร้า + หน้าชำระเงินทดลอง (2026-08-18) ===== */
.add-cart {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  border: 0; background: var(--brand); color: #fff;
  border-radius: 12px; padding: 11px 20px; font-size: 0.88em; font-weight: 600;
  cursor: pointer; font-family: inherit;
  transition: background .15s ease, transform .1s ease;
}
.add-cart::before {
  content: "+"; display: inline-grid; place-items: center;
  width: 18px; height: 18px; border-radius: 50%;
  background: rgba(255,255,255,.22); font-weight: 700; line-height: 1; font-size: 13px;
}
.add-cart:hover { background: var(--brand-deep); }
.add-cart:active { transform: scale(.97); }
.add-cart.added { background: #2f7a4d; }
.add-cart.added::before { content: "✓"; }
.dt-toast {
  position: fixed; left: 50%; bottom: 84px; transform: translate(-50%, 16px);
  background: var(--roast); color: #efe6da; border-radius: 999px;
  padding: 11px 22px; font-size: 0.9em; opacity: 0; pointer-events: none;
  transition: all .22s ease; z-index: 90; white-space: nowrap; box-shadow: 0 12px 30px rgba(0,0,0,.25);
}
.dt-toast.show { opacity: 1; transform: translate(-50%, 0); pointer-events: auto; }
.dt-toast a { color: #fff; font-weight: 700; }

/* หน้าชำระเงิน — หน้าเดียวจบ */
.co-grid { display: grid; gap: clamp(20px, 3vw, 36px); grid-template-columns: 1fr; align-items: start; }
@media (min-width: 900px) { .co-grid { grid-template-columns: 1.1fr 0.9fr; } }
.co-card { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: clamp(18px, 2.5vw, 28px); }
.co-card h2 { margin: 0 0 14px; font-size: 1.15rem; }
.co-item { display: flex; align-items: center; gap: 12px; padding: 12px 0; border-bottom: 1px solid var(--line); }
.co-item:last-of-type { border-bottom: 0; }
.co-item .nm { flex: 1; min-width: 0; font-weight: 600; font-size: 0.95em; }
.co-item .nm small { display: block; color: var(--ink-faint); font-weight: 400; }
.co-qty { display: flex; align-items: center; gap: 2px; border: 1px solid var(--line); border-radius: 999px; }
.co-qty button { border: 0; background: none; width: 30px; height: 30px; cursor: pointer; font-size: 1em; color: var(--brand); font-weight: 700; }
.co-qty span { min-width: 22px; text-align: center; font-weight: 600; font-size: 0.9em; }
.co-item .ln { font-weight: 700; white-space: nowrap; }
.co-form { display: grid; gap: 10px; grid-template-columns: 1fr 1fr; }
.co-form .full { grid-column: 1 / -1; }
.co-form label { font-size: 0.78em; font-weight: 600; color: var(--ink-soft); display: block; margin-bottom: 4px; }
.co-form input {
  width: 100%; box-sizing: border-box; border: 1px solid var(--line); border-radius: 10px;
  padding: 10px 12px; font: inherit; font-size: 16px; background: #fff;
}
.co-form input:focus { outline: none; border-color: var(--brand); }
/* ขนส่ง + วิธีชำระเงิน — ลิสต์แถวเลือกแบบมีโลโก้ (ไม่ใช่ปุ่มเรียงแถว) */
.pmx { border: 1px solid var(--line); border-radius: 14px; overflow: hidden; background: var(--card); }
.pmx-row { border-bottom: 1px solid var(--line); }
.pmx-row:last-child { border-bottom: 0; }
.pmx-row .head {
  display: flex; align-items: center; gap: 12px; padding: 12px 14px;
  cursor: pointer; transition: background .12s ease;
}
.pmx-row .head:hover { background: var(--paper); }
.pmx-row.on .head { background: var(--accent-soft); }
.pmx-row .dot {
  width: 18px; height: 18px; border-radius: 50%; flex: none;
  border: 2px solid var(--line); background: #fff; transition: all .12s ease;
}
.pmx-row.on .dot { border-color: var(--brand); box-shadow: inset 0 0 0 4px #fff; background: var(--brand); }
.pmx-row .tx { flex: 1; min-width: 0; line-height: 1.35; }
.pmx-row .tx b { font-size: 0.93em; display: block; }
.pmx-row .tx small { color: var(--ink-faint); font-size: 0.78em; }
.pmx-row .body { padding: 0 14px; }
.pmx-row.on .body:not(:empty) { padding: 4px 14px 14px 44px; }
@media (max-width: 560px) { .pmx-row.on .body:not(:empty) { padding-left: 14px; } }

/* โลโก้วาดด้วยโค้ด: กล่องสี + อักษร/ไอคอนประจำแบรนด์ */
.plogo {
  width: 42px; height: 42px; border-radius: 11px; flex: none;
  display: grid; place-items: center; font-weight: 800; font-size: 12px;
  letter-spacing: .02em; color: #fff;
}
.pg-pp { background: #113F67; }
.pg-card { background: linear-gradient(135deg, #37474F, #263238); }
.pg-mb { background: #2f7a4d; }
.pg-flash { background: #FFD100; color: #191919; font-size: 20px; }
.pg-kex { background: #F37021; font-size: 11px; }
.pg-ship { background: var(--ink-soft); font-size: 18px; }

/* ฟอร์มบัตร (กางในแถวที่เลือก) */
.pm-card { display: grid; gap: 10px; grid-template-columns: 1fr 1fr; }
.pm-card .full { grid-column: 1 / -1; }
.pm-note { grid-column: 1 / -1; font-size: 0.78em; color: var(--ink-faint); margin: 0; }

/* ธนาคาร — โลโก้วงกลมสีประจำแบงก์ + ชื่อ */
.bank-grid { display: grid; gap: 8px; grid-template-columns: repeat(auto-fill, minmax(86px, 1fr)); }
.bank-tile {
  border: 1.5px solid var(--line); background: #fff; border-radius: 12px;
  padding: 10px 6px 8px; font: inherit; cursor: pointer; text-align: center;
  display: flex; flex-direction: column; align-items: center; gap: 5px;
  transition: border-color .12s ease;
}
.bank-tile:hover { border-color: var(--brand); }
.bank-tile.on { border-color: var(--roast); box-shadow: 0 0 0 1.5px var(--roast); }
.bank-tile small { font-size: 0.72em; color: var(--ink-soft); line-height: 1.2; }
.bank-tile .bk {
  width: 38px; height: 38px; border-radius: 50%; display: grid; place-items: center;
  color: #fff; font-weight: 800; font-size: 11px;
}
.bk-scb { background: #4F2D7F; }
.bk-kbank { background: #029B3B; font-size: 15px; }
.bk-bay { background: #FFD400; color: #3d3319; }
.bk-bbl { background: #1E4598; }
.bk-ktb { background: #00A4E4; }
.co-check { display: flex; align-items: center; gap: 8px; font-size: 0.88em; color: var(--ink-soft); cursor: pointer; }
.co-check input { accent-color: var(--brand); width: 16px; height: 16px; }

/* สมุดที่อยู่ในหน้าชำระเงิน + หน้าสมาชิก */
.adr {
  display: block; width: 100%; text-align: left; font: inherit; cursor: pointer;
  border: 1.5px solid var(--line); background: var(--card); border-radius: 12px;
  padding: 10px 14px; margin-bottom: 8px; transition: border-color .15s ease;
}
.adr:hover { border-color: var(--brand); }
.adr.on { border-color: var(--roast); box-shadow: 0 0 0 1px var(--roast); background: var(--accent-soft); }
.adr b { font-size: 0.92em; }
.adr small { display: block; color: var(--ink-soft); font-size: 0.8em; line-height: 1.5; }
.adr .def {
  margin-left: 8px; font-size: 0.68em; font-weight: 700; color: var(--brand);
  border: 1px solid currentColor; border-radius: 999px; padding: 1px 8px; vertical-align: 2px;
}
.adr.new { color: var(--brand); font-weight: 600; font-size: 0.9em; text-align: center; border-style: dashed; }

/* หน้าสมาชิก: รายการที่อยู่ + ปุ่มจัดการ */
.ac-adr { position: relative; }
.ac-adr .acts { display: flex; gap: 12px; margin-top: 6px; }
.ac-adr .acts button {
  border: 0; background: none; font: inherit; font-size: 0.8em; font-weight: 600;
  color: var(--ink-soft); cursor: pointer; padding: 0;
}
.ac-adr .acts button:hover { color: var(--brand); }
.ac-adr .acts button.del:hover { color: #a33c2f; }

/* ช่องโค้ดส่วนลดในหน้าชำระเงิน */
.co-coupon .row { display: flex; gap: 8px; }
.co-coupon input { flex: 1; text-transform: uppercase; }
.co-coupon input::placeholder { text-transform: none; }
.co-coupon button {
  border: 1.5px solid var(--brand); background: none; color: var(--brand);
  border-radius: 10px; padding: 0 18px; font: inherit; font-weight: 700;
  font-size: 0.9em; cursor: pointer; white-space: nowrap;
}
.co-coupon button:hover { background: var(--brand); color: #fff; }
.co-coupon .msg { font-size: 0.82em; margin: 6px 0 0; display: none; }
.co-coupon .msg.ok { display: block; color: #2f7a4d; font-weight: 600; }
.co-coupon .msg.err { display: block; color: #a33c2f; }
.co-sum.disc b { color: #2f7a4d; }
.co-sum.vat { color: var(--ink-soft); }
.co-sum.vat b { color: var(--ink-faint); font-weight: 500; }

.co-sum { display: flex; justify-content: space-between; padding: 6px 0; font-size: 0.95em; }
.co-sum.total { font-size: 1.15em; font-weight: 700; border-top: 1px solid var(--line); margin-top: 8px; padding-top: 14px; }
.co-pay {
  width: 100%; border: 0; border-radius: 12px; background: var(--brand); color: #fff;
  font: inherit; font-weight: 700; font-size: 1.05em; padding: 15px; cursor: pointer; margin-top: 14px;
}
.co-pay:hover { background: var(--brand-deep); }
.co-pay:disabled { opacity: .5; cursor: default; }
.co-note { text-align: center; color: var(--ink-faint); font-size: 0.8em; margin-top: 10px; }
.co-simband {
  background: #fdf3d7; border: 1px solid #e8d089; color: #6b5410;
  border-radius: 10px; padding: 10px 14px; font-size: 0.85em; margin-bottom: 14px;
}
.co-success { text-align: center; padding: clamp(40px, 8vw, 90px) 20px; }
.co-success .big { font-size: clamp(2.4rem, 6vw, 4rem); }
.co-success h1 { font-size: clamp(1.6rem, 3.6vw, 2.4rem); margin: 12px 0 6px; }
.co-success .onum { font-family: monospace; font-size: 1.2em; font-weight: 700; color: var(--brand); }
.co-qr { text-align: center; padding: 10px 0; }
.co-qr img { width: min(260px, 70vw); border: 1px solid var(--line); border-radius: 12px; }

/* ===== หน้าแรก v4 — สูตร anthropic.com แท้ ในโทนกาแฟ (2026-08-18) =====
 * ลายมือของต้นแบบ: ชิดซ้าย · serif ใหญ่มาก leading แน่น · อากาศเยอะ ·
 * การ์ดสีนุ่มมุมโค้งใหญ่พร้อมลายเส้น · เส้นแบ่งบาง ๆ · ปุ่ม pill เข้ม ·
 * ไม่มีแถบดำเต็มความกว้าง — ทุกอย่างอยู่บนกระดาษครีมเดียวกัน */

.an-hero { padding: clamp(56px, 9vw, 130px) 0 clamp(36px, 6vw, 72px); }
.an-hero .eyebrow { color: var(--brand); }
.an-hero h1 {
  font-size: clamp(2.4rem, 6.4vw, 5rem); line-height: 1.12; letter-spacing: -0.015em;
  margin: 16px 0 22px; max-width: 15ch; font-weight: 600;
}
.an-hero .lead { color: var(--ink-soft); max-width: 42ch; margin: 0 0 clamp(24px, 3.5vw, 34px); }
.an-cta { display: flex; align-items: center; gap: 20px; flex-wrap: wrap; }
.an-pill {
  display: inline-block; background: var(--roast); color: #fff; text-decoration: none;
  border-radius: 999px; padding: 13px 30px; font-weight: 600; transition: background .15s ease;
}
.an-pill:hover { background: var(--brand-deep); }
.an-textlink { color: var(--ink); font-weight: 600; text-decoration: none; }
.an-textlink::after { content: " →"; }
.an-textlink:hover { color: var(--brand); }
.an-hero .quiet { color: var(--ink-faint); font-size: 0.84em; margin-top: clamp(22px, 3vw, 30px); }
.an-hero .quiet b { color: var(--ink-soft); }

/* การ์ดคู่สีนุ่ม — ลายเซ็นของต้นแบบ */
.an-cards { display: grid; gap: 16px; grid-template-columns: 1fr; }
@media (min-width: 760px) { .an-cards { grid-template-columns: 1fr 1fr; } }
.an-card {
  border-radius: clamp(18px, 2.5vw, 26px); padding: clamp(24px, 3.5vw, 40px);
  display: flex; flex-direction: column; gap: 10px; min-height: clamp(230px, 26vw, 300px);
  text-decoration: none; position: relative; overflow: hidden;
  transition: transform .18s ease;
}
.an-card:hover { transform: translateY(-3px); }
.an-card.latte { background: #ecdfcc; color: var(--ink); }
.an-card.roast { background: #e8d5bf; color: var(--ink); }
.an-card .eyebrow { color: inherit; opacity: .6; }
.an-card h3 {
  font-size: clamp(1.4rem, 2.6vw, 2rem); margin: 0; line-height: 1.25; max-width: 16ch;
}
.an-card .sub { color: inherit; opacity: .75; font-size: 0.92em; margin: 0; max-width: 34ch; }
.an-card .cta-row { margin-top: auto; display: flex; align-items: center; gap: 14px; flex-wrap: wrap; }
.an-card .price-big { font-weight: 700; font-size: 1.25em; }
.an-card svg { position: absolute; right: clamp(14px, 2.5vw, 30px); top: clamp(14px, 2.5vw, 26px); opacity: .5; }

/* ดัชนีสินค้า — รายการเส้นบางแบบหน้า research ของต้นแบบ */
.an-index-head {
  display: flex; align-items: baseline; justify-content: space-between; gap: 14px;
  margin-bottom: 4px;
}
.an-index-head h2 { font-size: clamp(1.4rem, 2.8vw, 2rem); margin: 0; }
.an-row {
  display: flex; align-items: baseline; gap: 18px; text-decoration: none;
  padding: clamp(20px, 3vw, 28px) 2px; border-bottom: 1px solid var(--line);
}
.an-row:first-of-type { border-top: 1px solid var(--line); margin-top: 18px; }
.an-row .name {
  font-family: "Noto Serif Thai", Georgia, serif; font-weight: 600;
  font-size: clamp(1.1rem, 2vw, 1.45rem); white-space: nowrap;
}
.an-row .best {
  font-size: 0.6em; font-weight: 600; letter-spacing: .1em; color: var(--brand);
  border: 1px solid currentColor; border-radius: 999px; padding: 2px 10px;
  vertical-align: 4px; margin-left: 10px;
}
.an-row .who { color: var(--ink-faint); font-size: 0.88em; flex: 1; }
.an-row .price { font-weight: 600; white-space: nowrap; color: var(--ink-soft); }
.an-row .price b { color: var(--ink); font-size: 1.1em; }
.an-row:hover .name { color: var(--brand); }
@media (max-width: 640px) {
  .an-row { flex-wrap: wrap; gap: 2px 12px; }
  .an-row .who { flex-basis: 100%; order: 3; }
  .an-row .price { margin-left: auto; }
}

/* เรื่องของเรา — สองคอลัมน์ ภาพการ์ดมุมโค้ง + ตัวหนังสือ */
.an-story { display: grid; gap: clamp(24px, 4vw, 56px); grid-template-columns: 1fr; align-items: center; }
@media (min-width: 860px) { .an-story { grid-template-columns: 1fr 1fr; } }
.an-story img {
  width: 100%; aspect-ratio: 4 / 3; object-fit: cover; display: block;
  border-radius: clamp(18px, 2.5vw, 26px);
}
.an-story h2 { font-size: clamp(1.7rem, 3.6vw, 2.6rem); margin: 12px 0 14px; line-height: 1.2; }
.an-story p { color: var(--ink-soft); max-width: 46ch; margin: 0 0 12px; }

/* ===== ผิว v5 (ย้ายมาจาก index — ใช้ร่วมทั้งเว็บ) ===== */
/* ===== v5 — งาช้าง anthropic + ของประดิษฐ์ของดอยไทย (ถุงคราฟท์ · ดอย · ระดับคั่ว) ===== */
.logo .bean { background:#C15F3C; }
.topbar { background:#191919; }

/* --- hero ซ้ายตัวหนังสือ ขวาฉากดอย --- */
.v5-hero { display:grid; gap:clamp(28px,4vw,56px); grid-template-columns:1fr; align-items:center;
  padding:clamp(40px,6vw,84px) 0 clamp(30px,4vw,56px); }
@media (min-width:900px){ .v5-hero { grid-template-columns:1.05fr .95fr; } }
.v5-hero h1 { font-size:clamp(2.2rem,5vw,3.9rem); line-height:1.12; margin:14px 0 20px; font-weight:650; }
.v5-hero .lead { color:var(--ink-soft); max-width:40ch; margin:0 0 clamp(22px,3vw,30px); }
.v5-quiet { color:var(--ink-faint); font-size:.84em; margin-top:clamp(20px,3vw,28px); }
.v5-quiet b { color:var(--ink-soft); }

/* ฉากดอยสูง — ภาพประกอบประจำแบรนด์ วาดด้วยโค้ดล้วน */
.v5-scene { position:relative; border-radius:clamp(18px,2.5vw,28px); overflow:hidden;
  background:linear-gradient(180deg,#EFE9D9 0%,#E9E0CA 58%,#E2D6BA 100%);
  min-height:clamp(300px,36vw,430px); display:flex; align-items:flex-end; justify-content:center; }
.v5-scene .sun { position:absolute; top:11%; right:14%; width:clamp(40px,5vw,62px); aspect-ratio:1;
  border-radius:50%; background:#C15F3C; opacity:.85; }
.v5-scene svg.mtn { position:absolute; left:0; right:0; bottom:-2px; width:100%; height:52%; }
.v5-scene .kbag { z-index:2; margin-bottom:clamp(22px,3.5vw,40px); }
.v5-scene .steam { position:absolute; z-index:3; bottom:calc(clamp(22px,3.5vw,40px) + 76%); opacity:.5; }

/* ถุงคราฟท์โรงคั่ว — ของประจำตัวดอยไทย (คนละภาษากับถุง bone ของ KESIYA) */
.kbag { position:relative; width:var(--w,170px); aspect-ratio:3/4.3; flex:none; font-size:var(--fs,14px);
  background:
    repeating-linear-gradient(92deg, rgba(255,255,255,.05) 0 2px, transparent 2px 5px),
    linear-gradient(160deg,#CBA97F 0%,#B18D5F 62%,#9E7C4F 100%);
  border-radius:9px 9px 13px 13px;
  box-shadow:inset -9px 0 16px rgba(60,40,10,.2), inset 9px 0 16px rgba(255,255,255,.24),
             0 20px 30px -16px rgba(60,40,10,.55); }
.kbag::before { content:""; position:absolute; inset:0 0 auto 0; height:13%;
  background:linear-gradient(180deg,#8F6E43,rgba(165,130,83,.15));
  border-radius:9px 9px 0 0; border-bottom:2px dashed rgba(255,255,255,.3); }
.kbag .lbl { position:absolute; left:11%; right:11%; top:26%; bottom:14%;
  background:#F8F5ED; border-radius:9px; box-shadow:0 3px 8px rgba(60,40,10,.2);
  display:flex; flex-direction:column; align-items:center; justify-content:center;
  gap:5%; padding:9% 6%; text-align:center; }
.kbag .lbl b { font-size:.68em; letter-spacing:.24em; color:#191919; font-weight:700; }
.kbag .lbl .dot { width:15%; aspect-ratio:1; border-radius:50%; background:var(--roastc,#4a2f1d); }
.kbag .lbl .g { font-weight:700; font-size:.95em; color:#191919; line-height:1.25; }
.kbag .lbl .r { font-size:.6em; color:#8f897b; letter-spacing:.06em; }

/* --- การ์ดกาแฟ 4 ใบ ถุงจริงตั้งโชว์ ราคาชัด กดซื้อได้เลย --- */
.v5-grid { display:grid; gap:14px; grid-template-columns:repeat(2,1fr); }
@media (min-width:900px){ .v5-grid { grid-template-columns:repeat(4,1fr); } }
.v5-gcard { background:var(--card); border:1px solid var(--line); border-radius:18px;
  padding:22px 16px 18px; text-align:center; display:flex; flex-direction:column;
  align-items:center; gap:7px; position:relative; transition:transform .16s ease, box-shadow .16s ease; }
.v5-gcard:hover { transform:translateY(-4px); box-shadow:0 20px 40px rgba(25,25,25,.08); }
.v5-gcard .kbag { --w:104px; --fs:10px; margin:2px 0 8px; }
.v5-gcard h3 { font-size:1.05rem; margin:0; }
.v5-gcard .who { color:var(--ink-faint); font-size:.78em; line-height:1.5; margin:0; min-height:3em; }
.v5-gcard .pr { font-weight:700; font-size:1.1em; }
.v5-gcard .pr small { color:var(--ink-faint); font-weight:500; font-size:.72em; }
.v5-gcard .best { position:absolute; top:12px; right:12px; background:#C15F3C; color:#fff;
  font-size:.62em; font-weight:700; letter-spacing:.08em; border-radius:999px; padding:4px 11px; }
.v5-gcard .add-cart { margin-top:2px; }

.v5-head { display:flex; align-items:baseline; justify-content:space-between; gap:14px; margin-bottom:clamp(18px,2.5vw,26px); }
.v5-head h2 { font-size:clamp(1.5rem,3vw,2.2rem); margin:0; font-weight:650; }

/* สเกลระดับคั่ว — ของเก่าที่ดี เอากลับมาแบบเงียบขึ้น */
.v5-roast { display:flex; gap:clamp(14px,3vw,34px); justify-content:center; flex-wrap:wrap;
  margin-top:clamp(24px,3.5vw,36px); color:var(--ink-faint); font-size:.8em; }
.v5-roast span { display:flex; align-items:center; gap:7px; }
.v5-roast i { width:15px; height:15px; border-radius:50%; flex:none; }

/* เรื่องของเรา + จุดยืน 3 ข้อ */
.v5-story { display:grid; gap:clamp(24px,4vw,56px); grid-template-columns:1fr; align-items:center; }
@media (min-width:880px){ .v5-story { grid-template-columns:1fr 1fr; } }
.v5-story img { width:100%; aspect-ratio:4/3; object-fit:cover; display:block; border-radius:clamp(18px,2.5vw,26px); }
.v5-story h2 { font-size:clamp(1.7rem,3.4vw,2.5rem); line-height:1.18; margin:10px 0 14px; font-weight:650; }
.v5-story p { color:var(--ink-soft); max-width:44ch; margin:0 0 16px; }
.v5-pts { display:flex; flex-direction:column; gap:10px; margin:18px 0 20px; }
.v5-pts div { display:flex; gap:12px; align-items:baseline; }
.v5-pts .n { color:#C15F3C; font-weight:700; font-size:.8em; flex:none; }
.v5-pts p { margin:0; font-size:.92em; }
.v5-pts b { color:var(--ink); }

.an-pill { background:#191919; }
.an-pill:hover { background:#C15F3C; }
.v5-gcard .add-cart { width:100%; margin-top:4px; }
.v5-gcard .vnote { color:var(--ink-faint); font-size:.74em; margin:0; border:0; background:none; padding:0; }
.pick-link { display:inline-flex; align-items:center; justify-content:center; width:100%;
  border:1.5px solid var(--line); border-radius:12px; padding:10px 20px; margin-top:4px;
  font-size:.88em; font-weight:600; color:var(--ink); text-decoration:none;
  transition:border-color .15s ease, color .15s ease; }
.pick-link:hover { border-color:#C15F3C; color:#C15F3C; }
.pcard { background:var(--card); }

/* ===== สมาชิก + ล็อคอิน (2026-08-19) ===== */

/* ลิงก์สมาชิกบนหัวเว็บ — pill คู่กับปุ่มตะกร้า */
.acct {
  display: inline-flex; align-items: center; gap: 7px; text-decoration: none;
  border: 1px solid var(--line); background: var(--card);
  border-radius: 999px; padding: 7px 14px; font-size: 0.85em; font-weight: 500;
  white-space: nowrap;
}
.acct:hover { border-color: var(--brand); color: var(--brand); }
@media (max-width: 640px) { .acct .tx { display: none; } .acct { padding: 8px 10px; } }

/* หน้า login/สมัคร — การ์ดเดียวกลางหน้า */
.lg-wrap { max-width: 430px; margin: 0 auto; padding: clamp(30px, 5vw, 60px) 20px 60px; }
.lg-card { background: var(--card); border: 1px solid var(--line); border-radius: 18px; padding: clamp(22px, 4vw, 34px); }
.lg-tabs { display: grid; grid-template-columns: 1fr 1fr; gap: 4px; background: var(--accent-soft); border-radius: 12px; padding: 4px; margin-bottom: 22px; }
.lg-tabs button {
  border: 0; background: none; font: inherit; font-weight: 600; font-size: 0.92em;
  padding: 9px 0; border-radius: 9px; cursor: pointer; color: var(--ink-soft);
}
.lg-tabs button.on { background: var(--card); color: var(--ink); box-shadow: 0 1px 4px rgba(25,25,25,.08); }
.lg-form { display: grid; gap: 12px; }
.lg-form label { font-size: 0.78em; font-weight: 600; color: var(--ink-soft); display: block; margin-bottom: 4px; }
.lg-form input {
  width: 100%; box-sizing: border-box; border: 1px solid var(--line); border-radius: 10px;
  padding: 11px 13px; font: inherit; font-size: 16px; background: #fff;
}
.lg-form input:focus { outline: none; border-color: var(--brand); }
.lg-hint { font-size: 0.8em; color: var(--ink-faint); margin: 0; line-height: 1.6; }
.lg-err {
  display: none; background: #f8e3dc; border: 1px solid #dfb2a2; color: #8a3b26;
  border-radius: 10px; padding: 10px 14px; font-size: 0.85em;
}
.lg-err.show { display: block; }
.lg-line { border: 0; border-top: 1px solid var(--line); margin: 18px 0 14px; }
.lg-alt {
  display: flex; align-items: center; justify-content: center; gap: 9px; width: 100%;
  border: 1px solid var(--line); border-radius: 12px; background: #fff; color: var(--ink-faint);
  font: inherit; font-size: 0.9em; font-weight: 600; padding: 12px; cursor: not-allowed;
}
.lg-alt .dotln { width: 17px; height: 17px; border-radius: 5px; background: #06C755; opacity: .55; flex: none; }

/* หัวหน้าสมาชิก */
.ac-hero { padding: clamp(28px, 4vw, 48px) 0 clamp(8px, 1.5vw, 14px); }
.ac-hero .row { display: flex; align-items: baseline; gap: 14px; flex-wrap: wrap; }
.ac-hero h1 { font-size: clamp(1.6rem, 3.4vw, 2.4rem); margin: 6px 0 4px; }
.ac-hero .out {
  margin-left: auto; font-size: 0.85em; color: var(--ink-faint); text-decoration: none;
  border-bottom: 1px solid transparent; cursor: pointer; background: none; border-top: 0; border-inline: 0; font-family: inherit; padding: 0;
}
.ac-hero .out:hover { color: var(--brand); border-bottom-color: currentColor; }
.ac-sec { padding: clamp(16px, 2.5vw, 28px) 0; }
.ac-sec h2 { font-size: clamp(1.15rem, 2.2vw, 1.5rem); margin: 0 0 4px; }
.ac-sec .sub { color: var(--ink-faint); font-size: 0.85em; margin: 0 0 16px; }
.ac-empty {
  background: var(--card); border: 1px dashed var(--line); border-radius: var(--radius);
  padding: 26px 22px; color: var(--ink-soft); font-size: 0.92em; text-align: center;
}
.ac-empty a { color: var(--brand); font-weight: 600; }

/* คูปอง — ตั๋วมีรอยปรุ ฉีกครึ่งซ้ายเป็นตัวเลขส่วนลด */
.cp-grid { display: grid; gap: 14px; grid-template-columns: 1fr; }
@media (min-width: 700px) { .cp-grid { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1040px) { .cp-grid { grid-template-columns: repeat(3, 1fr); } }
.cp { display: flex; background: var(--card); border: 1px solid var(--line); border-radius: 14px; position: relative; overflow: hidden; }
.cp .val {
  flex: none; width: 108px; background: var(--brand); color: #fff;
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 1px;
  padding: 18px 8px;
}
.cp .val b { font-size: 1.55rem; font-weight: 700; line-height: 1.1; letter-spacing: -0.02em; }
.cp .val span { font-size: 0.68em; font-weight: 600; letter-spacing: .12em; opacity: .85; }
.cp .bd { flex: 1; min-width: 0; padding: 14px 16px; border-left: 2px dashed var(--paper); }
.cp .ttl { font-weight: 600; font-size: 0.95em; line-height: 1.45; margin: 0 0 8px; }
.cp .cond { font-size: 0.78em; color: var(--ink-faint); margin: 0 0 10px; line-height: 1.6; }
.cp .code-row { display: flex; align-items: center; gap: 8px; }
.cp .code {
  font-family: ui-monospace, Menlo, monospace; font-weight: 700; font-size: 0.9em;
  border: 1.5px dashed var(--brand); color: var(--brand); border-radius: 8px; padding: 4px 12px;
  letter-spacing: .06em;
}
.cp .copy {
  border: 0; background: none; font: inherit; font-size: 0.8em; font-weight: 600;
  color: var(--ink-soft); cursor: pointer; padding: 4px 6px; border-radius: 6px;
  white-space: nowrap;
}
.cp .code-row { flex-wrap: wrap; }
.cp .copy:hover { color: var(--brand); }
/* ป้ายจำนวนเหลือ — หัวใจของคูปองจำกัดจำนวน: เห็นก่อนอ่านอย่างอื่น */
.cp .left {
  position: absolute; top: -1px; right: 14px;
  background: var(--ink); color: #fff;
  font-size: 0.72em; font-weight: 700; letter-spacing: .02em;
  border-radius: 0 0 9px 9px; padding: 4px 12px 5px; white-space: nowrap;
}
.cp .left.hot { background: #a33c2f; animation: cp-pulse 1.6s ease-in-out infinite; }
@keyframes cp-pulse {
  0%, 100% { box-shadow: 0 0 0 0 rgba(163,60,47,.45); }
  50% { box-shadow: 0 0 0 6px rgba(163,60,47,0); }
}
.cp .bd { position: relative; }
.cp .left + .ttl { padding-right: 92px; }
/* แถบโควต้า: เต็มแค่ไหน = ถูกใช้ไปแล้วเท่านั้น */
.cp .qwrap { margin: -4px 0 10px; }
.cp .qbar { height: 5px; border-radius: 999px; background: var(--accent-soft); overflow: hidden; }
.cp .qbar i { display: block; height: 100%; border-radius: 999px; background: linear-gradient(90deg, var(--brand), #a33c2f); }
.cp .qwrap small { font-size: 0.7em; color: var(--ink-faint); }
.cp .use { margin-left: auto; font-size: 0.8em; font-weight: 700; color: var(--brand); text-decoration: none; white-space: nowrap; }
.cp .use:hover { text-decoration: underline; }

/* รอยเจาะตั๋ว: วงกลมสีพื้นกระดาษคร่อมรอยปรุ */
.cp::before, .cp::after {
  content: ""; position: absolute; left: 108px; width: 16px; height: 16px;
  border-radius: 50%; background: var(--paper); border: 1px solid var(--line);
  transform: translateX(-50%); z-index: 1;
}
.cp::before { top: -9px; }
.cp::after { bottom: -9px; }

/* คำสั่งซื้อ — การ์ดต่อออเดอร์ + จุดสถานะเดินทาง */
.od { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: clamp(16px, 2.5vw, 22px); margin-bottom: 14px; }
.od .top { display: flex; align-items: baseline; gap: 10px 16px; flex-wrap: wrap; margin-bottom: 10px; }
.od .num { font-family: ui-monospace, Menlo, monospace; font-weight: 700; font-size: 1em; }
.od .date { font-size: 0.8em; color: var(--ink-faint); }
.od .chip {
  margin-left: auto; font-size: 0.75em; font-weight: 700; letter-spacing: .03em;
  border-radius: 999px; padding: 4px 13px; color: #fff; background: var(--st, var(--ink-faint));
  cursor: default;
}
.od .items { font-size: 0.88em; color: var(--ink-soft); line-height: 1.7; margin: 0 0 4px; }
.od .items b { color: var(--ink); font-weight: 600; }
.od .ttl-row { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; border-top: 1px solid var(--line); margin-top: 10px; padding-top: 10px; }
.od .ttl-row .lbl { font-size: 0.82em; color: var(--ink-faint); }
.od .ttl-row .amt { font-weight: 700; font-size: 1.08em; }
/* เส้นทางสถานะ 6 จุด */
.od .trail { display: flex; align-items: flex-start; margin: 14px 2px 4px; }
.od .step { flex: 1; display: flex; flex-direction: column; align-items: center; gap: 6px; position: relative; }
.od .step i {
  width: 11px; height: 11px; border-radius: 50%; background: var(--line); z-index: 1; flex: none;
  box-shadow: 0 0 0 3px var(--card);
}
.od .step.done i { background: var(--brand); }
.od .step.now i { background: var(--brand); box-shadow: 0 0 0 3px var(--card), 0 0 0 5px rgba(193,95,60,.3); }
.od .step::before {
  content: ""; position: absolute; top: 5px; left: -50%; right: 50%; height: 2px; background: var(--line);
}
.od .step.done::before, .od .step.now::before { background: var(--brand); }
.od .step:first-child::before { display: none; }
.od .step small { font-size: 0.66em; color: var(--ink-faint); line-height: 1.3; text-align: center; }
.od .step.done small, .od .step.now small { color: var(--ink-soft); }
.od .step.now small { font-weight: 700; color: var(--brand); }
@media (max-width: 560px) { .od .step small { display: none; } .od .step.now small { display: block; } }
/* แถวเลขพัสดุ */
.od .track {
  display: flex; align-items: center; gap: 10px; flex-wrap: wrap;
  background: var(--accent-soft); border-radius: 10px; padding: 9px 14px; margin-top: 12px; font-size: 0.86em;
}
.od .track .no { font-family: ui-monospace, Menlo, monospace; font-weight: 700; letter-spacing: .04em; }
.od .track .copy { border: 0; background: none; font: inherit; font-size: 0.86em; font-weight: 600; color: var(--ink-soft); cursor: pointer; padding: 2px 4px; }
.od .track .copy:hover { color: var(--brand); }
.od .track .go { margin-left: auto; color: var(--brand); font-weight: 700; text-decoration: none; white-space: nowrap; }
.od .track button.go { border: 0; background: none; font: inherit; font-size: 1em; cursor: pointer; padding: 2px 0; }
.od .track button.go:disabled { opacity: .5; cursor: wait; }
/* เส้นเวลาพัสดุในหน้าเราเอง — กดดูจากการ์ดออเดอร์ ไม่ต้องเด้งไปเว็บขนส่ง (owner 2026-08-25) */
.od .tl { display: none; background: var(--card); border: 1px solid var(--line); border-radius: 10px; margin-top: 8px; padding: 12px 16px 10px; }
.od .tl.open { display: block; }
.od .tl .tl-head { font-size: 0.78em; font-weight: 700; color: var(--ink-faint); letter-spacing: .02em; margin: 0 0 10px; }
.od .tl .row { position: relative; padding: 0 0 14px 22px; font-size: 0.87em; color: var(--ink-soft); line-height: 1.45; }
.od .tl .row::before {
  content: ""; position: absolute; left: 0; top: 4px; width: 9px; height: 9px;
  border-radius: 50%; background: var(--ink-faint); z-index: 1;
}
.od .tl .row::after {
  content: ""; position: absolute; left: 3.5px; top: 15px; bottom: -2px; width: 2px; background: var(--line);
}
.od .tl .row:last-of-type { padding-bottom: 4px; }
.od .tl .row:last-of-type::after { display: none; }
/* แถวบนสุด = เหตุการณ์ล่าสุด — เด่นสุด */
.od .tl .row:first-of-type { color: var(--ink); font-weight: 600; }
.od .tl .row:first-of-type::before { background: var(--brand); box-shadow: 0 0 0 3px rgba(193, 95, 60, .18); }
.od .tl .row small { display: block; font-weight: 400; font-size: 0.8em; color: var(--ink-faint); margin-top: 2px; }
.od .tl .ext { display: inline-block; font-size: 0.82em; color: var(--brand); font-weight: 700; text-decoration: none; margin-top: 8px; }
