/* Base */
:root {
  --bg: #F4F6FA;
  --surface: #FFFFFF;
  --text: #111827;
  --muted: #4B5563;
  --accent: #2F5BEA;
  --accent-text: #FFFFFF;
  --plate-bg: #111827;
  --plate-text: #FFFFFF;
  --line: #E5E7EB;
  --font-head: Optima, Candara, 'Segoe UI', 'Noto Sans', sans-serif;
  --font-body: Georgia, Cambria, 'Times New Roman', serif;
  --radius-card: 20px;
  --radius-btn: 10px;
  --pad-side: clamp(16px, 4vw, 40px);
  --shadow-soft: 0 1px 2px rgb(0 0 0 / .06), 0 12px 32px rgb(0 0 0 / .08);
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

html.has-menu-open,
body.has-menu-open { overflow: hidden; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-body);
  font-size: clamp(1rem, 0.96rem + 0.2vw, 1.125rem);
  line-height: 1.65;
  position: relative;
  overflow-x: hidden;
}

/* Background layer */
body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  background:
    radial-gradient(42% 38% at 12% 8%, rgb(47 91 234 / .18), transparent 70%),
    radial-gradient(38% 34% at 88% 22%, rgb(47 91 234 / .16), transparent 70%),
    radial-gradient(46% 40% at 78% 84%, rgb(47 91 234 / .14), transparent 72%),
    radial-gradient(40% 36% at 16% 90%, rgb(47 91 234 / .12), transparent 68%);
}

img { max-width: 100%; height: auto; display: block; }
.c-photo { width: 100%; object-fit: cover; border-radius: var(--radius-card); }

h1, h2, h3, h4 {
  font-family: var(--font-head);
  font-weight: 700;
  line-height: 1.15;
  letter-spacing: -0.01em;
  margin: 0 0 0.5em;
}

h1 { font-size: clamp(2.4rem, 4.6vw + 0.6rem, 4.6rem); line-height: 1.08; letter-spacing: -0.02em; }
h2 { font-size: clamp(1.8rem, 2.6vw + 0.8rem, 3rem); }
h3 { font-size: clamp(1.2rem, 1vw + 0.9rem, 1.5rem); }
p { margin: 0 0 1em; max-width: 62ch; line-height: 1.6; }
a { color: var(--accent); text-underline-offset: 3px; }
a:hover { color: #1d3fbe; }

.l-wrap { max-width: 1200px; margin: 0 auto; padding: 0 var(--pad-side); }
.l-wrap-narrow { max-width: 760px; }
.l-block { padding: clamp(64px, 9vw, 128px) 0; }
.l-block + .l-block { padding-top: 0; }
.l-block:nth-of-type(even) { background: rgb(255 255 255 / .55); }

.u-skip {
  position: absolute;
  left: -9999px;
  top: 0;
  background: var(--plate-bg);
  color: var(--plate-text);
  padding: 12px 20px;
  z-index: 100;
}
.u-skip:focus { left: 12px; top: 12px; }

.u-accent {
  font-style: normal;
  color: var(--accent);
  letter-spacing: -0.02em;
}

/* Typography accents */
.c-block-title { margin-bottom: 16px; }
.c-block-lead { color: var(--muted); font-size: 1.05em; margin-bottom: 32px; }

/* Header */
.c-masthead { background: var(--surface); border-bottom: 1px solid var(--line); }
.c-masthead-topline { background: var(--plate-bg); color: var(--plate-text); font-size: 14px; }
.c-masthead-contacts {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 24px;
  justify-content: center;
  padding-top: 6px;
  padding-bottom: 6px;
  font-family: var(--font-head);
}
.c-masthead-contacts a { color: var(--plate-text); }
.c-masthead-bar {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 16px;
  min-height: 72px;
  position: relative;
  z-index: 70;
  background: var(--surface);
}
.c-brand {
  font-family: var(--font-head);
  font-weight: 700;
  font-size: 1.25rem;
  color: var(--text);
  text-decoration: none;
  text-align: center;
  white-space: nowrap;
}
.c-brand:hover { color: var(--text); }
.c-menu { display: flex; gap: 24px; align-items: center; }
.c-menu-side:first-of-type { justify-content: flex-end; }
.c-menu-link {
  font-family: var(--font-head);
  font-size: 16px;
  color: var(--text);
  text-decoration: none;
  position: relative;
  padding: 4px 0;
}
.c-menu-link::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: 0;
  height: 2px;
  width: 100%;
  background: var(--accent);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.25s ease;
}
.c-menu-link:hover::after,
.c-menu-link:focus-visible::after,
.c-menu-link[aria-current="page"]::after { transform: scaleX(1); }
.c-menu-link:hover { color: var(--accent); }
.c-menu-link[aria-current="page"] { color: var(--accent); }

.c-menu-btn {
  display: none;
  min-height: 48px;
  padding: 0 20px;
  border: 1px solid var(--line);
  border-radius: var(--radius-btn);
  background: var(--surface);
  color: var(--text);
  font-family: var(--font-head);
  font-size: 16px;
  cursor: pointer;
  transition: background-color 0.2s ease, color 0.2s ease, border-color 0.2s ease;
}
.c-menu-btn:hover { background: var(--accent); border-color: var(--accent); color: var(--accent-text); }
.c-menu-btn:focus-visible { outline: 3px solid var(--accent); outline-offset: 2px; }
.c-menu-btn:active { transform: translateY(1px); }
.has-menu-open .c-menu-btn { background: var(--accent); border-color: var(--accent); color: var(--accent-text); }

/* Menu overlay */
.c-menu-overlay { display: none; }
.has-menu-open .c-menu-overlay {
  display: flex;
  position: fixed;
  inset: 0;
  background: var(--surface);
  z-index: 60;
  align-items: center;
  justify-content: center;
  overflow-y: auto;
  padding: clamp(96px, 16vh, 140px) var(--pad-side) 48px;
}
.has-menu-open .c-menu-full {
  flex-direction: column;
  gap: 28px;
  text-align: center;
}
.has-menu-open .c-menu-full .c-menu-link {
  font-size: 1.4rem;
  opacity: 1;
  animation: menuRise 0.45s ease both;
}
.has-menu-open .c-menu-full .c-menu-link:nth-child(1) { animation-delay: 0.05s; }
.has-menu-open .c-menu-full .c-menu-link:nth-child(2) { animation-delay: 0.12s; }
.has-menu-open .c-menu-full .c-menu-link:nth-child(3) { animation-delay: 0.19s; }
.has-menu-open .c-menu-full .c-menu-link:nth-child(4) { animation-delay: 0.26s; }
.has-menu-open .c-menu-full .c-menu-link:nth-child(5) { animation-delay: 0.33s; }
@keyframes menuRise {
  from { opacity: 0; transform: translateY(10px); }
  to { opacity: 1; transform: translateY(0); }
}

/* Hero */
.l-block-hero { padding-top: clamp(48px, 6vw, 88px); }
.l-hero {
  display: grid;
  grid-template-columns: 55fr 45fr;
  gap: clamp(24px, 5vw, 64px);
  align-items: center;
  min-height: auto;
}
.c-hero-title { margin-bottom: 20px; max-width: 18ch; text-wrap: balance; }
.c-hero-title .u-accent { text-wrap: balance; }
.c-hero-title .c-hero-line { display: block; }
.c-hero-line { opacity: 1; transform: translateY(0); animation: lineUp 0.5s ease both; }
.c-hero-line:nth-child(2) { animation-delay: 0.12s; }
.c-hero-line:nth-child(3) { animation-delay: 0.24s; }
@keyframes lineUp {
  from { opacity: 0.4; transform: translateY(8px); }
  to { opacity: 1; transform: translateY(0); }
}
.c-hero-lead { color: var(--muted); margin-bottom: 28px; }
.l-hero-actions { display: flex; flex-wrap: wrap; gap: 16px 24px; align-items: center; }
.l-hero-photo { margin: 0; }
.l-hero-photo .c-photo {
  aspect-ratio: 3 / 4;
  max-height: 80vh;
  border-radius: 16px;
  object-fit: cover;
  box-shadow: 0 20px 40px rgb(17 24 39 / .08);
}

/* Buttons */
.c-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  padding: 0 26px;
  border: none;
  border-radius: var(--radius-btn);
  background: var(--accent);
  color: var(--accent-text);
  font-family: var(--font-head);
  font-weight: 600;
  font-size: 16px;
  text-decoration: none;
  cursor: pointer;
  transition: background-color 0.2s ease, color 0.2s ease, transform 0.1s ease;
}
.c-btn:hover { background: var(--plate-bg); color: var(--plate-text); }
.c-btn:focus-visible { outline: 3px solid var(--accent); outline-offset: 2px; }
.c-btn:active { transform: translateY(1px); }
.c-btn-quiet {
  display: inline-flex;
  align-items: center;
  min-height: 48px;
  padding: 0 8px;
  background: none;
  border: none;
  border-radius: var(--radius-btn);
  font-family: var(--font-head);
  font-weight: 600;
  font-size: 16px;
  color: var(--accent);
  text-decoration: underline;
  text-decoration-thickness: 2px;
  text-underline-offset: 4px;
  cursor: pointer;
  transition: color 0.2s ease, transform 0.1s ease;
}
.c-btn-quiet:hover { color: #1d3fbe; }
.c-btn-quiet:focus-visible { outline: 3px solid var(--accent); outline-offset: 2px; }
.c-btn-quiet:active { transform: translateY(1px); }

/* Zigzag */
.l-zigzag,
.l-zigzag-rev {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 64px;
  align-items: center;
}
.l-zigzag + .l-zigzag { margin-top: 48px; }
.l-zigzag-photo { margin: 0; }
.l-zigzag-photo .c-photo { aspect-ratio: 4 / 3; }
.l-zigzag-rev .l-zigzag-photo { order: -1; }

/* Tabs */
.c-tabs-bar { display: flex; flex-wrap: wrap; gap: 8px 24px; margin-bottom: 28px; }
.c-tab {
  min-height: 48px;
  background: none;
  border: none;
  border-bottom: 3px solid transparent;
  padding: 12px 4px;
  border-radius: var(--radius-btn) var(--radius-btn) 0 0;
  font-family: var(--font-head);
  font-weight: 600;
  font-size: 16px;
  color: var(--muted);
  cursor: pointer;
  transition: color 0.2s ease, border-color 0.2s ease;
}
.c-tab:hover { color: var(--accent); }
.c-tab:focus-visible { outline: 3px solid var(--accent); outline-offset: -3px; }
.c-tab:active { transform: translateY(1px); }
.c-tab[aria-selected="true"] { color: var(--accent); border-bottom-color: var(--accent); }

/* Cards */
.l-cards {
  display: grid;
  grid-template-columns: 1fr 1fr;
  align-items: stretch;
  gap: 24px;
}
.c-card {
  background: var(--surface);
  border-radius: var(--radius-card);
  padding: 28px;
  box-shadow: var(--shadow-soft);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
  height: 100%;
  display: flex;
  flex-direction: column;
}
.c-card:hover { transform: translateY(-6px); box-shadow: 0 2px 4px rgb(0 0 0 / .07), 0 18px 40px rgb(0 0 0 / .12); }
.c-card h3 { margin-bottom: 10px; }
.c-card p { margin: 0; color: var(--muted); }

/* Gallery */
.l-gallery {
  display: grid;
  grid-template-columns: 3fr 2fr;
  align-items: stretch;
  gap: 24px;
}
.l-gallery .c-photo { aspect-ratio: 4 / 3; object-fit: cover; }
.c-frame { margin: 0; }
.c-frame-wide .c-photo { aspect-ratio: 4 / 3; }
.c-frame-mat {
  background: var(--surface);
  padding: 12px;
  border-radius: var(--radius-card);
  box-shadow: var(--shadow-soft);
}
.c-frame-mat .c-photo { aspect-ratio: 1 / 1; }
.c-frame-tall .c-photo { aspect-ratio: 3 / 4; }

/* FAQ */
.c-faq { display: grid; gap: 14px; }
.c-faq-item {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius-card);
  padding: 4px 24px;
}
.c-faq-item summary {
  font-family: var(--font-head);
  font-weight: 600;
  font-size: 1.05rem;
  padding: 18px 0;
  cursor: pointer;
  list-style-position: outside;
}
.c-faq-item summary:focus-visible { outline: 3px solid var(--accent); outline-offset: 2px; border-radius: 6px; }
.c-faq-item[open] summary { color: var(--accent); }
.c-faq-item p { color: var(--muted); margin: 0 0 20px; }

/* Form */
.c-form {
  background: var(--surface);
  border-radius: var(--radius-card);
  padding: clamp(24px, 4vw, 40px);
  box-shadow: var(--shadow-soft);
  display: grid;
  gap: 20px;
}
.c-form-field { display: grid; gap: 8px; }
.c-form-label { font-family: var(--font-head); font-weight: 600; font-size: 15px; }
.c-form-input {
  font-family: var(--font-body);
  font-size: 16px;
  color: var(--text);
  padding: 12px 14px;
  min-height: 48px;
  border: 1px solid var(--line);
  border-radius: var(--radius-btn);
  background: var(--bg);
  width: 100%;
}
.c-form-input::placeholder { color: var(--muted); opacity: 1; }
.c-form-input:focus { outline: 3px solid var(--accent); outline-offset: 1px; }
.is-invalid { border-color: #b42318; }
.c-form-area { resize: vertical; min-height: 120px; }
.c-form-check { display: flex; gap: 10px; align-items: flex-start; font-size: 15px; color: var(--muted); }
.c-form-check input { width: 20px; height: 20px; margin-top: 2px; accent-color: var(--accent); }
.c-form-note { font-size: 14px; color: var(--muted); margin: 0; }
.c-form-send { justify-self: start; }
.is-sending { opacity: 0.6; pointer-events: none; }

/* Plate */
.c-plate {
  background: var(--plate-bg);
  color: var(--plate-text);
  border-radius: var(--radius-card);
  padding: clamp(32px, 5vw, 56px);
}
.c-plate-title { color: var(--plate-text); }
.c-plate-body { display: flex; flex-wrap: wrap; gap: 24px 48px; align-items: center; justify-content: space-between; }
.c-plate-body ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; font-family: var(--font-head); }
.c-plate-body li span { color: #9ca3af; margin-right: 8px; font-size: 14px; }
.c-plate-body a { color: var(--plate-text); }
.c-plate-body a:hover { color: var(--plate-text); text-decoration: underline; }
.c-btn-plate { background: var(--plate-text); color: var(--plate-bg); }
.c-btn-plate:hover { background: var(--accent); color: var(--accent-text); }

/* Floating */
.c-call-btn {
  position: fixed;
  right: 16px;
  bottom: 84px;
  z-index: 50;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  padding: 0 24px;
  border-radius: 999px;
  background: var(--accent);
  color: var(--accent-text);
  font-family: var(--font-head);
  font-weight: 600;
  font-size: 16px;
  text-decoration: none;
  box-shadow: var(--shadow-soft);
  transition: background-color 0.2s ease, color 0.2s ease, transform 0.1s ease;
}
.c-call-btn:hover { background: var(--plate-bg); color: var(--plate-text); }
.c-call-btn:focus-visible { outline: 3px solid var(--accent); outline-offset: 2px; }
.c-call-btn:active { transform: translateY(1px); }

.c-notice {
  position: fixed;
  left: 16px;
  right: 16px;
  bottom: 16px;
  max-width: 720px;
  z-index: 55;
  display: flex;
  flex-wrap: wrap;
  gap: 12px 24px;
  align-items: center;
  justify-content: space-between;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius-card);
  padding: 16px 20px;
  box-shadow: var(--shadow-soft);
}
.c-notice[hidden] { display: none; }
.c-notice-text { margin: 0; font-size: 15px; }
.c-notice-close {
  font-family: var(--font-head);
  font-weight: 600;
  font-size: 14px;
  color: var(--text);
  background: none;
  border: none;
  cursor: pointer;
  padding: 8px 12px;
  min-height: 40px;
  border-radius: 6px;
}
.c-notice-close:hover { color: var(--accent); }
.c-notice-close:focus-visible { outline: 3px solid var(--accent); }

.c-announce { display: none; }

/* Footer */
.l-footer { background: var(--surface); border-top: 1px solid var(--line); padding: clamp(48px, 6vw, 80px) 0 0; margin-top: clamp(64px, 9vw, 128px); }
.l-footer-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 32px;
}
.c-brand-footer { font-family: var(--font-head); font-weight: 700; font-size: 1.1rem; margin: 0 0 12px; }
.l-footer address { font-style: normal; font-size: 15px; color: var(--muted); }
.l-footer address p { margin: 0 0 8px; max-width: none; }
.l-footer-title { font-size: 1rem; margin-bottom: 14px; }
.l-footer-links { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.l-footer-links a { color: var(--muted); text-decoration: none; }
.l-footer-links a:hover { color: var(--accent); text-decoration: underline; }
.l-footer-col .c-form-note { margin: 0; }
.l-footer-bottom { padding: 24px 0; border-top: 1px solid var(--line); margin-top: 40px; }
.l-footer-bottom p { margin: 0; font-size: 14px; color: var(--muted); }
footer ul { list-style: none; margin: 0; padding: 0; }
footer ul li { font-size: 15px; color: var(--muted); margin-bottom: 6px; }
footer ul li span { display: inline-block; min-width: 72px; color: var(--text); font-family: var(--font-head); font-weight: 600; }

/* Prose */
.u-prose { max-width: 760px; }
.u-prose h2 { font-size: clamp(1.4rem, 1.6vw + 0.9rem, 2rem); margin-top: 2em; }
.u-prose h3 { font-size: 1.2rem; margin-top: 1.6em; }
.u-prose ul, .u-prose ol { padding-left: 24px; margin-bottom: 1em; }
.u-prose li { margin-bottom: 6px; }
.u-prose table { width: 100%; border-collapse: collapse; margin: 1.5em 0; font-size: 0.95em; }
.u-prose th, .u-prose td { text-align: left; padding: 10px 12px; border-bottom: 1px solid var(--line); }
.u-prose th { font-family: var(--font-head); font-weight: 600; }

/* Inner pages */
.c-page-head { padding-top: clamp(40px, 5vw, 72px); }
.c-page-lead { color: var(--muted); font-size: 1.05em; margin-bottom: 32px; }
.c-links-list { list-style: none; padding: 0; display: grid; gap: 12px; }
.c-links-list a { font-weight: 600; }

/* Reveal */
html.is-ready .c-fade { opacity: 0; transform: translateY(16px); transition: opacity 0.5s ease, transform 0.5s ease; }
html.is-ready .c-fade.is-shown { opacity: 1; transform: none; }

/* Breakpoints */
@media (max-width: 1023px) {
  .l-footer-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 900px) {
  .c-menu-side { display: none; }
  .c-masthead-bar { grid-template-columns: 1fr auto; justify-content: space-between; }
  .c-menu-btn { display: inline-flex; align-items: center; justify-content: center; }
  .l-hero { grid-template-columns: 1fr; }
  .l-hero-photo { max-width: 560px; }
}
@media (max-width: 768px) {
  .l-zigzag, .l-zigzag-rev { grid-template-columns: 1fr; gap: 24px; }
  .l-zigzag + .l-zigzag { margin-top: 48px; }
  .l-zigzag-rev .l-zigzag-photo { order: 0; }
  .l-block > .l-wrap > * + * { margin-top: 48px; }
}
@media (max-width: 639px) {
  .l-cards { grid-template-columns: 1fr; }
  .l-gallery { grid-template-columns: 1fr; }
  .c-frame-mat { max-width: 480px; }
  .l-footer-grid { grid-template-columns: 1fr; }
  .c-plate-body { flex-direction: column; align-items: flex-start; }
}
@media (max-width: 479px) {
  .l-hero-actions { flex-direction: column; align-items: stretch; }
  .c-btn, .c-btn-quiet { width: 100%; justify-content: center; }
  .c-call-btn { bottom: 96px; right: 12px; }
  .c-notice { left: 8px; right: 8px; }
}

/* Reduced motion */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation: none !important;
    transition: none !important;
  }
  html { scroll-behavior: auto; }
  html.is-ready .c-fade { opacity: 1; transform: none; }
  .c-hero-line { opacity: 1; transform: none; }
  .has-menu-open .c-menu-full .c-menu-link { opacity: 1; transform: none; }
}
