/* ═════════════════════════════════════════════
   STORMA · fælles stylesheet
   ═════════════════════════════════════════════ */

:root {
  --bg:      #FBFAF7;
  --bg-2:    #F2EEE7;
  --ink:     #161513;
  --muted:   #6E6A63;
  --line:    #E4DFD6;
  --white:   #FFFFFF;

  /* Flisefarver: bruges som accenter */
  --terra:   #C9552F;
  --cobalt:  #2340B8;
  --saffron: #E9A92E;
  --sage:    #5F9670;
  --blush:   #EDB1A0;
  --sky:     #9DBCE2;

  --font: "Instrument Sans", system-ui, -apple-system, sans-serif;
  --wrap: 1360px;
  --pad: clamp(1.25rem, 4vw, 3rem);
  --ease: cubic-bezier(.2, .7, .2, 1);
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
  font-family: var(--font);
  font-size: 16px;
  line-height: 1.6;
  color: var(--ink);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
}
img, video { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; background: none; border: 0; cursor: pointer; }

.wrap { width: 100%; max-width: var(--wrap); margin-inline: auto; padding-inline: var(--pad); }

/* ───────── Typografi ───────── */
.h-xl { font-size: clamp(2.6rem, 6vw, 5.4rem); font-weight: 500; line-height: 1.02; letter-spacing: -0.035em; }
.h-lg { font-size: clamp(2rem, 3.6vw, 3.2rem); font-weight: 500; line-height: 1.08; letter-spacing: -0.03em; }
.h-md { font-size: clamp(1.4rem, 2vw, 1.75rem); font-weight: 500; line-height: 1.2; letter-spacing: -0.02em; }
.label { font-size: .75rem; font-weight: 600; letter-spacing: .14em; text-transform: uppercase; }
.muted { color: var(--muted); }
.lead { font-size: clamp(1.05rem, 1.4vw, 1.2rem); color: var(--muted); max-width: 36rem; }

/* ───────── Knapper og links ───────── */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: .6rem;
  height: 52px; padding: 0 1.75rem;
  font-size: .92rem; font-weight: 500; letter-spacing: .01em;
  border: 1px solid currentColor;
  transition: background .2s, color .2s, border-color .2s;
}
.btn-dark  { background: var(--ink); color: var(--white); border-color: var(--ink); }
.btn-dark:hover  { background: #000; }
.btn-light { background: var(--white); color: var(--ink); border-color: var(--white); }
.btn-light:hover { background: var(--bg-2); border-color: var(--bg-2); }
.btn-ghost:hover { background: var(--ink); color: var(--white); border-color: var(--ink); }
.btn-ghost-light { color: var(--white); }
.btn-ghost-light:hover { background: var(--white); color: var(--ink); }
.btn-block { width: 100%; }

.link-arrow { display: inline-flex; align-items: center; gap: .5rem; font-weight: 500; border-bottom: 1px solid currentColor; padding-bottom: 2px; }
.link-arrow::after { content: "→"; transition: transform .2s var(--ease); }
.link-arrow:hover::after { transform: translateX(4px); }

/* ───────── Topbar + header ───────── */
.top { position: sticky; top: 0; z-index: 50; }
.announce {
  background: var(--ink); color: var(--white);
  font-size: .8rem; text-align: center; padding: .55rem var(--pad);
}
.announce a { text-decoration: underline; text-underline-offset: 3px; }

.site-header {
  background: var(--bg);
  border-bottom: 1px solid var(--line);
  transition: background .3s, color .3s, border-color .3s;
}
.hdr {
  display: grid; grid-template-columns: 1fr auto 1fr; align-items: center;
  height: 72px;
}
.hdr nav { display: flex; gap: 2rem; font-size: .92rem; }
.hdr nav a { position: relative; }
.hdr nav a::after {
  content: ""; position: absolute; left: 0; right: 0; bottom: -4px; height: 1px;
  background: currentColor; transform: scaleX(0); transform-origin: left; transition: transform .25s var(--ease);
}
.hdr nav a:hover::after, .hdr nav a[aria-current="page"]::after { transform: scaleX(1); }
.brand { display: flex; align-items: center; gap: .65rem; font-size: 1.35rem; font-weight: 600; letter-spacing: .28em; padding-left: .28em; }
.hdr-right { display: flex; justify-content: flex-end; align-items: center; gap: .35rem; margin-right: -.55rem; }
.icon-btn {
  position: relative; display: grid; place-items: center;
  width: 40px; height: 40px; border-radius: 50%;
  transition: background .2s;
}
.icon-btn:hover { background: rgba(127,127,127,.12); }
.icon-btn svg { width: 22px; height: 22px; fill: none; stroke: currentColor; stroke-width: 1.5; stroke-linecap: round; stroke-linejoin: round; }
.cart-count {
  position: absolute; top: 3px; right: 1px; min-width: 17px; height: 17px; padding: 0 4px;
  border-radius: 999px; background: var(--terra); color: var(--white);
  font-size: .68rem; font-weight: 600; line-height: 17px; text-align: center;
}
.menu-btn { display: none; font-size: .92rem; font-weight: 500; margin-left: .5rem; }

/* Søgepanel */
.search-panel { background: var(--bg); color: var(--ink); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); padding: 1.25rem 0 1.75rem; }
.search-row { display: flex; align-items: center; gap: .9rem; border-bottom: 1.5px solid var(--ink); padding-bottom: .6rem; }
.search-row > svg { width: 22px; height: 22px; fill: none; stroke: currentColor; stroke-width: 1.5; stroke-linecap: round; flex: none; }
.search-row input { flex: 1; border: 0; background: none; font: 400 clamp(1.2rem, 2.4vw, 1.6rem) var(--font); color: var(--ink); outline: none; min-width: 0; }
.search-row input::-webkit-search-cancel-button { display: none; }
.search-results { display: grid; gap: .25rem; margin-top: 1.25rem; max-height: 60vh; overflow: auto; }
.result { display: grid; grid-template-columns: 56px 1fr auto; gap: 1rem; align-items: center; padding: .5rem; margin: 0 -.5rem; transition: background .15s; }
.result:hover { background: var(--bg-2); }
.result-media { position: relative; display: block; width: 56px; aspect-ratio: 4 / 5; overflow: hidden; background: var(--bg-2); }
.result-media img, .result-media .art { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.result b, .cart-list b { display: block; font-weight: 500; }
.result small, .cart-list small { display: block; color: var(--muted); font-size: .85rem; }
.result-price { font-size: .9rem; color: var(--muted); }

/* Skuffe til kurv og profil */
.backdrop { position: fixed; inset: 0; z-index: 90; background: rgba(22,21,19,.4); opacity: 0; transition: opacity .3s; }
.backdrop.show { opacity: 1; }
.drawer {
  position: fixed; top: 0; right: 0; bottom: 0; z-index: 100;
  width: min(420px, 100%); background: var(--bg); color: var(--ink);
  display: flex; flex-direction: column;
  transform: translateX(100%); transition: transform .35s var(--ease);
  visibility: hidden;
}
.drawer.open { transform: none; visibility: visible; }
.drawer-head { display: flex; justify-content: space-between; align-items: center; padding: 1.25rem 1.5rem; border-bottom: 1px solid var(--line); }
.drawer-body { padding: 1.5rem; overflow: auto; flex: 1; }
.cart-list { list-style: none; margin-bottom: 1.5rem; }
.cart-list li { display: grid; grid-template-columns: 56px 1fr auto; gap: 1rem; padding: 1rem 0; border-bottom: 1px solid var(--line); align-items: start; }
.cart-remove { font-size: .82rem; color: var(--muted); text-decoration: underline; margin-top: .4rem; }
.cart-total { display: flex; justify-content: space-between; font-size: 1.05rem; margin-bottom: 1.25rem; }
.cart-total b { font-weight: 600; }
.cart-note { font-size: .82rem; color: var(--muted); margin-top: 1rem; }

/* Header oven på hero-video (forsiden) */
.overlay-header .top { position: fixed; left: 0; right: 0; }
.overlay-header .site-header:not(.solid) { background: transparent; color: var(--white); border-color: rgba(255,255,255,.18); }

/* Mobilmenu */
.mobile-nav {
  display: none; flex-direction: column; gap: 0;
  background: var(--bg); color: var(--ink); border-bottom: 1px solid var(--line);
}
.mobile-nav a { padding: 1rem var(--pad); border-top: 1px solid var(--line); font-size: 1.05rem; }
.mobile-nav.open { display: flex; }

/* ───────── Sektioner ───────── */
.section { padding: clamp(4.5rem, 9vw, 8rem) 0; }
.section-sm { padding: clamp(3rem, 6vw, 5rem) 0; }
.sec-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 2rem; margin-bottom: 2.5rem; flex-wrap: wrap; }
.sec-head .label { color: var(--muted); margin-bottom: .9rem; display: block; }

/* ───────── Produktkort ───────── */
.grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 2.5rem 1.25rem; }
.card { display: block; }
.card-media {
  position: relative; aspect-ratio: 4 / 5; overflow: hidden; background: var(--bg-2);
}
.card-media img, .card-media .art {
  position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover;
  transition: transform 1s var(--ease);
}
.card:hover .card-media img, .card:hover .card-media .art { transform: scale(1.04); }
.tag {
  position: absolute; top: 1rem; left: 1rem; z-index: 1;
  background: var(--white); color: var(--ink);
  font-size: .72rem; font-weight: 600; letter-spacing: .1em; text-transform: uppercase;
  padding: .4rem .7rem;
}
.tag.on-the-way::before { content: ""; display: inline-block; width: 6px; height: 6px; border-radius: 50%; background: var(--terra); margin-right: .45rem; vertical-align: 1px; }
.card-info { display: flex; justify-content: space-between; gap: 1rem; padding-top: 1rem; }
.card-name { font-weight: 500; font-size: 1.02rem; }
.card-sub { color: var(--muted); font-size: .9rem; }
.card-price { font-weight: 500; white-space: nowrap; font-size: .95rem; }
.card-price.soon { color: var(--muted); font-weight: 400; }
.swatches { display: flex; gap: 6px; margin-top: .6rem; }
.swatches i { width: 14px; height: 14px; border-radius: 50%; box-shadow: inset 0 0 0 1px rgba(0,0,0,.08); }

/* "Flere på vej"-kort */
.card-soon .card-media { display: grid; place-items: center; text-align: center; background: var(--bg-2); }
.card-soon .card-media div { padding: 2rem; max-width: 18rem; }
.card-soon .card-media p { color: var(--muted); margin-top: .6rem; font-size: .95rem; }

/* Flise-placeholder (bruges indtil der er rigtige fotos) */
.art {
  background:
    radial-gradient(circle at 0 0, var(--c1) 0 36%, transparent calc(36% + .5px)) 0 0 / 50% 50%,
    radial-gradient(circle at 100% 100%, var(--c2) 0 36%, transparent calc(36% + .5px)) 0 0 / 50% 50%,
    var(--c3);
}

/* ───────── Footer ───────── */
.site-footer { background: var(--ink); color: rgba(255,255,255,.72); padding: 5rem 0 2.5rem; font-size: .92rem; }
.foot-grid { display: grid; grid-template-columns: 1.6fr repeat(4, 1fr); gap: 3rem 2rem; }
.soon-link { color: rgba(255,255,255,.45); }
.soon-link small { display: inline-block; margin-left: .4rem; font-size: .7rem; letter-spacing: .08em; text-transform: uppercase; border: 1px solid rgba(255,255,255,.25); padding: .05rem .4rem; }
.foot-grid h4 { color: var(--white); font-size: .75rem; font-weight: 600; letter-spacing: .14em; text-transform: uppercase; margin-bottom: 1.1rem; }
.foot-grid ul { list-style: none; display: grid; gap: .5rem; }
.foot-grid a:hover { color: var(--white); }
.foot-brand { color: var(--white); font-size: 1.5rem; font-weight: 600; letter-spacing: .28em; margin-bottom: 1rem; display: inline-block; }
.foot-bottom { display: flex; justify-content: space-between; gap: 1rem; flex-wrap: wrap; margin-top: 4rem; padding-top: 1.5rem; border-top: 1px solid rgba(255,255,255,.14); font-size: .82rem; }

/* ───────── Animation ved scroll ───────── */
@media (prefers-reduced-motion: no-preference) {
  .reveal { opacity: 0; transform: translateY(24px); transition: opacity .9s var(--ease), transform .9s var(--ease); }
  .reveal.in { opacity: 1; transform: none; }
}

/* ───────── Responsivt ───────── */
@media (max-width: 960px) {
  .grid { grid-template-columns: repeat(2, 1fr); }
  .foot-grid { grid-template-columns: 1fr 1fr; }
  .foot-grid > :first-child { grid-column: 1 / -1; }
}
@media (max-width: 760px) {
  .hdr { grid-template-columns: auto 1fr auto; height: 62px; }
  .hdr nav { display: none; }
  .brand { grid-column: 1; font-size: 1.15rem; }
  .hdr-right { grid-column: 3; gap: 0; }
  .icon-btn { width: 36px; height: 36px; }
  .menu-btn { display: block; }
  .grid { grid-template-columns: 1fr 1fr; gap: 2rem .75rem; }
  .card-info { flex-direction: column; gap: .2rem; }
}
@media (max-width: 480px) {
  .grid { grid-template-columns: 1fr; }
  .foot-grid { gap: 2.5rem 1.5rem; }
}
