:root {
  --quartz: #f3f6fb;
  --quartz-deep: #d9e2ee;
  --aurora-emerald: #1f9a74;
  --aurora-mint: #5ee0b0;
  --aurora-violet: #6b46d6;
  --aurora-lilac: #b79bff;
  --aurora-cyan: #3ec8e0;
  --silver: #e8eef6;
  --ink: #14182a;
  --ink-soft: #3a4158;
  --glass: rgba(255, 255, 255, 0.42);
  --glass-strong: rgba(255, 255, 255, 0.68);
  --line: rgba(107, 70, 214, 0.22);
  --shadow: 0 24px 60px rgba(20, 24, 42, 0.12);
  --radius: 1.35rem;
  --font-body: "IBM Plex Sans Thai", sans-serif;
  --font-display: "Syne", "IBM Plex Sans Thai", sans-serif;
}

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

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  color: var(--ink);
  font-family: var(--font-body);
  line-height: 1.7;
  background:
    radial-gradient(900px 420px at 8% -10%, rgba(183, 155, 255, 0.45), transparent 55%),
    radial-gradient(800px 380px at 92% 8%, rgba(62, 200, 224, 0.35), transparent 50%),
    radial-gradient(700px 500px at 70% 90%, rgba(94, 224, 176, 0.28), transparent 55%),
    linear-gradient(180deg, #eef3fb 0%, #f7f9fd 42%, #e7f6f1 100%);
  min-height: 100vh;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  background-image:
    linear-gradient(115deg, transparent 40%, rgba(255, 255, 255, 0.35) 48%, transparent 56%),
    linear-gradient(18deg, rgba(107, 70, 214, 0.04) 25%, transparent 26%);
  mix-blend-mode: soft-light;
  animation: aurora-shift 18s ease-in-out infinite alternate;
  z-index: 0;
}

@keyframes aurora-shift {
  from { transform: translate3d(0, 0, 0); opacity: 0.7; }
  to { transform: translate3d(-2%, 1.5%, 0); opacity: 1; }
}

main,
.site-header,
.site-footer,
.cookie-banner {
  position: relative;
  z-index: 1;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

a {
  color: var(--aurora-violet);
  text-decoration-thickness: 1px;
  text-underline-offset: 0.18em;
}

a:hover {
  color: var(--aurora-emerald);
}

.shell {
  width: min(1160px, calc(100% - 2rem));
  margin-inline: auto;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  border: 0;
}

.skip-link {
  position: absolute;
  left: 1rem;
  top: -40px;
  background: var(--ink);
  color: white;
  padding: 0.5rem 0.8rem;
  z-index: 20;
}

.skip-link:focus {
  top: 0.6rem;
}

.site-header {
  padding: 1rem 0;
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.7rem 1rem;
  background: var(--glass);
  border: 1px solid var(--line);
  border-radius: 999px;
  backdrop-filter: blur(16px);
  box-shadow: var(--shadow);
}

.brand {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  color: var(--ink);
  text-decoration: none;
  font-family: var(--font-display);
  font-weight: 700;
  letter-spacing: -0.03em;
}

.brand-mark {
  width: 1.55rem;
  height: 1.55rem;
  background: linear-gradient(135deg, var(--aurora-lilac), var(--aurora-cyan) 50%, var(--aurora-mint));
  clip-path: polygon(50% 0%, 100% 28%, 100% 72%, 50% 100%, 0% 72%, 0% 28%);
}

.nav-toggle {
  display: none;
  width: 2.6rem;
  height: 2.6rem;
  border: 0;
  background: transparent;
  cursor: pointer;
}

.nav-toggle span {
  display: block;
  height: 2px;
  margin: 5px 6px;
  background: var(--ink);
}

.site-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem 1rem;
}

.site-nav a {
  color: var(--ink-soft);
  text-decoration: none;
  font-size: 0.95rem;
}

.site-nav a:hover {
  color: var(--aurora-violet);
}

.hero-split {
  display: grid;
  grid-template-columns: 0.92fr 1.08fr;
  gap: 2rem;
  align-items: stretch;
  padding: 2.2rem 0 3.4rem;
}

.hero-copy {
  padding: 1.4rem 0;
}

.kicker {
  display: inline-block;
  font-size: 0.82rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--aurora-emerald);
  margin-bottom: 0.8rem;
}

h1, h2, h3 {
  font-family: var(--font-display);
  letter-spacing: -0.03em;
  line-height: 1.2;
  margin: 0 0 0.8rem;
}

h1 {
  font-size: clamp(2.1rem, 4vw, 3.5rem);
  font-weight: 800;
}

h2 {
  font-size: clamp(1.55rem, 2.6vw, 2.15rem);
}

.lede {
  font-size: 1.12rem;
  color: var(--ink-soft);
  max-width: 38rem;
}

.hero-frame {
  position: relative;
  min-height: 420px;
}

.hero-frame img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}

.crystal-shard {
  position: absolute;
  inset: auto auto -1.2rem -1.2rem;
  width: min(70%, 280px);
  padding: 1rem 1.1rem;
  background: var(--glass-strong);
  border: 1px solid rgba(255, 255, 255, 0.7);
  border-radius: 1rem;
  backdrop-filter: blur(12px);
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 0;
  cursor: pointer;
  font-family: inherit;
  font-weight: 600;
  padding: 0.75rem 1.2rem;
  border-radius: 999px;
  text-decoration: none;
  position: relative;
  overflow: hidden;
}

.btn-primary {
  color: #f8fbff;
  background: linear-gradient(120deg, var(--aurora-violet), var(--aurora-cyan) 55%, var(--aurora-emerald));
  background-size: 160% 160%;
}

.btn-primary::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.7), transparent);
  transform: translateX(-120%);
}

.btn-primary:hover::after,
.btn-primary:focus-visible::after {
  animation: crystal-pulse 0.9s ease;
}

@keyframes crystal-pulse {
  to { transform: translateX(120%); }
}

.btn-ghost {
  background: transparent;
  color: var(--ink);
  border: 1px solid var(--line);
}

.panel {
  background: var(--glass);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 1.4rem;
  backdrop-filter: blur(14px);
}

.section {
  padding: 2.4rem 0;
}

.section-head {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  align-items: end;
  margin-bottom: 1.4rem;
}

.card-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1rem;
}

.card {
  background: var(--glass-strong);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow);
}

.card img,
.cover img,
.portrait img {
  width: 100%;
  aspect-ratio: 16 / 10;
  object-fit: cover;
}

.portrait img {
  aspect-ratio: 1 / 1;
}

.card-body,
.cover-body {
  padding: 1.05rem 1.15rem 1.25rem;
}

.meta {
  color: var(--ink-soft);
  font-size: 0.92rem;
}

.evidence {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 1.2rem;
  align-items: center;
}

.quote {
  font-size: 1.25rem;
  font-family: var(--font-display);
  line-height: 1.45;
}

.page-hero {
  padding: 2rem 0 1rem;
}

.page-hero h1 {
  max-width: 18ch;
}

.prose {
  max-width: 44rem;
}

.prose p {
  margin: 0 0 1rem;
}

.stack {
  display: grid;
  gap: 1rem;
}

.form {
  display: grid;
  gap: 0.9rem;
  max-width: 36rem;
}

label {
  display: grid;
  gap: 0.35rem;
  font-weight: 600;
}

input,
select,
textarea {
  font: inherit;
  padding: 0.7rem 0.8rem;
  border-radius: 0.8rem;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.8);
  color: var(--ink);
}

textarea {
  min-height: 8rem;
  resize: vertical;
}

.field-error {
  color: #8a1f4a;
  font-size: 0.88rem;
  font-weight: 500;
}

.form-status {
  margin: 0.4rem 0 0;
  padding: 0.7rem 0.85rem;
  border-radius: 0.8rem;
}

.form-status.is-ok {
  background: rgba(94, 224, 176, 0.28);
}

.form-status.is-err {
  background: rgba(183, 155, 255, 0.28);
}

.legal h2 {
  margin-top: 1.6rem;
}

.cookie-banner {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 30;
  padding: 0 0 1rem;
}

.cookie-inner {
  background: var(--glass-strong);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 1rem 1.1rem;
  backdrop-filter: blur(18px);
  box-shadow: var(--shadow);
}

.cookie-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem;
  margin-top: 0.7rem;
}

.site-footer {
  margin-top: 3rem;
  padding: 2rem 0 2.5rem;
  background: linear-gradient(180deg, transparent, rgba(255, 255, 255, 0.45));
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr 1fr;
  gap: 1.2rem;
}

.footer-brand {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.2rem;
}

.footer-label {
  font-weight: 700;
  margin-bottom: 0.35rem;
}

.footer-base {
  margin-top: 1.4rem;
  color: var(--ink-soft);
}

.team-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1rem;
}

.works-list {
  display: grid;
  gap: 1.5rem;
}

.work-row {
  display: grid;
  grid-template-columns: 1.15fr 0.85fr;
  gap: 1.2rem;
  align-items: center;
}

.work-row:nth-child(even) {
  grid-template-columns: 0.85fr 1.15fr;
}

.work-row:nth-child(even) .work-copy {
  order: -1;
}

@media (max-width: 900px) {
  .nav-toggle { display: block; }
  .site-nav {
    display: none;
    position: absolute;
    top: 4.6rem;
    left: 1rem;
    right: 1rem;
    background: var(--glass-strong);
    border: 1px solid var(--line);
    border-radius: 1rem;
    padding: 1rem;
    flex-direction: column;
  }
  .site-nav.is-open { display: flex; }
  .header-inner { border-radius: 1.2rem; position: relative; }
  .hero-split,
  .evidence,
  .card-grid,
  .footer-grid,
  .team-grid,
  .work-row,
  .work-row:nth-child(even) {
    grid-template-columns: 1fr;
  }
  .work-row:nth-child(even) .work-copy { order: 0; }
  .hero-frame { min-height: 280px; }
  .contact-layout,
  .service-row {
    grid-template-columns: 1fr !important;
  }
}
