/* Ukenummer site — shared design system. No dependencies, no external requests. */

:root {
  --bg: #f7f5f2;
  --surface: #ffffff;
  --surface-2: #efebe6;
  --border: #e3ddd6;
  --text: #1b1917;
  --text-2: #6a635c;
  --brand: #b51a00;
  --brand-ink: #ffffff;
  --brand-soft: #f6e3de;
  --hero-1: #7d1200;
  --hero-2: #b51a00;
  --radius: 22px;
  --maxw: 1120px;
  --shadow: 0 1px 2px rgba(40, 20, 10, .06), 0 12px 32px rgba(60, 25, 10, .09);
  --sans: -apple-system, BlinkMacSystemFont, "SF Pro Text", "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  --rounded: ui-rounded, "SF Pro Rounded", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  color-scheme: light dark;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #121110;
    --surface: #1d1b19;
    --surface-2: #26231f;
    --border: #34302b;
    --text: #f3efea;
    --text-2: #a8a098;
    --brand: #ff6a4d;
    --brand-ink: #1b0600;
    --brand-soft: #3a1a12;
    --hero-1: #3a0a00;
    --hero-2: #7d1200;
    --shadow: 0 1px 2px rgba(0, 0, 0, .4), 0 12px 32px rgba(0, 0, 0, .35);
  }
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-padding-top: 76px; }
body {
  margin: 0; background: var(--bg); color: var(--text);
  font: 17px/1.55 var(--sans); -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; height: auto; display: block; }
a { color: var(--brand); }
h1, h2, h3 { line-height: 1.15; letter-spacing: -.015em; margin: 0 0 .4em; }
h2 { font-size: clamp(1.7rem, 3.4vw, 2.5rem); }
h3 { font-size: 1.25rem; }
p { margin: 0 0 1em; }
.container { width: min(100% - 32px, var(--maxw)); margin-inline: auto; }
.sr-only {
  position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden;
  clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}
.sr-only:focus { position: fixed; top: 8px; left: 8px; width: auto; height: auto; clip: auto; padding: 8px 14px;
  background: var(--surface); color: var(--text); z-index: 100; border-radius: 10px; }
:focus-visible { outline: 3px solid var(--brand); outline-offset: 3px; border-radius: 6px; }

/* Header */

.site-header {
  position: sticky; top: 0; z-index: 20;
  background: color-mix(in srgb, var(--bg) 82%, transparent);
  backdrop-filter: saturate(160%) blur(14px); -webkit-backdrop-filter: saturate(160%) blur(14px);
  border-bottom: 1px solid var(--border);
}
.site-header .container { display: flex; align-items: center; gap: 16px; min-height: 60px; }
.wordmark { display: inline-flex; align-items: center; gap: 10px; font-weight: 700; color: var(--text); text-decoration: none; margin-right: auto; }
.wordmark img { border-radius: 8px; box-shadow: 0 0 0 1px var(--border); }
.site-nav { display: flex; gap: 22px; align-items: center; }
.site-nav a { color: var(--text-2); text-decoration: none; font-size: .95rem; }
.site-nav a:hover { color: var(--text); }
.site-nav .lang { padding: 5px 12px; border: 1px solid var(--border); border-radius: 999px; color: var(--text); }
.nav-toggle { display: none; background: none; border: 0; font-size: 1.5rem; color: var(--text); min-width: 44px; min-height: 44px; cursor: pointer; }
@media (max-width: 800px) {
  .nav-toggle { display: block; }
  .site-nav { display: none; position: absolute; top: 60px; left: 0; right: 0; flex-direction: column; align-items: flex-start;
    gap: 0; padding: 8px 16px 16px; background: var(--bg); border-bottom: 1px solid var(--border); }
  .site-nav[data-open] { display: flex; }
  .site-nav a { padding: 10px 0; width: 100%; }
}

/* Buttons */

.btn-appstore {
  display: inline-flex; align-items: center; gap: 10px; padding: 11px 22px 11px 18px;
  background: #000; color: #fff; text-decoration: none; border-radius: 14px; line-height: 1.1;
  border: 1px solid rgba(255, 255, 255, .25); transition: transform .15s ease;
}
.btn-appstore:hover { transform: translateY(-1px); }
.btn-appstore small { display: block; font-size: .72rem; opacity: .85; }
.btn-appstore strong { display: block; font-size: 1.25rem; font-weight: 600; }
.btn-appstore svg { width: 26px; height: 26px; flex: none; }
.btn-ghost {
  display: inline-flex; align-items: center; padding: 12px 20px; border-radius: 14px; text-decoration: none;
  color: #fff; border: 1px solid rgba(255, 255, 255, .4);
}
.btn-ghost:hover { background: rgba(255, 255, 255, .1); }
.actions { display: flex; flex-wrap: wrap; gap: 12px; align-items: center; }

/* Hero */

.hero {
  position: relative; overflow: hidden; color: #fff6f2;
  background:
    radial-gradient(1200px 500px at 85% -10%, rgba(255, 255, 255, .14), transparent 60%),
    linear-gradient(160deg, var(--hero-1), var(--hero-2));
}
.hero .container { display: grid; grid-template-columns: 1.05fr .95fr; gap: 48px; align-items: center; padding: 72px 0 80px; }
.hero h1 { font-size: clamp(2.2rem, 5vw, 3.6rem); }
.hero .lead { font-size: 1.15rem; color: rgba(255, 246, 242, .88); max-width: 34em; }
.hero .meta { margin-top: 18px; font-size: .92rem; color: rgba(255, 246, 242, .75); }
.eyebrow { display: inline-block; font-size: .8rem; font-weight: 700; letter-spacing: .14em; text-transform: uppercase;
  color: rgba(255, 246, 242, .8); margin-bottom: 14px; }

/* The live week card — a Norwegian desk calendar page */
.week-card {
  justify-self: center; width: min(100%, 380px); text-align: center; color: #1b1917;
  background: #fffdfb; border-radius: 28px; padding: 26px 26px 30px;
  box-shadow: 0 30px 60px rgba(40, 5, 0, .35), 0 2px 0 rgba(0, 0, 0, .05);
  position: relative;
}
.week-card::before {
  content: ""; position: absolute; inset: 0 0 auto 0; height: 14px; border-radius: 28px 28px 0 0;
  background: repeating-linear-gradient(90deg, transparent 0 22px, rgba(0, 0, 0, .10) 22px 26px);
}
.week-card .label { font-weight: 800; letter-spacing: .5em; text-indent: .5em; color: #b51a00; margin-top: 10px; }
.week-card .number {
  font: 900 clamp(7rem, 20vw, 10.5rem)/1 var(--rounded); letter-spacing: -.04em; margin: 4px 0 6px;
  font-variant-numeric: tabular-nums;
}
.week-card .range { font-size: 1.15rem; color: #6a635c; }
.week-card .days { display: flex; justify-content: center; gap: 8px; margin: 18px 0 14px; }
.week-card .days span {
  width: 36px; height: 44px; border-radius: 10px; display: grid; place-items: center;
  font-size: .72rem; font-weight: 700; color: #6a635c; background: #f3eee8; line-height: 1.1;
}
.week-card .days span b { display: block; font-size: 1rem; color: #1b1917; }
.week-card .days span.today { background: #b51a00; color: #ffe5de; }
.week-card .days span.today b { color: #fff; }
.week-card .days span.holiday b { color: #b51a00; }
.week-card .days span.today.holiday b { color: #fff; }
.week-card .progress { display: inline-block; font-weight: 700; font-size: .95rem; color: #b51a00;
  background: #f6e3de; padding: 5px 14px; border-radius: 999px; }
.week-card noscript p { margin: 12px 0 0; color: #6a635c; font-size: .95rem; }

/* Sections */

.section { padding: 88px 0; }
.section-alt { background: var(--surface-2); }
.section-head { max-width: 44em; margin-bottom: 44px; }
.section-head p { color: var(--text-2); font-size: 1.1rem; }
.kicker { display: inline-block; font-size: .8rem; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; color: var(--brand); margin-bottom: 10px; }

.feature-row { display: grid; grid-template-columns: 1fr 300px; gap: 56px; align-items: center; padding: 28px 0; }
.feature-row:nth-child(odd) .text { order: 2; }
.feature-row .text p { color: var(--text-2); }
.ticks { list-style: none; padding: 0; margin: 0; }
.ticks li { position: relative; padding-left: 30px; margin: 8px 0; }
.ticks li::before {
  content: ""; position: absolute; left: 0; top: .45em; width: 18px; height: 18px; border-radius: 50%;
  background: var(--brand-soft) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23b51a00' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M5 12l5 5L20 7'/%3E%3C/svg%3E") center / 12px no-repeat;
}
.phone {
  border-radius: 42px; padding: 9px; background: #0b0b0b; box-shadow: var(--shadow);
  width: 100%; max-width: 300px; margin-inline: auto;
}
.phone img { border-radius: 34px; }

/* Widgets */

.widget-grid { display: grid; grid-template-columns: repeat(12, 1fr); gap: 20px; align-items: start; }
.widget { margin: 0; }
.widget img { border-radius: 26px; box-shadow: var(--shadow); width: 100%; }
.widget figcaption { font-size: .92rem; color: var(--text-2); margin-top: 10px; }
.widget.small { grid-column: span 3; }
.widget.medium { grid-column: span 5; }
.widget.large { grid-column: span 4; grid-row: span 2; }
.widget.lock { grid-column: span 4; }
.widget.lock .lock-bg {
  border-radius: 26px; padding: 26px; display: flex; gap: 22px; align-items: center; justify-content: center;
  background: linear-gradient(135deg, #1d2a44, #3b2340); box-shadow: var(--shadow);
}
.widget.lock .lock-bg img { box-shadow: none; border-radius: 0; width: auto; height: 76px; }
.widget.control { grid-column: span 4; }
.control-tile {
  border-radius: 26px; padding: 26px; background: #1f1f24; color: #fff; box-shadow: var(--shadow);
  display: flex; align-items: center; gap: 16px;
}
.control-tile .knob { width: 64px; height: 64px; border-radius: 50%; background: #3a3a41; display: grid; place-items: center; flex: none; }
.control-tile .knob svg { width: 30px; height: 30px; }
.control-tile strong { display: block; font-size: 1.2rem; }
.control-tile span { color: #b9b9c2; font-size: .9rem; }
.picture-dark { display: none; }
@media (prefers-color-scheme: dark) {
  .picture-light { display: none; }
  .picture-dark { display: block; }
}
@media (max-width: 900px) {
  .widget.small { grid-column: span 6; }
  .widget.medium { grid-column: span 12; }
  .widget.large { grid-column: span 12; grid-row: auto; }
  .widget.lock, .widget.control { grid-column: span 12; }
}

/* Watch */

.watch-row { display: flex; flex-wrap: wrap; gap: 28px; justify-content: center; }
.watch { width: 190px; padding: 14px; border-radius: 52px; background: #0b0b0b; box-shadow: var(--shadow); }
.watch img { border-radius: 38px; }
.watch-note { text-align: center; color: var(--text-2); margin-top: 28px; }

/* Holidays table */

.holiday-tools { display: flex; align-items: center; gap: 12px; margin-bottom: 18px; }
.holiday-tools button {
  min-width: 44px; min-height: 44px; border-radius: 12px; border: 1px solid var(--border);
  background: var(--surface); color: var(--text); font-size: 1.1rem; cursor: pointer;
}
.holiday-tools strong { font-size: 1.3rem; min-width: 4ch; text-align: center; font-variant-numeric: tabular-nums; }
.holidays { width: 100%; border-collapse: collapse; background: var(--surface); border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow); }
.holidays th, .holidays td { padding: 14px 18px; text-align: left; border-bottom: 1px solid var(--border); }
.holidays thead th { font-size: .8rem; letter-spacing: .08em; text-transform: uppercase; color: var(--text-2); background: var(--surface-2); }
.holidays tbody tr:last-child td { border-bottom: 0; }
.holidays td.week { font-variant-numeric: tabular-nums; white-space: nowrap; }
.holidays td.when { color: var(--brand); font-weight: 600; white-space: nowrap; }
.holidays tr.past td { color: var(--text-2); }
.holidays tr.past td.when { font-weight: 400; color: var(--text-2); }
.holidays tr.next td { background: var(--brand-soft); }
@media (max-width: 640px) {
  .holidays th:nth-child(3), .holidays td:nth-child(3) { display: none; }
  .holidays th, .holidays td { padding: 12px; }
}

/* Cards (FAQ, privacy, etc.) */

.cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 20px; }
.card { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 26px; }
.card h3 { margin-bottom: .35em; }
.card p { color: var(--text-2); margin: 0; }
.faq details { background: var(--surface); border: 1px solid var(--border); border-radius: 16px; padding: 18px 22px; margin-bottom: 12px; }
.faq summary { font-weight: 600; cursor: pointer; list-style: none; display: flex; justify-content: space-between; gap: 16px; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; color: var(--brand); font-size: 1.3rem; line-height: 1; }
.faq details[open] summary::after { content: "–"; }
.faq details p { margin: 12px 0 0; color: var(--text-2); }

.cta { text-align: center; }
.cta .actions { justify-content: center; }
.cta .section-lead { color: var(--text-2); font-size: 1.1rem; }
.cta .btn-appstore { border-color: var(--border); }

/* Document pages (privacy, support) */

.doc { padding: 56px 0 88px; }
.doc .container { max-width: 760px; }
.doc h1 { font-size: clamp(2rem, 4.4vw, 2.8rem); }
.doc h2 { font-size: 1.4rem; margin-top: 1.8em; }
.doc .updated { color: var(--text-2); }
.doc .lang-switch { display: flex; gap: 10px; margin: 18px 0 30px; }
.doc .lang-switch a { padding: 6px 14px; border-radius: 999px; border: 1px solid var(--border); text-decoration: none; color: var(--text); }
.doc section + section { margin-top: 64px; padding-top: 40px; border-top: 1px solid var(--border); }
.doc ul { padding-left: 1.2em; }
.doc li { margin: 6px 0; }
.contact-card { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 24px; margin: 24px 0; }

/* Footer */

.site-footer { padding: 40px 0 56px; border-top: 1px solid var(--border); color: var(--text-2); font-size: .92rem; }
.site-footer .container { display: flex; flex-wrap: wrap; gap: 14px 28px; align-items: center; justify-content: space-between; }
.site-footer nav { display: flex; flex-wrap: wrap; gap: 18px; }
.site-footer a { color: var(--text-2); }

/* Responsive */

@media (max-width: 900px) {
  .hero .container { grid-template-columns: 1fr; padding: 48px 0 56px; gap: 36px; }
  .feature-row { grid-template-columns: 1fr; gap: 28px; }
  .feature-row:nth-child(odd) .text { order: 0; }
  .section { padding: 64px 0; }
}

/* Scroll reveal (only when JS is on and motion is allowed) */

.js .reveal { opacity: 0; transform: translateY(16px); transition: opacity .6s ease, transform .6s ease; }
.js .reveal.in { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
  .js .reveal { opacity: 1; transform: none; transition: none; }
  .btn-appstore { transition: none; }
}
