/* ============================================================
   Restaurang & Pizzeria Lokus — designsystem
   Mörk krogbas med guld (matchar rondell-loggan), Playfair Display + Inter.
   Förlaga: Kado-mönstret (mallbanken) — stora matbilder, tydliga prisrader.
   ============================================================ */

:root {
  /* Färger (brand-spec §4) */
  --ink: #0C0B09;
  --ink-2: #1A1814;
  --ink-3: #28251F;
  --brass: #CDA45E;
  --brass-deep: #A6813F;
  --cream: #F3EFE8;
  --cream-dim: rgba(243, 239, 232, 0.72);
  --cream-faint: rgba(243, 239, 232, 0.55);
  --sand: #F0EBE2;
  --sand-2: #E6DFD1;
  --ink-on-sand: #211E18;
  --muted-on-sand: #5E564A;
  --red: #B03A2E;
  --line: rgba(205, 164, 94, 0.18);
  --line-soft: rgba(205, 164, 94, 0.09);
  --line-sand: rgba(33, 30, 24, 0.12);

  /* Typografi */
  --font-display: "Playfair Display", Georgia, serif;
  --font-body: "Inter", "Helvetica Neue", Arial, sans-serif;

  /* Skala */
  --space-xs: 0.5rem;
  --space-sm: 0.75rem;
  --space-md: 1rem;
  --space-lg: 1.75rem;
  --space-xl: 2.75rem;
  --space-section: clamp(5rem, 10vw, 7.5rem);
  --space-section-tight: clamp(3rem, 7vw, 5rem);

  --radius: 14px;
  --radius-lg: 22px;
  --nav-h: 78px;
  --ease-out: cubic-bezier(0.22, 1, 0.36, 1);
  --wrap: 1180px;
}

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

html { scroll-behavior: smooth; scroll-padding-top: calc(var(--nav-h) + 16px); }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

body {
  font-family: var(--font-body);
  font-size: 1.0625rem;
  line-height: 1.65;
  color: var(--cream);
  background: var(--ink);
  -webkit-font-smoothing: antialiased;
  overflow-x: clip;
}

img { max-width: 100%; display: block; }
::selection { background: var(--brass); color: var(--ink); }

a { color: var(--brass); text-decoration: none; }
a:hover { color: var(--cream); }

/* Typografi */
h1, h2, h3, .display {
  font-family: var(--font-display);
  font-weight: 600;
  line-height: 1.08;
  letter-spacing: -0.015em;
  color: inherit;
}
h1, .h1 { font-size: clamp(2.5rem, 6vw, 4.25rem); }
h2, .h2 { font-size: clamp(1.9rem, 4vw, 2.9rem); }
h3, .h3 { font-size: clamp(1.25rem, 2vw, 1.5rem); line-height: 1.25; }
p { max-width: 65ch; }

.kicker {
  display: flex; align-items: center; gap: 0.75rem;
  font-size: 0.8125rem; font-weight: 700;
  letter-spacing: 0.18em; text-transform: uppercase;
  color: var(--brass);
  margin-bottom: var(--space-md);
}
.kicker::before { content: ""; width: 34px; height: 1.5px; background: var(--brass); flex: none; }

.lead { font-size: clamp(1.125rem, 1.6vw, 1.3125rem); line-height: 1.6; color: var(--cream-dim); }
.muted { color: var(--cream-dim); }

/* Layout */
.wrap { max-width: var(--wrap); margin-inline: auto; padding-inline: clamp(1.25rem, 4vw, 2.5rem); }
.section { padding-block: var(--space-section); }
.section-tight { padding-block: var(--space-section-tight); }
.section-sand { background: var(--sand); color: var(--ink-on-sand); }
.section-sand .muted, .section-sand .lead { color: var(--muted-on-sand); }
.section-sand a:not(.btn) { color: #7E5A2E; }
.section-sand a:not(.btn):hover { color: var(--ink-on-sand); }
.section-sand .kicker { color: #7E5A2E; }
.section-sand .kicker::before { background: #7E5A2E; }
.section-sand .btn-ghost { color: var(--ink-on-sand); border-color: rgba(33, 30, 24, 0.4); }
.section-sand .btn-ghost:hover { border-color: var(--brass-deep); color: var(--brass-deep); }
.section-sand .h3-brass { color: #7E5A2E; }
.section-ink2 { background: var(--ink-2); }
.section-ink2 .kort { background: var(--ink-3); }
.section-head { max-width: 720px; margin-bottom: clamp(2rem, 5vw, 3.5rem); }
.section-head p { margin-top: 0.9rem; }

/* Knappar (CTA nära sin text — spacing-reglerna) */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 0.5rem;
  font-family: var(--font-body); font-size: 0.9375rem; font-weight: 700;
  padding: 0.9rem 1.7rem;
  border-radius: 999px;
  border: 1.5px solid transparent;
  cursor: pointer;
  transition: transform 0.22s var(--ease-out), background-color 0.22s var(--ease-out),
              color 0.22s var(--ease-out), border-color 0.22s var(--ease-out);
}
.btn:active { transform: scale(0.98); }
.btn-brass { background: var(--brass); color: var(--ink); }
.btn-brass:hover { background: var(--cream); color: var(--ink); transform: translateY(-2px); }
.btn-ghost { background: transparent; color: var(--cream); border-color: rgba(243, 239, 232, 0.35); }
.btn-ghost:hover { border-color: var(--brass); color: var(--brass); transform: translateY(-2px); }
.btn-ink { background: var(--ink); color: var(--cream); }
.btn-ink:hover { background: var(--ink-3); color: var(--brass); transform: translateY(-2px); }
.btn-rad { display: flex; flex-wrap: wrap; gap: 0.75rem; margin-top: var(--space-lg); }

/* Nav */
.nav {
  position: fixed; inset: 0 0 auto 0; z-index: 100;
  height: var(--nav-h);
  display: flex; align-items: center;
  border-bottom: 1px solid transparent;
  transition: background-color 0.3s var(--ease-out), border-color 0.3s var(--ease-out);
}
.nav.scrolled {
  background: rgba(12, 11, 9, 0.94);
  -webkit-backdrop-filter: blur(14px);
  backdrop-filter: blur(14px);
  border-bottom-color: var(--line-soft);
}
.nav-inner { display: flex; align-items: center; justify-content: space-between; gap: var(--space-lg); width: 100%; }
.nav-logo img { height: 48px; width: auto; }
.nav-links { display: flex; align-items: center; gap: clamp(1.1rem, 2vw, 1.9rem); list-style: none; padding: 0; }
.nav-links > li { position: relative; }
.nav-links a {
  font-size: 0.9375rem; font-weight: 600; color: var(--cream);
  padding: 0.5rem 0.15rem;
  transition: color 0.2s var(--ease-out);
}
.nav-links a:hover, .nav-links a[aria-current="page"] { color: var(--brass); }


.nav-cta { display: flex; gap: 0.6rem; }
.nav-cta .btn { padding: 0.7rem 1.3rem; font-size: 0.875rem; }

.nav-burger {
  display: none;
  background: none; border: 1px solid var(--line);
  border-radius: 10px; width: 46px; height: 46px;
  align-items: center; justify-content: center;
  color: var(--cream); cursor: pointer;
}

/* Mobilmeny — helt solid (Drippn-läxan: aldrig rgba+blur här) */
.mobile-menu {
  position: fixed; inset: 0; z-index: 200;
  background: var(--ink);
  display: flex; flex-direction: column;
  padding: var(--space-lg);
  opacity: 0; visibility: hidden;
  transition: opacity 0.28s var(--ease-out), visibility 0.28s;
  overflow-y: auto;
}
.mobile-menu.open { opacity: 1; visibility: visible; }
.mobile-menu-top { display: flex; align-items: center; justify-content: space-between; margin-bottom: var(--space-lg); }
.mobile-menu-top img { height: 30px; }
.mobile-close {
  background: none; border: 1px solid var(--line); border-radius: 10px;
  width: 48px; height: 48px;
  display: flex; align-items: center; justify-content: center;
  color: var(--cream); cursor: pointer;
}
.mobile-links { list-style: none; padding: 0; display: grid; gap: 0.1rem; }
.mobile-links a {
  display: block; padding: 0.65rem 0;
  font-family: var(--font-display); font-size: 1.55rem; font-weight: 600; color: var(--cream);
}
.mobile-links a:hover { color: var(--brass); }
.mobile-menu .btn-rad { margin-top: var(--space-lg); }
.mobile-meta { margin-top: auto; padding-top: var(--space-lg); font-size: 0.875rem; color: var(--cream-faint); }

/* Hero */
.hero {
  position: relative;
  min-height: 92svh;
  display: flex; align-items: flex-end;
  padding: calc(var(--nav-h) + 2.5rem) 0 clamp(3.5rem, 8vw, 5.5rem);
  isolation: isolate;
}
.hero-bg { position: absolute; inset: 0; z-index: -2; overflow: hidden; }
.hero-bg img { width: 100%; height: 100%; object-fit: cover; }
.hero-bg::after {
  content: ""; position: absolute; inset: 0;
  background: linear-gradient(180deg, rgba(12,11,9,0.6) 0%, rgba(12,11,9,0.48) 40%, rgba(12,11,9,0.94) 100%);
}
.hero .wrap { width: 100%; }
.hero-content { max-width: 760px; }
.hero .kicker { margin-bottom: var(--space-lg); text-shadow: 0 1px 8px rgba(12,11,9,0.9); }
.hero h1 { margin-bottom: clamp(1.5rem, 3vw, 2.25rem); }
.hero .lead { margin-bottom: 0; }

/* Sidhero (undersidor) */
.page-hero {
  position: relative;
  padding: calc(var(--nav-h) + clamp(3.5rem, 9vw, 6rem)) 0 clamp(2.75rem, 7vw, 4.5rem);
  isolation: isolate;
}
.page-hero .kicker { margin-bottom: var(--space-md); }
.page-hero h1 { max-width: 16ch; }
.page-hero .lead { margin-top: 1.25rem; }
.page-hero-bg { position: absolute; inset: 0; z-index: -2; overflow: hidden; }
.page-hero-bg img { width: 100%; height: 100%; object-fit: cover; }
.page-hero-bg::after {
  content: ""; position: absolute; inset: 0;
  background: linear-gradient(180deg, rgba(12,11,9,0.78) 0%, rgba(12,11,9,0.94) 100%);
}

/* Kort & rutnät */
.grid-2 { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: clamp(1.25rem, 3vw, 2rem); }
.grid-3 { display: grid; grid-template-columns: repeat(auto-fit, minmax(270px, 1fr)); gap: clamp(1.25rem, 3vw, 2rem); }
.grid-4 { display: grid; grid-template-columns: repeat(auto-fit, minmax(230px, 1fr)); gap: clamp(1rem, 2.5vw, 1.5rem); }

.kort {
  background: var(--ink-2);
  border: 1px solid var(--line-soft);
  border-radius: var(--radius-lg);
  overflow: hidden;
  transition: transform 0.3s var(--ease-out), border-color 0.3s var(--ease-out);
}
.kort:hover { transform: translateY(-5px); border-color: var(--line); }
.kort-bild { aspect-ratio: 16 / 10; overflow: hidden; }
.kort-bild img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.6s var(--ease-out); }
.kort:hover .kort-bild img { transform: scale(1.045); }
.kort-body { padding: clamp(1.25rem, 2.5vw, 1.75rem); }
.kort-body h3 { margin-bottom: 0.5rem; }
.kort-body p { font-size: 0.9375rem; color: var(--cream-dim); margin-bottom: 1rem; }
.kort-meta { font-size: 0.875rem; color: var(--cream-faint); display: grid; gap: 0.2rem; margin-bottom: 1rem; list-style: none; padding: 0; }
.kort-body .btn { padding: 0.65rem 1.2rem; font-size: 0.875rem; }
.kort .btn-rad { margin-top: 0; }

.section-sand .kort { background: #FFFFFF; border-color: var(--line-sand); }
.section-sand .kort-body p { color: var(--muted-on-sand); }
.section-sand .kort-meta { color: var(--muted-on-sand); }

/* Split-sektion (text + bild) */
.split { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(2rem, 5vw, 4.5rem); align-items: center; }
.split-bild { border-radius: var(--radius-lg); overflow: hidden; aspect-ratio: 4 / 3; }
.split-bild img { width: 100%; height: 100%; object-fit: cover; }
.split h2 { margin-bottom: 1rem; }
.split p + p { margin-top: 0.9rem; }
.split .btn-rad { margin-top: var(--space-lg); }
@media (max-width: 880px) { .split { grid-template-columns: 1fr; } .split-bild { order: -1; } }

/* Siffror/utmärkelser */
.merit-rad { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 1.5rem; }
.merit { border-top: 1.5px solid var(--line); padding-top: 1.1rem; }
.merit b { font-family: var(--font-display); font-size: 1.35rem; font-weight: 600; display: block; margin-bottom: 0.3rem; }
.merit span { font-size: 0.9rem; color: var(--cream-dim); }
.section-sand .merit { border-top-color: var(--line-sand); }
.section-sand .merit span { color: var(--muted-on-sand); }

/* Listor med checkmarkering */
.check-lista { list-style: none; padding: 0; display: grid; gap: 0.6rem; }
.check-lista li { padding-left: 1.75rem; position: relative; }
.check-lista li::before {
  content: ""; position: absolute; left: 0; top: 0.42em;
  width: 15px; height: 15px;
  border-radius: 50%;
  background: var(--brass);
  -webkit-mask: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 16 16"><path fill="black" d="M6.4 12.2 2.6 8.4l1.2-1.2 2.6 2.6 5.8-5.8 1.2 1.2z"/></svg>') center / contain no-repeat;
          mask: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 16 16"><path fill="black" d="M6.4 12.2 2.6 8.4l1.2-1.2 2.6 2.6 5.8-5.8 1.2 1.2z"/></svg>') center / contain no-repeat;
}

/* FAQ */
.faq { display: grid; gap: 0.75rem; max-width: 780px; }
.faq details {
  background: var(--ink-2);
  border: 1px solid var(--line-soft);
  border-radius: var(--radius);
  padding: 1.1rem 1.4rem;
  transition: border-color 0.25s var(--ease-out);
}
.faq details[open] { border-color: var(--line); }
.faq summary {
  font-weight: 600; cursor: pointer; list-style: none;
  display: flex; justify-content: space-between; align-items: center; gap: 1rem;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; font-family: var(--font-display); font-size: 1.4rem; color: var(--brass); transition: transform 0.25s var(--ease-out); flex: none; }
.faq details[open] summary::after { transform: rotate(45deg); }
.faq details p { margin-top: 0.75rem; color: var(--cream-dim); font-size: 0.9688rem; }
.section-sand .faq details { background: #fff; border-color: var(--line-sand); }
.section-sand .faq details p { color: var(--muted-on-sand); }

/* Meny-tabell (catering) */
.meny-grupp { margin-bottom: var(--space-xl); max-width: 780px; }
.meny-grupp h3 { margin-bottom: 1rem; color: var(--brass); }
.meny-ankare { display: flex; flex-wrap: wrap; gap: 0.5rem; margin-bottom: clamp(2rem, 4vw, 3rem); }
.meny-ankare a {
  font-size: 0.875rem; font-weight: 600; color: var(--cream-dim);
  padding: 0.5rem 1rem;
  border: 1px solid var(--line);
  border-radius: 999px;
  transition: color 0.2s var(--ease-out), border-color 0.2s var(--ease-out);
}
.meny-ankare a:hover { color: var(--brass); border-color: var(--brass); }
.meny-rad {
  display: flex; align-items: baseline; gap: 0.75rem;
  padding: 0.7rem 0;
  border-bottom: 1px solid var(--line-soft);
}
.meny-rad:last-child { border-bottom: none; }
.meny-namn { font-weight: 600; }
.meny-info { font-size: 0.9375rem; color: rgba(243, 239, 232, 0.65); }
.meny-prick { flex: 1; border-bottom: 1.5px dotted var(--line); transform: translateY(-4px); min-width: 24px; }
.meny-pris { font-family: var(--font-display); font-weight: 600; white-space: nowrap; }

/* Formulär */
.form { display: grid; gap: 1rem; max-width: 620px; }
.form-rad { display: grid; gap: 1rem; grid-template-columns: 1fr 1fr; }
@media (max-width: 640px) { .form-rad { grid-template-columns: 1fr; } }
.form label { display: grid; gap: 0.4rem; font-size: 0.875rem; font-weight: 600; }
.form input, .form select, .form textarea {
  font: inherit; font-size: 1rem;
  padding: 0.85rem 1rem;
  border-radius: 11px;
  border: 1.5px solid var(--line);
  background: var(--ink-2);
  color: var(--cream);
  width: 100%;
}
.form input:focus, .form select:focus, .form textarea:focus { border-color: var(--brass); }
.form input:focus-visible, .form select:focus-visible, .form textarea:focus-visible { outline: 2px solid var(--brass); outline-offset: 2px; }
.form textarea { min-height: 130px; resize: vertical; }
.form .btn { justify-self: start; }
.form-status { font-size: 0.9375rem; min-height: 1.4em; }
.form-status.ok { color: #7FBF7F; }
.section-sand .form-status.ok { color: #2F6B2F; }
.form-status.fel { color: #E08575; }
.section-sand .form-status.fel { color: #8A2A1C; }
.section-sand .form input, .section-sand .form select, .section-sand .form textarea {
  background: #fff; color: var(--ink-on-sand); border-color: var(--line-sand);
}

/* CTA-band */
.cta-band { text-align: center; }
.cta-band h2 { max-width: 20ch; margin-inline: auto; margin-bottom: 1rem; }
.cta-band p { margin-inline: auto; margin-bottom: 0; }
.cta-band .btn-rad { justify-content: center; }

/* Footer */
footer { background: var(--ink-2); border-top: 1px solid var(--line-soft); padding: var(--space-section-tight) 0 2rem; }
.footer-grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr 1fr; gap: clamp(1.5rem, 4vw, 3rem); margin-bottom: var(--space-xl); }
.footer-logo img { height: 44px; width: auto; margin-bottom: 1rem; }
.footer-grid p, .footer-grid li { font-size: 0.9063rem; color: var(--cream-dim); }
.footer-grid h4 { font-size: 0.8125rem; letter-spacing: 0.14em; text-transform: uppercase; color: var(--brass); margin-bottom: 0.9rem; }
.footer-grid ul { list-style: none; padding: 0; display: grid; gap: 0.45rem; }
.footer-grid a { color: var(--cream-dim); }
.footer-grid a:hover { color: var(--brass); }
.footer-bottom {
  border-top: 1px solid var(--line-soft);
  padding-top: 1.5rem;
  display: flex; flex-wrap: wrap; gap: 1rem; justify-content: space-between;
  font-size: 0.8125rem; color: var(--cream-faint);
}
@media (max-width: 880px) { .footer-grid { grid-template-columns: 1fr 1fr; } }
@media (max-width: 520px) { .footer-grid { grid-template-columns: 1fr; } }

/* Rubrikvariant (ersätter inline styles) */
.h3-brass { color: var(--brass); margin-bottom: 0.9rem; }

/* Hero-entré — ren CSS, JS-oberoende */
@keyframes heroIn {
  from { opacity: 0; transform: translateY(22px); }
  to { opacity: 1; transform: none; }
}
.hero .reveal.synlig, .page-hero .reveal.synlig { animation: heroIn 0.75s var(--ease-out) both; }
.hero .reveal-d1.synlig, .page-hero .reveal-d1.synlig { animation-delay: 0.12s; }
.hero .reveal-d2.synlig, .page-hero .reveal-d2.synlig { animation-delay: 0.24s; }
@media (prefers-reduced-motion: reduce) {
  .hero .reveal.synlig, .page-hero .reveal.synlig { animation: none; }
}

/* Scroll-reveal — resilient (aldrig på kritisk kontaktinfo) */
.reveal { opacity: 0; transform: translateY(24px); transition: opacity 0.65s var(--ease-out), transform 0.65s var(--ease-out); }
.reveal.synlig { opacity: 1; transform: none; }
.reveal-d1 { transition-delay: 0.08s; }
.reveal-d2 { transition-delay: 0.16s; }
.reveal-d3 { transition-delay: 0.24s; }
@media (prefers-reduced-motion: reduce) {
  .reveal { opacity: 1 !important; transform: none !important; transition: none !important; }
  .kort, .kort-bild img, .btn { transition: none !important; }
}

/* Responsivt */
@media (max-width: 1024px) {
  .nav-links { display: none; }
  .nav-cta .btn-ghost { display: none; }
  .nav-burger { display: flex; }
}
@media (max-width: 640px) {
  body { font-size: 1rem; }
  .hero { min-height: 88svh; }
  .btn-rad .btn { flex: 1 1 auto; }
}
