/* Tawan Chay — base styles */

:root {
  --bg: #faf6f0;
  --bg-soft: #f0e8dc;
  --bg-panel: #ffffff;
  --bg-deep: #e8dfd2;
  --card: #ffffff;
  --text: #1a2b22;
  --muted: #4f5851;
  --gold: #b47a18;
  --gold-hover: #94610f;
  --gold-light: #c9922e;
  --green: #1e3429;
  --green-mid: #284638;
  --green-light: #3a5c48;
  --button-gold: #b47a18;
  --button-gold-dark: #94610f;
  --button-green: #183b2c;
  --border: rgba(30, 52, 41, 0.1);
  --border-strong: rgba(30, 52, 41, 0.16);
  --shadow-sm: 0 2px 10px rgba(30, 52, 41, 0.06);
  --shadow: 0 14px 40px rgba(30, 52, 41, 0.1);
  --shadow-lg: 0 24px 60px rgba(30, 52, 41, 0.14);
  --radius: 14px;
  --radius-lg: 20px;
  --radius-xl: 28px;
  --container: 1180px;
  --header-h: 80px;
  --mobile-header-height: var(--header-h);
  --font-display: "Playfair Display", Georgia, "Times New Roman", serif;
  --font-body: "Plus Jakarta Sans", system-ui, sans-serif;
}

*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
}

html, body {
  max-width: 100%;
  overflow-x: hidden;
}

body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-body), "Noto Sans Thai", system-ui, sans-serif;
  font-size: 1rem;
  line-height: 1.65;
  min-height: 100vh;
  min-height: 100svh;
  display: flex;
  flex-direction: column;
  -webkit-font-smoothing: antialiased;
}

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

main {
  flex: 1;
}

img, svg {
  display: block;
  max-width: 100%;
}

a {
  color: var(--green);
  transition: color 0.2s;
}

a:hover {
  color: var(--gold);
}

address {
  font-style: normal;
}

.skip-link {
  position: absolute;
  top: 0.75rem;
  left: 0.75rem;
  z-index: 10000;
  padding: 0.55rem 0.85rem;
  border-radius: var(--radius);
  background: var(--green);
  color: #fff;
  font-size: 0.875rem;
  font-weight: 600;
  text-decoration: none;
  transform: translateY(-150%);
  transition: transform 0.2s ease;
}

.skip-link:focus {
  transform: translateY(0);
}

.container {
  width: min(var(--container), 100% - 2rem);
  margin-inline: auto;
}

/* Typography */

h1, h2, h3, h4 {
  font-family: var(--font-body);
  font-weight: 600;
  letter-spacing: -0.02em;
  line-height: 1.2;
  color: var(--green);
}

.display-heading {
  font-family: var(--font-display);
  font-weight: 600;
  letter-spacing: -0.02em;
  line-height: 1.08;
  color: var(--green);
}

.display-heading--light {
  color: #fff;
}

.logo__mark,
.footer-logo__mark {
  max-width: 100%;
}

h1 { font-size: clamp(1.85rem, 3.5vw, 2.65rem); }
h2 { font-size: clamp(1.45rem, 2.4vw, 1.95rem); }
h3 { font-size: clamp(1.05rem, 1.6vw, 1.2rem); }

nav,
button,
.btn,
.eyebrow,
.section-eyebrow,
.section-label,
.footer-heading,
.subtitle {
  font-family: var(--font-body);
}

.lead {
  font-size: 1.08rem;
  color: var(--muted);
  max-width: 52ch;
}

.text-thai {
  font-family: "Noto Sans Thai", var(--font-body), sans-serif;
}

.section-eyebrow,
.eyebrow,
.section-label {
  display: inline-block;
  color: var(--gold);
  font-family: var(--font-body);
  font-size: 0.78rem;
  line-height: 1;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  margin: 0 0 12px;
}

.section {
  padding: clamp(2.5rem, 5vw, 4rem) 0;
}

.section-soft {
  background: var(--bg-soft);
}

.section-intro {
  max-width: 520px;
  margin-bottom: clamp(1.75rem, 3vw, 2.25rem);
}

.section-intro h2 {
  margin-top: 0;
  margin-bottom: 0.5rem;
}

.section-intro > p:not(.section-eyebrow):not(.eyebrow):not(.section-label) {
  color: var(--muted);
  font-size: 1.02rem;
}

.section-intro--light h2 {
  color: rgba(255, 255, 255, 0.92);
}

.section-intro--light > p:not(.section-eyebrow):not(.eyebrow):not(.section-label) {
  color: rgba(255, 255, 255, 0.72);
}

.section-header {
  text-align: left;
  max-width: 58ch;
  margin: 0 0 clamp(1.5rem, 3vw, 2rem);
}

.section-header .lead {
  margin: 0.75rem 0 0;
}

.section-header--left {
  text-align: left;
  margin-left: 0;
  margin-right: 0;
  max-width: 58ch;
}

.section-header--left .lead {
  margin-left: 0;
}

.empty-state {
  text-align: center;
  color: var(--muted);
  max-width: 42ch;
  margin: 0 auto;
}

.divider {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.75rem;
  margin: 1.5rem 0;
  color: var(--gold);
}

.divider::before,
.divider::after {
  content: "";
  height: 1px;
  width: 48px;
  background: linear-gradient(90deg, transparent, rgba(184, 122, 26, 0.35));
}

.divider::before {
  background: linear-gradient(90deg, rgba(184, 122, 26, 0.35), transparent);
}

.divider-diamond {
  width: 8px;
  height: 8px;
  background: var(--gold);
  transform: rotate(45deg);
  opacity: 0.7;
}

/* Page hero (inner pages) */

.inner-page {
  position: relative;
  isolation: isolate;
}

.inner-page > .page-hero + * {
  position: relative;
  overflow: hidden;
}

.inner-page > .page-hero + *::after {
  content: "";
  position: absolute;
  width: 440px;
  height: 440px;
  top: -100px;
  right: -140px;
  background: url('../img/sun-mark.svg') no-repeat center / contain;
  opacity: 0.07;
  transform: rotate(-6deg);
  pointer-events: none;
  z-index: 0;
}

.inner-page > .page-hero + * > .container {
  position: relative;
  z-index: 1;
}

.page-hero {
  padding: clamp(2.25rem, 4vw, 3rem) 0 clamp(2rem, 3.5vw, 2.5rem);
  text-align: left;
  background: linear-gradient(180deg, var(--bg-panel) 0%, var(--bg) 100%);
  border-bottom: 1px solid var(--border);
}

.page-hero__inner {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1.25rem 2.5rem;
}

.page-hero__content {
  flex: 1;
  min-width: 0;
}

.breadcrumbs {
  flex-shrink: 0;
  padding-top: 0.4rem;
}

.breadcrumbs__list {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  align-items: center;
  gap: 0.35rem 0.15rem;
  margin: 0;
  padding: 0;
}

.breadcrumbs__item {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.78rem;
  font-weight: 500;
  line-height: 1.4;
}

.breadcrumbs__sep {
  color: rgba(30, 52, 41, 0.28);
  user-select: none;
}

.breadcrumbs__link {
  color: var(--muted);
  text-decoration: none;
}

.breadcrumbs__link:hover {
  color: var(--gold);
}

.breadcrumbs__current {
  color: var(--green-mid);
  font-weight: 600;
}

.page-hero + .section {
  padding-top: clamp(2.25rem, 4vw, 3rem);
}

.page-hero h1 {
  margin-bottom: 0.35rem;
}

.page-hero .lead {
  margin: 0;
  max-width: 48ch;
}

/* Pattern corners */

.has-pattern {
  position: relative;
}

.has-pattern::before {
  content: "";
  position: absolute;
  top: 0;
  right: 0;
  width: min(280px, 40vw);
  height: min(280px, 40vw);
  background: url("../img/pattern-corner.svg") no-repeat top right / contain;
  opacity: 0.25;
  pointer-events: none;
}

/* Animations */

.fade-in {
  animation: fadeIn 0.6s ease both;
}

@keyframes fadeIn {
  from { opacity: 0; transform: translateY(12px); }
  to   { opacity: 1; transform: translateY(0); }
}

@media (max-width: 768px) {
  .page-hero__inner {
    flex-direction: column;
    gap: 0.85rem;
  }

  .breadcrumbs {
    order: -1;
    width: 100%;
    padding-top: 0;
  }

  .breadcrumbs__list {
    justify-content: flex-start;
  }
}

@media (max-width: 960px) {
  .inner-page > .page-hero + *::after {
    width: 320px;
    height: 320px;
    top: -70px;
    right: -100px;
    opacity: 0.06;
  }
}

@media (max-width: 540px) {
  .section-eyebrow,
  .eyebrow,
  .section-label {
    font-size: 0.72rem;
  }

  .inner-page > .page-hero + *::after {
    display: none;
  }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .fade-in { animation: none; }
  .footer-heart { animation: none; }
}
