/* JN design: tokens */
:root {
  --frost: #e9ecee;        /* page */
  --frost-2: #dde2e6;      /* quiet bands */
  --paper: #f5f6f7;        /* fields, raised */
  --slate: #232a31;        /* text, dark sections */
  --slate-2: #2f373f;
  --muted: #4f5b66;        /* secondary text on frost */
  --line: #c6cdd3;         /* hairlines on frost */
  --line-dark: #3d4650;    /* hairlines on slate */
  --cobalt: #1e3a9e;       /* the strong colour */
  --cobalt-hover: #172f82;
  --cobalt-soft: #aebdf0;  /* cobalt for text on dark */

  --font: "Schibsted Grotesk", "Helvetica Neue", Arial, sans-serif;
  --font-display: "Newsreader", Georgia, "Times New Roman", serif;
  --wrap: 1240px;
  --gutter: clamp(16px, 4vw, 40px);
  --section: clamp(72px, 10vw, 136px);
  --header-h: 72px;
  --radius: 3px;
}

/* Base */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-padding-top: calc(var(--header-h) + 16px); -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--frost);
  color: var(--slate);
  font-family: var(--font);
  font-size: 1.0625rem;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  overflow-x: clip;
}
img { display: block; max-width: 100%; height: auto; }
h1, h2, h3 { margin: 0; font-weight: 600; line-height: 1.05; letter-spacing: -0.02em; text-wrap: balance; }
/* serif display type echoes the serif JN logo; small headings stay sans */
h1, h2, .pk__price, .steps__n { font-family: var(--font-display); font-weight: 500; letter-spacing: -0.015em; font-optical-sizing: auto; }
h2 { font-size: clamp(2.1rem, 4vw, 3.25rem); line-height: 1.04; }
h3 { font-size: 1.25rem; letter-spacing: -0.01em; line-height: 1.2; }
p { margin: 0; text-wrap: pretty; }
a { color: inherit; }
ul, ol { margin: 0; padding: 0; list-style: none; }
:focus-visible { outline: 2px solid var(--cobalt); outline-offset: 3px; }
.packages--dark :focus-visible, .cta-band :focus-visible, .site-footer :focus-visible, .hero__panel:focus-visible { outline-color: #fff; }

.wrap { width: 100%; max-width: var(--wrap); margin-inline: auto; padding-inline: var(--gutter); }
.section { padding-block: var(--section); }
.visually-hidden { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip-link { position: absolute; left: 16px; top: -60px; z-index: 100; padding: 10px 14px; background: var(--slate); color: #fff; border-radius: var(--radius); }
.skip-link:focus { top: 12px; }

.section-head { display: grid; gap: 14px; max-width: 46rem; margin-bottom: clamp(36px, 5vw, 56px); }
.section-head p { color: var(--muted); font-size: 1.125rem; }

/* Buttons: squared, not pills */
.btn {
  display: inline-flex; align-items: center; justify-content: center;
  min-height: 50px; padding: 0 24px;
  border: 1.5px solid transparent; border-radius: var(--radius);
  font: inherit; font-size: 1rem; font-weight: 600; letter-spacing: 0.005em;
  text-decoration: none; cursor: pointer;
  transition: background-color .18s ease, color .18s ease, border-color .18s ease;
}
.btn--primary { background: var(--cobalt); color: #fff; }
.btn--primary:hover { background: var(--cobalt-hover); }
.btn--ghost { border-color: var(--slate); color: var(--slate); background: transparent; }
.btn--ghost:hover { background: var(--slate); color: var(--frost); }
.btn--light { background: var(--frost); color: var(--cobalt); }
.btn--light:hover { background: #fff; }
.btn--small { min-height: 42px; padding: 0 18px; font-size: 0.9375rem; }

.text-link { display: inline-block; margin-top: 36px; font-weight: 600; text-underline-offset: 6px; text-decoration-thickness: 1.5px; }
.text-link--light { color: var(--cobalt-soft); }
.text-link--light:hover { color: #fff; }

/* Header */
.site-header {
  position: sticky; top: 0; z-index: 50;
  height: var(--header-h);
  background: var(--frost);
  border-bottom: 1px solid transparent;
  transition: border-color .2s ease;
}
.site-header.is-scrolled { border-bottom-color: var(--line); }
.site-header__inner {
  display: flex; align-items: center; gap: 28px;
  height: 100%; max-width: var(--wrap); margin-inline: auto; padding-inline: var(--gutter);
}
.logo { display: block; flex: none; }
.logo img { width: auto; height: 46px; }
.site-nav { display: flex; align-items: center; gap: 28px; margin-left: auto; }
.site-nav__links { display: flex; gap: 26px; }
.site-nav__links a { text-decoration: none; font-weight: 500; }
.site-nav__links a:hover, .site-nav__links a[aria-current="page"] { text-decoration: underline; text-underline-offset: 7px; text-decoration-thickness: 2px; }
.site-nav__links a[aria-current="page"] { text-decoration-color: var(--cobalt); }
.lang { display: flex; gap: 2px; padding-left: 22px; border-left: 1px solid var(--line); }
.lang a { display: block; padding: 6px 7px; font-size: 0.875rem; font-weight: 500; color: var(--muted); text-decoration: none; border-radius: var(--radius); }
.lang a:hover { color: var(--slate); }
.lang a[aria-current="true"] { color: var(--cobalt); font-weight: 700; }

.menu-toggle { display: none; width: 44px; height: 44px; margin-right: -10px; padding: 0; border: 0; background: none; color: var(--slate); cursor: pointer; }
.menu-toggle__bars, .menu-toggle__bars::before { display: block; width: 24px; height: 2px; margin: auto; background: currentColor; transition: transform .25s ease; }
.menu-toggle__bars { position: relative; transform: translateY(-4px); }
.menu-toggle__bars::before { content: ""; position: absolute; left: 0; top: 8px; }
.menu-open .menu-toggle__bars { transform: translateY(0) rotate(45deg); }
.menu-open .menu-toggle__bars::before { transform: translateY(-8px) rotate(-90deg); }

@media (max-width: 900px) {
  .menu-toggle { display: block; }
  .site-header__cta { margin-left: auto; }
  .site-nav {
    position: fixed; inset: var(--header-h) 0 0 0; z-index: 49;
    flex-direction: column; align-items: stretch; gap: 32px; margin: 0;
    padding: 24px var(--gutter) 40px;
    background: var(--frost); border-top: 1px solid var(--line);
    visibility: hidden; opacity: 0;
    transition: opacity .2s ease, visibility 0s linear .2s;
  }
  .menu-open .site-nav { visibility: visible; opacity: 1; transition: opacity .2s ease; }
  .site-nav__links { flex-direction: column; gap: 0; }
  .site-nav__links li { border-bottom: 1px solid var(--line); }
  .site-nav__links a { display: block; padding: 16px 0; font-size: 1.75rem; font-weight: 600; letter-spacing: -0.02em; }
  .site-nav__links a[aria-current="page"] { color: var(--cobalt); text-decoration: none; }
  .lang { padding-left: 0; border-left: 0; gap: 8px; }
  .lang a { padding: 10px 14px; border: 1px solid var(--line); font-size: 1rem; }
  .lang a[aria-current="true"] { border-color: var(--cobalt); }
}
@media (max-width: 420px) {
  .site-header__inner { gap: 14px; }
  .site-header__cta { padding: 0 12px; }
  .logo img { height: 40px; }
}

/* Home hero: text left, the latest work in a cobalt panel right */
.hero { padding-block: clamp(40px, 7vw, 96px) clamp(64px, 9vw, 120px); }
.hero__grid {
  display: grid;
  grid-template-columns: minmax(0, 7fr) minmax(0, 5fr);
  gap: clamp(36px, 5vw, 72px);
  align-items: center;
}
.hero__title {
  font-size: clamp(3rem, 7vw, 6.25rem);
  line-height: 0.98;
  letter-spacing: -0.025em;
}
/* room below each line so descenders (y, p, j) are not clipped by the reveal mask */
.hero__title .line { display: block; overflow: clip; padding-bottom: 0.2em; margin-bottom: -0.14em; }
.hero__title .line > span { display: block; }
.hero__lead { margin-top: 28px; max-width: 34em; font-size: clamp(1.0625rem, 1.35vw, 1.1875rem); color: var(--muted); }
.hero__actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 36px; }

.hero__panel {
  display: block;
  padding: clamp(18px, 2.2vw, 28px);
  background: var(--cobalt);
  color: #fff;
  text-decoration: none;
  border-radius: var(--radius);
}
.frame { display: block; background: var(--slate); border-radius: 2px; overflow: hidden; }
.frame__bar {
  display: block; padding: 9px 12px;
  font-size: 0.75rem; color: #b9c2ca; letter-spacing: 0.01em;
  border-bottom: 1px solid var(--line-dark);
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.frame img { width: 100%; aspect-ratio: 16 / 10; object-fit: cover; object-position: top; }

/* Real screenshots: desktop in a browser frame, phone overlapping its corner */
.shots { position: relative; display: block; padding-right: 12%; padding-bottom: 10%; }
.shots .phone {
  position: absolute; right: 0; bottom: 0;
  width: 26%; aspect-ratio: 780 / 1688; object-fit: cover; object-position: top;
  border: 5px solid var(--slate); border-radius: 14px;
  background: var(--slate);
  box-shadow: 0 18px 40px rgba(10, 16, 40, 0.35);
  transition: transform .4s ease;
}
.hero__panel:hover .phone, .case__media:hover .phone { transform: translateY(-6px); }
.hero__panel-text { display: grid; gap: 2px; margin-top: 20px; }
.hero__panel-label { font-size: 0.875rem; color: var(--cobalt-soft); }
.hero__panel-title { font-family: var(--font-display); font-size: 1.75rem; font-weight: 500; letter-spacing: -0.01em; }
.hero__panel-link { margin-top: 8px; font-weight: 600; text-decoration: underline; text-underline-offset: 5px; text-decoration-thickness: 1.5px; }

.intro .hero__title .line > span { transform: translateY(105%); }
.intro .hero__lead, .intro .hero__actions { opacity: 0; }
.intro .hero__panel { opacity: 0; }

@media (max-width: 960px) {
  .hero__grid { grid-template-columns: 1fr; }
}

/* Process: a real sequence, so it is numbered */
.process { background: var(--frost-2); }
.process h2 { margin-bottom: clamp(36px, 5vw, 56px); }
.steps { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 32px; }
.steps li { padding-top: 22px; border-top: 2px solid var(--slate); }
.steps__n { display: block; margin-bottom: 18px; font-size: 2.75rem; font-weight: 700; line-height: 1; color: var(--cobalt); letter-spacing: -0.03em; }
.steps h3 { margin-bottom: 10px; }
.steps p { color: var(--muted); }
@media (max-width: 960px) { .steps { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 40px 28px; } }
@media (max-width: 560px) { .steps { grid-template-columns: 1fr; } }

/* Packages */
.pk-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 20px; }
.pk { display: flex; flex-direction: column; padding: 28px 26px 30px; border-radius: var(--radius); }
.pk__name { font-size: 1.25rem; }
.pk__price { margin-top: 18px; font-size: clamp(2.25rem, 3.6vw, 3rem); font-weight: 700; letter-spacing: -0.03em; line-height: 1; }
.pk__text { margin-top: 16px; }
@media (max-width: 900px) { .pk-grid { grid-template-columns: 1fr; } }

.packages--dark { background: var(--slate); color: var(--frost); }
.packages--dark .section-head p { color: #b6bfc7; }
.packages--dark .pk { background: var(--slate-2); }
.packages--dark .pk__price { color: var(--cobalt-soft); }
.packages--dark .pk__text { color: #c3cbd2; }

.packages--full { padding-top: 0; }
.packages--full .pk { background: var(--paper); border: 1px solid var(--line); }
.packages--full .pk__text { color: var(--muted); }
.pk__list { margin: 24px 0 28px; border-top: 1px solid var(--line); flex: 1; }
.pk__list li { padding: 11px 0 11px 22px; border-bottom: 1px solid var(--line); position: relative; }
.pk__list li::before { content: ""; position: absolute; left: 2px; top: calc(11px + 0.8em - 1px); width: 9px; height: 2px; background: var(--cobalt); }
.pk__btn { align-self: flex-start; }
.packages--full .pk--featured { background: var(--cobalt); border-color: var(--cobalt); color: #fff; }
.packages--full .pk--featured .pk__text { color: #d6ddf6; }
.packages--full .pk--featured .pk__list, .packages--full .pk--featured .pk__list li { border-color: rgba(255,255,255,.22); }
.packages--full .pk--featured .pk__list li::before { background: #fff; }
.packages--full .pk--featured .btn--primary { background: var(--frost); color: var(--cobalt); }
.packages--full .pk--featured .btn--primary:hover { background: #fff; }
.packages--full .pk--featured :focus-visible { outline-color: #fff; }

.included {
  display: grid; grid-template-columns: minmax(0, 4fr) minmax(0, 8fr); gap: 16px 48px;
  margin-top: clamp(56px, 8vw, 96px); padding-top: 40px; border-top: 2px solid var(--slate);
}
.included ul { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0 32px; }
.included li { padding: 12px 0; border-bottom: 1px solid var(--line); }
.included__terms { grid-column: 2; margin-top: 12px; font-weight: 600; }
.other {
  display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 20px 40px;
  margin-top: clamp(56px, 8vw, 96px); padding: 32px; background: var(--frost-2); border-radius: var(--radius);
}
.other h2 { font-size: clamp(1.5rem, 2.6vw, 2rem); }
.other p { margin-top: 8px; color: var(--muted); max-width: 40em; }
@media (max-width: 760px) {
  .included { grid-template-columns: 1fr; }
  .included ul { grid-template-columns: 1fr; }
  .included__terms { grid-column: 1; }
}

/* Inner page heads */
.page-head { padding-bottom: clamp(32px, 5vw, 56px); }
.page-title { font-size: clamp(2.75rem, 6vw, 5rem); letter-spacing: -0.025em; line-height: 1; }
.page-lead { margin-top: 22px; max-width: 36em; font-size: clamp(1.0625rem, 1.35vw, 1.1875rem); color: var(--muted); }

/* Work */
.work { padding-top: 0; }
.case {
  display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); gap: clamp(28px, 4vw, 56px);
  align-items: center;
  padding: clamp(18px, 2.4vw, 28px); background: var(--slate); color: var(--frost); border-radius: var(--radius);
}
.case__media { display: block; }
.case__text { padding-right: clamp(0px, 2vw, 20px); }
.case__title { font-size: clamp(2rem, 3.2vw, 2.75rem); }
.case__text > p:first-of-type { margin-top: 16px; color: #c3cbd2; }
.case__points { margin: 22px 0 28px; border-top: 1px solid var(--line-dark); }
.case__points li { padding: 10px 0; border-bottom: 1px solid var(--line-dark); }
.case .btn--primary { background: var(--frost); color: var(--cobalt); }
.case .btn--primary:hover { background: #fff; }
.case :focus-visible { outline-color: #fff; }
.case__note { margin-top: 16px; font-size: 0.875rem; color: #9aa5af; }
.case + .case { margin-top: clamp(20px, 3vw, 32px); }
.work__more { margin-top: 28px; color: var(--muted); }
@media (max-width: 960px) { .case { grid-template-columns: 1fr; } .case__text { padding: 4px 6px 10px; } }

/* Finnish local search pages (fi/kotisivut-*.html) */
.lp-facts { display: flex; flex-wrap: wrap; gap: 10px 28px; margin-top: 26px; font-weight: 600; }
.lp-facts li { position: relative; padding-left: 20px; }
.lp-facts li::before { content: ""; position: absolute; left: 0; top: calc(0.8em - 1px); width: 10px; height: 2px; background: var(--cobalt); }
.lp-head .hero__actions { margin-top: 32px; }
.lp-needs { background: var(--frost-2); }
.lp-needs__grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0 48px; }
.lp-needs__grid li { padding: 26px 0 28px; border-top: 2px solid var(--slate); }
.lp-needs__grid h3 { margin-bottom: 10px; }
.lp-needs__grid p { color: var(--muted); max-width: 32em; }
.lp-demo { padding-top: var(--section); }
.lp-faq__grid { display: grid; grid-template-columns: minmax(0, 4fr) minmax(0, 8fr); gap: 24px 48px; align-items: start; }
.lp-faq__list { border-top: 2px solid var(--slate); }
.lp-faq details { border-bottom: 1px solid var(--line); }
.lp-faq summary {
  display: flex; justify-content: space-between; align-items: center; gap: 20px;
  padding: 20px 0; font-size: 1.1875rem; font-weight: 600; cursor: pointer; list-style: none;
}
.lp-faq summary::-webkit-details-marker { display: none; }
.lp-faq summary::after { content: "+"; flex: none; font-size: 1.5rem; font-weight: 400; line-height: 1; color: var(--cobalt); }
.lp-faq details[open] summary::after { content: "\2212"; }
.lp-faq summary:hover { color: var(--cobalt); }
.lp-faq details p { padding-bottom: 22px; max-width: 40em; color: var(--muted); }
.lp-more { padding-top: 0; }
.lp-more h2 { font-size: clamp(1.5rem, 2.6vw, 2rem); margin-bottom: 20px; }
.lp-more__list { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
.lp-more__list a {
  display: flex; align-items: center; justify-content: space-between; gap: 16px; height: 100%;
  padding: 20px 22px; background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius);
  font-weight: 600; text-decoration: none;
}
.lp-more__list a::after { content: "\2192"; color: var(--cobalt); }
.lp-more__list a:hover { border-color: var(--cobalt); color: var(--cobalt); }
@media (max-width: 860px) {
  .lp-needs__grid, .lp-faq__grid, .lp-more__list { grid-template-columns: 1fr; }
}

/* About */
.about__grid { display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 4fr); gap: clamp(40px, 7vw, 112px); align-items: start; }
.about__text > p { margin-top: 20px; max-width: 36em; }
.about__text > p.page-lead { margin-top: 26px; color: var(--slate); }
.about__actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 36px; }
.about__side { display: grid; gap: 20px; }
.about__photo { margin: 0; }
.about__photo img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; border-radius: var(--radius); }
.about__photo figcaption { margin-top: 8px; font-size: 0.8125rem; color: var(--muted); }
.about__photo figcaption a { color: inherit; text-underline-offset: 3px; }
.facts { margin: 0; padding: 28px; background: var(--cobalt); color: #fff; border-radius: var(--radius); }
.facts div { padding: 16px 0; border-bottom: 1px solid rgba(255,255,255,.22); }
.facts div:first-child { padding-top: 0; }
.facts div:last-child { border-bottom: 0; padding-bottom: 0; }
.facts dt { font-size: 0.875rem; color: var(--cobalt-soft); }
.facts dd { margin: 4px 0 0; font-size: 1.1875rem; font-weight: 600; }
@media (max-width: 860px) { .about__grid { grid-template-columns: 1fr; } }

/* Contact */
.contact__grid { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: clamp(40px, 7vw, 112px); align-items: start; }
.direct { margin-top: 40px; padding-top: 24px; border-top: 2px solid var(--slate); }
.direct h2 { font-size: 1.125rem; letter-spacing: 0; margin-bottom: 12px; }
.direct li { padding: 6px 0; font-size: 1.125rem; }
.direct a { text-underline-offset: 5px; }
.direct a:hover { color: var(--cobalt); }

.form { display: grid; gap: 22px; padding: clamp(22px, 3vw, 36px); background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius); }
.form__row { display: grid; grid-template-columns: 1fr 1fr; gap: 22px; }
.field { display: grid; gap: 8px; align-content: start; }
.field label { font-weight: 600; }
.field input, .field select, .field textarea {
  width: 100%; min-height: 50px; padding: 12px 14px;
  border: 1.5px solid var(--line); border-radius: var(--radius);
  background: #fff; color: var(--slate); font: inherit; font-size: 1rem;
}
.field textarea { resize: vertical; min-height: 150px; }
.field select {
  appearance: none; padding-right: 42px;
  background-image: linear-gradient(45deg, transparent 50%, var(--slate) 50%), linear-gradient(135deg, var(--slate) 50%, transparent 50%);
  background-position: calc(100% - 21px) 50%, calc(100% - 16px) 50%;
  background-size: 5px 5px; background-repeat: no-repeat;
}
.field input:hover, .field select:hover, .field textarea:hover { border-color: #9aa5af; }
.field input:focus-visible, .field select:focus-visible, .field textarea:focus-visible { outline-offset: 0; border-color: var(--cobalt); }
.field__hint { font-size: 0.875rem; color: var(--muted); }
.field.is-invalid input, .field.is-invalid select, .field.is-invalid textarea { border-color: #b3261e; }
.field__error { font-size: 0.875rem; color: #b3261e; font-weight: 500; }
.form__footer { display: flex; flex-wrap: wrap; align-items: center; gap: 14px 22px; }
.form__status { max-width: 30em; color: var(--muted); }
.form__status.is-done { color: var(--cobalt); font-weight: 600; }
.form__status.is-error { color: #b3261e; }
.form__privacy { font-size: 0.875rem; color: var(--muted); }
@media (max-width: 860px) { .contact__grid { grid-template-columns: 1fr; } }
@media (max-width: 560px) { .form__row { grid-template-columns: 1fr; } .form__footer .btn { width: 100%; } }

/* CTA band */
.cta-band { background: var(--cobalt); color: #fff; padding-block: clamp(56px, 8vw, 96px); }
.cta-band__inner { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 24px 48px; }
.cta-band p { margin-top: 12px; color: #d6ddf6; font-size: 1.125rem; }

/* Footer */
.site-footer { background: var(--slate); color: #c3cbd2; padding-top: 64px; }
.site-footer__inner { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 3fr) minmax(0, 4fr); gap: 40px; }
.site-footer__logo { width: auto; height: 56px; filter: brightness(0) invert(1); }
.site-footer__brand p { margin-top: 18px; max-width: 26em; }
.site-footer h2 { font-size: 1rem; letter-spacing: 0; color: #fff; margin-bottom: 14px; }
.site-footer li { padding: 4px 0; }
.site-footer a { text-decoration: none; }
.site-footer a:hover { color: #fff; text-decoration: underline; text-underline-offset: 4px; }
.site-footer__bottom { margin-top: 48px; padding-block: 22px 28px; border-top: 1px solid var(--line-dark); font-size: 0.875rem; color: #9aa5af; }
@media (max-width: 760px) { .site-footer__inner { grid-template-columns: 1fr; gap: 32px; } }

@media (prefers-reduced-motion: reduce) {
  .btn, .site-nav, .menu-open .site-nav, .menu-toggle__bars, .menu-toggle__bars::before, .shots .phone { transition: none; }
}

/* long email addresses wrap instead of pushing the page sideways on phones */
.direct a, .site-footer a { overflow-wrap: anywhere; }
