/* ============================================================
   Web Hosting Thailand — 2026 redesign
   Palette: petrol ink / teal / Thai marigold on porcelain
   Type: Kanit (display) · IBM Plex Sans (body) · IBM Plex Mono (specs)
   ============================================================ */

:root {
  --ink: oklch(24% 0.045 230);          /* deep petrol */
  --ink-soft: oklch(38% 0.04 225);
  --teal: oklch(48% 0.09 190);           /* primary */
  --teal-deep: oklch(38% 0.08 195);
  --gold: oklch(72% 0.14 75);            /* Thai marigold */
  --gold-deep: oklch(62% 0.14 70);
  --paper: oklch(98.5% 0.004 190);       /* porcelain */
  --paper-2: oklch(96.5% 0.008 190);
  --line: oklch(90% 0.012 200);
  --text: oklch(30% 0.03 225);
  --text-soft: oklch(45% 0.025 225);
  --white: #fff;
  --green: oklch(50% 0.14 152);            /* CTA green */
  --radius: 10px;
  --shadow: 0 1px 2px oklch(24% 0.045 230 / .06), 0 8px 24px oklch(24% 0.045 230 / .07);
  --display: "Kanit", "IBM Plex Sans", sans-serif;
  --body: "IBM Plex Sans", system-ui, sans-serif;
  --mono: "IBM Plex Mono", ui-monospace, monospace;
}

* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation: none !important; transition: none !important; }
}

body {
  font-family: var(--body);
  color: var(--text);
  background: var(--paper);
  line-height: 1.65;
  font-size: clamp(1rem, .95rem + .2vw, 1.0625rem);
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3 { font-family: var(--display); color: var(--ink); line-height: 1.15; text-wrap: balance; }
h1 { font-size: clamp(2rem, 1.4rem + 2.8vw, 3.4rem); font-weight: 600; letter-spacing: -.01em; }
h2 { font-size: clamp(1.5rem, 1.2rem + 1.4vw, 2.2rem); font-weight: 600; }
h3 { font-size: 1.2rem; font-weight: 500; }
p { max-width: 68ch; }
a { color: var(--teal-deep); text-decoration-thickness: 1px; text-underline-offset: 3px; }
a:hover { color: var(--gold-deep); }
:focus-visible { outline: 2px solid var(--gold-deep); outline-offset: 2px; border-radius: 2px; }
img { max-width: 100%; height: auto; }

.wrap { max-width: 1120px; margin-inline: auto; padding-inline: clamp(1rem, 4vw, 2rem); }

/* ---------- eyebrow / kicker ---------- */
.kicker {
  font-family: var(--mono); font-size: .78rem; letter-spacing: .14em;
  text-transform: uppercase; color: var(--teal);
  display: inline-flex; align-items: center; gap: .6rem; margin-bottom: 1rem;
}
.kicker::before { content: ""; width: 2rem; height: 2px; background: var(--gold); }

/* ---------- header ---------- */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: rgb(255 255 255 / .88); backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--line);
}
.nav-bar { display: flex; align-items: center; gap: 1.5rem; height: 64px; }
.brand { display: flex; align-items: center; gap: .7rem; text-decoration: none; margin-right: auto; }
/* Flag circle is the left ~150px of the 800x150 wordmark image; crop it with object-fit */
.brand img { flex: none; width: 46px; height: 46px; object-fit: cover; object-position: left center; }
.brand-name { font-family: var(--display); font-weight: 600; font-size: 1.55rem; color: oklch(50% 0.2 25); line-height: 1.05; }
.brand-name small { display: block; font-family: var(--mono); font-weight: 400; font-size: .62rem; letter-spacing: .18em; color: var(--teal); text-transform: uppercase; }

.nav-menu { display: flex; gap: .25rem; list-style: none; align-items: center; }
.nav-menu > li { position: relative; }
.nav-menu a, .nav-menu button {
  font-family: var(--body); font-size: .92rem; font-weight: 500; color: var(--ink-soft);
  text-decoration: none; padding: .55rem .8rem; border-radius: 8px; display: block;
  background: none; border: 0; cursor: pointer;
}
.nav-menu > li > a:hover, .nav-menu > li > button:hover { background: var(--paper-2); color: var(--ink); }
.nav-menu li:has(.dropdown) > button::after { content: " ▾"; font-size: .7em; color: var(--teal); }
/* Dropdown: no hover gap (padding bridge instead of margin), animated open */
.dropdown {
  position: absolute; top: 100%; left: 0; min-width: 230px;
  padding: .5rem; margin: 0; list-style: none;
  background: var(--white); border: 1px solid var(--line); border-radius: var(--radius);
  box-shadow: var(--shadow);
  visibility: hidden; opacity: 0; transform: translateY(8px);
  transition: opacity .18s ease, transform .18s ease, visibility 0s linear .18s;
}
/* invisible hover bridge covering the gap above the panel */
.dropdown::before { content: ""; position: absolute; left: 0; right: 0; top: -14px; height: 14px; }
.nav-menu > li:has(.dropdown) { padding-bottom: 0; }
.nav-menu li:hover > .dropdown, .nav-menu li:focus-within > .dropdown {
  visibility: visible; opacity: 1; transform: translateY(4px);
  transition: opacity .18s ease, transform .18s ease, visibility 0s;
}
@media (prefers-reduced-motion: reduce) { .dropdown { transition: none; } }
.dropdown a { padding: .5rem .7rem; border-radius: 6px; font-weight: 400; }
.dropdown a:hover { background: var(--paper-2); color: var(--teal-deep); }
.dropdown .dd-label { font-family: var(--mono); font-size: .68rem; letter-spacing: .12em; text-transform: uppercase; color: var(--text-soft); padding: .6rem .7rem .2rem; }

.btn {
  display: inline-block; font-family: var(--display); font-weight: 500; font-size: .95rem;
  padding: .6rem 1.3rem; border-radius: 999px; text-decoration: none; border: 1.5px solid transparent;
  transition: transform .15s ease, box-shadow .15s ease;
}
.btn-primary { background: var(--teal-deep); color: var(--white); }
.btn-primary:hover { background: var(--ink); color: var(--white); transform: translateY(-1px); box-shadow: var(--shadow); }
.btn-ghost { border-color: var(--teal-deep); color: var(--teal-deep); }
.btn-ghost:hover { border-color: var(--gold-deep); color: var(--gold-deep); }
.btn-gold { background: var(--gold); color: var(--ink); }
.btn-gold:hover { background: var(--gold-deep); color: var(--ink); transform: translateY(-1px); box-shadow: var(--shadow); }

.btn-green, .nav-menu .btn-green {
  background: var(--green); color: #fff; padding: .55rem 1.2rem;
  border-radius: 999px; font-family: var(--display); font-weight: 500;
}
.btn-green:hover, .nav-menu .btn-green:hover {
  background: oklch(42% 0.13 152); color: #fff; transform: translateY(-1px); box-shadow: var(--shadow);
}

.nav-toggle { display: none; }

@media (max-width: 900px) {
  .nav-toggle {
    display: block; background: none; border: 1px solid var(--line); border-radius: 8px;
    font-size: 1.3rem; line-height: 1; padding: .35rem .6rem; color: var(--ink); cursor: pointer;
  }
  .nav-menu {
    display: none; position: absolute; top: 64px; left: 0; right: 0;
    flex-direction: column; align-items: stretch; gap: 0;
    background: var(--white); border-bottom: 1px solid var(--line); padding: .75rem 1rem 1.25rem;
    max-height: calc(100dvh - 64px); overflow-y: auto;
  }
  .nav-menu.open { display: flex; }
  .dropdown { position: static; display: block; border: 0; box-shadow: none; padding: 0 0 0 .75rem; }
  .nav-cta { margin-top: .5rem; }
}

/* ---------- hero ---------- */
.hero {
  position: relative; overflow: hidden;
  background:
    radial-gradient(1200px 500px at 85% -10%, oklch(48% 0.09 190 / .10), transparent 60%),
    radial-gradient(900px 400px at 0% 110%, oklch(72% 0.14 75 / .12), transparent 60%),
    var(--paper);
  border-bottom: 1px solid var(--line);
}
.hero-weave { position: absolute; inset: 0; pointer-events: none; opacity: .5; }
.hero-inner { position: relative; padding-block: clamp(3.5rem, 9vw, 6.5rem); max-width: 780px; }
.hero-grid {
  position: relative; display: grid; grid-template-columns: 1.05fr .95fr;
  gap: clamp(2rem, 5vw, 4rem); align-items: center;
  padding-block: clamp(3rem, 7vw, 5.5rem);
}
.hero-grid .hero-inner { padding-block: 0; max-width: none; }
.hero-visual { position: relative; min-height: 380px; }
.hero-visual .img-main {
  width: 88%; aspect-ratio: 4 / 3.4; object-fit: cover; border-radius: 14px;
  box-shadow: 0 20px 50px oklch(24% 0.045 230 / .25);
  border: 4px solid #fff;
}
.hero-visual .img-sub {
  position: absolute; right: 0; bottom: -1.75rem; width: 46%;
  aspect-ratio: 1 / 1; object-fit: cover; border-radius: 12px;
  border: 4px solid #fff; box-shadow: 0 14px 34px oklch(24% 0.045 230 / .3);
}
.hero-visual::before {
  content: ""; position: absolute; inset: -1.25rem auto auto -1.25rem;
  width: 42%; aspect-ratio: 1; border-radius: 14px;
  background: repeating-linear-gradient(45deg, oklch(72% .14 75 / .5) 0 2px, transparent 2px 10px);
  z-index: -1;
}
.hero-visual .img-badge {
  position: absolute; left: -1rem; bottom: 2.5rem; background: #fff;
  border-radius: 10px; box-shadow: var(--shadow); border: 1px solid var(--line);
  padding: .7rem 1rem; font-family: var(--mono); font-size: .72rem;
  letter-spacing: .08em; text-transform: uppercase; color: var(--teal-deep);
}
.hero-visual .img-badge strong { display: block; font-family: var(--display); font-size: 1.15rem; letter-spacing: 0; color: var(--ink); }
@media (max-width: 900px) {
  .hero-grid { grid-template-columns: 1fr; }
  .hero-visual { min-height: 0; margin-top: .5rem; }
  .hero-visual .img-sub { bottom: -1rem; }
}
.hero p.lede { font-size: clamp(1.05rem, 1rem + .5vw, 1.25rem); color: var(--text-soft); margin-top: 1.25rem; }
.hero-actions { display: flex; flex-wrap: wrap; gap: .75rem; margin-top: 2rem; }
.hero-facts { display: flex; flex-wrap: wrap; gap: 1.75rem 2.5rem; margin-top: 3rem; }
.fact .fact-n { font-family: var(--display); font-weight: 600; font-size: 1.5rem; color: var(--teal-deep); }
.fact .fact-l { font-family: var(--mono); font-size: .72rem; letter-spacing: .1em; text-transform: uppercase; color: var(--text-soft); }

/* ---------- sections ---------- */
.section { padding-block: clamp(3rem, 7vw, 5.5rem); }
.section.alt { background: var(--paper-2); border-block: 1px solid var(--line); }
.section-head { max-width: 720px; margin-bottom: clamp(1.75rem, 4vw, 3rem); }
.section-head p { color: var(--text-soft); margin-top: .75rem; }

.grid-3 { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 1.25rem; }
.grid-2 { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 1.5rem; }

.card {
  background: var(--white); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 1.5rem; position: relative;
}
.card h3 { margin-bottom: .5rem; }
.card p { font-size: .95rem; color: var(--text-soft); }
.card .card-link { display: inline-block; margin-top: .8rem; font-weight: 500; font-size: .9rem; }
.card-icon { color: var(--teal); margin-bottom: .9rem; }

/* ---------- spec plates (pricing) ---------- */
.plans { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 1.25rem; align-items: stretch; }
.plate {
  background: var(--white); border: 1px solid var(--line); border-radius: var(--radius);
  overflow: hidden; display: flex; flex-direction: column;
  box-shadow: 0 1px 2px oklch(24% 0.045 230 / .04);
}
.plate-head {
  background: var(--ink); color: var(--white); padding: 1rem 1.25rem;
  border-top: 4px solid var(--gold);
}
.plate-head .plate-name { font-family: var(--mono); font-size: .72rem; letter-spacing: .16em; text-transform: uppercase; color: var(--gold); }
.plate-head .plate-size { font-family: var(--display); font-weight: 600; font-size: 1.6rem; line-height: 1.2; }
.plate.featured .plate-head { background: var(--teal-deep); }
.plate-body { padding: 1.1rem 1.25rem; flex: 1; }
.plate-body ul { list-style: none; font-size: .88rem; }
.plate-body li {
  display: flex; justify-content: space-between; gap: 1rem;
  padding-block: .42rem; border-bottom: 1px dashed var(--line);
}
.plate-body li:last-child { border-bottom: 0; }
.plate-body .k { font-family: var(--mono); font-size: .74rem; letter-spacing: .04em; color: var(--text-soft); text-transform: uppercase; padding-top: .15em; }
.plate-body .v { text-align: right; font-weight: 500; color: var(--ink); }
.plate-foot { padding: 1rem 1.25rem 1.35rem; border-top: 1px solid var(--line); }
.price { font-family: var(--display); font-weight: 600; font-size: 1.7rem; color: var(--ink); }
.price small { font-family: var(--body); font-weight: 400; font-size: .8rem; color: var(--text-soft); }
.plate-foot .btn { width: 100%; text-align: center; margin-top: .8rem; }
.price-note { font-family: var(--mono); font-size: .72rem; color: var(--text-soft); margin-top: 1.25rem; }

/* ---------- tables ---------- */
.table-scroll { overflow-x: auto; border: 1px solid var(--line); border-radius: var(--radius); background: var(--white); }
table.cmp { width: 100%; border-collapse: collapse; font-size: .9rem; min-width: 760px; }
.cmp th, .cmp td { padding: .8rem 1rem; text-align: left; border-bottom: 1px solid var(--line); vertical-align: top; }
.cmp thead th {
  font-family: var(--mono); font-size: .72rem; letter-spacing: .08em; text-transform: uppercase;
  color: var(--text-soft); background: var(--paper-2); position: sticky; top: 0;
}
.cmp tbody tr:last-child td { border-bottom: 0; }
.cmp .us { background: oklch(48% 0.09 190 / .06); font-weight: 500; }
.cmp .yes { color: var(--teal-deep); font-weight: 600; }
.cmp .no { color: var(--text-soft); }

/* ---------- FAQ ---------- */
.faq-item { border: 1px solid var(--line); border-radius: var(--radius); background: var(--white); margin-bottom: .75rem; }
.faq-item summary {
  cursor: pointer; padding: 1rem 1.25rem; font-family: var(--display); font-weight: 500;
  color: var(--ink); list-style: none; display: flex; justify-content: space-between; gap: 1rem;
}
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary::after { content: "+"; color: var(--gold-deep); font-size: 1.3rem; line-height: 1; flex: none; }
.faq-item[open] summary::after { content: "–"; }
.faq-item .faq-a { padding: 0 1.25rem 1.2rem; color: var(--text-soft); font-size: .95rem; }
.faq-item .faq-a p + p { margin-top: .6rem; }

/* ---------- prose pages ---------- */
.prose { max-width: 760px; }
.prose h2 { margin-top: 2.5rem; margin-bottom: .75rem; }
.prose h3 { margin-top: 1.75rem; margin-bottom: .5rem; }
.prose p { margin-bottom: 1rem; }
.prose ul, .prose ol { margin: 0 0 1rem 1.25rem; }
.prose li { margin-bottom: .4rem; }
.prose .callout {
  border-left: 3px solid var(--gold); background: var(--paper-2);
  padding: 1rem 1.25rem; border-radius: 0 var(--radius) var(--radius) 0; margin-block: 1.5rem;
}

/* photos */
figure.photo { margin: 1.75rem 0; }
figure.photo img {
  width: 100%; aspect-ratio: 16 / 7; object-fit: cover;
  border-radius: var(--radius); box-shadow: var(--shadow);
}
figure.photo figcaption {
  font-family: var(--mono); font-size: .72rem; letter-spacing: .06em;
  color: var(--text-soft); margin-top: .5rem;
}
.card > img.card-photo {
  width: calc(100% + 3rem); margin: -1.5rem -1.5rem 1rem;
  aspect-ratio: 16 / 8; object-fit: cover; border-radius: var(--radius) var(--radius) 0 0;
}

/* page hero (inner pages) */
.page-hero { border-bottom: 1px solid var(--line); background:
  radial-gradient(900px 300px at 90% -20%, oklch(48% 0.09 190 / .08), transparent 60%), var(--paper); }
.page-hero .hero-inner { padding-block: clamp(2.5rem, 6vw, 4rem); }
.breadcrumb { font-family: var(--mono); font-size: .75rem; color: var(--text-soft); margin-bottom: 1rem; }
.breadcrumb a { color: var(--teal); text-decoration: none; }
.breadcrumb a:hover { text-decoration: underline; }

/* ---------- CTA band ---------- */
.cta-band { background: var(--ink); color: var(--white); position: relative; overflow: hidden; }
.cta-band .wrap { padding-block: clamp(2.5rem, 6vw, 4rem); display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 1.5rem; position: relative; }
.cta-band h2 { color: var(--white); }
.cta-band p { color: oklch(80% 0.02 220); margin-top: .5rem; }
.cta-band::before {
  content: ""; position: absolute; inset: 0;
  background: radial-gradient(600px 300px at 90% 120%, oklch(72% 0.14 75 / .18), transparent 65%);
}

/* ---------- footer ---------- */
.site-footer {
  position: relative; overflow: hidden;
  background: linear-gradient(160deg, oklch(26% 0.05 225) 0%, oklch(20% 0.045 235) 45%, oklch(24% 0.07 200) 100%);
  border-top: 3px solid var(--gold);
  color: oklch(78% 0.02 220); font-size: .9rem;
}
.site-footer::before {
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background:
    radial-gradient(700px 320px at 8% 0%, oklch(48% 0.09 190 / .18), transparent 60%),
    radial-gradient(600px 300px at 95% 100%, oklch(72% 0.14 75 / .12), transparent 60%);
}
.site-footer > .wrap { position: relative; }
.footer-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); gap: 2rem; padding-block: 3rem 2rem; }
.footer-grid h4 { font-family: var(--mono); font-size: .72rem; letter-spacing: .14em; text-transform: uppercase; color: var(--gold); margin-bottom: .9rem; font-weight: 500; }
.footer-grid a { display: block; color: oklch(82% 0.015 220); text-decoration: none; padding-block: .22rem; }
.footer-grid a:hover { color: var(--gold); }
.footer-co { grid-column: 1 / -1; border-top: 1px solid oklch(35% 0.03 225); padding-top: 1.5rem; display: flex; flex-wrap: wrap; gap: 1rem 3rem; justify-content: space-between; }
.footer-co address { font-style: normal; line-height: 1.7; }
.footer-legal { padding-block: 1rem 1.5rem; font-family: var(--mono); font-size: .72rem; color: oklch(60% 0.02 220); display: flex; flex-wrap: wrap; gap: 1rem; justify-content: space-between; }
.footer-legal a { color: inherit; }

/* ---------- forms ---------- */
.form-grid { display: grid; gap: 1rem; max-width: 640px; }
.form-grid label { font-weight: 500; font-size: .9rem; color: var(--ink); display: block; margin-bottom: .3rem; }
.form-grid input, .form-grid textarea, .form-grid select {
  width: 100%; font: inherit; padding: .65rem .8rem; border: 1px solid var(--line);
  border-radius: 8px; background: var(--white); color: var(--text);
}
.form-grid input:focus, .form-grid textarea:focus { outline: 2px solid var(--teal); border-color: var(--teal); }
.notice-ok, .notice-err { padding: 1rem 1.25rem; border-radius: var(--radius); margin-bottom: 1.5rem; }
.notice-ok { background: oklch(48% 0.09 190 / .1); border: 1px solid var(--teal); color: var(--teal-deep); }
.notice-err { background: oklch(60% 0.15 30 / .08); border: 1px solid oklch(55% 0.15 30); color: oklch(45% 0.15 30); }
.hp-field { position: absolute; left: -9999px; }

