/* cbnolja.se – kvällsinspirerad stil. Inga externa resurser. */
:root{
  --bg:#15142b;          /* midnattsindigo */
  --bg-2:#1c1b38;        /* yta */
  --bg-3:#25244a;        /* upphöjd yta */
  --line:#34325f;
  --text:#ece9f6;
  --muted:#b9b4d2;
  --moon:#efcf8e;        /* månljus */
  --moon-ink:#1a1830;
  --dusk:#b3a6f2;        /* skymningslila, länkar */
  --dusk-hover:#d6cdff;
  --radius:14px;
  --maxw:72rem;
  --measure:44rem;
  --serif:"Iowan Old Style","Palatino Linotype",Palatino,"Book Antiqua",Georgia,serif;
  --sans:system-ui,-apple-system,"Segoe UI",Roboto,"Helvetica Neue",Arial,sans-serif;
  color-scheme:dark;
}
*,*::before,*::after{box-sizing:border-box}
html{-webkit-text-size-adjust:100%;text-size-adjust:100%}
body{margin:0;background:var(--bg);color:var(--text);font:1.0625rem/1.7 var(--sans);
  background-image:radial-gradient(60rem 30rem at 85% -10%,rgba(239,207,142,.10),transparent 60%),
                   radial-gradient(50rem 30rem at -10% 0%,rgba(179,166,242,.10),transparent 60%);
  background-repeat:no-repeat}
img{max-width:100%;height:auto;display:block}
a{color:var(--dusk);text-underline-offset:.18em;text-decoration-thickness:1px}
a:hover{color:var(--dusk-hover);text-decoration-thickness:2px}
:focus-visible{outline:3px solid var(--moon);outline-offset:3px;border-radius:4px}
.wrap{max-width:var(--maxw);margin:0 auto;padding:0 16px}
.skip{position:absolute;left:-999px;top:0;background:var(--moon);color:var(--moon-ink);padding:.6rem 1rem;z-index:10}
.skip:focus{left:16px;top:12px}

/* Sidhuvud */
.site-head{border-bottom:1px solid var(--line);background:rgba(21,20,43,.85)}
.head-inner{display:flex;flex-wrap:wrap;align-items:center;justify-content:space-between;gap:.5rem 1.5rem;padding-top:.9rem;padding-bottom:.9rem}
.logo{display:inline-flex;align-items:center;gap:.5rem;color:var(--text);text-decoration:none;font:600 1.25rem/1 var(--serif);letter-spacing:.01em}
.logo-mark{color:var(--moon)}
.logo .tld{color:var(--muted);font-weight:400}
.main-nav ul{list-style:none;margin:0;padding:0;display:flex;flex-wrap:wrap;gap:.25rem .9rem}
.main-nav a{color:var(--muted);text-decoration:none;font-size:.95rem;padding:.35rem 0;display:inline-block;min-height:44px;line-height:2.1}
.main-nav a:hover,.main-nav a[aria-current="page"]{color:var(--text);box-shadow:inset 0 -2px 0 var(--moon)}

/* Brödsmulor */
.crumbs ol{list-style:none;padding:0;margin:1.25rem 0 0;display:flex;flex-wrap:wrap;gap:.25rem;font-size:.875rem;color:var(--muted)}
.crumbs li+li::before{content:"/";margin-right:.35rem;color:var(--line)}
.crumbs a{color:var(--muted)}

/* Innehåll */
.content{max-width:var(--measure);padding:1.5rem 0 3rem}
h1,h2,h3,.h3{font-family:var(--serif);font-weight:600;line-height:1.25;color:var(--text)}
h1{font-size:clamp(2rem,1.4rem + 2.6vw,3rem);margin:.6rem 0 1rem;letter-spacing:-.01em}
h2{font-size:clamp(1.4rem,1.2rem + .9vw,1.8rem);margin:2.6rem 0 .8rem}
h3,.h3{font-size:1.2rem;margin:1.8rem 0 .5rem}
p,ul,ol,dl{margin:0 0 1.1rem}
.lead{font-size:1.15rem;color:var(--text)}
.lead strong{color:var(--moon)}
.small{font-size:.875rem;color:var(--muted)}
sup.fn{font-size:.7em;line-height:0;margin-left:.08em}
sup.fn a{text-decoration:none;padding:0 .12em}
.byline,.updated{font-size:.875rem;color:var(--muted)}
.updated{margin-top:2.5rem;border-top:1px solid var(--line);padding-top:1rem}

/* Innehållsförteckning */
.toc{background:var(--bg-2);border:1px solid var(--line);border-radius:var(--radius);padding:1rem 1.25rem;margin:1.5rem 0}
.toc-h{font-size:1rem;margin:0 0 .4rem;font-family:var(--sans);text-transform:uppercase;letter-spacing:.08em;color:var(--muted)}
.toc ol{margin:0;padding-left:1.2rem}

/* Faktarutor */
.facts{display:grid;grid-template-columns:1fr;gap:0;border:1px solid var(--line);border-radius:var(--radius);overflow:hidden}
.facts div{display:grid;grid-template-columns:minmax(8rem,34%) 1fr;gap:1rem;padding:.7rem 1rem;border-bottom:1px solid var(--line)}
.facts div:last-child{border-bottom:0}
.facts dt{color:var(--muted)}
.facts dd{margin:0;overflow-wrap:anywhere}

/* Tabeller */
.table-wrap{overflow-x:auto;margin:0 0 1.1rem;border:1px solid var(--line);border-radius:var(--radius)}
table{border-collapse:collapse;width:100%;min-width:32rem;font-size:.95rem}
caption{text-align:left;padding:.8rem 1rem;color:var(--muted);font-size:.875rem}
th,td{padding:.65rem 1rem;text-align:left;vertical-align:top;border-top:1px solid var(--line)}
thead th{background:var(--bg-3);font-weight:600}
tbody th{font-weight:600;color:var(--text)}

/* Kort */
.cards.two{display:grid;gap:1rem;grid-template-columns:1fr}
.card{background:var(--bg-2);border:1px solid var(--line);border-radius:var(--radius);padding:1.25rem 1.4rem}
.card h2{margin-top:0}
.linklist{list-style:none;padding:0}
.linklist li{border-top:1px solid var(--line)}
.linklist li:first-child{border-top:0}
.linklist a{display:block;padding:.6rem 0;text-decoration:none}
.linklist a::after{content:" →";color:var(--moon)}

/* Produkter */
.products{display:grid;gap:1rem;grid-template-columns:1fr;margin:1rem 0}
.product-card{background:var(--bg-2);border:1px solid var(--line);border-radius:var(--radius);padding:1rem 1.25rem 1.25rem}
.product-card img{border-radius:10px;background:#f4f1ea;aspect-ratio:1/1;object-fit:contain;width:100%;max-width:280px;margin:0 auto 1rem}
.product-card h2,.product-card h3{margin:.2rem 0 .5rem}
.specs{list-style:none;padding:0;margin:0 0 .8rem;display:flex;flex-wrap:wrap;gap:.4rem}
.specs li{background:var(--bg-3);border:1px solid var(--line);border-radius:999px;padding:.15rem .7rem;font-size:.875rem}
.price{font-weight:600;margin:.2rem 0 .8rem}
.price-note{display:block;font-weight:400;font-size:.8rem;color:var(--muted)}
.btn{display:inline-block;background:var(--moon);color:var(--moon-ink);font-weight:600;text-decoration:none;border-radius:999px;padding:.7rem 1.3rem;min-height:44px}
.btn:hover{background:#f6dca8;color:var(--moon-ink);text-decoration:none}

/* Diagram */
.diagram{margin:1.5rem 0;background:var(--bg-2);border:1px solid var(--line);border-radius:var(--radius);padding:1rem}
.diagram svg{width:100%;height:auto}
.diagram figcaption{font-size:.875rem;color:var(--muted);margin-top:.5rem}
.dg-box{fill:var(--bg-3);stroke:var(--line);stroke-width:1.5}
.dg-hl{fill:var(--moon);stroke:var(--moon)}
.dg-txt{fill:var(--text);font-weight:600}
.dg-hl-txt{fill:var(--moon-ink)}
.dg-small{fill:var(--muted);font-size:12px}
.dg-arrow{stroke:var(--dusk);stroke-width:2;fill:none;marker-end:none}

/* Tidslinje, steg */
.timeline{list-style:none;padding:0;border-left:2px solid var(--line);margin-left:.4rem}
.timeline li{position:relative;padding:0 0 1.2rem 1.2rem;display:grid;gap:.1rem}
.timeline li::before{content:"";position:absolute;left:-7px;top:.55rem;width:12px;height:12px;border-radius:50%;background:var(--moon)}
.timeline .year{font:600 1.1rem var(--serif);color:var(--moon)}
.steps{padding-left:1.3rem}
.steps li{margin-bottom:.7rem}

/* Ordlista */
.glossary div{padding:.8rem 0;border-top:1px solid var(--line)}
.glossary dt{font-weight:600;font-family:var(--serif);font-size:1.1rem}
.glossary dd{margin:.2rem 0 0}

/* Källor */
.notes{margin-top:2rem;font-size:.875rem;color:var(--muted)}
.notes h2{font-size:1.1rem}
.notes ol,.sources{padding-left:1.4rem}
.notes li,.sources li{margin-bottom:.45rem;overflow-wrap:anywhere}
.notes li:target{color:var(--text)}

.placeholder{background:#3a2c12;border:1px dashed var(--moon);color:var(--moon);padding:.7rem 1rem;border-radius:10px}

/* Sidfot */
.site-foot{border-top:1px solid var(--line);padding:1.5rem 0 2.5rem;color:var(--muted);font-size:.9rem}
.site-foot ul{list-style:none;padding:0;display:flex;flex-wrap:wrap;gap:.25rem 1.2rem}
.site-foot a{color:var(--muted)}
.zone-note{font-size:.875rem}

@media (min-width:46rem){
  .cards.two,.products{grid-template-columns:1fr 1fr}
}
@media (prefers-reduced-motion:reduce){*{scroll-behavior:auto!important}}
@media print{body{background:#fff;color:#000}.site-head,.site-foot{display:none}a{color:#000}}

/* Fotografier */
.photo{margin:1.5rem 0}
.photo img{width:100%;height:auto;border-radius:var(--radius);border:1px solid var(--line);background:var(--bg-2)}
.photo.portrait,.photo.square{max-width:26rem}
.photo.deco img{border:0}
.photo figcaption{font-size:.8rem;color:var(--muted);margin-top:.4rem}
