:root {
  --ink: #102321;
  --muted: #60706d;
  --teal: #005858;
  --teal-dark: #003f40;
  --lime: #b0b818;
  --lime-bright: #d2dc24;
  --mist: #eaf3f0;
  --paper: #fafcfb;
  --white: #ffffff;
  --line: rgba(0, 88, 88, 0.16);
  --font-display: "Space Grotesk", "IBM Plex Sans Thai", sans-serif;
  --font-body: "IBM Plex Sans Thai", "Space Grotesk", sans-serif;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  color: var(--ink);
  background: var(--paper);
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.6;
  overflow-x: hidden;
}
body.dialog-open, body.is-splashing { overflow: hidden; }
img { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
button { font: inherit; }
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}
.section-shell { width: min(1180px, calc(100% - 48px)); margin-inline: auto; }

.splash-screen {
  position: fixed;
  inset: 0;
  z-index: 1000;
  display: grid;
  place-items: center;
  overflow: hidden;
  background: #ffffff;
  transition: transform 850ms cubic-bezier(.76,0,.24,1), visibility 850ms;
}
.splash-screen.is-leaving { transform: translateY(-100%); visibility: hidden; }
.splash-grid {
  position: absolute;
  inset: 0;
  opacity: .65;
  background-image:
    linear-gradient(rgba(0,88,88,.055) 1px, transparent 1px),
    linear-gradient(90deg, rgba(0,88,88,.055) 1px, transparent 1px);
  background-size: 64px 64px;
  mask-image: radial-gradient(circle at center, black 0%, transparent 72%);
}
.splash-content { position: relative; z-index: 2; width: min(760px, calc(100% - 48px)); text-align: center; }
.splash-logo { width: min(720px, 88vw); margin: 44px auto 52px; opacity: 0; transform: scale(.94); filter: blur(10px); transition: opacity 700ms ease 180ms, transform 900ms cubic-bezier(.2,.75,.2,1) 180ms, filter 700ms ease 180ms; }
.splash-enter { display: inline-flex; align-items: center; gap: 30px; padding: 14px 18px 12px; color: var(--teal); border: 0; border-bottom: 2px solid var(--lime); background: transparent; font: 700 .78rem/1 var(--font-display); letter-spacing: .14em; cursor: pointer; opacity: 0; transform: translateY(12px); transition: opacity 500ms ease 700ms, transform 500ms ease 700ms, background-color 180ms ease; }
.splash-enter:hover { background: var(--mist); }
.splash-enter i { font-style: normal; font-size: 1rem; }
.splash-screen.is-ready .splash-enter { opacity: 1; transform: none; }
.splash-screen.is-ready .splash-logo { opacity: 1; transform: scale(1); filter: blur(0); }
.splash-signal { position: absolute; right: clamp(-360px,-12vw,-140px); bottom: -78px; width: min(720px, 65vw); opacity: .07; transform: rotate(-4deg); mix-blend-mode: multiply; }
.splash-code { position: absolute; left: 28px; bottom: 24px; color: rgba(0,88,88,.58); text-align: left; font: 600 .6rem/1.7 var(--font-display); letter-spacing: .12em; }

.ambient-grid {
  position: fixed;
  inset: 0;
  z-index: -2;
  pointer-events: none;
  opacity: 0.42;
  background-image:
    linear-gradient(rgba(0, 88, 88, 0.04) 1px, transparent 1px),
    linear-gradient(90deg, rgba(0, 88, 88, 0.04) 1px, transparent 1px);
  background-size: 48px 48px;
  mask-image: linear-gradient(to bottom, black, transparent 82%);
}

.site-header {
  position: fixed;
  top: 18px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 50;
  width: min(1180px, calc(100% - 32px));
  min-height: 68px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 32px;
  padding: 10px 12px 10px 20px;
  border: 1px solid rgba(0, 88, 88, 0.12);
  background: rgba(250, 252, 251, 0.84);
  backdrop-filter: blur(20px);
  box-shadow: 0 12px 40px rgba(0, 63, 64, 0.08);
  transition: top 220ms ease, background-color 220ms ease;
}
.site-header.is-scrolled { top: 8px; background: rgba(250, 252, 251, 0.96); }
.brand img { width: 178px; height: 46px; object-fit: contain; object-position: left center; }
.site-nav { display: flex; align-items: center; gap: 30px; font-family: var(--font-display); font-size: 0.9rem; font-weight: 600; }
.site-nav > a:not(.nav-cta) { position: relative; }
.site-nav > a:not(.nav-cta)::after {
  content: "";
  position: absolute;
  left: 0;
  right: 100%;
  bottom: -5px;
  height: 2px;
  background: var(--lime);
  transition: right 180ms ease;
}
.site-nav > a:hover::after { right: 0; }
.nav-cta { padding: 11px 18px; color: var(--white); background: var(--teal); }
.menu-toggle { display: none; border: 0; background: transparent; }

.hero {
  min-height: 100svh;
  padding-top: 148px;
  padding-bottom: 88px;
  display: grid;
  grid-template-columns: 0.92fr 1.08fr;
  align-items: center;
  gap: clamp(48px, 7vw, 96px);
}
.eyebrow, .section-index, .project-meta, .member-role, .dialog-kicker {
  font-family: var(--font-display);
  font-weight: 700;
  letter-spacing: 0.11em;
  font-size: 0.76rem;
}
.eyebrow { display: flex; align-items: center; gap: 10px; color: var(--teal); margin-bottom: 28px; }
.status-dot { width: 9px; height: 9px; border-radius: 50%; background: var(--lime); box-shadow: 0 0 0 6px rgba(176, 184, 24, 0.16); }
.hero h1 {
  margin: 0;
  font-family: var(--font-display);
  font-size: clamp(4.2rem, 8vw, 7.6rem);
  line-height: 0.86;
  letter-spacing: -0.07em;
  font-weight: 650;
}
.hero h1 em { color: var(--teal); font-style: normal; position: relative; }
.hero h1 em::after { content: ""; position: absolute; left: 0.08em; right: -0.02em; bottom: -0.04em; height: 7px; background: var(--lime); }
.hero-lede { max-width: 590px; margin: 36px 0 30px; color: var(--muted); font-size: clamp(1rem, 1.3vw, 1.16rem); }
.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; }
.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 18px;
  min-height: 52px;
  padding: 0 22px;
  border: 1px solid var(--teal);
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 0.92rem;
  transition: transform 180ms ease, box-shadow 180ms ease, color 180ms ease, background-color 180ms ease;
}
.button:hover { transform: translateY(-2px); box-shadow: 0 10px 24px rgba(0, 88, 88, 0.15); }
.button-primary { color: var(--white); background: var(--teal); }
.button-primary:hover { background: var(--teal-dark); }
.button-ghost { color: var(--teal); background: transparent; }
.hero-tags { margin-top: 42px; display: flex; gap: 20px; color: #72827f; font-family: var(--font-display); font-size: 0.68rem; letter-spacing: 0.12em; }
.hero-tags span + span::before { content: "/"; margin-right: 20px; color: var(--lime); }

.hero-visual { position: relative; min-width: 0; }
.visual-frame {
  position: relative;
  min-height: 620px;
  overflow: hidden;
  background: var(--teal-dark);
  clip-path: polygon(0 0, 91% 0, 100% 9%, 100% 100%, 9% 100%, 0 91%);
  box-shadow: 34px 34px 0 var(--mist);
}
.visual-frame::after { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, transparent 50%, rgba(0, 43, 44, 0.78)); }
.visual-frame > img { width: 100%; height: 620px; object-fit: cover; filter: saturate(0.72) contrast(1.04); }
.visual-frame > img { object-position: center; }
.visual-label { position: absolute; z-index: 2; left: 34px; right: 34px; bottom: 28px; display: flex; align-items: end; justify-content: space-between; color: white; font-family: var(--font-display); }
.visual-label span { font-size: 0.7rem; letter-spacing: 0.14em; color: var(--lime-bright); }
.visual-label strong { max-width: 170px; text-align: right; font-size: 1.15rem; line-height: 1.15; }
.frame-corner { position: absolute; z-index: 3; width: 54px; height: 54px; border-color: var(--lime-bright); }
.corner-a { top: 24px; left: 24px; border-top: 2px solid; border-left: 2px solid; }
.corner-b { right: 24px; bottom: 78px; border-right: 2px solid; border-bottom: 2px solid; }
.signal-card { position: absolute; z-index: 4; right: -28px; top: 74px; width: 190px; padding: 15px 16px; background: rgba(255,255,255,.93); border-left: 4px solid var(--lime); box-shadow: 0 14px 32px rgba(0,63,64,.16); backdrop-filter: blur(14px); }
.signal-head { display: flex; justify-content: space-between; font: 700 .61rem/1 var(--font-display); letter-spacing: .08em; color: var(--teal); }
.live-dot { color: #5a6800; }
.signal-bars { display: flex; align-items: end; gap: 5px; height: 35px; margin-top: 12px; }
.signal-bars i { flex: 1; background: var(--teal); animation: pulse 1.8s ease-in-out infinite alternate; }
.signal-bars i:nth-child(1) { height: 20%; }.signal-bars i:nth-child(2) { height: 60%; }.signal-bars i:nth-child(3) { height: 35%; }.signal-bars i:nth-child(4) { height: 82%; background: var(--lime); }.signal-bars i:nth-child(5) { height: 55%; }.signal-bars i:nth-child(6) { height: 70%; }.signal-bars i:nth-child(7) { height: 30%; }
@keyframes pulse { to { opacity: .38; transform: scaleY(.7); transform-origin: bottom; } }

.focus-section, .team-section { padding-block: 120px; }
.section-heading { display: grid; grid-template-columns: 1fr minmax(260px, .44fr); gap: 48px; align-items: end; margin-bottom: 58px; }
.section-index { display: block; margin-bottom: 20px; color: var(--teal); }
.section-heading h2, .contact-panel h2 {
  margin: 0;
  font-family: var(--font-display);
  font-size: clamp(2.7rem, 5.4vw, 5.3rem);
  line-height: .97;
  letter-spacing: -.055em;
}
.section-heading > p { margin: 0 0 8px; color: var(--muted); font-size: 1.05rem; }
.focus-grid { display: grid; grid-template-columns: repeat(3, 1fr); border-top: 1px solid var(--line); border-left: 1px solid var(--line); }
.focus-card { position: relative; min-height: 360px; padding: 34px; border-right: 1px solid var(--line); border-bottom: 1px solid var(--line); background: rgba(255,255,255,.54); transition: background-color 180ms ease, transform 180ms ease; }
.focus-card:hover { transform: translateY(-5px); background: var(--white); }
.card-number { position: absolute; right: 24px; top: 22px; color: var(--lime); font: 700 .78rem/1 var(--font-display); }
.focus-icon { width: 66px; height: 66px; display: grid; place-items: center; margin-bottom: 72px; color: var(--teal); background: var(--mist); }
.focus-icon svg { width: 38px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.focus-card h3 { margin: 0 0 12px; font: 600 1.4rem/1.2 var(--font-display); }
.focus-card p { margin: 0; color: var(--muted); }

.projects-section { padding-block: 120px; color: var(--white); background: var(--teal-dark); position: relative; overflow: hidden; }
.projects-section::before { content: ""; position: absolute; inset: 0; opacity: .24; background-image: radial-gradient(circle at center, rgba(210,220,36,.28) 1px, transparent 1px); background-size: 34px 34px; }
.projects-section .section-shell { position: relative; }
.section-heading-light .section-index, .section-heading-light > p { color: #b6cbc8; }
.projects-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 18px; }
.project-card { min-width: 0; background: #f8fbfa; color: var(--ink); overflow: hidden; cursor: pointer; transition: transform 220ms ease, box-shadow 220ms ease; }
.project-card:hover { transform: translateY(-6px); box-shadow: 0 22px 48px rgba(0,20,20,.26); }
.project-image { position: relative; height: 300px; overflow: hidden; background: #dfeae7; }
.project-image::after { content: ""; position: absolute; inset: 0; box-shadow: inset 0 0 0 1px rgba(255,255,255,.2); pointer-events: none; }
.project-image img { width: 100%; height: 100%; object-fit: cover; transition: transform 600ms cubic-bezier(.2,.65,.2,1), filter 300ms ease; filter: saturate(.8); }
.project-card:hover .project-image img { transform: scale(1.045); filter: saturate(1); }
.project-copy { padding: 28px; }
.project-meta { display: flex; justify-content: space-between; color: var(--teal); margin-bottom: 18px; }
.project-card h3 { margin: 0; max-width: 570px; font: 600 clamp(1.45rem,2.7vw,2.35rem)/1.08 var(--font-display); letter-spacing: -.035em; }
.project-card p { color: var(--muted); max-width: 590px; margin: 18px 0 24px; }
.project-link { display: inline-flex; gap: 12px; align-items: center; padding: 0 0 5px; color: var(--teal); border: 0; border-bottom: 1px solid var(--lime); background: transparent; font-family: var(--font-display); font-weight: 700; cursor: pointer; }
.project-featured { grid-column: 1 / -1; display: grid; grid-template-columns: 1.12fr .88fr; }
.project-featured .project-image { height: 510px; }
.project-featured .project-copy { padding: 44px; display: flex; flex-direction: column; justify-content: center; }
.project-wide { grid-column: 1 / -1; display: grid; grid-template-columns: .78fr 1.22fr; }
.project-wide .project-image { height: 360px; }
.project-image-contain img { object-fit: contain; padding: 28px; background: white; }

.team-section { padding-bottom: 80px; }
.team-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; }
.member-card { min-width: 0; padding: 14px 14px 24px; border: 1px solid var(--line); background: rgba(255,255,255,.72); transition: transform 180ms ease, border-color 180ms ease; }
.member-card:hover { transform: translateY(-5px); border-color: var(--lime); }
.member-photo { aspect-ratio: 1; margin-bottom: 20px; overflow: hidden; background: var(--mist); position: relative; }
.member-photo::after { content: ""; position: absolute; inset: auto 0 0; height: 5px; background: linear-gradient(90deg, var(--teal) 76%, var(--lime) 76%); }
.member-photo img { width: 100%; height: 100%; object-fit: cover; }
.member-role { display: block; color: var(--teal); font-size: .65rem; min-height: 34px; }
.member-card h3 { margin: 6px 0 2px; font-size: 1.18rem; line-height: 1.35; }
.member-card p { margin: 0; color: var(--muted); font: 500 .85rem/1.4 var(--font-display); }

.contact-section { padding-block: 70px 120px; }
.contact-panel { position: relative; overflow: hidden; padding: clamp(42px, 7vw, 84px); color: white; background: var(--teal); }
.contact-panel .section-index { color: #dbe88a; }
.contact-panel h2 { position: relative; z-index: 2; max-width: 800px; }
.contact-panel p { position: relative; z-index: 2; max-width: 620px; color: #c5d9d6; font-size: 1.05rem; }
.button-light { position: relative; z-index: 2; margin-top: 18px; color: var(--teal); background: white; border-color: white; }
.contact-orbit { position: absolute; right: -120px; top: 50%; width: 470px; height: 470px; transform: translateY(-50%); border: 1px solid rgba(255,255,255,.25); border-radius: 50%; }
.contact-orbit::before, .contact-orbit::after { content: ""; position: absolute; border: 1px solid rgba(255,255,255,.17); border-radius: 50%; }
.contact-orbit::before { inset: 62px; }.contact-orbit::after { inset: 132px; }
.contact-orbit span { position: absolute; top: 50%; left: 50%; width: 14px; height: 14px; margin: -7px; border-radius: 50%; background: var(--lime-bright); box-shadow: 0 0 34px 9px rgba(210,220,36,.42); }
.contact-orbit i { position: absolute; top: 54px; left: 104px; width: 8px; height: 8px; border-radius: 50%; background: white; }

.site-footer { min-height: 150px; border-top: 1px solid var(--line); display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: 28px; color: var(--muted); font-size: .86rem; }
.site-footer img { width: 150px; height: 48px; object-fit: contain; object-position: left; }
.site-footer a { justify-self: end; color: var(--teal); font-weight: 700; }

.project-dialog { width: min(620px, calc(100% - 32px)); border: 0; padding: 42px; color: var(--ink); background: var(--paper); box-shadow: 0 30px 100px rgba(0,32,32,.35); }
.project-dialog::backdrop { background: rgba(0,35,35,.72); backdrop-filter: blur(6px); }
.dialog-close { position: absolute; right: 18px; top: 14px; width: 42px; height: 42px; border: 1px solid var(--line); color: var(--teal); background: transparent; font-size: 1.7rem; cursor: pointer; }
.dialog-kicker { color: var(--teal); }
.project-dialog h2 { margin: 16px 32px 18px 0; font: 600 clamp(2rem,6vw,3.2rem)/1.02 var(--font-display); letter-spacing: -.045em; }
.project-dialog > p { color: var(--muted); font-size: 1.03rem; }
.dialog-specs { margin-top: 28px; display: grid; grid-template-columns: repeat(3,1fr); border-top: 1px solid var(--line); border-left: 1px solid var(--line); }
.dialog-spec { padding: 14px; border-right: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.dialog-spec span { display: block; color: var(--muted); font: 700 .62rem/1.2 var(--font-display); letter-spacing: .1em; }
.dialog-spec strong { display: block; margin-top: 7px; color: var(--teal); font-size: .84rem; }

.reveal { opacity: 0; transform: translateY(20px); transition: opacity 600ms ease, transform 600ms ease; transition-delay: var(--delay, 0ms); }
.reveal.is-visible { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; }
  .reveal { opacity: 1; transform: none; }
}

@media (max-width: 980px) {
  .hero { grid-template-columns: 1fr; padding-top: 150px; }
  .hero-copy { max-width: 760px; }
  .visual-frame, .visual-frame > img { min-height: 540px; height: 540px; }
  .focus-grid { grid-template-columns: 1fr; }
  .focus-card { min-height: 0; }
  .focus-icon { margin-bottom: 38px; }
  .team-grid { grid-template-columns: repeat(3,1fr); }
}

@media (max-width: 760px) {
  .section-shell { width: min(100% - 30px, 580px); }
  .site-header { width: calc(100% - 20px); top: 10px; min-height: 62px; padding-left: 14px; }
  .brand img { width: 145px; height: 40px; }
  .menu-toggle { display: grid; place-content: center; gap: 7px; width: 46px; height: 46px; cursor: pointer; }
  .menu-toggle span:not(.sr-only) { display: block; width: 23px; height: 2px; background: var(--teal); transition: transform 180ms ease; }
  .menu-toggle[aria-expanded="true"] span:first-child { transform: translateY(4.5px) rotate(45deg); }
  .menu-toggle[aria-expanded="true"] span:nth-child(2) { transform: translateY(-4.5px) rotate(-45deg); }
  .site-nav { position: absolute; left: -1px; right: -1px; top: calc(100% + 6px); display: none; flex-direction: column; align-items: stretch; gap: 0; padding: 14px; border: 1px solid var(--line); background: rgba(250,252,251,.98); box-shadow: 0 16px 38px rgba(0,63,64,.12); }
  .site-nav.is-open { display: flex; }
  .site-nav a { padding: 13px 10px; }
  .nav-cta { text-align: center; }
  .hero { min-height: auto; padding-top: 130px; padding-bottom: 74px; gap: 48px; }
  .hero h1 { font-size: clamp(4rem, 20vw, 6rem); }
  .hero-tags { gap: 10px; flex-wrap: wrap; }
  .hero-tags span + span::before { margin-right: 10px; }
  .visual-frame, .visual-frame > img { min-height: 470px; height: 470px; }
  .signal-card { right: -4px; top: 32px; }
  .section-heading { grid-template-columns: 1fr; gap: 22px; }
  .section-heading h2, .contact-panel h2 { font-size: clamp(2.65rem, 13vw, 4.2rem); }
  .focus-section, .team-section, .projects-section { padding-block: 88px; }
  .project-featured, .project-wide { display: block; }
  .project-featured .project-image, .project-wide .project-image, .project-image { height: 280px; }
  .project-featured .project-copy { padding: 28px; }
  .team-grid { grid-template-columns: repeat(2, 1fr); }
  .contact-section { padding-bottom: 80px; }
  .contact-orbit { opacity: .5; right: -260px; }
  .site-footer { grid-template-columns: 1fr auto; padding-block: 30px; }
  .site-footer p { grid-row: 2; grid-column: 1 / -1; margin: 0; }
  .dialog-specs { grid-template-columns: 1fr; }
  .splash-logo { margin-block: 34px 42px; }
  .splash-signal { width: 100vw; right: -56vw; bottom: 20px; }
}

@media (max-width: 480px) {
  .hero h1 { font-size: clamp(3.45rem, 18vw, 4.35rem); }
  .hero-actions .button { width: 100%; }
  .visual-frame, .visual-frame > img { min-height: 400px; height: 400px; }
  .visual-label { left: 24px; right: 24px; }
  .visual-label strong { font-size: .95rem; }
  .team-grid { grid-template-columns: 1fr; }
  .member-card { display: grid; grid-template-columns: 120px 1fr; grid-template-rows: auto auto 1fr; column-gap: 16px; align-items: end; }
  .member-photo { grid-row: 1 / 4; margin: 0; }
  .member-role { min-height: auto; }
  .project-dialog { padding: 34px 24px 24px; }
}
