/* =========================================
   CoreBistro — shared design system
   ========================================= */

:root {
  --bg-base: #FAF6F0;
  --bg-warm: #F5EFE3;
  --bg-tinted: #F5E8DC;
  --primary: #A85638;
  --primary-dark: #8E4429;
  --secondary: #5C6B3F;
  --secondary-dark: #475130;
  --ink: #2D2419;
  --muted: #6B5D4E;
  --rule: #E6DDCE;

  --font-display: "Fraunces", "Times New Roman", serif;
  --font-body: "DM Sans", -apple-system, BlinkMacSystemFont, "Segoe UI", system-ui, sans-serif;

  --container: 1200px;
  --gutter: 32px;
  --section-y: 96px;
}

*, *::before, *::after { box-sizing: border-box; }

html { scroll-behavior: smooth; }

html, body { margin: 0; padding: 0; }

body {
  background: var(--bg-base);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  animation: pageFadeIn 300ms ease both;
}

@keyframes pageFadeIn {
  from { opacity: 0; transform: translateY(6px); }
  to   { opacity: 1; transform: translateY(0); }
}

img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
p { color: var(--ink); text-wrap: pretty; margin: 0; }
ul { list-style: none; padding: 0; margin: 0; }

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

section { padding: var(--section-y) 0; }

@media (max-width: 960px) {
  :root { --section-y: 72px; --gutter: 24px; }
}
@media (max-width: 680px) {
  :root { --section-y: 56px; --gutter: 20px; }
}

/* =========================================
   Typography
   ========================================= */
.eyebrow {
  font-family: var(--font-body);
  font-weight: 500;
  font-size: 13px;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--primary);
  display: inline-flex;
  align-items: center;
  gap: 8px;
}
.eyebrow::before { content: "—"; color: var(--primary); }

.display-xl,
.display-l,
.display-m,
.display-s {
  font-family: var(--font-display);
  font-weight: 600;
  letter-spacing: -0.02em;
  color: var(--ink);
  line-height: 1.05;
  margin: 0;
  text-wrap: balance;
}
.display-xl { font-size: clamp(44px, 6.2vw, 88px); }
.display-l  { font-size: clamp(36px, 4.4vw, 60px); }
.display-m  { font-size: clamp(28px, 3vw, 40px); }
.display-s  { font-size: clamp(22px, 2vw, 28px); }

.em-italic {
  font-style: italic;
  font-weight: 500;
  color: var(--secondary);
}

.lead {
  font-size: 19px;
  line-height: 1.55;
  color: var(--muted);
  max-width: 60ch;
  text-wrap: pretty;
}

.muted { color: var(--muted); }

/* =========================================
   Buttons
   ========================================= */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  height: 48px;
  padding: 0 22px;
  font-family: var(--font-body);
  font-size: 15px;
  font-weight: 500;
  letter-spacing: 0.01em;
  border-radius: 2px;
  cursor: pointer;
  border: 1px solid transparent;
  transition: background 120ms ease, color 120ms ease, border-color 120ms ease;
  white-space: nowrap;
}
.btn-primary { background: var(--primary); color: var(--bg-base); }
.btn-primary:hover { background: var(--primary-dark); }
.btn-secondary { background: transparent; color: var(--ink); border-color: var(--ink); }
.btn-secondary:hover { background: var(--ink); color: var(--bg-base); }
.btn-olive { background: var(--secondary); color: var(--bg-base); }
.btn-olive:hover { background: var(--secondary-dark); }
.btn-sm { height: 40px; padding: 0 16px; font-size: 14px; }
.btn-lg { height: 56px; padding: 0 28px; font-size: 16px; }

.text-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--primary);
  font-weight: 500;
  font-size: 15px;
  border-bottom: 1px solid currentColor;
  padding-bottom: 2px;
  transition: gap 120ms ease;
}
.text-link:hover { gap: 12px; }

/* =========================================
   Header
   ========================================= */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(250, 246, 240, 0.94);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--rule);
}
.site-header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  height: 76px;
}
.site-header__logo img { height: 36px; width: auto; }

.site-nav {
  display: flex;
  gap: 32px;
  align-items: center;
}
.site-nav a {
  font-size: 15px;
  color: var(--ink);
  font-weight: 500;
  position: relative;
  padding: 6px 0;
  transition: color 120ms ease;
}
.site-nav a:hover { color: var(--primary); }
.site-nav a.is-active { color: var(--secondary); }
.site-nav a.is-active::after {
  content: "";
  position: absolute;
  left: 0; right: 0; bottom: 0;
  height: 2px;
  background: var(--secondary);
}

.site-header__cta {
  display: flex;
  align-items: center;
  gap: 18px;
}
.site-header__phone {
  font-size: 14px;
  color: var(--ink);
  font-weight: 500;
}
.site-header__phone span { color: var(--muted); margin-right: 4px; }

/* Hamburger */
.hamburger {
  display: none;
  background: none;
  border: 0;
  cursor: pointer;
  padding: 6px;
  flex-direction: column;
  gap: 5px;
}
.hamburger span {
  display: block;
  width: 22px;
  height: 2px;
  background: var(--ink);
  border-radius: 1px;
  transition: transform 200ms ease, opacity 200ms ease;
  transform-origin: center;
}
.hamburger[aria-expanded="true"] span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.hamburger[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.hamburger[aria-expanded="true"] span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* Mobile nav drawer */
.mobile-nav {
  display: none;
  position: fixed;
  inset: 76px 0 0 0;
  background: var(--bg-base);
  border-top: 1px solid var(--rule);
  z-index: 99;
  padding: 32px var(--gutter);
  flex-direction: column;
  gap: 8px;
  overflow-y: auto;
}
.mobile-nav.is-open { display: flex; }
.mobile-nav a {
  font-size: 22px;
  font-family: var(--font-display);
  font-weight: 600;
  color: var(--ink);
  padding: 12px 0;
  border-bottom: 1px solid var(--rule);
  letter-spacing: -0.01em;
}
.mobile-nav a:last-child { border-bottom: 0; }
.mobile-nav a:hover { color: var(--primary); }
.mobile-nav__footer {
  margin-top: 24px;
  padding-top: 24px;
  border-top: 1px solid var(--rule);
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.mobile-nav__footer a.btn { align-self: flex-start; }

@media (max-width: 960px) {
  .site-nav,
  .site-header__phone { display: none; }
  .hamburger { display: flex; }
}
@media (max-width: 680px) {
  .site-header__cta .btn-sm { display: none; }
}

/* =========================================
   Demo banner
   ========================================= */
.demo-banner {
  background: var(--bg-tinted);
  border-bottom: 1px solid #E0CFB8;
  font-size: 13px;
  color: var(--ink);
}
.demo-banner__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 10px 0;
}
.demo-banner__msg {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  line-height: 1.4;
}
.demo-banner__msg .pin {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 22px;
  height: 22px;
  background: var(--primary);
  color: var(--bg-base);
  border-radius: 50%;
  font-size: 11px;
  font-weight: 600;
  flex-shrink: 0;
}
.demo-banner__msg strong { color: var(--primary); font-weight: 600; }
.demo-banner__close {
  background: transparent;
  border: 0;
  color: var(--muted);
  font-size: 20px;
  line-height: 1;
  cursor: pointer;
  padding: 4px 8px;
  flex-shrink: 0;
  transition: color 120ms ease;
}
.demo-banner__close:hover { color: var(--ink); }
.demo-banner.is-hidden { display: none; }

@media (max-width: 680px) {
  .demo-banner { font-size: 12px; }
  .demo-banner__inner { padding: 8px 0; }
}

/* =========================================
   Footer
   ========================================= */
.site-footer {
  background: var(--ink);
  color: var(--bg-base);
  padding: 80px 0 28px;
}
.site-footer a {
  color: var(--bg-base);
  transition: color 120ms ease;
}
.site-footer a:hover { color: #d8b89a; }
.site-footer__grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr 1fr;
  gap: 56px;
  padding-bottom: 56px;
  border-bottom: 1px solid rgba(250, 246, 240, 0.15);
}
.site-footer__brand .footer-logo {
  font-family: var(--font-display);
  font-size: 28px;
  font-weight: 600;
  letter-spacing: -0.02em;
  display: flex;
  align-items: center;
  gap: 12px;
}
.site-footer__brand .tagline {
  margin-top: 16px;
  color: rgba(250, 246, 240, 0.65);
  font-size: 14px;
  max-width: 28ch;
  line-height: 1.55;
}
.site-footer h4 {
  font-family: var(--font-body);
  font-weight: 500;
  font-size: 13px;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: rgba(250, 246, 240, 0.5);
  margin: 0 0 16px;
}
.site-footer ul {
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.site-footer ul li { font-size: 15px; }
.site-footer__socials {
  display: flex;
  gap: 12px;
  margin-top: 18px;
}
.site-footer__socials a {
  width: 36px;
  height: 36px;
  border: 1px solid rgba(250, 246, 240, 0.25);
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 13px;
  font-weight: 500;
  letter-spacing: 0.04em;
}
.site-footer__bottom {
  display: flex;
  justify-content: space-between;
  padding-top: 24px;
  font-size: 13px;
  color: rgba(250, 246, 240, 0.5);
}

@media (max-width: 960px) {
  .site-footer__grid { grid-template-columns: 1fr 1fr; gap: 40px; }
}
@media (max-width: 680px) {
  .site-footer__grid { grid-template-columns: 1fr; }
  .site-footer__bottom { flex-direction: column; gap: 8px; }
}

/* =========================================
   Shared components
   ========================================= */
.sprig-divider {
  display: flex;
  justify-content: center;
  align-items: center;
  opacity: 0.65;
  padding: 8px 0;
}
.sprig-divider svg { width: 56px; height: 24px; }

.chip-number {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 24px;
  border: 1px solid var(--rule);
  border-radius: 2px;
  font-family: ui-monospace, "SF Mono", Menlo, monospace;
  font-size: 12px;
  color: var(--muted);
  letter-spacing: 0.04em;
}

.tag {
  display: inline-flex;
  align-items: center;
  height: 22px;
  padding: 0 8px;
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  border: 1px solid var(--secondary);
  color: var(--secondary);
  border-radius: 2px;
}
.tag.tag-warn { border-color: var(--primary); color: var(--primary); }

/* Section header pattern */
.section-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  gap: 32px;
  margin-bottom: 48px;
  flex-wrap: wrap;
}
.section-head__lead { max-width: 60ch; }
.section-head .eyebrow { margin-bottom: 16px; }
.section-head h2 { margin: 0; }

/* CTA band */
.cta-band { background: var(--bg-tinted); }
.cta-band .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 32px;
  flex-wrap: wrap;
}
.cta-band__copy { max-width: 40ch; }
.cta-band h2 { margin: 0 0 12px; }

/* Page intro (no-image hero) */
.page-intro {
  padding: 96px 0 56px;
  border-bottom: 1px solid var(--rule);
}
.page-intro .eyebrow { margin-bottom: 18px; }
.page-intro .display-xl { max-width: 16ch; }
.page-intro .lead { margin-top: 24px; }

/* Photo placeholder */
.photo-ph {
  background: var(--bg-warm);
  border: 1px dashed #C9BEAC;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  color: var(--muted);
  font-family: ui-monospace, "SF Mono", Menlo, Consolas, monospace;
  font-size: 12px;
  letter-spacing: 0.04em;
  padding: 20px;
  gap: 6px;
  position: relative;
  border-radius: 2px;
}
.photo-ph::before {
  content: "";
  position: absolute;
  inset: 6px;
  background-image: repeating-linear-gradient(
    135deg,
    transparent 0,
    transparent 14px,
    rgba(94, 75, 53, 0.05) 14px,
    rgba(94, 75, 53, 0.05) 28px
  );
  pointer-events: none;
}
.photo-ph .ph-label {
  font-weight: 500;
  text-transform: uppercase;
  color: var(--ink);
  z-index: 1;
}
.photo-ph .ph-desc {
  z-index: 1;
  max-width: 24ch;
  text-transform: none;
  letter-spacing: 0;
  line-height: 1.4;
}
