/* HOPLA — hoplakunst.dk */
@import url("https://fonts.googleapis.com/css2?family=Gochi+Hand&display=swap");

:root {
  --bg: #ffffff;
  --ink: #111111;
  --muted: #9a9a9a;
  /* Midlertidig håndskrift til logoet, indtil Mathildes indscannede "Hopla" er klar */
  --hand: "Gochi Hand", "Comic Sans MS", cursive;
  --sans: "Helvetica Neue", Helvetica, Arial, sans-serif;
  --pad: clamp(18px, 3vw, 44px);
  --small: 12px;
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html { -webkit-text-size-adjust: 100%; }
body {
  background: var(--bg); color: var(--ink);
  font-family: var(--sans); font-size: var(--small); line-height: 1.45;
  letter-spacing: .02em;
}
img { display: block; max-width: 100%; height: auto; }
a { color: inherit; text-decoration: none; }
.u { text-transform: uppercase; }

/* ---------- Header ---------- */
.site-header {
  position: fixed; top: 0; left: 0; right: 0; z-index: 30;
  display: flex; align-items: center; gap: clamp(30px, 7vw, 120px);
  padding: 22px var(--pad);
  pointer-events: none;
}
.site-header > * { pointer-events: auto; }
.logo { font-family: var(--hand); font-size: clamp(40px, 4.4vw, 60px); line-height: .8; }
.nav { display: flex; gap: 14px; text-transform: uppercase; }
.nav-right { margin-left: auto; }
.nav a:hover, .nav a[aria-current="page"] { text-decoration: underline; text-underline-offset: 3px; }
body.solid .site-header { background: var(--bg); }

main { padding-top: 110px; min-height: 80vh; }

/* ---------- Footer ---------- */
.site-footer {
  display: flex; justify-content: space-between; align-items: flex-end;
  padding: 80px var(--pad) 24px; text-transform: uppercase;
}
.site-footer .muted { color: var(--muted); }

/* ---------- Forside: rodet kollage ---------- */
.collage {
  display: grid; grid-template-columns: repeat(12, 1fr);
  column-gap: clamp(10px, 1.6vw, 24px); row-gap: clamp(24px, 3vw, 48px);
  padding: 20px var(--pad) 0; align-items: start;
}
.collage figure { position: relative; }
.collage img { width: 100%; }
.collage figcaption {
  position: absolute; left: 0; bottom: -18px; text-transform: uppercase; color: var(--muted);
  opacity: 0; transition: opacity .25s;
}
.collage figure:hover figcaption { opacity: 1; }

/* ---------- Index-lister (portfolio + shop) ---------- */
.index { padding: 40px var(--pad) 0; position: relative; }
.index-intro { max-width: 46ch; margin: 0 0 56px calc(var(--labelw) + 0px); text-transform: none; color: var(--muted); }
.index { --labelw: clamp(110px, 15vw, 240px); }
.group { display: grid; grid-template-columns: var(--labelw) auto; margin-bottom: 52px; text-transform: uppercase; }
.group h2 { font-size: inherit; font-weight: 400; }
.rows { list-style: none; width: fit-content; display: grid; grid-template-columns: auto auto auto; column-gap: 22px; }
.row { display: grid; grid-column: 1 / -1; grid-template-columns: subgrid; cursor: default; padding: 0; }
.row .a { min-width: 0; }
.row .b { color: var(--muted); }
.row .c { color: var(--muted); }
.row:hover .a, .row.on .a { text-decoration: underline; text-underline-offset: 3px; }
.row.no-img { color: var(--muted); }
.row.no-img:hover .a { text-decoration: none; }

/* Shop: pris kommer frem ved hover */
.shop .rows { grid-template-columns: minmax(22ch, auto) 9ch 9ch; }
.shop .row .c { text-align: right; }
.shop .row .c { opacity: 0; transform: translateX(-6px); transition: opacity .25s, transform .25s; color: var(--ink); }
.shop .row:hover .c, .shop .row.on .c { opacity: 1; transform: none; }
.shop .row.sold .a { text-decoration: line-through; color: var(--muted); }
.shop-note { text-transform: none; max-width: 52ch; margin-top: 4px; color: var(--muted); }
.shop-note a { color: var(--ink); text-decoration: underline; text-underline-offset: 3px; }
.clothes-imgs { display: flex; gap: 14px; margin-top: 18px; }
.clothes-imgs figure { width: 150px; }
.clothes-imgs figcaption { color: var(--muted); margin-top: 6px; }

/* Billedet der "skrives frem" ved hover */
.preview {
  position: fixed; z-index: 20; right: var(--pad); top: 50%;
  width: min(38vw, 560px); height: min(70vh, 640px);
  transform: translateY(-46%);
  display: flex; align-items: center; justify-content: center;
  pointer-events: none;
}
.preview figure { position: relative; max-width: 100%; max-height: 100%; display: flex; flex-direction: column; }
.preview img {
  max-width: 100%; max-height: calc(min(70vh, 640px) - 24px); width: auto; height: auto; object-fit: contain;
  clip-path: inset(0 0 100% 0);
  transition: clip-path .55s cubic-bezier(.7,0,.2,1);
}
.preview.show img { clip-path: inset(0 0 0 0); }
.preview .cap { margin-top: 8px; text-transform: uppercase; opacity: 0; transition: opacity .3s .2s; }
.preview.show .cap { opacity: 1; }

/* ---------- Information ---------- */
.info { display: grid; grid-template-columns: var(--labelw, 200px) minmax(0, 48ch) 1fr; gap: 0 clamp(20px, 5vw, 80px); padding: 40px var(--pad) 0; }
.info { --labelw: clamp(110px, 15vw, 240px); }
.info h2 { font-size: inherit; font-weight: 400; text-transform: uppercase; }
.info .text p { font-size: 14px; line-height: 1.6; margin-bottom: 1.1em; letter-spacing: .01em; }
.info .contact { margin-top: 28px; text-transform: uppercase; display: grid; gap: 2px; }
.info .contact a:hover { text-decoration: underline; text-underline-offset: 3px; }
.info figure { max-width: 380px; justify-self: end; }

/* ---------- Mobil ---------- */
@media (max-width: 760px) {
  .site-header { flex-wrap: wrap; gap: 6px 14px; padding: 16px var(--pad); background: var(--bg); }
  .logo { width: 100%; }
  .nav-right { margin-left: 0; }
  main { padding-top: 96px; }

  .collage { grid-template-columns: repeat(6, 1fr); row-gap: 22px; }
  .collage figure { grid-column: var(--m, 1 / span 4) !important; margin-top: 0 !important; transform: none !important; }

  .index, .info { --labelw: 100%; }
  .group { grid-template-columns: 1fr; row-gap: 8px; }
  .index-intro { margin-left: 0; }
  .rows { width: 100%; grid-template-columns: 1fr auto; }
  .row .b:empty { display: none; }
  .row { padding: 3px 0; }
  .shop .rows { grid-template-columns: 1fr auto auto; }
  .shop .row .c { opacity: 1; transform: none; }

  .preview { left: 0; right: 0; top: auto; bottom: 0; width: 100%; height: 46vh; transform: none; background: var(--bg); padding: 12px var(--pad) 30px; border-top: 1px solid #eee; transition: transform .3s; transform: translateY(100%); }
  .preview.show { transform: none; }
  .preview img { max-height: calc(46vh - 70px); }

  .info { grid-template-columns: 1fr; row-gap: 16px; }
  .info figure { justify-self: start; }
}
