/* Kometa: ivory pages, a dark hero, thin gold lines, square corners. */
:root {
  --night: #070605;
  --ivory: #F5F2ED;
  --paper: #FBF9F6;
  --champagne: #E8D9C3;
  --ink: #17130F;
  --muted: #655C52;
  --gold: #C99B45;
  --gold-deep: #86601F;
  --gold-light: #E6BC6A;
  --hair: rgba(23, 19, 15, .16);
  --hair-light: rgba(245, 242, 237, .22);

  --font-display: "Cormorant Garamond", "Times New Roman", serif;
  --font-mark: "Cinzel", "Times New Roman", serif;
  --font-body: "Jost", "Helvetica Neue", Arial, sans-serif;

  --gutter: clamp(20px, 5vw, 64px);
  --gutter-l: max(var(--gutter), env(safe-area-inset-left, 0px));
  --gutter-r: max(var(--gutter), env(safe-area-inset-right, 0px));
  --safe-top: env(safe-area-inset-top, 0px);
  --safe-bottom: env(safe-area-inset-bottom, 0px);
  --max: 1240px;
  --header-h: 84px;
}

*, *::before, *::after { box-sizing: border-box; }
html.menu-open { overflow: hidden; }
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; -webkit-tap-highlight-color: transparent; scroll-behavior: smooth; overflow-y: scroll; scrollbar-gutter: stable; } /* scrollbar always reserved, so no page shifts width */
@media (prefers-reduced-motion: no-preference) { @view-transition { navigation: auto; } }
.site-header { view-transition-name: site-header; }
::view-transition-old(root), ::view-transition-new(root) { animation-duration: .35s; }
body {
  margin: 0;
  background: var(--ivory);
  color: var(--ink);
  font: 300 16px/1.75 var(--font-body);
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
h1, h2, h3 { font-family: var(--font-display); font-weight: 300; margin: 0; line-height: 1.1; text-wrap: balance; }
p { margin: 0; }
ul { list-style: none; margin: 0; padding: 0; }
:focus-visible { outline: 2px solid var(--gold); outline-offset: 3px; }

.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip { position: absolute; left: -999px; top: 0; background: var(--night); color: var(--ivory); padding: .75rem 1rem; z-index: 100; }
.skip:focus { left: 0; }

.container { max-width: var(--max); margin: 0 auto; padding-left: var(--gutter-l); padding-right: var(--gutter-r); }

/* Shared type */
.eyebrow { font: 400 .72rem/1 var(--font-body); letter-spacing: .28em; text-transform: uppercase; color: var(--gold-deep); }
.rule { width: 44px; height: 1px; background: var(--gold); margin: 1.5rem 0; border: 0; }
.page-title { font-size: clamp(2rem, 4vw, 2.9rem); letter-spacing: .08em; text-transform: uppercase; }
.lead { font: 300 clamp(1.35rem, 2.4vw, 1.75rem)/1.35 var(--font-display); max-width: 24ch; }
.prose { display: grid; gap: 1.1rem; max-width: 52ch; font-size: .95rem; color: var(--muted); }
.prose-lg { font-size: 1.05rem; }

/* Buttons and links */
.btn {
  display: inline-block; font: 400 .72rem/1 var(--font-body); letter-spacing: .22em; text-transform: uppercase;
  color: var(--gold-deep); border: 1px solid var(--gold); padding: 1.05rem 1.7rem; background: transparent; cursor: pointer;
  transition: background .3s, color .3s, border-color .3s;
}
.btn:hover { background: var(--gold); color: var(--night); }
.btn-sm { padding: .85rem 1.2rem; font-size: .68rem; }
.btn-light { color: var(--ivory); border-color: var(--gold); }
.link-arrow { font: 400 .68rem/1 var(--font-body); letter-spacing: .2em; text-transform: uppercase; color: var(--gold-deep); display: inline-flex; gap: .6rem; }
.link-arrow::after { content: "→"; transition: transform .3s; }
.link-arrow:hover::after { transform: translateX(4px); }

/* Header */
.site-header { padding-top: var(--safe-top); position: sticky; top: 0; z-index: 50; background: var(--ivory); border-bottom: 1px solid var(--hair); transition: background .35s, border-color .35s, color .35s; }
.has-hero .site-header { position: fixed; inset: 0 0 auto; background: transparent; border-color: transparent; color: var(--ivory); }
.has-hero .site-header.is-solid { background: rgba(7, 6, 5, .92); backdrop-filter: blur(8px); border-color: var(--hair-light); }
.bar { max-width: var(--max); margin: 0 auto; padding: 0 var(--gutter-r) 0 var(--gutter-l); min-height: var(--header-h); display: flex; align-items: center; justify-content: space-between; gap: 2rem; }

.brand { display: grid; grid-template-columns: auto 1fr; grid-template-areas: "mark word" "mark desc"; column-gap: .9rem; align-items: center; line-height: 1; }
.brand .comet { grid-area: mark; width: 46px; height: auto; }
.wordmark {
  grid-area: word; font: 500 1.7rem/1 var(--font-mark); letter-spacing: .3em; margin-right: -.3em;
  /* polished gold: light top edge, bright body, darker base */
  background: linear-gradient(180deg, #F7E3A6 0%, #E6BC6A 38%, #B8863A 62%, #E9C679 82%, #9C6F2A 100%);
  -webkit-background-clip: text; background-clip: text; color: transparent; -webkit-text-fill-color: transparent;
  filter: drop-shadow(0 0 10px rgba(230, 188, 106, .35));
}
.site-footer .wordmark { filter: none; }
/* Gold artwork loses contrast on ivory, so deepen it there. */
body:not(.has-hero) .site-header .brand img,
.site-footer .brand img { filter: brightness(.72) saturate(1.2); }
body:not(.has-hero) .site-header .wordmark,
.site-footer .wordmark { background-image: linear-gradient(180deg, #C9993F 0%, #9A6F25 50%, #7A5518 100%); filter: none; }
.has-hero .site-header .brand img { filter: none; }
.descriptor { grid-area: desc; font: 400 .5rem/1 var(--font-body); letter-spacing: .24em; text-transform: uppercase; margin-top: .5rem; opacity: .75; }
.site-footer .brand { grid-template-columns: 1fr; grid-template-areas: "word" "desc"; }

.site-nav { display: flex; align-items: center; gap: clamp(1.25rem, 3vw, 2.75rem); }
.site-nav ul { display: flex; gap: clamp(1.25rem, 3vw, 2.5rem); }
.site-nav li a { font: 400 .72rem/1 var(--font-body); letter-spacing: .18em; text-transform: uppercase; padding-block: .5rem; border-bottom: 1px solid transparent; transition: border-color .3s; }
.site-nav li a:hover, .site-nav li a[aria-current="page"] { border-color: var(--gold); }
.has-hero .btn-sm { color: var(--ivory); border-color: var(--gold); }
.has-hero .btn-sm:hover { color: var(--night); }

.menu-toggle { display: none; background: none; border: 0; color: inherit; width: 44px; height: 44px; position: relative; cursor: pointer; }
.menu-toggle i { position: absolute; left: 10px; right: 10px; height: 1px; background: currentColor; transition: transform .3s, top .3s; }
.menu-toggle i:first-of-type { top: 18px; } .menu-toggle i:last-of-type { top: 26px; }
.menu-toggle[aria-expanded="true"] i:first-of-type { top: 22px; transform: rotate(45deg); }
.menu-toggle[aria-expanded="true"] i:last-of-type { top: 22px; transform: rotate(-45deg); }

/* Hero */
/* Hero and client strip together fill the screen (small-viewport units, so mobile browser bars don't resize it). */
.fold { display: flex; flex-direction: column; min-height: clamp(560px, 100vh, 1200px); min-height: clamp(560px, 100svh, 1200px); }
.fold .hero { flex: 1 0 auto; }
.fold .trusted { flex: none; }
.hero { position: relative; display: flex; align-items: center; color: var(--ivory); background: var(--night) center / cover no-repeat; isolation: isolate; padding-top: calc(var(--header-h) + var(--safe-top)); }
.hero::before { content: ""; position: absolute; inset: 0; z-index: -1; background: linear-gradient(180deg, rgba(7,6,5,1) 0%, rgba(7,6,5,.94) 18%, rgba(7,6,5,.72) 50%, rgba(7,6,5,.62) 78%, rgba(7,6,5,.86) 100%); }
.hero-comet { position: absolute; z-index: -1; right: 6%; top: 22%; width: min(34vw, 460px); height: auto; opacity: .95; pointer-events: none; }
@media (max-width: 900px) { .hero-comet { top: 14%; right: -4%; width: 62vw; } }
.hero h1 { font-size: clamp(2.6rem, 6vw, 4.5rem); max-width: 14ch; }
.hero .rule { margin-block: 2rem 1.75rem; }
.hero p.sub { max-width: 40ch; color: rgba(245,242,237,.88); font-size: 1.02rem; margin-bottom: 2.25rem; }

/* Trusted strip */
.trusted { background: var(--paper); border-bottom: 1px solid var(--hair); }
.trusted .container { display: flex; align-items: center; gap: 2rem 3rem; flex-wrap: wrap; padding-block: 2.2rem; }
.trusted .eyebrow { color: var(--muted); max-width: 18ch; line-height: 1.6; font-size: .62rem; letter-spacing: .2em; }
.trusted ul { flex: 1; display: flex; justify-content: space-between; gap: 1.5rem 2.5rem; flex-wrap: wrap; font: 400 1.05rem var(--font-display); letter-spacing: .16em; text-transform: uppercase; color: var(--muted); }

/* Split pages: text left, tall image right */
/* Page head: every inner page shares one left edge (the container's) and one top offset. */
:root { --page-left: max(var(--gutter-l), calc((100% - var(--max)) / 2 + var(--gutter))); --page-top: clamp(3rem, 8vw, 6rem); }
.split { display: grid; grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr); min-height: calc(100vh - var(--header-h)); min-height: calc(100svh - var(--header-h)); padding-left: var(--page-left); }
.split-text { padding: var(--page-top) clamp(2rem, 6vw, 5rem) var(--page-top) 0; max-width: 640px; width: 100%; display: flex; flex-direction: column; align-items: flex-start; }
.split-text .page-title + .rule { margin-bottom: 2rem; }
.split-img { background: var(--champagne) center / cover no-repeat; min-height: 360px; }
.split-text .btn { margin-top: 2.5rem; }

/* Services list */
.services { margin-top: 2.5rem; display: grid; max-width: 520px; width: 100%; }
.service { display: grid; grid-template-columns: 48px 1fr; gap: 1.1rem; padding-block: 1.4rem; border-bottom: 1px solid var(--hair); }
.service:first-child { border-top: 1px solid var(--hair); }
.service .ico { width: 44px; height: 44px; border: 1px solid var(--gold); border-radius: 50%; display: grid; place-items: center; color: var(--gold-deep); }
.service .ico svg { width: 20px; height: 20px; }
.service h3 { font: 500 .74rem/1.4 var(--font-body); letter-spacing: .2em; text-transform: uppercase; margin-bottom: .4rem; }
.service p { font-size: .9rem; color: var(--muted); }

/* Quote band */
.quote-band { background: var(--night); color: #E9D3A0; text-align: center; padding: clamp(2.5rem, 6vw, 4rem) var(--gutter-r) clamp(2.5rem, 6vw, 4rem) var(--gutter-l); }
.quote-band blockquote { margin: 0 auto; max-width: 34ch; font: italic 300 clamp(1.35rem, 3vw, 2rem)/1.4 var(--font-display); text-wrap: balance; }

/* Sections */
.section { padding-block: clamp(4rem, 9vw, 7rem); }
.section-head { display: flex; justify-content: space-between; align-items: end; gap: 2rem; flex-wrap: wrap; margin-bottom: 3rem; }
.section-head .rule { margin-bottom: 0; }
.three { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: clamp(1.5rem, 3vw, 2.5rem); }

/* Work cards */
.card { display: grid; gap: 1rem; align-content: start; }
.card .thumb { aspect-ratio: 4 / 3; overflow: hidden; background: var(--champagne); }
.card .thumb img { width: 100%; height: 100%; object-fit: cover; transition: transform .8s ease; }
.card:hover .thumb img { transform: scale(1.04); }
.card h3 { font: 500 .74rem/1.4 var(--font-body); letter-spacing: .2em; text-transform: uppercase; }
.card p { font-size: .9rem; color: var(--muted); }
.work-intro { padding-block: var(--page-top) 2rem; }
.work-intro .lead { max-width: 30ch; }
.work-foot { text-align: center; padding-block: 3rem 5rem; }

/* CTA */
.cta { background: var(--champagne); text-align: center; padding-block: clamp(3.5rem, 8vw, 6rem); }
.cta h2 { font-size: clamp(1.8rem, 4vw, 2.8rem); margin-bottom: 1.5rem; }
.cta .rule { margin-inline: auto; }

/* Contact */
.contact-list { margin-top: 2.5rem; display: grid; gap: 1.1rem; }
.contact-list li { display: flex; gap: 1rem; align-items: center; font-size: .92rem; }
.contact-list svg { width: 20px; height: 20px; color: var(--gold); flex: none; }
.form { display: grid; gap: 1.4rem; margin-top: 2.5rem; width: 100%; max-width: 520px; }
.field { display: grid; gap: .45rem; }
.field label { font: 400 .66rem/1 var(--font-body); letter-spacing: .22em; text-transform: uppercase; color: var(--muted); }
.field input, .field textarea { font: 300 1rem/1.5 var(--font-body); color: var(--ink); background: transparent; border: 0; border-bottom: 1px solid var(--hair); padding: .6rem 0; border-radius: 0; transition: border-color .3s; width: 100%; }
.field input:focus, .field textarea:focus { outline: 0; border-color: var(--gold); }
.field textarea { min-height: 7rem; resize: vertical; }
.field .err { color: #8a2f1f; font-size: .8rem; }
.hp { position: absolute; left: -9999px; }
.notice { border: 1px solid var(--gold); padding: 1rem 1.25rem; font-size: .92rem; margin-top: 2rem; max-width: 520px; }

/* Footer */
.site-footer { border-top: 1px solid var(--hair); background: var(--ivory); }
.site-footer .bar { min-height: 110px; padding-block: 1.75rem calc(1.75rem + var(--safe-bottom)); flex-wrap: wrap; }
.site-footer .wordmark { font-size: 1.3rem; }
.site-footer .copy { font-size: .72rem; color: var(--muted); letter-spacing: .04em; }
.legal { display: flex; gap: 1.75rem; font: 400 .64rem/1 var(--font-body); letter-spacing: .18em; text-transform: uppercase; }
.legal a:hover { color: var(--gold-deep); }

/* Reveal on scroll; content is visible by default and only hidden once JS is running */
.js .reveal { opacity: 0; transform: translateY(18px); transition: opacity .9s ease, transform .9s ease; }
.js .reveal.in { opacity: 1; transform: none; }

@media (max-width: 900px) {
  :root { --header-h: 72px; }
  .menu-toggle { display: block; }
  /* Fullscreen menu: gold items, comet at the bottom. Fixed inside the header, so the header must not blur (backdrop-filter would trap it). */
  .site-header, .has-hero .site-header.is-solid { backdrop-filter: none; }
  .brand, .menu-toggle { position: relative; z-index: 2; }
  .site-nav { position: fixed; inset: 0; z-index: 1; height: 100vh; height: 100dvh; background: var(--night); color: var(--gold-light); flex-direction: column; align-items: center; justify-content: center; gap: 2.25rem; padding: calc(var(--header-h) + var(--safe-top) + 1rem) var(--gutter-r) calc(15rem + var(--safe-bottom)) var(--gutter-l); overflow-y: auto; text-align: center; opacity: 0; visibility: hidden; transition: opacity .35s, visibility .35s; }
  .site-nav::after { content: ""; position: absolute; left: 50%; bottom: calc(1.5rem + var(--safe-bottom)); width: min(260px, 60vw); aspect-ratio: 572 / 411; transform: translateX(-50%); background: url("../img/kometa_comet.png") center / contain no-repeat; pointer-events: none; }
  .site-nav ul { align-items: center; gap: 1.5rem; }
  .site-nav li a { font: 300 clamp(1.7rem, 7vw, 2.2rem)/1.1 var(--font-display); letter-spacing: .14em; color: var(--gold-light); border-bottom-color: transparent; }
  .site-nav li a:hover, .site-nav li a[aria-current="page"] { border-bottom-color: var(--gold); }
  .site-nav .btn-sm { color: var(--gold-light); border-color: var(--gold); }
  .site-nav.open { opacity: 1; visibility: visible; }
  .site-nav ul { flex-direction: column; }
  .site-header.menu-open { background: transparent; border-color: transparent; color: var(--ivory); }
  .descriptor { display: none; }
  .split { grid-template-columns: 1fr; min-height: 0; }
  .split { padding-left: 0; }
  .split-text { max-width: none; padding: var(--page-top) var(--gutter-r) var(--page-top) var(--gutter-l); }
  .split-img { aspect-ratio: 4 / 3; min-height: 0; }
  .three { grid-template-columns: 1fr; }
  .hero { align-items: flex-end; padding-bottom: 3.5rem; }
  .trusted ul { justify-content: flex-start; }
}
@media (max-width: 560px) {
  .site-footer .bar { flex-direction: column; align-items: flex-start; }
  .legal { flex-wrap: wrap; gap: 1rem 1.5rem; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition: none !important; animation: none !important; }
  .js .reveal { opacity: 1; transform: none; }
}
