/* ==== base: style ==== */
:root { --green-950: #003f32; --green-900: #005241; --green-800: #00694a; --green-700: #008b57; --green-600: #008b57; --green-500: #16b873; --green-100: #dcf7e9; --green-50: #f2fbf6; --cream: #fffdf8; --yellow: #ffd42a; --ink: #0b4038; --text: #445c59; --muted: #55706b; --line: #dce9e5; --white: #ffffff; --shadow: 0 18px 45px rgba(0, 82, 65, .11); --shadow-soft: 0 8px 24px rgba(0, 82, 65, .08); --radius: 16px; --container: 1200px; --kkn-card-radius: 18px; --kkn-card-border: #dce9e5; --kkn-card-shadow: 0 12px 30px rgba(0, 70, 54, .075); --kkn-card-shadow-hover: 0 18px 42px rgba(0, 70, 54, .13); --kkn-image-bg: #f2fbf6; --tb-h: 36px; --hd-h: 76px; --chrome-h: calc(var(--tb-h) + var(--hd-h)); --kk-shadow: 0 12px 32px rgba(0, 82, 65, .10); --kk-shadow-lg: 0 20px 44px rgba(0, 82, 65, .16); --amber: #ffb800; --amber-100: #fff1c7; --amber-900: #6b4300; --danger: #c0392b; --green-300: #9fd9bc; --green-400: #6fe0ac; --line-strong: #cfe0da; --line-brand: #06c755; /* MASTER tokens: see site.css MASTER section */
    --select-bg: var(--green-50); /* พื้นตัวเลือกที่กดแล้ว */
    --select-line: var(--green-700); /* เส้นตัวเลือกที่กดแล้ว (บาง 1px) */
    --hover-bg: #f8fcfa; /* พื้นตอนเอาเมาส์ชี้ */
    --hover-line: var(--green-300); --card-radius: var(--kkn-card-radius); --card-shadow: var(--kkn-card-shadow); }
*,
*::before,
*::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 108px; }
body { margin: 0; color: var(--text); background: var(--white); font-family: "Prompt", Tahoma, sans-serif; font-size: 15px; line-height: 1.68; overflow-x: hidden; }
body.menu-open,
body.modal-open { overflow: hidden; }
a { color: inherit; text-decoration: none; }
button,
input { font: inherit; }
button { color: inherit; }
img { display: block; max-width: 100%; height: auto; }
h1,
h2,
h3,
p { margin-top: 0; }
h1,
h2,
h3 { color: var(--ink); line-height: 1.25; }
.container { width: min(var(--container), calc(100% - 40px)); margin-inline: auto; }
.section { padding: 66px 0; }
.svg-sprite { position: absolute; width: 0; height: 0; overflow: hidden; }
svg { width: 1.15em; height: 1.15em; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.skip-link { position: fixed; left: 15px; top: -100px; z-index: 10000; padding: 9px 16px; color: white; background: var(--green-950); border-radius: 0 0 8px 8px; }
.skip-link:focus { top: 0; }
.eyebrow { display: inline-block; margin-bottom: 8px; color: var(--green-600); font-size: 13px; font-weight: 700; letter-spacing: .04em; }
.button { display: inline-flex; min-height: 46px; align-items: center; justify-content: center; gap: 8px; padding: 10px 20px; border: 1px solid transparent; border-radius: 10px; font-weight: 600; transition: transform .2s ease, box-shadow .2s ease, background .2s ease, color .2s ease, border-color .2s ease; }
.button:hover { transform: translateY(-3px); box-shadow: 0 10px 22px rgba(0, 90, 60, .16); }
.button-primary { color: white; background: linear-gradient(135deg, var(--green-600), var(--green-800)); }
.button-primary:hover { background: linear-gradient(135deg, var(--green-500), var(--green-800)); }
.section-heading { max-width: 700px; margin: 0 auto 30px; text-align: center; }
.section-heading h2 { margin-bottom: 5px; font-size: clamp(25px, 2.4vw, 34px); letter-spacing: -.02em; }
.section-heading p { margin-bottom: 0; color: var(--muted); }
/* Header */
.site-header { position: sticky; z-index: 1000; top: 0; width: 100%; background: rgba(255,255,255,.96); border-bottom: 1px solid rgba(0,82,65,.09); backdrop-filter: blur(10px); transition: box-shadow .25s ease; }
.site-header.scrolled { box-shadow: 0 6px 24px rgba(0,70,54,.1); }
.header-inner { display: grid; min-height: 76px; grid-template-columns: 150px 1fr auto; align-items: center; gap: 24px; }
.brand { justify-self: start; }
.brand img { width: 125px; height: 55px; object-fit: contain; }
.primary-nav { display: flex; height: 76px; align-items: stretch; justify-content: center; gap: 26px; }
.primary-nav a { position: relative; display: flex; align-items: center; color: var(--ink); font-size: 14px; font-weight: 500; white-space: nowrap; }
.primary-nav a::after { position: absolute; right: 0; bottom: 0; left: 0; height: 3px; content: ""; background: var(--green-600); transform: scaleX(0); transition: transform .2s ease; }
.primary-nav a:hover::after,
.primary-nav a.active::after { transform: scaleX(1); }
.header-actions { display: flex; align-items: center; gap: 8px; }
.icon-button { position: relative; display: grid; width: 38px; height: 38px; padding: 0; place-items: center; color: var(--green-800); background: transparent; border: 0; border-radius: 50%; cursor: pointer; transition: background .2s ease; }
.icon-button:hover { background: var(--green-50); }
.icon-button svg { width: 21px; height: 21px; }
.cart-button span { position: absolute; top: 0; right: 0; display: grid; width: 17px; height: 17px; place-items: center; color: white; background: var(--green-600); border: 2px solid white; border-radius: 50%; font-size: 8px; }
.header-quote { min-height: 42px; margin-left: 4px; padding: 8px 16px; font-size: 13px; }
.menu-toggle { display: none; width: 42px; height: 42px; padding: 9px; background: transparent; border: 0; cursor: pointer; }
.menu-toggle span { display: block; width: 24px; height: 2px; margin: 5px 0; background: var(--green-900); transition: .25s ease; }
.search-panel { position: fixed; z-index: 2000; inset: 0; display: grid; padding: 24px; place-items: start center; background: rgba(0,55,43,.76); backdrop-filter: blur(7px); }
.search-panel[hidden] { display: none; }
.search-box { position: relative; width: min(680px, 100%); margin-top: 15vh; padding: 35px; background: white; border-radius: 14px; box-shadow: var(--shadow); }
.search-box label { display: block; margin-bottom: 12px; color: var(--ink); font-size: 24px; font-weight: 700; }
.search-box > div { display: flex; gap: 8px; }
.search-box input { width: 100%; min-width: 0; height: 48px; padding: 0 15px; border: 1px solid var(--line); border-radius: 10px; outline: 0; }
.search-box input:focus { border-color: var(--green-500); box-shadow: 0 0 0 3px rgba(0,139,87,.14); }
.search-box > div button { display: inline-flex; align-items: center; gap: 7px; padding: 0 18px; color: white; background: var(--green-700); border: 0; border-radius: 10px; cursor: pointer; }
.search-close { position: absolute; top: 10px; right: 13px; padding: 3px 10px; color: var(--green-900); background: transparent; border: 0; font-size: 28px; cursor: pointer; }
/* Hero */
.hero { position: relative; min-height: 585px; overflow: hidden; background: radial-gradient(circle at 85% 8%, rgba(252,218,57,.16), transparent 24%), linear-gradient(105deg, var(--green-50) 0%, #fbfff9 48%, var(--green-100) 100%); }
.hero::before { position: absolute; right: 0; bottom: 0; left: 0; height: 130px; content: ""; background: linear-gradient(170deg, transparent 45%, rgba(255,255,255,.84) 46%); }
/* School hero v2 — composition matched to the supplied reference */
/* Generic product illustrations */
/* Promotions */
/* Products and portfolio */
.products { background: #fff; }
.badge { position: absolute; z-index: 3; top: 19px; left: 18px; padding: 3px 10px; color: white; border-radius: 5px; font-size: 12px; font-weight: 600; }
.portfolio { padding-top: 34px; }
/* Process, about, clients, reviews */
.clients { padding-bottom: 48px; }
.clients .section-heading { margin-bottom: 20px; }
.reviews { padding-top: 30px; background: #ffffff; }
/* CTA and footer */
.site-footer strong { color: white; }
.qr-line { box-shadow: inset 0 0 0 2px #008e58; }
.back-to-top { position: fixed; z-index: 900; right: 22px; bottom: 22px; display: grid; width: 48px; height: 48px; padding: 0; place-items: center; color: white; background: var(--green-600); border: 2px solid rgba(255,255,255,.75); border-radius: 50%; box-shadow: 0 10px 26px rgba(0,61,44,.3); font-size: 24px; cursor: pointer; opacity: 0; pointer-events: none; transform: translateY(15px); transition: .25s ease; }
.back-to-top.visible { opacity: 1; pointer-events: auto; transform: translateY(0); }
.toast { position: fixed; z-index: 3000; right: 20px; bottom: 84px; max-width: 320px; padding: 12px 17px; color: white; background: var(--green-950); border-radius: 10px; box-shadow: var(--shadow); opacity: 0; pointer-events: none; transform: translateY(10px); transition: .25s ease; }
.toast.show { opacity: 1; transform: translateY(0); }
/* Motion */
.reveal { opacity: 0; transform: translateY(18px); transition: opacity .55s ease, transform .55s ease; }
.reveal.in-view { opacity: 1; transform: translateY(0); }
@media (prefers-reduced-motion: reduce) {
    html { scroll-behavior: auto; }
    *,
    *::before,
    *::after { scroll-behavior: auto !important; animation-duration: .01ms !important; transition-duration: .01ms !important; }
    .reveal { opacity: 1; transform: none; }
}
/* Tablet */
@media (max-width: 1120px) {
    .header-inner { grid-template-columns: 120px 1fr auto; gap: 12px; }
    .primary-nav { gap: 16px; }
    .primary-nav a { font-size: 12px; }
    .header-actions .icon-button:nth-child(2) { display: none; }
    .header-quote { padding-inline: 12px; }
}
@media (max-width: 900px) {
    .header-inner { min-height: 68px; grid-template-columns: 1fr auto auto; }
    .brand img { width: 99px; height: auto; }
    .menu-toggle { display: block; grid-column: 3; }
    .menu-toggle.open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
    .menu-toggle.open span:nth-child(2) { opacity: 0; }
    .menu-toggle.open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }
    .primary-nav { position: fixed; z-index: 1001; top: 98px; right: 0; bottom: 0; display: flex; width: min(340px, 88vw); height: auto; padding: 20px; align-items: stretch; justify-content: flex-start; flex-direction: column; gap: 0; background: white; box-shadow: -15px 15px 35px rgba(0,60,46,.16); transform: translateX(105%); transition: transform .28s ease; }
    .primary-nav.open { transform: translateX(0); }
    .primary-nav a { min-height: 52px; padding: 0 9px; border-bottom: 1px solid var(--line); font-size: 14px; }
    .primary-nav a::after { right: auto; width: 3px; height: 100%; transform: scaleY(0); }
    .primary-nav a:hover::after,
    .primary-nav a.active::after { transform: scaleY(1); }
    .header-actions { grid-column: 2; grid-row: 1; }
    .header-actions .icon-button:nth-child(2),
    .header-actions .cart-button { display: grid; }
    .header-quote { display: none; }
    .hero { min-height: auto; }
}
/* Mobile 390px */
@media (max-width: 620px) {
    body { font-size: 14px; }
    .container { width: min(100% - 28px, var(--container)); }
    .section { padding: 48px 0; }
    .header-inner { min-height: 64px; }
    .primary-nav { top: 96px; }
    .header-actions { gap: 0; }
    .header-actions .icon-button:nth-child(2) { display: none; }
    .hero::before { height: 65px; }
    .section-heading { margin-bottom: 22px; }
    .section-heading h2 { font-size: 24px; }
    .section-heading p { font-size: 12px; }
    .portfolio { padding-top: 15px; }
    .search-box { margin-top: 8vh; padding: 28px 18px 18px; }
    .search-box label { font-size: 21px; }
    .search-box > div { flex-direction: column; }
    .search-box > div button { height: 46px; justify-content: center; }
}
@media (max-width: 380px) {
    .header-actions .cart-button { display: none; }
}
/* ==== base: revision ==== */
/* Kornkanok homepage — approved September 2026 revision */
/* Promotion: one panoramic banner + one square carousel */
.promo-slide { position:absolute; inset:0; opacity:0; pointer-events:none; transition:opacity .55s ease; }
.promo-slide.is-active { opacity:1; pointer-events:auto; }
.promo-slide::after { position:absolute; inset:0; content:""; background:linear-gradient(to top,rgba(0,48,38,.82),transparent 58%); }
.promo-slide img { width:100%; height:100%; object-fit:cover; }
.promo-slide div { position:absolute; z-index:2; right:26px; bottom:35px; left:26px; color:white; }
.promo-slide small { color:var(--line-strong); font-weight:700; }
.promo-slide h3 { margin:3px 0 0; font-size:24px; line-height:1.25; }
.promo-dots { position:absolute; z-index:4; bottom:14px; left:50%; display:flex; gap:7px; transform:translateX(-50%); }
.promo-dots button { width:7px; height:7px; padding:0; background:rgba(255,255,255,.55); border:0; border-radius:50%; cursor:pointer; }
.promo-dots button.is-active { width:23px; background:#fff; border-radius:10px; }
/* Real photography replaces the previous drawn product icons. */
/* Portfolio: two complete rows of real samples. */
/* Modern process cards with crisp inline SVG artwork. */
.process { padding-top: 40px; padding-block:72px; background:linear-gradient(180deg,#fff,var(--green-50)); }
/* New about block. */
.about { padding-block:82px; background:linear-gradient(120deg,var(--green-50),#ffffff 62%,var(--green-50)); }
/* Roomy, readable footer. */
.site-footer { color: rgba(255,255,255,.75); background:linear-gradient(115deg,var(--green-950),var(--green-900) 57%,var(--green-950)); }
.site-footer h2 { color: white; margin-bottom:17px; font-size:15px; }
.site-footer p { margin-bottom: 8px; font-size:12px; line-height:1.85; }
@media (max-width:540px) {
    .promo-slide h3 { font-size:21px; }
    .about { padding-block:58px; }
}
/* ===== เมนูย่อย (Dropdown) สำหรับ "ติดต่อเรา" ===== */
.nav-item.has-dropdown { position: relative; display: flex; align-items: stretch; }
.nav-item.has-dropdown .nav-parent-link { position: relative; display: flex; align-items: center; color: var(--ink); font-size: 14px; font-weight: 500; white-space: nowrap; }
.nav-item.has-dropdown .nav-parent-link::after { position: absolute; right: 0; bottom: 0; left: 0; height: 3px; content: ""; background: var(--green-600); transform: scaleX(0); transition: transform .2s ease; }
.nav-item.has-dropdown:hover .nav-parent-link::after,
.nav-item.has-dropdown .nav-parent-link.active::after { transform: scaleX(1); }
.nav-dropdown-toggle { display: flex; align-items: center; padding: 0 2px 0 4px; color: var(--ink); background: transparent; border: 0; cursor: pointer; }
.nav-dropdown { position: absolute; top: 100%; left: 0; z-index: 50; min-width: 190px; padding: 8px 0; background: #fff; border-radius: 10px; box-shadow: 0 18px 40px rgba(0,60,46,.16); opacity: 0; visibility: hidden; transform: translateY(8px); transition: opacity .18s ease, transform .18s ease, visibility .18s ease; }
.nav-item.has-dropdown:hover .nav-dropdown,
.nav-item.has-dropdown.open .nav-dropdown { opacity: 1; visibility: visible; transform: translateY(0); }
.nav-dropdown a { display: block; padding: 10px 18px; font-size: 14px; color: var(--ink); white-space: nowrap; }
.nav-dropdown a::after { content: none; }
.nav-dropdown a:hover,
.nav-dropdown a.active { color: var(--green-600); background: var(--green-50); }
@media (max-width: 900px) {
    .nav-item.has-dropdown { flex-direction: column; align-items: stretch; }
    .nav-item.has-dropdown .nav-parent-link { flex: 1; min-height: 52px; padding: 0 9px; border-bottom: 1px solid var(--line); font-size: 14px; }
    .nav-item.has-dropdown .nav-parent-link::after { right: auto; width: 3px; height: 100%; transform: scaleY(0); }
    .nav-item.has-dropdown:hover .nav-parent-link::after,
    .nav-item.has-dropdown .nav-parent-link.active::after { transform: scaleY(1); }
    .nav-dropdown-toggle { position: absolute; top: 0; right: 0; width: 52px; height: 52px; justify-content: center; border-bottom: 1px solid var(--line); }
    .nav-dropdown { position: static; min-width: 0; padding: 0; background: var(--green-50); border-radius: 0; box-shadow: none; opacity: 1; visibility: visible; transform: none; max-height: 0; overflow: hidden; transition: max-height .25s ease; }
    .nav-item.has-dropdown.open .nav-dropdown { max-height: 220px; }
    .nav-dropdown a { min-height: 46px; padding: 0 24px; display: flex; align-items: center; border-bottom: 1px solid var(--line); font-size: 13px; }
}
/* ==== base: pages ==== */
.web-form { padding:30px; background:#fff; border:1px solid var(--line); border-radius:22px; }
.field { display:grid; gap:6px; }
.field.full { grid-column:1/-1; }
.field label { font-size:12px; font-weight:600; }
.field input,
.field select,
.field textarea { min-height:46px; padding:10px 12px; border:1px solid var(--line); border-radius:10px; font:13px "Prompt",Tahoma,sans-serif; }
.field textarea { min-height:120px; }
.web-form button { margin-top:17px; border:0; }
.client-logo-wall { display:grid; grid-template-columns:repeat(9,1fr); gap:11px; }
.client-logo-card { display:grid; min-height:115px; place-items:center; padding:14px; background:#fff; border:1px solid var(--line); border-radius:14px; }
.client-logo-card img { width:100%; height:82px; object-fit:contain; }
@media(max-width:900px) {
    .client-logo-wall { grid-template-columns:repeat(6,1fr); }
}
@media(max-width:700px) {
    .field.full { grid-column:1; }
    .client-logo-wall { grid-template-columns:repeat(4,1fr); }
}
@media(max-width:480px) {
    .client-logo-wall { grid-template-columns:repeat(3,1fr); }
    .client-logo-card { min-height:90px; padding:8px; }
    .client-logo-card img { height:68px; }
}
