/* ===== Crumb & Crypt — Victorian Haunted Bakery ===== */

@import url('https://fonts.googleapis.com/css2?family=Cormorant+Garamond:ital,wght@0,400;0,500;0,600;1,400&family=Pirata+One&family=EB+Garamond:ital@0;1&display=swap');

:root {
  --ink: #efe6d8;
  --ink-dim: #cabfa9;
  --bg-void: #0c0907;
  --bg-panel: #16110d;
  --bg-panel-2: #1e1712;
  --ember: #e0793c;
  --ember-dim: #9a4f24;
  --wax: #7a1f2b;
  --moss: #4f6b4a;
  --gold: #c9a24b;
  --line: rgba(201, 162, 75, 0.25);
  --shadow-deep: rgba(0, 0, 0, 0.65);
}

* { box-sizing: border-box; }

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background-color: var(--bg-void);
  background-image:
    radial-gradient(ellipse at 50% 0%, rgba(224, 121, 60, 0.10), transparent 60%),
    radial-gradient(ellipse at 15% 40%, rgba(122, 31, 43, 0.10), transparent 55%),
    radial-gradient(ellipse at 85% 70%, rgba(79, 107, 74, 0.08), transparent 55%);
  color: var(--ink);
  font-family: 'EB Garamond', 'Cormorant Garamond', serif;
  font-size: 1.05rem;
  line-height: 1.7;
  position: relative;
}

/* grain overlay */
body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 500;
  opacity: 0.05;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='120' height='120'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
  mix-blend-mode: overlay;
}

h1, h2, h3, .brand-name {
  font-family: 'Pirata One', 'Cormorant Garamond', serif;
  font-weight: 400;
  letter-spacing: 0.03em;
  color: var(--ink);
  text-shadow: 0 0 18px rgba(224, 121, 60, 0.25);
}

h1 { font-size: clamp(3rem, 9vw, 6rem); margin: 0; }
h2 { font-size: clamp(1.9rem, 5vw, 2.8rem); }
h3 { font-size: 1.5rem; }

a { color: var(--ember); }

.container {
  max-width: 1080px;
  margin: 0 auto;
  padding: 0 1.5rem;
}

/* ===== Nav ===== */
.site-nav {
  position: sticky;
  top: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1rem 2rem;
  padding-right: calc(2rem + 56px);
  background: rgba(12, 9, 7, 0.85);
  backdrop-filter: blur(6px);
  border-bottom: 1px solid var(--line);
}

.brand-name {
  font-size: 1.7rem;
  letter-spacing: 0.06em;
}

.brand-name span {
  color: var(--ember);
}

.nav-links {
  display: flex;
  gap: 1.8rem;
  list-style: none;
  margin: 0;
  padding: 0;
  font-family: 'Cormorant Garamond', serif;
  font-size: 1.1rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.nav-links a {
  color: var(--ink-dim);
  text-decoration: none;
  border-bottom: 1px solid transparent;
  transition: color 0.3s ease, border-color 0.3s ease;
}

.nav-links a:hover,
.nav-links a:focus-visible {
  color: var(--ember);
  border-color: var(--ember-dim);
}

/* ===== Hero ===== */
.hero {
  position: relative;
  min-height: 92vh;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  overflow: hidden;
  background: linear-gradient(180deg, rgba(12,9,7,0.3), rgba(12,9,7,0.9)), url("img/hero-bakery.png");
  background-size: cover;
  background-position: center;
  border-bottom: 1px solid var(--line);
}

.hero::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse 60% 50% at 50% 30%, rgba(224,121,60,0.18), transparent 70%);
  animation: flicker 5s infinite ease-in-out;
  pointer-events: none;
}

@keyframes flicker {
  0%, 100% { opacity: 1; }
  8% { opacity: 0.85; }
  20% { opacity: 1; }
  35% { opacity: 0.7; }
  45% { opacity: 1; }
  60% { opacity: 0.9; }
  75% { opacity: 1; }
}

.hero-fog {
  position: absolute;
  bottom: 0;
  left: -20%;
  width: 140%;
  height: 40%;
  background: radial-gradient(ellipse at center, rgba(239,230,216,0.09), transparent 70%);
  filter: blur(10px);
  animation: drift 22s infinite linear alternate;
  pointer-events: none;
}

@keyframes drift {
  from { transform: translateX(-4%); }
  to { transform: translateX(4%); }
}

.hero-content {
  position: relative;
  z-index: 2;
  padding: 2rem;
}

.hero-eyebrow {
  text-transform: uppercase;
  letter-spacing: 0.35em;
  font-size: 0.85rem;
  color: var(--gold);
  margin-bottom: 1rem;
}

.hero h1 {
  margin-bottom: 0.5rem;
}

.hero-tagline {
  font-style: italic;
  font-size: 1.3rem;
  color: var(--ink-dim);
  margin: 1rem auto 2rem;
  max-width: 34rem;
}

.btn {
  display: inline-block;
  padding: 0.85rem 2.2rem;
  border: 1px solid var(--gold);
  color: var(--gold);
  text-decoration: none;
  font-family: 'Cormorant Garamond', serif;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  font-size: 1rem;
  border-radius: 2px;
  transition: background 0.3s ease, color 0.3s ease, box-shadow 0.3s ease;
}

.btn:hover, .btn:focus-visible {
  background: var(--gold);
  color: var(--bg-void);
  box-shadow: 0 0 22px rgba(201,162,75,0.45);
}

/* ===== Sections ===== */
section {
  padding: 6rem 0;
  position: relative;
}

.section-heading {
  text-align: center;
  margin-bottom: 0.6rem;
}

.section-sub {
  text-align: center;
  color: var(--ink-dim);
  font-style: italic;
  max-width: 38rem;
  margin: 0 auto 3.5rem;
}

.divider {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 1rem;
  color: var(--ember-dim);
  margin: 0 auto 2.5rem;
}
.divider::before, .divider::after {
  content: "";
  height: 1px;
  width: 80px;
  background: linear-gradient(90deg, transparent, var(--line), transparent);
}

/* ===== Story section ===== */
.story {
  background: var(--bg-panel);
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}

.story-grid {
  display: grid;
  grid-template-columns: 1fr 1.2fr;
  gap: 3rem;
  align-items: center;
}

.story-portrait {
  position: relative;
}

.story-portrait img {
  width: 100%;
  border-radius: 4px;
  filter: sepia(0.25) contrast(1.05);
  box-shadow: 0 0 0 1px var(--line), 0 20px 50px var(--shadow-deep);
}

.story-portrait::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: 4px;
  box-shadow: inset 0 0 60px 20px rgba(12,9,7,0.8);
  pointer-events: none;
}

.story-text h2 { margin-bottom: 1rem; }
.story-text p { color: var(--ink-dim); }
.story-signature {
  margin-top: 1.5rem;
  font-family: 'Pirata One', serif;
  color: var(--ember);
  font-size: 1.4rem;
}

/* ===== Menu ===== */
.menu {
  background: var(--bg-void);
}

.menu-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 2rem;
}

.menu-card {
  background: var(--bg-panel-2);
  border: 1px solid var(--line);
  border-radius: 6px;
  padding: 1.6rem;
  position: relative;
  transition: transform 0.3s ease, box-shadow 0.3s ease, border-color 0.3s ease;
}

.menu-card:hover {
  transform: translateY(-4px);
  border-color: var(--ember-dim);
  box-shadow: 0 16px 40px var(--shadow-deep), 0 0 20px rgba(224,121,60,0.08);
}

.menu-card img {
  width: 100%;
  aspect-ratio: 1 / 1;
  object-fit: cover;
  border-radius: 4px;
  margin-bottom: 1rem;
  filter: saturate(0.9) contrast(1.05);
}

.menu-card-head {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 0.5rem;
  border-bottom: 1px dashed var(--line);
  padding-bottom: 0.5rem;
  margin-bottom: 0.6rem;
}

.menu-card-plain {
  display: flex;
  flex-direction: column;
  justify-content: center;
  min-height: 100%;
}

.menu-card-plain::before {
  content: "\2740";
  display: block;
  text-align: center;
  color: var(--ember-dim);
  font-size: 1.4rem;
  margin-bottom: 1rem;
}

.menu-card-head h3 {
  margin: 0;
}

.price {
  font-family: 'Cormorant Garamond', serif;
  color: var(--gold);
  font-size: 1.2rem;
  white-space: nowrap;
}

.menu-card p {
  color: var(--ink-dim);
  font-size: 0.98rem;
  margin: 0;
}

/* ===== Hours ===== */
.hours {
  background: var(--bg-panel);
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  text-align: center;
}

.hours-plaque {
  max-width: 480px;
  margin: 0 auto;
  padding: 3rem 2rem;
  border: 1px solid var(--gold);
  border-radius: 4px;
  background:
    radial-gradient(ellipse at 50% 0%, rgba(201,162,75,0.08), transparent 70%),
    var(--bg-panel-2);
  box-shadow: 0 0 40px rgba(0,0,0,0.5), inset 0 0 0 1px rgba(201,162,75,0.15);
}

.hours-time {
  font-family: 'Pirata One', serif;
  font-size: clamp(2.4rem, 6vw, 3.2rem);
  color: var(--ember);
  margin: 0.5rem 0;
  text-shadow: 0 0 22px rgba(224,121,60,0.4);
}

.hours-days {
  color: var(--ink-dim);
  text-transform: uppercase;
  letter-spacing: 0.2em;
  font-size: 0.9rem;
}

.hours-note {
  margin-top: 1.5rem;
  font-style: italic;
  color: var(--ink-dim);
  font-size: 0.95rem;
}

/* ===== Footer ===== */
footer {
  padding: 3rem 1.5rem 2rem;
  text-align: center;
  border-top: 1px solid var(--line);
  color: var(--ink-dim);
  font-size: 0.85rem;
}

footer .brand-name {
  display: block;
  margin-bottom: 0.5rem;
  font-size: 1.3rem;
}

footer a {
  color: var(--ink-dim);
}

.footer-note {
  margin-top: 1rem;
  opacity: 0.6;
  font-size: 0.78rem;
}

/* ===== Responsive ===== */
@media (max-width: 760px) {
  .story-grid {
    grid-template-columns: 1fr;
  }
  .site-nav {
    flex-direction: column;
    gap: 0.8rem;
    padding: 1rem;
    padding-right: 1rem;
  }
  .nav-links {
    gap: 1.2rem;
    flex-wrap: wrap;
    justify-content: center;
  }
  section { padding: 4rem 0; }
}

@media (prefers-reduced-motion: reduce) {
  .hero::before, .hero-fog { animation: none; }
}
