/* ============ Tokens ============ */
:root {
  --bg: #F6F2EA;
  --surface: #FFFFFF;
  --text: #14213D;
  --muted: #4D5870;
  --accent: #9A4F14;
  --accent-deep: #7C3E0F;
  --accent-text: #FFFFFF;
  --plate-bg: #14213D;
  --plate-text: #F6F2EA;
  --line: #DCD2C2;
  --soft: #EFE8DA;
  --font-head: Optima, Candara, 'Segoe UI', 'Noto Sans', sans-serif;
  --font-body: Georgia, Cambria, 'Times New Roman', serif;
  --radius-card: 8px;
  --radius-btn: 999px;
  --shadow: 0 1px 2px rgb(0 0 0 / .06), 0 12px 32px rgb(0 0 0 / .08);
  --pad-x: clamp(16px, 4vw, 40px);
  --section-gap: 72px;
}

/* ============ Base ============ */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: var(--font-body);
  font-size: clamp(1rem, 0.96rem + 0.2vw, 1.125rem);
  line-height: 1.65;
  color: var(--text);
  background-color: var(--bg);
  background-image: repeating-linear-gradient(115deg, var(--bg) 0 96px, var(--soft) 96px 192px);
  background-attachment: fixed;
  min-height: 100%;
}
img { max-width: 100%; height: auto; display: block; }
h1, h2, h3, h4 {
  font-family: var(--font-head);
  font-weight: 700;
  letter-spacing: -0.01em;
  line-height: 1.15;
  color: var(--text);
}
h1 { font-size: clamp(2.4rem, 4.6vw + 0.6rem, 4.2rem); line-height: 1.08; }
h2 { font-size: clamp(1.8rem, 2.6vw + 0.8rem, 3rem); letter-spacing: -0.01em; margin-bottom: 12px; }
h3 { font-size: clamp(1.2rem, 1rem + 0.6vw, 1.5rem); }
p { max-width: 68ch; }
a { color: var(--accent); text-decoration-thickness: 1px; text-underline-offset: 3px; }
a:hover { color: var(--accent-deep); }
:focus-visible { outline: 3px solid var(--accent); outline-offset: 3px; border-radius: 4px; }

/* ============ Layout ============ */
.l-wrap {
  width: 100%;
  max-width: 1200px;
  margin-inline: auto;
  padding-inline: var(--pad-x);
}
.l-band { padding-block: clamp(64px, 9vw, 128px); }
#owner-note { padding-block: 48px 0; }
#approach { padding-top: var(--section-gap); }
.l-band-lead { color: var(--muted); font-size: 1.05em; margin: 0 0 40px; line-height: 1.6; }
.l-band h2 { margin: 0 0 8px; }
.u-prose h2, .u-prose h3 { margin: 32px 0 12px; }
.u-prose ul, .u-prose ol { padding-left: 1.4em; }
.u-prose table { width: 100%; border-collapse: collapse; margin: 16px 0; }
.u-prose th, .u-prose td { border: 1px solid var(--line); padding: 10px 12px; text-align: left; }
.u-skip {
  position: absolute; left: -9999px; top: 0;
  background: var(--accent); color: var(--accent-text);
  padding: 12px 20px; border-radius: var(--radius-btn); z-index: 100;
}
.u-skip:focus { left: 16px; top: 16px; }
.u-accent {
  font-family: var(--font-head);
  font-size: clamp(2.6rem, 6vw + 1rem, 6rem);
  line-height: 1.05; font-weight: 700; letter-spacing: -0.02em;
  display: block; color: var(--accent);
}
.u-note { color: var(--muted); font-size: 0.95em; margin-bottom: 0; }

/* ============ Announcement plate ============ */
.c-plate {
  background: var(--plate-bg);
  color: var(--plate-text);
  border-radius: var(--radius-card);
  padding: 20px clamp(20px, 4vw, 40px);
  margin: 0 0 16px;
}
.c-plate p { color: var(--plate-text); margin: 0; }
.u-prose .c-plate p, .c-plate p { color: var(--plate-text); }
.u-prose .c-plate, .l-wrap > .c-plate p { color: var(--plate-text); }
#owner-note .c-plate { box-shadow: var(--shadow); }

/* ============ Header ============ */
.l-topbar {
  background: var(--surface);
  padding: 14px 0;
}
.l-topbar-inner {
  display: flex;
  align-items: center;
  justify-content: flex-start;
  gap: clamp(16px, 3vw, 24px);
  flex-wrap: wrap;
}
.c-brandmark {
  font-family: var(--font-head);
  font-weight: 700;
  font-size: 1.05rem;
  color: var(--text);
  text-decoration: none;
  margin-left: auto;
  max-width: 260px;
  line-height: 1.3;
}
.l-topbar-rule { height: 5px; background: var(--accent); width: 100%; }

/* ============ Nav ============ */
.c-menu-btn {
  display: none;
  align-items: center; gap: 8px;
  font-family: var(--font-head); font-size: 1rem; font-weight: 600;
  background: none; border: 1px solid var(--line); border-radius: var(--radius-btn);
  color: var(--text); padding: 10px 18px; min-height: 44px; cursor: pointer;
}
.c-menu-btn-bar, .c-menu-btn-bar::before, .c-menu-btn-bar::after {
  width: 18px; height: 2px; background: var(--text); content: "";
  display: block; transition: transform .25s ease, opacity .2s ease;
}
.c-menu-btn-bar::before, .c-menu-btn-bar::after { position: relative; }
.c-menu-list {
  list-style: none; display: flex; gap: 6px;
  margin: 0; padding: 0; flex-wrap: wrap;
}
.c-menu-link {
  display: block;
  font-family: var(--font-head);
  font-size: 1rem; font-weight: 600;
  color: var(--text); text-decoration: none;
  padding: 10px 14px; position: relative;
  background-image: linear-gradient(var(--accent), var(--accent));
  background-repeat: no-repeat;
  background-size: 100% 0%;
  background-position: 0 100%;
  transition: background-size .25s ease, color .25s ease;
}
.c-menu-link:hover { background-size: 100% 100%; color: var(--surface); }
.c-menu-link[aria-current="page"]::before {
  content: ""; position: absolute; left: 14px; bottom: 4px;
  width: 6px; height: 6px; border-radius: 50%; background: var(--accent);
  animation: menu-dot .5s ease both;
}
.c-menu-link[aria-current="page"]:hover::before { background: var(--surface); }
@keyframes menu-dot { from { transform: scale(0); } to { transform: scale(1); } }

/* ============ Hero ============ */
.has-hero { padding-top: clamp(48px, 7vw, 96px); }
.has-hero .l-wrap > .u-hero-line:first-child,
#top-collage .u-hero-line { text-align: center; margin-inline: auto; }
#top-collage .u-hero-line:not(.l-hero-lead):first-child {
  font-family: var(--font-head); font-weight: 600;
  font-size: clamp(1.05rem, 1rem + 0.5vw, 1.35rem); color: var(--muted);
}
.l-hero-lead { color: var(--muted); font-size: clamp(1.05rem, 1rem + 0.4vw, 1.3rem); }
.l-hero-actions { display: flex; justify-content: center; margin-top: 24px; }
.l-hero-collage {
  display: grid; grid-template-columns: 1fr 1fr; gap: 24px; margin-top: 32px;
}
.c-hero-shot {
  margin: 0; border-radius: var(--radius-card); overflow: hidden;
  box-shadow: var(--shadow);
}
.c-hero-shot img { width: 100%; height: 100%; object-fit: cover; aspect-ratio: 16 / 9; }
html.is-js .u-hero-line { animation: rise .55s ease both; }
html.is-js .u-hero-line:nth-child(1) { animation-delay: .05s; }
html.is-js .u-hero-line:nth-child(2) { animation-delay: .18s; }
html.is-js .u-hero-line:nth-child(3) { animation-delay: .3s; }
html.is-js .l-hero-actions { animation: rise .55s ease both; animation-delay: .42s; }
@keyframes rise { from { transform: translateY(8px); } to { transform: translateY(0); } }

/* ============ Split / tiles ============ */
.l-split {
  display: grid; grid-template-columns: 1fr 1fr; gap: clamp(24px, 4vw, 48px);
  align-items: start; margin-top: 32px;
}
.l-split-media { margin: 0; border-radius: var(--radius-card); overflow: hidden; box-shadow: var(--shadow); }
.l-split-media img { width: 100%; height: 100%; object-fit: cover; aspect-ratio: 4 / 3; }
.c-area-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 16px; }
.c-tile {
  background: var(--surface);
  border-radius: var(--radius-card);
  padding: 24px clamp(20px, 3vw, 32px);
  box-shadow: var(--shadow);
  height: 100%;
  transition: transform .3s ease, box-shadow .3s ease;
}
.c-tile:hover { transform: translateY(-4px); box-shadow: 0 1px 2px rgb(0 0 0 / .06), 0 18px 40px rgb(0 0 0 / .12); }
.c-tile h3 { margin: 0 0 8px; }
.c-tile p { margin: 0 0 12px; }
.c-tile p:last-child { margin-bottom: 0; }
.c-card-grid {
  list-style: none; margin: 24px 0 0; padding: 0;
  display: grid; grid-template-columns: 1fr; gap: 20px;
}

/* ============ Tabs ============ */
.c-tab-list {
  display: flex; flex-wrap: wrap; gap: 10px; margin-top: 24px;
}
.c-tab {
  font-family: var(--font-head); font-size: 1rem; font-weight: 600;
  min-height: 48px; padding: 0 22px; cursor: pointer;
  border: 1px solid var(--line); border-radius: var(--radius-btn);
  background: var(--surface); color: var(--text);
  transition: background-color .25s ease, color .25s ease, border-color .25s ease;
}
.c-tab:hover { border-color: var(--accent); color: var(--accent); }
.c-tab[aria-selected="true"] {
  background: var(--accent); color: var(--accent-text); border-color: var(--accent);
}
.c-tab-panel { padding-top: 8px; }

/* ============ Compare table ============ */
.c-table-wrap { overflow-x: auto; margin-top: 24px; border-radius: var(--radius-card); box-shadow: var(--shadow); background: var(--surface); }
.c-compare { width: 100%; border-collapse: collapse; min-width: 640px; }
.c-compare th, .c-compare td { padding: 14px 16px; text-align: left; border-bottom: 1px solid var(--line); }
.c-compare thead th { font-family: var(--font-head); font-weight: 700; background: var(--soft); }
.c-compare tbody th[scope="row"] { font-family: var(--font-head); font-weight: 600; }
.c-compare tbody tr:last-child th, .c-compare tbody tr:last-child td { border-bottom: none; }

/* ============ Buttons ============ */
.c-btn {
  display: inline-flex; align-items: center; justify-content: center;
  min-height: 48px; padding: 0 26px;
  font-family: var(--font-head); font-size: 1rem; font-weight: 600;
  text-decoration: none; border: none; cursor: pointer;
  border-radius: var(--radius-btn);
  background-image: linear-gradient(120deg, var(--accent) 0%, var(--accent-deep) 60%, var(--accent) 100%);
  background-color: var(--accent);
  background-size: 220% 100%; background-position: 0% 50%;
  color: var(--accent-text);
  transition: background-position .35s ease, transform .15s ease, box-shadow .25s ease;
}
.c-btn:hover { background-color: var(--accent-deep); background-position: 100% 50%; box-shadow: var(--shadow); }
.c-btn:focus-visible {
  outline: 3px solid var(--accent); outline-offset: 3px;
  box-shadow: 0 0 0 6px rgb(154 79 20 / .3);
}
.c-btn:active { transform: scale(0.97); }
.c-btn-quiet {
  background: transparent; color: var(--accent);
  border: 2px solid var(--accent);
  background-image: none;
}
.c-btn-quiet:hover { background: var(--accent); color: var(--accent-text); }

/* ============ Form ============ */
.c-brief-form {
  background: var(--surface); border-radius: var(--radius-card);
  box-shadow: var(--shadow); padding: clamp(24px, 4vw, 40px);
  margin-top: 32px; max-width: 760px;
  display: grid; gap: 20px;
}
.c-field { display: grid; gap: 6px; }
.c-field-name { font-family: var(--font-head); font-weight: 600; font-size: 1rem; }
.c-field-box {
  font: inherit; color: var(--text);
  border: 1px solid var(--line); border-radius: var(--radius-card);
  padding: 12px 14px; min-height: 48px; width: 100%;
  background: var(--bg);
}
.c-field-box::placeholder { color: var(--muted); opacity: 1; }
.c-field-area { min-height: 120px; resize: vertical; }
.c-field-check { display: flex; gap: 10px; align-items: flex-start; font-size: 0.95em; }
.c-field-check input { width: 20px; height: 20px; margin-top: 3px; accent-color: var(--accent); flex: none; }
.c-field-check label { max-width: 60ch; }
.is-invalid .c-field-box, .c-field-box.is-invalid { border-color: #A32E0E; box-shadow: 0 0 0 3px rgb(163 46 14 / .18); }
.is-sending .c-form-send { opacity: .7; pointer-events: none; }
.c-form-note { color: var(--muted); font-size: 0.95em; margin: 0; }
.c-form-send { justify-self: start; }

/* ============ FAQ ============ */
.c-accordion { display: grid; gap: 14px; margin-top: 24px; max-width: 860px; }
.c-accordion-item {
  background: var(--surface); border-radius: var(--radius-card);
  box-shadow: var(--shadow); padding: 4px clamp(18px, 3vw, 28px);
}
.c-accordion-item summary {
  font-family: var(--font-head); font-weight: 600; font-size: 1.05rem;
  padding: 16px 0; cursor: pointer; list-style: none; position: relative;
  padding-right: 36px;
}
.c-accordion-item summary::-webkit-details-marker { display: none; }
.c-accordion-item summary::after {
  content: ""; position: absolute; right: 4px; top: 50%;
  width: 10px; height: 10px; border-right: 2px solid var(--accent);
  border-bottom: 2px solid var(--accent);
  transform: translateY(-70%) rotate(45deg);
  transition: transform .25s ease;
}
.c-accordion-item[open] summary::after { transform: translateY(-30%) rotate(225deg); }
.c-accordion-item p { margin: 0 0 18px; color: var(--muted); }

/* ============ Floating panel ============ */
.c-quick-panel { display: none; }

/* ============ Footer ============ */
.l-foot { background: var(--plate-bg); color: var(--plate-text); padding: clamp(48px, 6vw, 80px) 0 24px; }
.l-foot-grid { display: grid; grid-template-columns: 1fr; gap: 32px; }
.l-foot .c-brandmark { color: var(--plate-text); margin: 0 0 12px; max-width: none; }
.l-foot address { font-style: normal; color: var(--plate-text); }
.l-foot address p { color: var(--plate-text); margin: 0 0 8px; }
.l-foot-title { font-size: 1.1rem; color: var(--plate-text); margin: 0 0 12px; }
.l-foot ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.l-foot-links a { color: var(--plate-text); text-decoration: none; border-bottom: 1px solid rgb(246 242 234 / .35); }
.l-foot-links a:hover { color: #fff; border-bottom-color: #fff; }
.l-foot ul[role="list"] span, .l-foot li span { color: var(--line); font-family: var(--font-head); font-size: .85rem; display: block; }
.l-foot a[href^="mailto:"], .l-foot a[href^="tel:"] { color: var(--plate-text); }
.l-foot-base { border-top: 1px solid rgb(246 242 234 / .2); margin-top: 32px; padding-top: 20px; }
.l-foot-copy { color: var(--line); font-size: .9rem; margin: 0; }

/* ============ Inner pages ============ */
.c-page-head { padding-top: clamp(40px, 6vw, 72px); }
.c-page-head h1 { margin: 0 0 12px; }
.c-page-head p { color: var(--muted); font-size: 1.1em; margin: 0; }
.c-steps { list-style: none; margin: 24px 0 0; padding: 0; display: grid; gap: 16px; counter-reset: step; max-width: 860px; }
.c-steps li { counter-increment: step; position: relative; padding-left: 56px; }
.c-steps li::before {
  content: counter(step);
  position: absolute; left: 0; top: 0;
  width: 40px; height: 40px; border-radius: 50%;
  background: var(--accent); color: var(--accent-text);
  font-family: var(--font-head); font-weight: 700;
  display: flex; align-items: center; justify-content: center;
}
.c-gallery { display: grid; grid-template-columns: 1fr; gap: 20px; margin-top: 32px; }
.c-gallery figure { margin: 0; border-radius: var(--radius-card); overflow: hidden; box-shadow: var(--shadow); }
.c-gallery img { width: 100%; height: 100%; object-fit: cover; transition: transform .5s ease; }
.c-gallery figure:hover img { transform: scale(1.04); }
.c-contact-list { list-style: none; margin: 16px 0 0; padding: 0; display: grid; gap: 12px; }
.c-contact-list span { font-family: var(--font-head); font-weight: 600; display: block; font-size: .95rem; }
.c-thanks-actions, .c-lost-actions { display: flex; flex-wrap: wrap; gap: 14px; margin-top: 28px; }
.c-frame { position: relative; }
.c-frame img { transition: transform .5s ease; }
.c-frame:hover img { transform: scale(1.03); }

/* ============ Reveal ============ */
html.is-js .u-fade { opacity: 0; transform: translateY(12px); transition: opacity .6s ease, transform .6s ease; }
html.is-js .u-fade.is-visible { opacity: 1; transform: none; }

/* ============ Responsive ============ */
@media (max-width: 1279px) {
  .l-hero-collage { gap: 16px; }
}
@media (max-width: 1023px) {
  .l-split { grid-template-columns: 1fr; }
  .c-card-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 767px) {
  .c-menu-btn { display: inline-flex; }
  .c-menu-list {
    display: none; flex-direction: column; gap: 0;
    width: 100%; padding: 8px 0 4px;
  }
  .c-menu.is-open .c-menu-list { display: flex; }
  .c-menu-link { padding: 12px 8px; border-bottom: 1px solid var(--line); background-size: 0% 100%; }
  .c-menu-link:hover { background-size: 100% 100%; }
  .c-brandmark { margin-left: 0; max-width: none; }
  .l-topbar-inner { justify-content: space-between; }
  .c-quick-panel {
    display: block; position: sticky; bottom: 0; z-index: 50;
    background: var(--surface); border-top: 1px solid var(--line);
    padding: 12px var(--pad-x) calc(12px + env(safe-area-inset-bottom, 0px));
    text-align: center; box-shadow: 0 -8px 24px rgb(0 0 0 / .08);
  }
  .c-quick-panel .c-btn { width: auto; max-width: 320px; }
}
@media (max-width: 639px) {
  .c-card-grid { grid-template-columns: 1fr; }
  .l-hero-collage { grid-template-columns: 1fr; }
}
@media (max-width: 479px) {
  body { font-size: 1rem; }
  .c-tab-list { gap: 8px; }
  .c-tab { padding: 0 16px; font-size: .95rem; }
  .c-hero-shot img { aspect-ratio: 4 / 3; }
  .l-hero-actions .c-btn { width: auto; max-width: 320px; }
}
@media (min-width: 768px) {
  .l-foot-grid { grid-template-columns: 1.4fr 1fr 1fr; }
  .c-gallery { grid-template-columns: repeat(2, 1fr); }
}
@media (min-width: 1024px) {
  .c-card-grid { grid-template-columns: repeat(3, 1fr); }
}
@media (max-height: 600px) {
  .has-hero { padding-top: 40px; }
  .l-hero-collage { margin-top: 24px; }
  html.is-js .u-hero-line { animation: none; }
}

/* ============ Motion ============ */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: .01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: .01ms !important;
  }
  html.is-js .u-fade { opacity: 1; transform: none; }
  html.is-js .u-hero-line { animation: none; }
}

/* ============ Rhythm fixes ============ */
#owner-note .c-plate { line-height: 1.6; }
#owner-note .c-plate p { max-width: 62ch; margin: 0 auto; }
#top-collage h1 { max-width: 20ch; margin-inline: auto; }
#top-collage .l-hero-lead { max-width: 56ch; margin-inline: auto; }
.has-hero { padding-bottom: 64px; }
.l-split-text { min-width: 0; }
.c-area-list .c-tile,
.c-card-grid .c-tile { display: flex; flex-direction: column; gap: 8px; align-items: flex-start; }
.c-card-grid { grid-auto-rows: 1fr; align-items: stretch; }
.c-tab { padding: 10px 20px; }
.c-tab-list { flex-wrap: wrap; gap: 10px; }

.u-prose .c-plate p { color: var(--plate-text) !important; }

/* ============ Reveal fallbacks ============ */
html.is-js .c-tab-panel .u-fade,
html.is-js [hidden] .u-fade { opacity: 1; transform: none; }
html.is-js details .u-fade { opacity: 1; transform: none; }
