/* Earls Cafe — public site
   Warm stone-blush ground, deep navy actions, Caslon headings, Jost text. */
:root {
  --bg: #F5EEEA;
  --bg-soft: #FAF6F3;
  --line: #E4D9D2;
  --ink: #1F1B19;
  --muted: #5E5550;
  --stone: #8F8580;
  --navy: #133A63;
  --navy-deep: #0D2A49;
  --roast: #6B4A34;

  --serif: "Libre Caslon Text", Georgia, "Times New Roman", serif;
  --sans: "Jost", "Futura", system-ui, -apple-system, "Segoe UI", sans-serif;

  --wrap: 72rem;
  --gutter: clamp(1.25rem, 4vw, 2.5rem);
  --header-h: 4.5rem;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: calc(var(--header-h) + .5rem); -webkit-text-size-adjust: 100%; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } * { transition: none !important; } }

body { margin: 0; background: var(--bg); color: var(--ink); font: 400 1.0625rem/1.6 var(--sans); -webkit-font-smoothing: antialiased; overflow-x: clip; }
img { display: block; max-width: 100%; }
a { color: inherit; }
h1, h2, h3, h4 { font-family: var(--serif); font-weight: 400; margin: 0; }
p { margin: 0; }
ul { list-style: none; margin: 0; padding: 0; }
:focus-visible { outline: 2px solid var(--navy); outline-offset: 3px; border-radius: 3px; }

.wrap { width: 100%; max-width: var(--wrap); margin: 0 auto; padding: 0 var(--gutter); }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip { position: absolute; left: 1rem; top: -3rem; background: var(--navy); color: #fff; padding: .5rem 1rem; z-index: 60; }
.skip:focus { top: 1rem; }

/* ---------- Buttons & links ---------- */
.btn {
  display: inline-flex; align-items: center; gap: .6rem; text-decoration: none; white-space: nowrap;
  font: 500 .98rem var(--sans); padding: .7rem 1.35rem; border-radius: 6px; border: 1px solid transparent;
  transition: background-color .2s, color .2s, border-color .2s;
}
.btn-solid { background: var(--navy); color: #fff; }
.btn-solid:hover { background: var(--navy-deep); }
.btn-outline { border-color: rgba(255, 255, 255, .85); color: #fff; }
.btn-outline:hover { background: #fff; color: var(--ink); }
.arrow { flex: none; }
.text-link {
  display: inline-flex; align-items: center; gap: .55rem; color: var(--navy); text-decoration: none; font-weight: 500;
  padding-bottom: .2rem; border-bottom: 1.5px solid var(--navy);
}
.text-link:hover .arrow { transform: translateX(3px); }
.text-link .arrow { transition: transform .2s; }

/* ---------- Header ---------- */
.site-header { position: sticky; top: 0; z-index: 30; background: rgba(245, 238, 234, .94); backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px); border-bottom: 1px solid var(--line); }
.header-inner { display: flex; align-items: center; gap: 2rem; height: var(--header-h); }

.logo { display: inline-flex; flex-direction: column; align-items: center; text-decoration: none; color: var(--ink); line-height: 1; }
.logo-word { font-family: var(--serif); font-size: 2.35rem; letter-spacing: -.01em; line-height: .9; }
.logo-sub {
  display: flex; align-items: center; gap: .5rem; margin-top: .2rem;
  font: 500 .6rem var(--sans); letter-spacing: .38em; text-transform: uppercase; color: var(--stone); padding-left: .38em;
}
.logo-sub::before, .logo-sub::after { content: ""; width: 1.4rem; height: 1px; background: currentColor; opacity: .7; }
.logo.light { color: #fff; }
.logo.light .logo-sub { color: #B9C6D6; }

.site-nav { margin-left: auto; display: flex; align-items: center; gap: 2.2rem; font-size: 1rem; }
.site-nav a:not(.btn) { text-decoration: none; color: var(--navy); padding: .3rem 0; border-bottom: 1.5px solid transparent; }
.site-nav a:not(.btn):hover { border-bottom-color: rgba(19, 58, 99, .35); }
.site-nav a[aria-current="true"] { border-bottom-color: var(--navy); }
.nav-cta { margin-left: 1rem; }
.nav-cta-mobile { display: none !important; }
.nav-toggle { display: none; }

@media (max-width: 900px) {
  .site-nav { gap: 1.4rem; }
  .nav-cta { margin-left: 0; }
}
@media (max-width: 780px) {
  .nav-cta { display: none; }
  .nav-toggle {
    display: grid; place-items: center; margin-left: auto; width: 2.75rem; height: 2.75rem;
    background: none; border: 1px solid var(--line); border-radius: 6px; cursor: pointer;
  }
  .bars, .bars::before, .bars::after { display: block; width: 18px; height: 1.5px; background: var(--navy); position: relative; transition: transform .2s; }
  .bars::before, .bars::after { content: ""; position: absolute; left: 0; }
  .bars::before { top: -6px; } .bars::after { top: 6px; }
  .nav-toggle[aria-expanded="true"] .bars { background: transparent; }
  .nav-toggle[aria-expanded="true"] .bars::before { transform: translateY(6px) rotate(45deg); }
  .nav-toggle[aria-expanded="true"] .bars::after { transform: translateY(-6px) rotate(-45deg); }
  .site-nav {
    position: absolute; top: 100%; left: 0; right: 0; margin: 0; display: none;
    flex-direction: column; align-items: stretch; gap: 0; background: var(--bg);
    border-bottom: 1px solid var(--line); padding: .25rem var(--gutter) 1.25rem;
  }
  .site-nav.is-open { display: flex; }
  .site-nav a:not(.btn) { padding: .9rem 0; border-bottom: 1px solid var(--line); }
  .site-nav a[aria-current="true"] { border-bottom-color: var(--line); font-weight: 500; }
  .nav-cta-mobile { display: inline-flex !important; justify-content: center; margin-top: 1rem; }
}

/* ---------- Hero ---------- */
.hero { position: relative; min-height: clamp(26rem, 62vh, 38rem); display: flex; align-items: center; background: #3A322D; overflow: hidden; color: #fff; }
.hero-img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: 70% 50%; }
.hero::after {
  content: ""; position: absolute; inset: 0;
  background: linear-gradient(90deg, rgba(28, 22, 19, .82) 0%, rgba(28, 22, 19, .55) 38%, rgba(28, 22, 19, 0) 70%);
}
.hero-inner { position: relative; z-index: 1; padding-top: 3rem; padding-bottom: 3rem; }
.hero-copy { max-width: 30rem; }
.hero h1 { font-size: clamp(2.5rem, 5.2vw, 3.9rem); line-height: 1.08; text-wrap: balance; }
.hero-sub { margin-top: 1.25rem; font-size: 1.08rem; line-height: 1.6; color: rgba(255, 255, 255, .9); max-width: 26rem; }
.hero .btn { margin-top: 2rem; }

@media (max-width: 640px) {
  .hero { align-items: flex-end; min-height: 34rem; }
  .hero::after { background: linear-gradient(0deg, rgba(28, 22, 19, .88) 0%, rgba(28, 22, 19, .55) 45%, rgba(28, 22, 19, .05) 80%); }
  .hero-img { object-position: 62% 30%; }
}

/* ---------- About ---------- */
.about { padding: clamp(3.5rem, 7vw, 5.5rem) 0; }
.about-grid { display: grid; grid-template-columns: minmax(0, 1.05fr) minmax(0, 1fr); gap: clamp(2rem, 5vw, 4.5rem); align-items: center; }
.about-grid.no-image { grid-template-columns: minmax(0, 40rem); }
.about-media { margin: 0; border-radius: 8px; overflow: hidden; aspect-ratio: 16 / 9; background: var(--line); box-shadow: 0 18px 40px -24px rgba(31, 27, 25, .45); }
.about-media img { width: 100%; height: 100%; object-fit: cover; }
.stars { display: flex; gap: .35rem; color: var(--navy); margin-bottom: 1rem; }
.about h2 { font-size: clamp(2rem, 3.6vw, 2.6rem); line-height: 1.12; text-wrap: balance; margin-bottom: 1.1rem; }
.about-copy p:not(.stars) { color: #3B3431; font-size: 1.08rem; max-width: 32rem; }
.about-copy p + p:not(.stars) { margin-top: .9rem; }
.about .text-link { margin-top: 1.75rem; }
@media (max-width: 820px) { .about-grid { grid-template-columns: 1fr; } }

/* ---------- Section heads ---------- */
.section-head { text-align: center; margin-bottom: clamp(2rem, 4vw, 2.75rem); }
.eyebrow { font: 500 .82rem var(--sans); letter-spacing: .18em; text-transform: uppercase; color: var(--navy); margin-bottom: .5rem; }
.section-head h2 { font-size: clamp(2.3rem, 4.6vw, 3.2rem); line-height: 1.08; }
.section-sub { margin-top: .6rem; color: #3B3431; font-size: 1.08rem; }

/* ---------- Menu ---------- */
.menu { background: var(--bg-soft); padding: clamp(3.5rem, 7vw, 5rem) 0; border-top: 1px solid var(--line); }
.cards { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 1rem; }
.card {
  display: flex; flex-direction: column; align-items: center; gap: .1rem; padding: 0 0 .9rem; text-align: center;
  background: none; border: 0; cursor: pointer; font: inherit; color: var(--ink); border-radius: 8px;
}
.card-media { display: block; width: 100%; aspect-ratio: 1.6; border-radius: 6px; overflow: hidden; background: var(--line); margin-bottom: .8rem; position: relative; }
.card-media img { width: 100%; height: 100%; object-fit: cover; transition: transform .4s ease; }
.card:hover .card-media img { transform: scale(1.04); }
.card-media::after { content: ""; position: absolute; inset: 0; border-radius: inherit; box-shadow: inset 0 0 0 0 var(--navy); transition: box-shadow .2s; }
.card[aria-selected="true"] .card-media::after { box-shadow: inset 0 0 0 3px var(--navy); }
.card-name { font-size: 1.15rem; font-weight: 500; }
.card-sub { font-size: 1rem; color: var(--muted); }
.card[aria-selected="true"] .card-name { color: var(--navy); }
@media (max-width: 860px) { .cards { grid-template-columns: repeat(2, minmax(0, 1fr)); } }

.menu-panel { margin-top: 2.5rem; padding-top: 2.5rem; border-top: 1px solid var(--line); }
.js .menu-panel[hidden] { display: none; }
.panel-title { font-size: 1.6rem; margin-bottom: 1.75rem; }
.panel-title span { font: 400 1rem var(--sans); color: var(--muted); margin-left: .5rem; }

.items { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 2.2rem 4rem; }
.item.has-photo { display: grid; grid-template-columns: 6rem minmax(0, 1fr); gap: 1.2rem; align-items: start; }
.item-photo { width: 6rem; height: 6rem; object-fit: cover; border-radius: 6px; background: var(--line); }
.item-line { display: flex; align-items: baseline; gap: .6rem; }
.item h4 { font-size: 1.2rem; line-height: 1.3; }
.leader { flex: 1; min-width: 1.5rem; border-bottom: 1px dotted #C9BDB6; transform: translateY(-.3rem); }
.price { font-family: var(--serif); font-size: 1.1rem; color: var(--navy); white-space: nowrap; }
.item p { margin-top: .35rem; color: var(--muted); font-size: .98rem; }

.badge {
  display: inline-flex; align-items: center; gap: .4rem; margin-top: .65rem;
  font-size: .8rem; font-weight: 500; color: var(--roast);
  padding: .2rem .65rem .2rem .5rem; border: 1px solid #DCCABC; border-radius: 999px; background: #F3E9E1;
}
.badge-plant_based { color: #3E5E4B; border-color: #C6D4C9; background: #EAF0EB; }
.badge-new { color: var(--navy); border-color: #C3D0DE; background: #E8EEF5; }
.badge-icon { flex: none; }

.menu-note { margin-top: 3rem; padding-top: 1.25rem; border-top: 1px solid var(--line); font-size: .92rem; color: var(--muted); text-align: center; }

@media (max-width: 760px) {
  .items { grid-template-columns: 1fr; gap: 1.8rem; }
  .item.has-photo { grid-template-columns: 5rem minmax(0, 1fr); gap: 1rem; }
  .item-photo { width: 5rem; height: 5rem; }
}

/* ---------- Gallery ---------- */
.gallery { padding: clamp(3.5rem, 7vw, 5rem) 0; }
.gallery-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: .75rem; }
.gallery-grid li { aspect-ratio: 1; border-radius: 6px; overflow: hidden; background: var(--line); }
.gallery-grid img { width: 100%; height: 100%; object-fit: cover; }
@media (max-width: 760px) { .gallery-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: .5rem; } }

/* ---------- Visit ---------- */
.visit { position: relative; overflow: hidden; background: #E9E3DF; border-top: 1px solid var(--line); }
.visit-img { position: absolute; inset: 0 0 0 auto; width: 72%; height: 100%; object-fit: cover; object-position: 30% 60%; }
.visit::before {
  content: ""; position: absolute; inset: 0; z-index: 1;
  background: linear-gradient(90deg, #EDE8E5 0%, #EDE8E5 30%, rgba(237, 232, 229, .7) 42%, rgba(237, 232, 229, 0) 62%);
}
.visit-inner { position: relative; z-index: 2; padding-top: clamp(3rem, 6vw, 4.5rem); padding-bottom: clamp(3rem, 6vw, 4.5rem); }
.visit-copy { max-width: 22rem; }
.visit h2 { font-size: clamp(2rem, 3.6vw, 2.6rem); line-height: 1.1; margin-bottom: 1.1rem; }
.visit-list { display: grid; gap: .8rem; margin-bottom: 1.75rem; }
.visit-list li { display: grid; grid-template-columns: 1.25rem minmax(0, 1fr); gap: .65rem; align-items: start; }
.visit-list svg { color: var(--navy); margin-top: .2rem; }
.visit-list address { font-style: normal; }
.hours-lines { display: grid; gap: .1rem; }
.hours-lines b { font-weight: 500; }
.status { font-size: .9rem; color: var(--muted); }
.status.is-open { color: #2F6B4D; }
.contact { display: flex; flex-wrap: wrap; gap: .4rem 1.25rem; margin-top: 1.5rem; font-size: .95rem; }
.contact a { color: var(--navy); text-decoration: none; border-bottom: 1px solid rgba(19, 58, 99, .3); }
.contact a:hover { border-bottom-color: var(--navy); }

@media (max-width: 760px) {
  .visit-img { position: relative; width: 100%; height: 14rem; inset: auto; }
  .visit::before { display: none; }
  .visit-copy { max-width: none; }
}

/* ---------- Footer ---------- */
.site-footer { background: var(--navy-deep); color: #C5D0DC; padding: 2.25rem 0; font-size: .92rem; }
.footer-inner { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 1rem 2rem; }
.site-footer .logo-word { font-size: 1.8rem; }
