/* Shared header, footer and attribution chrome. Loaded after theme.css. */

body {
  --header-bg: color-mix(in srgb, var(--surface) 96%, white);
  --nav-ink: var(--ink);
  --footer-ink: var(--ink);
  --footer-muted: color-mix(in srgb, var(--footer-ink) 72%, transparent);
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 30;
  background: var(--header-bg);
  color: var(--nav-ink);
  border-bottom: 1px solid var(--line);
  backdrop-filter: blur(18px);
}
.header-inner {
  min-height: 72px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  position: relative;
}
.brand {
  min-width: 0;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: inherit;
  text-decoration: none;
  font-size: .83rem;
  font-weight: 750;
  letter-spacing: -.025em;
}
.brand-logo { width: 34px; height: 34px; border-radius: 50%; object-fit: cover; }
.brand-name { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 230px; }
.nav { display: flex; align-items: center; justify-content: flex-end; gap: 22px; }
.nav a {
  color: var(--nav-ink);
  text-decoration: none;
  font-size: .78rem;
  font-weight: 650;
  white-space: nowrap;
  opacity: 1;
}
.nav a.active,
.nav a:hover {
  color: var(--nav-ink);
  text-decoration: underline;
  text-underline-offset: 4px;
}
.nav-toggle {
  display: none;
  color: var(--nav-ink);
  background: transparent;
  border: 1px solid color-mix(in srgb, var(--nav-ink) 28%, transparent);
  border-radius: 999px;
  padding: 7px 12px;
  font-size: .72rem;
}

body.header-static .site-header {
  position: relative;
}
body.header-sticky .site-header {
  position: sticky;
  top: 0;
}
body.header-transparent .site-header {
  position: absolute;
  inset: 0 0 auto 0;
  background: linear-gradient(to bottom, rgba(0, 0, 0, .58), rgba(0, 0, 0, 0));
  border-bottom: 0;
  color: #fff;
  --nav-ink: #fff;
}
body.header-transparent.is-scrolled .site-header {
  position: sticky;
  background: var(--header-bg);
  border-bottom: 1px solid var(--line);
  color: var(--ink);
  --nav-ink: var(--ink);
}

body.theme-editorial .site-header.editorial-header.over-hero {
  background: linear-gradient(to bottom, rgba(0, 0, 0, .58), rgba(0, 0, 0, 0));
  border-bottom: 0;
  position: absolute;
  inset: 0 0 auto 0;
  color: #fff;
  --nav-ink: #fff;
  z-index: 5;
}
body.theme-editorial .site-header.editorial-header.solid,
body.theme-editorial.header-sticky .site-header.editorial-header,
body.theme-editorial.is-scrolled .site-header.editorial-header {
  position: sticky;
  top: 0;
  z-index: 5;
  background: var(--header-bg);
  border-bottom: 1px solid var(--line);
  color: var(--nav-ink);
}

body.theme-brasserie .brasserie-header {
  border-bottom: 1px solid var(--line);
  background: var(--header-bg);
}
body.theme-brasserie .header-inner {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  min-height: 88px;
}
body.theme-brasserie .centered-brand {
  justify-self: center;
  text-align: center;
  font-size: 1.35rem;
  letter-spacing: .12em;
  text-transform: uppercase;
}
body.theme-brasserie .nav-left { justify-content: flex-start; }
body.theme-brasserie .nav-right { justify-content: flex-end; }

@media (max-width: 920px) {
  .nav-toggle { display: inline-flex; }
  .nav {
    display: none;
    position: absolute;
    top: calc(100% + 1px);
    left: 0;
    right: 0;
    padding: 20px;
    background: var(--header-bg);
    color: var(--nav-ink);
    border-bottom: 1px solid var(--line);
    box-shadow: var(--shadow);
    z-index: 40;
  }
  .nav.open { display: grid; }
  .nav a { padding: 8px 0; font-size: .82rem; }
  body.theme-brasserie .header-inner { grid-template-columns: 1fr auto; }
  body.theme-brasserie .nav-left,
  body.theme-brasserie .nav-right {
    display: none;
  }
  body.theme-brasserie .nav-left.open,
  body.theme-brasserie .nav-right.open {
    display: grid;
  }
}

/* Footer presets */
.site-footer {
  border-top: 1px solid var(--line);
  padding: 48px 0 0;
  color: var(--footer-ink);
  background: color-mix(in srgb, var(--surface) 94%, white);
}
.footer-grid { display: grid; grid-template-columns: 1.3fr 1fr .7fr; gap: 38px; }
.footer-brand strong { font-size: 1.4rem; letter-spacing: -.04em; display: block; }
.footer-brand p, .footer-contact p, .footer-hours li { color: var(--footer-muted); font-size: .78rem; }
.footer-label {
  color: var(--footer-muted);
  font-size: .62rem;
  font-weight: 750;
  text-transform: uppercase;
  letter-spacing: .16em;
  display: block;
  margin-bottom: 8px;
}
.social { display: flex; flex-direction: column; gap: 8px; }
.social a, .footer-links a {
  color: var(--footer-ink);
  text-decoration: none;
  font-size: .78rem;
}
.social a:hover, .footer-links a:hover { text-decoration: underline; }
.footer-links { display: flex; flex-direction: column; gap: 8px; }
.footer-hours { list-style: none; margin: 0; padding: 0; display: grid; gap: 4px; }
.footer-hours li { display: flex; justify-content: space-between; gap: 12px; }
.footer-note { margin: 18px 0 0; color: var(--footer-muted); font-size: .78rem; }

.site-footer.footer-minimal .footer-grid {
  grid-template-columns: 1fr;
  text-align: center;
  justify-items: center;
}
.site-footer.footer-minimal .social,
.site-footer.footer-minimal .footer-links { flex-direction: row; flex-wrap: wrap; justify-content: center; gap: 10px 18px; }

.site-footer.footer-split .footer-grid {
  grid-template-columns: 1.4fr 1fr 1fr;
}

.site-footer.footer-bold {
  background: var(--ink);
  color: var(--surface);
  --footer-ink: var(--surface);
  --footer-muted: color-mix(in srgb, var(--surface) 74%, transparent);
  border-top: 0;
}
.site-footer.footer-bold .social a,
.site-footer.footer-bold .footer-links a { color: var(--surface); }

.site-attribution {
  margin-top: 36px;
  padding: 14px 0 18px;
  border-top: 1px solid color-mix(in srgb, var(--footer-ink) 16%, transparent);
  text-align: center;
  font-size: .68rem;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--footer-muted);
}
.site-attribution a {
  color: inherit;
  text-decoration: none;
  font-weight: 720;
}
.site-attribution a:hover { text-decoration: underline; }

@media (max-width: 920px) {
  .footer-grid { grid-template-columns: 1fr; }
  .site-footer.footer-split .footer-grid { grid-template-columns: 1fr; }
}

@media (max-width: 620px) {
  .header-inner { min-height: 62px; }
  .footer-grid { gap: 28px; }
}

/* Editor overlay outlines — only when the builder bridge is present. */
body.builder-editing .cms-section {
  outline: 1px dashed transparent;
  outline-offset: -2px;
  cursor: pointer;
}
body.builder-editing .cms-section.is-hovered {
  outline-color: color-mix(in srgb, var(--accent) 70%, white);
}
body.builder-editing .cms-section.is-selected {
  outline: 2px solid var(--accent);
}
body.builder-editing .cms-section.is-hidden-draft {
  opacity: .45;
}
