/* LetOpskrift.dk – styles (light, old-site vibe)
   Mål: Matche jeres tidligere look: lys, clean, premium cards, stor hero, sticky header,
   drawers til filtre + gemte opskrifter og tydelig UI.
*/

/* ========== Reset ========== */
*{box-sizing:border-box}
html,body{height:100%}
body{
  margin:0;
  font-family: system-ui, -apple-system, Segoe UI, Roboto, Arial, sans-serif;
  background:#ffffff;
  color:#111;
  line-height:1.55;
  -webkit-font-smoothing:antialiased;
  text-rendering:optimizeLegibility;
}
img{max-width:100%;display:block}
a{color:inherit;text-decoration:none}
button,input{font:inherit}
::selection{background:rgba(43,168,132,.18)}
:focus-visible{outline:3px solid rgba(43,168,132,.35); outline-offset:2px}

/* ========== Tokens ========== */
:root{
  --max: 1260px;

  --radius: 16px;
  --radius-lg: 26px;

  --bg: #ffffff;
  --panel: #ffffff;
  --line: #ececec;

  --text: #111111;
  --muted: #555555;
  --muted-2: #777777;

  --chip: #f3f4f6;
  --chip-line: #e5e7eb;

  --green: #2ba884;         /* primær accent som old vibe */
  --green-soft: rgba(43,168,132,.12);

  --shadow: 0 12px 28px rgba(0,0,0,.10);
  --shadow-soft: 0 8px 18px rgba(0,0,0,.08);

  --gap: 16px;
}

.container{max-width:var(--max); margin:0 auto; padding:0 1.4rem}
.grid{display:grid; gap:var(--gap)}
.hidden{display:none !important}

/* ========== Header ========== */
.site-header{
  background: rgba(255,255,255,.92);
  border-bottom:1px solid var(--line);
  position:sticky;
  top:0;
  z-index:1000;
  backdrop-filter: blur(8px);
}
.header-inner{
  padding: 1rem 0;
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap: 1rem;
}

.brand{
  display:flex;
  align-items:center;
  gap:.65rem;
  font-weight:900;
  letter-spacing:-.01em;
  font-size:1.05rem;
}
.brand .dot{
  width:10px;height:10px;border-radius:999px;
  background:var(--green);
  box-shadow: 0 0 0 7px rgba(43,168,132,.12);
}

.nav{
  display:flex;
  align-items:center;
  gap: 1.1rem;
}
.nav a{
  font-size:1rem;
  font-weight:650;
  color:#333;
  padding:.35rem .2rem;
}
.nav a:hover{color:#000}

.icon-btn{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  width:42px;height:42px;
  border-radius:999px;
  border:1px solid var(--line);
  background:#fff;
  cursor:pointer;
  box-shadow: 0 2px 0 rgba(0,0,0,.02);
}
.icon-btn:hover{background:#fafafa}

/* ========== Hero ========== */
.hero{
  position:relative;
  margin: 1.2rem auto 0;
  border-radius: var(--radius-lg);
  overflow:hidden;
  border:1px solid var(--line);
  box-shadow: var(--shadow);
  background:
    radial-gradient(1200px 520px at 20% 10%, rgba(43,168,132,.16), transparent 55%),
    radial-gradient(900px 420px at 85% 10%, rgba(17,17,17,.06), transparent 60%),
    #fff;
}
.hero-inner{
  padding: 2.2rem 1.8rem;
}
.hero h1{
  margin:0 0 .35rem;
  font-size: clamp(28px, 3.2vw, 44px);
  letter-spacing:-.02em;
}
.hero p{
  margin:0 0 1.25rem;
  color:var(--muted);
  max-width: 72ch;
  font-size: 1.05rem;
}

/* ========== Searchbar ========== */
.searchbar{
  display:flex;
  flex-wrap:wrap;
  gap:.8rem;
  align-items:center;
}
.searchbar .field{
  flex: 1 1 360px;
  display:flex;
  align-items:center;
  gap:.65rem;
  background:#fff;
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: .85rem 1rem;
  box-shadow: 0 2px 0 rgba(0,0,0,.02);
}
.searchbar input{
  flex:1;
  border:0;
  outline:0;
  background:transparent;
  font-size:1rem;
  color:var(--text);
}
.searchbar svg{color:#111; opacity:.85}

.pill{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  gap:.55rem;
  padding: .82rem 1.25rem;
  border-radius: 999px;
  border: 1px solid #111;
  cursor:pointer;
  background:#111;
  color:#fff;
  font-weight:800;
}
.pill:hover{filter:brightness(.95)}
.pill.secondary{
  background:#fff;
  color:#111;
  border:1px solid var(--line);
}
.pill.secondary:hover{background:#fafafa}

/* ========== Sections ========== */
.section{margin: 1.6rem 0}
.section-title{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:1rem;
  margin:0 0 .9rem;
}
.section-title h2{
  margin:0;
  font-size: 1.12rem;
  letter-spacing:-.01em;
}
.section-title .meta{
  color: var(--muted-2);
  font-size: .92rem;
}

/* ========== Cards ========== */
.cards{grid-template-columns: repeat(12, 1fr)}
.card{
  grid-column: span 4;
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow:hidden;
  box-shadow: var(--shadow-soft);
  transition: transform .12s ease, box-shadow .12s ease, border-color .12s ease;
}
.card:hover{
  transform: translateY(-2px);
  box-shadow: var(--shadow);
  border-color: rgba(0,0,0,.10);
}
.card .thumb{
  aspect-ratio: 16/10;
  background: linear-gradient(135deg, #f6f7f8, #ffffff);
  border-bottom: 1px solid var(--line);
}
.card .body{padding: .95rem}
.card .title{
  margin:0 0 .55rem;
  font-size: 1.02rem;
  line-height:1.25;
  font-weight: 900;
  color:#111;
}
.tags{
  display:flex;
  flex-wrap:wrap;
  gap:.45rem;
}
.tag{
  font-size:.82rem;
  color:#333;
  background: var(--chip);
  border: 1px solid var(--chip-line);
  padding: .28rem .6rem;
  border-radius: 999px;
}

/* Responsive cards */
@media (max-width: 980px){
  .card{grid-column: span 6}
}
@media (max-width: 620px){
  .card{grid-column: span 12}
  .hero-inner{padding: 1.6rem 1.2rem;}
}

/* ========== Overlay + Drawer ========== */
.overlay{
  position:fixed;
  inset:0;
  background: rgba(0,0,0,.42);
  z-index:70;
}
.drawer{
  position:fixed;
  top:0; right:0;
  height:100%;
  width:min(440px, 92vw);
  background:#fff;
  border-left:1px solid var(--line);
  box-shadow: -18px 0 45px rgba(0,0,0,.18);
  z-index:80;
  transform: translateX(102%);
  transition: transform .2s ease;
  display:flex;
  flex-direction:column;
}
.drawer.open{transform: translateX(0)}
.drawer header{
  padding: 1rem 1rem;
  display:flex;
  align-items:center;
  justify-content:space-between;
  border-bottom:1px solid var(--line);
}
.drawer header h3{
  margin:0;
  font-size:1.05rem;
  letter-spacing:-.01em;
}
.drawer .content{
  padding: 1rem;
  overflow:auto;
}
.drawer .actions{
  padding: 1rem;
  border-top:1px solid var(--line);
  display:flex;
  gap:.75rem;
}

/* Buttons in drawers */
.btn{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  gap:.5rem;
  padding: .8rem 1rem;
  border-radius: 12px;
  border: 1px solid var(--line);
  background:#fff;
  cursor:pointer;
  font-weight:800;
}
.btn:hover{background:#fafafa}
.btn.primary{
  background: var(--green);
  border-color: rgba(43,168,132,.35);
  color:#fff;
}
.btn.primary:hover{filter:brightness(.95)}

/* ========== Save button (Gem opskrift) ========== */
.save-wrap{display:inline-flex; align-items:center; gap:10px}
.save-btn{
  display:inline-flex;
  align-items:center;
  gap:.6rem;
  padding: .7rem 1rem;
  border-radius: 999px;
  border: 1px solid var(--line);
  background:#fff;
  cursor:pointer;
  font-weight:900;
}
.save-btn:hover{background:#fafafa}
.save-btn[data-saved="true"]{
  border-color: rgba(43,168,132,.55);
  background: rgba(43,168,132,.10);
}
.heart{width:18px;height:18px;display:inline-block}
.pop{animation: pop .16s ease}
@keyframes pop{from{transform:scale(.95)}to{transform:scale(1)}}

/* ========== Footer ========== */
.site-footer{
  margin: 2rem 0 1.2rem;
  border-top:1px solid var(--line);
  padding-top:1.2rem;
  color: var(--muted-2);
  font-size: .92rem;
}

/* ========== Small UX polish ========== */
.card a{display:block}
.hero .pill svg, .pill svg{opacity:.95}
.drawer p{color:var(--muted)}
/* =========================
   HERO: stor med baggrundsbillede (som opskrift-airfryer)
========================= */
.hero.hero--image{
  /* Full width “bleed”, men stadig pænt */
  margin-left: calc(50% - 50vw);
  margin-right: calc(50% - 50vw);
  width: 100vw;

  border: 0;
  border-radius: 0;
  box-shadow: none;

  background-image:
    linear-gradient(to bottom, rgba(0,0,0,.35), rgba(0,0,0,.35)),
    linear-gradient(to right, rgba(0,0,0,.55), rgba(0,0,0,.10)),
    var(--hero-img);
  background-size: cover;
  background-position: center;
}

.hero-inner--large{
  padding: 4.2rem 2.2rem;
  max-width: var(--max);
  margin: 0 auto;
}

.hero.hero--image h1{
  color:#fff;
  text-shadow: 0 10px 30px rgba(0,0,0,.45);
  font-size: clamp(34px, 4.2vw, 56px);
  max-width: 22ch;
}

.hero.hero--image p{
  color: rgba(255,255,255,.90);
  text-shadow: 0 10px 30px rgba(0,0,0,.35);
  font-size: 1.1rem;
  max-width: 70ch;
}

.hero.hero--image .searchbar{
  margin-top: 1.2rem;
  max-width: 920px;
}

.hero.hero--image .searchbar .field{
  background: rgba(255,255,255,.95);
  border: 1px solid rgba(255,255,255,.55);
}

.hero.hero--image .searchbar input{ color:#111; }
.hero.hero--image .searchbar svg{ color:#111; }

.hero.hero--image .pill{
  background:#111;
  border-color:#111;
}

.hero.hero--image .pill.secondary{
  background: rgba(255,255,255,.92);
  color:#111;
  border: 1px solid rgba(255,255,255,.55);
}

@media (max-width: 820px){
  .hero-inner--large{ padding: 3.2rem 1.2rem; }
  .hero.hero--image h1{ max-width: 28ch; }
}

/* =========================
   POPULÆRE KATEGORIER: billede-kort med tekst ovenpå
========================= */
.cat-card{
  position: relative;
  min-height: 180px;
}

.cat-card .thumb{
  display:none; /* vi bruger background i stedet */
}

.cat-card{
  background-image:
    linear-gradient(to top, rgba(0,0,0,.55), rgba(0,0,0,.05)),
    var(--card-img);
  background-size: cover;
  background-position: center;
}

.cat-card .body{
  position:absolute;
  left: 14px;
  right: 14px;
  bottom: 12px;
  padding: 0;
}

.cat-card .title{
  color:#fff;
  margin:0 0 .55rem;
  text-shadow: 0 10px 26px rgba(0,0,0,.45);
  font-size: 1.25rem;
}

.cat-card .tag{
  background: rgba(255,255,255,.88);
  border-color: rgba(255,255,255,.55);
  color:#111;
  font-weight:700;
}

@media (max-width: 620px){
  .cat-card{ min-height: 160px; }
}

/* =========================
   Generelt: lidt mere “luft” mellem sektioner (som i mock)
========================= */
.section{ margin: 2.1rem 0; }
/* =========================
   HERO: full width + centreret indhold som opskrift-airfryer
========================= */

/* Hero går full-bleed, men indhold holdes i max-bredde */
.hero.hero--image{
  position: relative;

  margin: 0;                 /* fjerner mærkelige top margins */
  margin-top: 14px;          /* lille luft under header */
  width: 100vw;
  margin-left: calc(50% - 50vw);
  margin-right: calc(50% - 50vw);

  border: 0;
  border-radius: 0;
  box-shadow: none;
  overflow: hidden;
  min-height: 520px;
  display: flex;
  align-items: center;
}

/* Baggrundsbilledet */
.hero.hero--image .hero-bg{
  position:absolute;
  inset:0;
  width:100%;
  height:100%;
  object-fit: cover;
  object-position: center;
  z-index:0;
}

/* Overlay så tekst altid står flot */
.hero.hero--image::before{
  content:"";
  position:absolute;
  inset:0;
  background:
    linear-gradient(to bottom, rgba(0,0,0,.35), rgba(0,0,0,.35)),
    linear-gradient(to right, rgba(0,0,0,.62), rgba(0,0,0,.10));
  z-index:1;
}

/* Hero indhold */
.hero-inner--large{
  position: relative;
  z-index: 2;
  width: min(var(--max), calc(100% - 2.4rem));
  margin: 0 auto;
  padding: 4.2rem 0;
}

.hero-inner--center{
  text-align: center;
}

.hero.hero--image h1{
  color:#fff;
  text-shadow: 0 10px 30px rgba(0,0,0,.45);
  font-size: clamp(34px, 4.4vw, 58px);
  letter-spacing: -.02em;
  margin: 0 0 10px;
}

.hero.hero--image p{
  color: rgba(255,255,255,.90);
  text-shadow: 0 10px 26px rgba(0,0,0,.35);
  font-size: 1.08rem;
  margin: 0 auto 18px;
  max-width: 78ch;
}

/* Search centreret og samme “bar” feel */
.searchbar--center{
  justify-content: center;
}
.hero.hero--image .searchbar{
  margin: 0 auto;
  max-width: 980px;
}

/* Input pill */
.hero.hero--image .searchbar .field{
  background: rgba(255,255,255,.95);
  border: 1px solid rgba(255,255,255,.55);
  box-shadow: 0 10px 30px rgba(0,0,0,.18);
}
.hero.hero--image .searchbar input{ color:#111; }
.hero.hero--image .searchbar svg{ color:#111; }

/* =========================
   Knapper: mindre Filtre + centreret “opskrift-airfryer” style
========================= */
.pill--sm{
  padding: .62rem .95rem;    /* mindre end før */
  font-weight: 800;
  font-size: .98rem;
}

.pill--outline{
  background: rgba(255,255,255,.92);
  color:#111;
  border: 1px solid rgba(255,255,255,.55);
}

.pill--outline:hover{
  background: #fff;
}

/* Primær “Se alle opskrifter” holdes mørk */
.hero.hero--image .pill.pill--sm:not(.pill--outline){
  background:#111;
  border-color:#111;
  color:#fff;
}

/* Mobil */
@media (max-width: 820px){
  .hero.hero--image{min-height: 470px;}
  .hero-inner--large{padding: 3rem 0;}
}
@media (max-width: 620px){
  .hero-inner--large{padding: 2.2rem 0;}
  .hero.hero--image h1{font-size: clamp(28px, 7vw, 42px);}
}
/* =========================
   HERO – ÆGTE CENTRERET (opskrift-airfryer-style)
========================= */

.hero.hero--image{
  position: relative;
  width: 100vw;
  margin-left: calc(50% - 50vw);
  margin-right: calc(50% - 50vw);
  min-height: 520px;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

/* Baggrundsbillede */
.hero-bg{
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  z-index: 0;
}

/* Overlay */
.hero.hero--image::before{
  content: "";
  position: absolute;
  inset: 0;
  background: rgba(0,0,0,.45);
  z-index: 1;
}

/* HERO INDHOLD – ÆGTE CENTRERET */
.hero-inner--center{
  position: relative;
  z-index: 2;
  width: 100%;
  max-width: 900px;
  margin: 0 auto;
  padding: 3.5rem 1.2rem;

  display: flex;
  flex-direction: column;
  align-items: center;   /* ← DET HER */
  text-align: center;    /* ← OG DET HER */
}

/* Tekst */
.hero.hero--image h1{
  color: #fff;
  font-size: clamp(34px, 4.5vw, 56px);
  margin: 0 0 14px;
}

.hero.hero--image p{
  color: rgba(255,255,255,.9);
  max-width: 70ch;
  margin: 0 0 22px;
}

/* Search + filtre */
.hero-search{
  width: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 14px;
}

/* Searchbar */
.hero-search .searchbar{
  width: 100%;
  max-width: 760px;
}

.hero-search .field{
  background: rgba(255,255,255,.95);
  border-radius: 999px;
  padding: 14px 18px;
}

/* Filtre-knap */
.pill--filter{
  background: rgba(255,255,255,.95);
  color: #111;
  border: 1px solid rgba(255,255,255,.6);
  padding: 10px 22px;
  font-weight: 700;
}

.pill--filter:hover{
  background: #fff;
}

/* Mobil */
@media (max-width: 640px){
  .hero.hero--image{ min-height: 460px; }
}
/* Gør søgefeltet smallere */
.hero-search .searchbar{
  width: 100%;
  max-width: 620px; /* ← VIGTIG */
}
/* =========================
   FILTRE-KNAP – LYS OG TYDELIG
========================= */

.pill--filter{
  background: rgba(255,255,255,.92) !important;
  color: #111 !important;
  border: 1px solid rgba(255,255,255,.65) !important;

  padding: 8px 18px;
  font-weight: 700;
  font-size: .95rem;

  display: inline-flex;
  align-items: center;
  gap: 6px;

  box-shadow: 0 8px 20px rgba(0,0,0,.18);
}

.pill--filter:hover{
  background: #fff !important;
}
.site-footer {
  background: #ffffff;
  border-top: 1px solid rgba(0,0,0,0.08);
  padding: 40px 0 24px;
  font-size: 14px;
}

.footer-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 24px;
}

.footer-col strong {
  display: block;
  margin-bottom: 10px;
}

.footer-text {
  line-height: 1.6;
  color: #555;
}

.footer-links {
  list-style: none;
  padding: 0;
  margin: 0;
}

.footer-links li {
  margin-bottom: 6px;
}

.footer-links a {
  color: #333;
  text-decoration: none;
}

.footer-links a:hover {
  text-decoration: underline;
}

.footer-bottom {
  margin-top: 32px;
  font-size: 13px;
  color: #777;
}
