/* ==========================================================================
   Barber Shop Demo
   Order: tokens, base, header, sections, form, footer, responsive.
   ========================================================================== */

/* ── Tokens ─────────────────────────────────────────────────────────── */
:root {
  --c-text: #1f1a17;
  --c-bg: #f6f1ea;
  --c-accent: #7a1f1f;
  --c-dark: #1f1a17;
  --c-muted: #6b625a;
  --c-line: #d9cfc2;
  --c-error: #b00020;

  /* Fonts from Site Core (config.php 'fonts'): the real font once configured, otherwise the fallback */
  --f-body: var(--sc-webfont-body, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif);
  --f-display: var(--sc-webfont-display, Georgia, "Times New Roman", serif);

  --fs-body: 1rem;
  --lh-body: 1.5;

  --content: 1200px;
  --gutter: clamp(20px, 6vw, 120px);

  --focus: 2px solid currentColor;
}

/* ── Base ──────────────────────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; }
body { margin: 0; background: var(--c-bg); color: var(--c-text); font: var(--fs-body)/var(--lh-body) var(--f-body); }
img, svg, video { display: block; max-width: 100%; height: auto; }
a { color: inherit; }
:focus-visible { outline: var(--focus); outline-offset: 3px; }
.visually-hidden { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip-link { position: absolute; left: 8px; top: -100px; z-index: 100; padding: 8px 14px; background: var(--c-bg); color: var(--c-text); }
.skip-link:focus { top: 8px; }
.site-main:focus { outline: none; }
.rich > :first-child { margin-top: 0; }
.rich > :last-child { margin-bottom: 0; }

/* ── Header ───────────────────────────────────────────────────────────── */
.site-header { display: flex; align-items: center; justify-content: space-between; gap: 24px; padding: 20px var(--gutter); }
.site-header__logo svg { height: 40px; width: auto; }
.site-header__toggle { display: none; }
.site-nav { display: flex; align-items: center; gap: 32px; }
.site-nav__list, .site-nav__langs { display: flex; gap: 24px; margin: 0; padding: 0; list-style: none; }
.site-nav__link[aria-current="page"], .site-nav__sublink[aria-current="page"], .site-nav__langs [aria-current] { text-decoration: underline; }
/* Second level (sc_nav): bare structure, style it per site */
.site-nav__sub { margin: 0; padding: 0; list-style: none; }
.site-nav__heading { font-weight: 700; }

/* ── Sections ─────────────────────────────────────────────────────── */
.section { width: min(100% - 2 * var(--gutter), var(--content)); margin-inline: auto; padding-block: 64px; }
.hero { position: relative; }
.hero__image { width: 100%; height: auto; }

h1, h2, h3 { font-family: var(--f-display); font-weight: 400; line-height: 1.15; }
.section--narrow { max-width: 760px; }
.section__title { margin: 0 0 24px; font-size: clamp(2rem, 4vw, 3rem); }
.section__body { max-width: 640px; margin-bottom: 40px; color: var(--c-muted); }
.section__more a { color: var(--c-accent); font-weight: 600; text-decoration: none; }
.button { display: inline-block; padding: 14px 28px; background: var(--c-accent); color: #fff; text-decoration: none; letter-spacing: .04em; }
.button:hover { background: #5e1717; }

.hero { min-height: min(80vh, 720px); display: grid; overflow: hidden; background: var(--c-dark); }
.hero > * { grid-area: 1 / 1; }
.hero__image { width: 100%; height: 100%; object-fit: cover; opacity: .55; }
.hero__text { align-self: end; padding: 64px var(--gutter); color: #fff; }
.hero__title { margin: 0 0 12px; font-size: clamp(2.5rem, 7vw, 5.5rem); }
.hero__subtitle { margin: 0 0 32px; font-size: 1.25rem; }

/* Price list */
.prices { display: grid; gap: 28px; margin: 0; padding: 0; list-style: none; max-width: 760px; }
.prices__head { display: flex; align-items: baseline; gap: 12px; }
.prices__name { margin: 0; font-size: 1.5rem; }
.prices__dots { flex: 1; border-bottom: 2px dotted var(--c-line); }
.prices__price { font-weight: 700; color: var(--c-accent); white-space: nowrap; }
.prices__time { margin: 4px 0 0; font-size: .875rem; color: var(--c-muted); }
.prices__body { margin-top: 6px; }

/* Team */
.team { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 40px; margin: 0; padding: 0; list-style: none; }
.team__image { width: 100%; aspect-ratio: 4 / 5; object-fit: cover; }
.team__name { margin: 16px 0 0; font-size: 1.75rem; }
.team__role { margin: 4px 0 8px; color: var(--c-accent); text-transform: uppercase; letter-spacing: .08em; font-size: .8rem; }

/* ── Form (default markup of sc_form) ─────────────────────────── */
.form { display: grid; gap: 16px; max-width: 640px; }
.form__field { display: grid; gap: 6px; }
.form__label { font-weight: 600; }
.form__input { width: 100%; padding: 10px 12px; font: inherit; color: inherit; background: var(--c-bg); border: 1px solid var(--c-line); border-radius: 0; }
.form__check { display: flex; gap: 10px; align-items: flex-start; }
.form__check input { margin-top: .3em; }
.form__group { border: 0; margin: 0; padding: 0; display: grid; gap: 8px; }
.form__field--error .form__input { border-color: var(--c-error); }
.form__error, .form__message--error { color: var(--c-error); margin: 0; }
.form__submit { justify-self: start; padding: 12px 28px; font: inherit; color: #fff; background: var(--c-accent); border: 0; cursor: pointer; }
.form--sent .form__message { font-size: 1.25em; }

/* ── Footer ───────────────────────────────────────────────────────────── */
.site-footer { display: flex; flex-wrap: wrap; gap: 24px 64px; padding: 48px var(--gutter); background: var(--c-dark); color: #e9e1d6; }
.site-footer__contact { display: grid; gap: 4px; align-content: start; }
.site-footer__hours p { margin: 0; }
.site-footer__heading { font-weight: 700; margin-bottom: 4px !important; }
.site-footer__address { font-style: normal; }
.site-footer__legal { display: flex; gap: 20px; margin: 0 0 0 auto; padding: 0; list-style: none; }

/* ── Responsive ───────────────────────────── */
@media (max-width: 900px) {
  .site-header__toggle { display: block; width: 44px; height: 44px; background: none; border: 0; padding: 0; color: inherit; cursor: pointer; }
  .site-header__burger, .site-header__burger::before, .site-header__burger::after { display: block; width: 24px; height: 2px; margin: auto; background: currentColor; position: relative; }
  .site-header__burger::before, .site-header__burger::after { content: ""; position: absolute; left: 0; }
  .site-header__burger::before { top: -7px; }
  .site-header__burger::after { top: 7px; }
  .site-nav { display: none; position: fixed; inset: 0; z-index: 50; flex-direction: column; justify-content: center; background: var(--c-bg); }
  .site-nav.is-open { display: flex; }
  .site-nav__list { flex-direction: column; align-items: center; }
  .site-header__toggle[aria-expanded="true"] { position: fixed; top: 20px; right: var(--gutter); z-index: 60; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; scroll-behavior: auto !important; }
}
