/* =========================================================
   KRI ry — Static Site Design System
   Light editorial: slate + live KRI blue + paper. Inter type.
   ========================================================= */

*, *::before, *::after { box-sizing: border-box; }
* { margin: 0; padding: 0; }

:root {
  /* Brand palette — engineering navy + live KRI blue + paper */
  --slate-900: #0f1a2c;
  --slate-800: #18243a;
  --slate-700: #243349;
  --slate-500: #4d5a72;
  --slate-400: #6b7790;
  --slate-300: #9aa3b8;
  --slate-200: #c9cfdc;
  --slate-100: #e6e9f1;
  --paper:     #fbfaf6;
  --paper-2:   #f4f1e9;
  --line:      #e2decf;

  --highlight-700: #273aa8;
  --highlight-600: #3648d6;
  --highlight-500: #3452ff;
  --highlight-300: #8fa0ff;
  --highlight-100: #e9edff;

  /* Backwards-compatible alias: old amber classes now render the KRI blue highlight. */
  --amber-700: var(--highlight-700);
  --amber-600: var(--highlight-600);
  --amber-500: var(--highlight-500);
  --amber-300: var(--highlight-300);
  --amber-100: var(--highlight-100);

  --teal-700:  #14605a;
  --teal-500:  #1d8a7f;

  /* Type */
  --font-sans: 'Inter', ui-sans-serif, system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
  --font-serif: 'Fraunces', 'Times New Roman', Georgia, serif;

  /* Fluid sizes */
  --t-xs:   clamp(0.72rem, 0.7rem + 0.2vw, 0.78rem);
  --t-sm:   clamp(0.85rem, 0.82rem + 0.2vw, 0.92rem);
  --t-base: clamp(0.98rem, 0.95rem + 0.25vw, 1.05rem);
  --t-lg:   clamp(1.12rem, 1.05rem + 0.6vw, 1.32rem);
  --t-xl:   clamp(1.45rem, 1.25rem + 1.2vw, 1.95rem);
  --t-2xl:  clamp(2.0rem,  1.65rem + 2.2vw, 3.0rem);
  --t-3xl:  clamp(2.6rem,  2.0rem + 3.5vw, 4.4rem);

  /* Spacing */
  --s-1: 4px; --s-2: 8px; --s-3: 12px; --s-4: 16px;
  --s-6: 24px; --s-8: 32px; --s-10: 40px; --s-12: 48px;
  --s-16: 64px; --s-20: 80px; --s-24: 96px; --s-32: 128px;

  /* Radii + shadows */
  --r-sm: 6px;  --r-md: 10px; --r-lg: 16px; --r-xl: 24px;
  --shadow-sm: 0 1px 2px rgba(15,26,44,.05), 0 2px 6px rgba(15,26,44,.04);
  --shadow-md: 0 4px 12px rgba(15,26,44,.07), 0 12px 30px rgba(15,26,44,.06);
  --shadow-lg: 0 12px 32px rgba(15,26,44,.10), 0 32px 80px rgba(15,26,44,.08);

  --ease: cubic-bezier(.2,.7,.2,1);
}

html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  font-family: var(--font-sans);
  font-size: var(--t-base);
  line-height: 1.6;
  color: var(--slate-800);
  background: var(--paper);
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

img { max-width: 100%; height: auto; display: block; }
a { color: var(--amber-700); text-decoration: none; transition: color .15s var(--ease); }
a:hover { color: var(--amber-600); }
.mobile-break { display: none; }

h1, h2, h3, h4 { font-family: var(--font-serif); font-weight: 400; line-height: 1.12; color: var(--slate-900); letter-spacing: -0.015em; }
h1 { font-size: var(--t-3xl); }
h2 { font-size: var(--t-2xl); }
h3 { font-size: var(--t-xl); }
h4 { font-size: var(--t-lg); }
em { font-style: italic; color: var(--amber-700); }

/* ====================== Layout ====================== */
.container { width: min(1180px, calc(100% - 32px)); margin: 0 auto; }
.container-narrow { width: min(820px, calc(100% - 32px)); margin: 0 auto; }
.section { padding: var(--s-24) 0; }
.section-tight { padding: var(--s-16) 0; }

.eyebrow {
  display: inline-block;
  font-size: var(--t-xs);
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--amber-700);
  margin-bottom: var(--s-4);
}

.lead {
  font-size: var(--t-lg);
  line-height: 1.55;
  color: var(--slate-500);
  font-weight: 300;
}

/* ====================== Header / Nav ====================== */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(251, 250, 246, 0.88);
  backdrop-filter: saturate(140%) blur(14px);
  -webkit-backdrop-filter: saturate(140%) blur(14px);
  border-bottom: 1px solid var(--line);
}
.nav {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: flex-start;
  gap: var(--s-6);
  padding: var(--s-4) 0;
}
.nav-brand {
  display: flex;
  align-items: center;
  gap: var(--s-3);
  color: var(--slate-900);
  font-weight: 700;
}
.nav-brand img {
  height: 38px;
  width: auto;
  display: block;
}
.nav-brand-text { line-height: 1.1; }
.nav-brand-text strong {
  display: block;
  font-family: var(--font-serif);
  font-size: 1.18rem;
  font-weight: 500;
  letter-spacing: 0;
  color: var(--slate-900);
}
.nav-brand-text span {
  display: block;
  font-size: 0.72rem;
  font-weight: 500;
  color: var(--slate-500);
  letter-spacing: 0.02em;
}
.nav-links {
  display: flex;
  align-items: center;
  gap: var(--s-8);
  list-style: none;
  margin-left: auto;
}
.nav-links a {
  font-size: var(--t-sm);
  font-weight: 500;
  color: var(--slate-700);
  position: relative;
  padding: 4px 0;
}
.nav-links a:hover { color: var(--slate-900); }
.nav-links a.active {
  color: var(--slate-900);
}
.nav-links a.active::after {
  content: "";
  position: absolute;
  left: 0; right: 0; bottom: -2px;
  height: 2px;
  background: var(--amber-500);
  border-radius: 2px;
}
.nav-cta {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-left: auto;
  padding: 10px 18px;
  background: var(--slate-900);
  color: var(--paper);
  border-radius: var(--r-md);
  font-size: var(--t-sm);
  font-weight: 600;
  letter-spacing: -0.005em;
  transition: background .18s var(--ease), transform .18s var(--ease);
}
.nav-cta:hover { background: var(--slate-700); color: var(--paper); transform: translateY(-1px); }
.nav-toggle {
  display: none;
  flex: 0 0 auto;
  margin-left: var(--s-2);
  background: var(--slate-900);
  border: 1px solid var(--slate-900);
  border-radius: var(--r-sm);
  width: 40px; height: 40px;
  cursor: pointer;
  font-size: 1.1rem;
  color: var(--paper);
}

/* ====================== Buttons ====================== */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 14px 24px;
  border-radius: var(--r-md);
  font-size: var(--t-sm);
  font-weight: 600;
  letter-spacing: -0.005em;
  border: 1px solid transparent;
  cursor: pointer;
  transition: all .18s var(--ease);
  white-space: nowrap;
}
.btn-primary { background: var(--slate-900); color: var(--paper); }
.btn-primary:hover { background: var(--slate-700); color: var(--paper); transform: translateY(-1px); box-shadow: var(--shadow-md); }
.btn-amber { background: var(--amber-600); color: white; }
.btn-amber:hover { background: var(--amber-700); color: white; transform: translateY(-1px); box-shadow: var(--shadow-md); }
.btn-ghost { background: transparent; color: var(--slate-900); border-color: var(--slate-300); }
.btn-ghost:hover { border-color: var(--slate-900); color: var(--slate-900); }

/* ====================== Hero ====================== */
.hero {
  position: relative;
  padding: var(--s-24) 0 var(--s-20);
  overflow: hidden;
  background:
    radial-gradient(ellipse 65% 50% at 78% 18%, rgba(217, 140, 44, .14), transparent 60%),
    radial-gradient(ellipse 55% 45% at 8% 90%, rgba(29, 138, 127, .07), transparent 60%),
    var(--paper);
  border-bottom: 1px solid var(--line);
}
.hero-grid {
  display: grid;
  grid-template-columns: 1.1fr 1fr;
  gap: var(--s-16);
  align-items: center;
}
.hero-grid > * { min-width: 0; }
.hero-title {
  font-size: clamp(2.4rem, 1.7rem + 3.6vw, 4.4rem);
  font-weight: 300;
  line-height: 1.05;
  letter-spacing: -0.025em;
  margin-bottom: var(--s-6);
}
.hero-sub {
  font-size: var(--t-lg);
  color: var(--slate-500);
  line-height: 1.55;
  margin-bottom: var(--s-8);
  max-width: 56ch;
  overflow-wrap: break-word;
}
.hero-cta { display: flex; gap: var(--s-3); flex-wrap: wrap; margin-bottom: var(--s-10); }
.hero-meta {
  display: flex;
  gap: var(--s-10);
  padding-top: var(--s-6);
  border-top: 1px solid var(--line);
  max-width: 540px;
}
.hero-meta-item { display: flex; flex-direction: column; gap: 2px; }
.hero-meta-num {
  font-family: var(--font-serif);
  font-size: 1.6rem;
  color: var(--slate-900);
  font-weight: 400;
  letter-spacing: -0.02em;
}
.hero-meta-label {
  font-size: var(--t-xs);
  color: var(--slate-500);
  letter-spacing: 0.06em;
  text-transform: uppercase;
  font-weight: 600;
}
.hero-visual {
  position: relative;
  width: 100%;
  aspect-ratio: 4 / 5;
  border-radius: var(--r-xl);
  overflow: hidden;
  box-shadow: var(--shadow-lg);
  background: var(--slate-100);
}
.hero-visual img {
  width: 100%; height: 100%;
  object-fit: cover;
}
.hero-visual::after {
  content: "";
  position: absolute; inset: 0;
  background: linear-gradient(180deg, transparent 55%, rgba(15, 26, 44, .55));
}
.hero-visual-tag {
  position: absolute;
  left: 20px; bottom: 20px; right: 20px;
  color: white;
  font-family: var(--font-serif);
  font-size: var(--t-lg);
  z-index: 2;
}
.hero-visual-tag span {
  display: block;
  font-family: var(--font-sans);
  font-size: var(--t-xs);
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--amber-300);
  font-weight: 600;
  margin-bottom: 4px;
}

/* ====================== Cards / Cabin grid ====================== */
.cabin-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--s-6);
}
.cabin-card {
  position: relative;
  border-radius: var(--r-lg);
  overflow: hidden;
  background: white;
  border: 1px solid var(--line);
  transition: transform .25s var(--ease), box-shadow .25s var(--ease);
  display: flex;
  flex-direction: column;
}
.cabin-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-lg); }
.cabin-card-image {
  position: relative;
  aspect-ratio: 4 / 3;
  background: var(--slate-100);
  overflow: hidden;
}
.cabin-card-image img { width: 100%; height: 100%; object-fit: cover; transition: transform .6s var(--ease); }
.cabin-card:hover .cabin-card-image img { transform: scale(1.04); }
.deal-badge {
  position: absolute; top: 12px; left: 12px; z-index: 2;
  background: var(--amber-500); color: #fff;
  padding: 7px 12px; border-radius: 12px;
  box-shadow: 0 4px 14px rgba(15, 26, 44, .28);
  text-align: center; line-height: 1.05;
}
.deal-badge b { display: block; font-size: 1.15rem; font-weight: 800; letter-spacing: -0.01em; }
.deal-badge small { display: block; font-size: 0.6rem; font-weight: 700; letter-spacing: 0.05em; text-transform: uppercase; }
.ruka-deal {
  display: flex; align-items: center; gap: 14px;
  background: var(--amber-100);
  border: 1px solid var(--amber-300);
  border-left: 4px solid var(--amber-500);
  border-radius: var(--r-md);
  padding: 14px 18px;
  margin-bottom: var(--s-6);
}
.ruka-deal strong { font-size: 1.5rem; font-weight: 800; color: var(--amber-700); line-height: 1; white-space: nowrap; }
.ruka-deal span { color: var(--slate-700); font-size: 0.95rem; }
.cabin-card-actions { display: flex; gap: 10px; flex-wrap: wrap; margin-top: auto; }
.booking-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: var(--s-5); }
.booking-card {
  display: flex; flex-direction: column; gap: 5px;
  padding: var(--s-6);
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--r-md);
  box-shadow: var(--shadow-sm);
  text-decoration: none;
  transition: transform .2s var(--ease), box-shadow .2s var(--ease), border-color .2s var(--ease);
}
.booking-card:hover { transform: translateY(-3px); box-shadow: var(--shadow-md); border-color: var(--amber-300); }
.booking-card-loc { font-size: var(--t-xs); font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--amber-700); }
.booking-card strong { font-family: var(--font-serif); font-size: 1.2rem; font-weight: 500; color: var(--slate-900); }
.booking-card-cta { margin-top: 6px; color: var(--amber-700); font-weight: 700; font-size: .92rem; }
.cabin-card-body { padding: var(--s-6) var(--s-6) var(--s-8); flex: 1; display: flex; flex-direction: column; }
.cabin-card-loc {
  font-size: var(--t-xs);
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--amber-700);
  font-weight: 700;
  margin-bottom: var(--s-2);
}
.cabin-card h3 {
  font-size: var(--t-xl);
  margin-bottom: var(--s-3);
}
.cabin-card p { color: var(--slate-500); font-size: var(--t-sm); margin-bottom: var(--s-4); flex: 1; }
.cabin-card-tags { display: flex; gap: 6px; flex-wrap: wrap; margin-bottom: var(--s-4); }
.cabin-card-actions {
  display: flex;
  align-items: center;
  gap: var(--s-2);
  flex-wrap: wrap;
}
.cabin-card-actions .btn { padding-inline: 16px; }
.tag {
  display: inline-block;
  font-size: var(--t-xs);
  font-weight: 600;
  padding: 4px 10px;
  border-radius: 999px;
  background: var(--paper-2);
  color: var(--slate-700);
  border: 1px solid var(--line);
}
.tag-amber { background: var(--amber-100); color: var(--amber-700); border-color: var(--amber-300); }
.tag-teal { background: #e3f2f0; color: var(--teal-700); border-color: #c1ddd8; }

/* ====================== Benefits / features ====================== */
.benefits {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--s-6);
}
.benefit {
  padding: var(--s-8);
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: var(--r-lg);
  position: relative;
}
.benefit-num {
  font-family: var(--font-serif);
  font-size: 1.4rem;
  color: var(--amber-600);
  font-weight: 400;
  margin-bottom: var(--s-4);
  display: block;
}
.benefit h3 { font-size: var(--t-lg); margin-bottom: var(--s-3); }
.benefit p { color: var(--slate-500); font-size: var(--t-sm); }
.benefit ul { list-style: none; margin-top: var(--s-3); }
.benefit ul li {
  position: relative;
  padding-left: 22px;
  font-size: var(--t-sm);
  color: var(--slate-700);
  margin-bottom: var(--s-2);
}
.benefit ul li::before {
  content: "→";
  position: absolute;
  left: 0;
  color: var(--amber-600);
  font-weight: 600;
}

/* ====================== Pricing table ====================== */
.pricing-tabs {
  display: flex;
  gap: var(--s-2);
  margin-bottom: var(--s-8);
  flex-wrap: wrap;
  border-bottom: 1px solid var(--line);
}
.pricing-tab {
  padding: 12px 20px;
  font-size: var(--t-sm);
  font-weight: 600;
  background: none;
  border: 0;
  border-bottom: 2px solid transparent;
  margin-bottom: -1px;
  color: var(--slate-500);
  cursor: pointer;
  font-family: inherit;
  transition: color .15s var(--ease), border-color .15s var(--ease);
}
.pricing-tab.active { color: var(--slate-900); border-bottom-color: var(--amber-500); }
.pricing-tab:hover { color: var(--slate-900); }
.pricing-panel { display: none; }
.pricing-panel.active { display: block; }
.kri-wp-content-panel {
  max-width: 900px;
  margin: 0 auto;
  padding: var(--s-8);
  background: white;
  border: 1px solid var(--line);
  border-radius: var(--r-lg);
  box-shadow: var(--shadow-sm);
}
.kri-wp-content-panel h2,
.kri-wp-content-panel h3 {
  margin: var(--s-8) 0 var(--s-4);
}
.kri-wp-content-panel h2:first-child,
.kri-wp-content-panel h3:first-child {
  margin-top: 0;
}
.kri-wp-content-panel p,
.kri-wp-content-panel ul,
.kri-wp-content-panel ol {
  margin-bottom: var(--s-4);
}
.kri-wp-content-panel ul,
.kri-wp-content-panel ol {
  padding-left: 1.4rem;
}
.kri-wp-content-panel img {
  max-width: 100%;
  height: auto;
  border-radius: var(--r-sm);
}
.kri-wp-content-panel .um {
  margin-inline: auto !important;
}
.kri-wp-content-panel .um a.um-button,
.kri-wp-content-panel .um input[type=submit].um-button {
  border-radius: var(--r-sm) !important;
  box-shadow: none !important;
}
.price-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: var(--s-4);
}
.price-card {
  padding: var(--s-6);
  background: white;
  border: 1px solid var(--line);
  border-radius: var(--r-lg);
  transition: border-color .18s var(--ease);
}
.price-card:hover { border-color: var(--amber-500); }
.price-tier {
  font-size: var(--t-xs);
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--slate-500);
  font-weight: 600;
  margin-bottom: var(--s-2);
}
.price-amount {
  font-family: var(--font-serif);
  font-size: 2rem;
  font-weight: 400;
  color: var(--slate-900);
  letter-spacing: -0.02em;
  margin-bottom: var(--s-1);
}
.price-amount small { font-size: 1rem; color: var(--slate-500); }
.price-weeks {
  font-size: var(--t-xs);
  color: var(--slate-700);
  font-weight: 600;
  margin-bottom: var(--s-3);
  padding-bottom: var(--s-3);
  border-bottom: 1px dashed var(--line);
}
.price-card p { font-size: var(--t-xs); color: var(--slate-500); line-height: 1.5; }

/* ====================== FAQ ====================== */
.faq { max-width: 820px; margin: 0 auto; }
.faq-item {
  border-bottom: 1px solid var(--line);
}
.faq-item summary {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: var(--s-4);
  padding: var(--s-6) 0;
  cursor: pointer;
  font-family: var(--font-serif);
  font-size: var(--t-lg);
  color: var(--slate-900);
  list-style: none;
}
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary::after {
  content: "+";
  font-family: var(--font-sans);
  font-size: 1.4rem;
  color: var(--amber-600);
  font-weight: 300;
  transition: transform .2s var(--ease);
}
.faq-item[open] summary::after { content: "−"; }
.faq-item .faq-body {
  padding: 0 0 var(--s-6);
  color: var(--slate-500);
  font-size: var(--t-base);
  line-height: 1.65;
}
.faq-item .faq-body p + p,
.faq-item .faq-body p + ul { margin-top: var(--s-3); }
.faq-item .faq-body ul { padding-left: 20px; }
.faq-item .faq-body li { margin-bottom: 4px; }

/* ====================== Gallery ====================== */
.gallery-group { margin-bottom: var(--s-16); }
.gallery-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: var(--s-4);
  margin-bottom: var(--s-8);
  padding-bottom: var(--s-4);
  border-bottom: 1px solid var(--line);
}
.gallery-head h2 { font-size: var(--t-2xl); }
.gallery-head small { color: var(--slate-500); font-size: var(--t-sm); }
.gallery-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: var(--s-3);
}
.gallery-grid a {
  display: block;
  aspect-ratio: 4 / 3;
  overflow: hidden;
  border-radius: var(--r-md);
  background: var(--slate-100);
  position: relative;
}
.gallery-grid a img {
  width: 100%; height: 100%;
  object-fit: cover;
  transition: transform .5s var(--ease), filter .25s var(--ease);
}
.gallery-grid a:hover img { transform: scale(1.05); filter: brightness(0.92); }
.gallery-grid a.tall { aspect-ratio: 3 / 4; }

/* ====================== News cards ====================== */
.news-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--s-6);
}
.news-card {
  background: white;
  border: 1px solid var(--line);
  border-radius: var(--r-lg);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: transform .25s var(--ease), box-shadow .25s var(--ease);
}
.news-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-md); }
.news-card-image { aspect-ratio: 16 / 9; background: var(--slate-100); overflow: hidden; }
.news-card-image img { width: 100%; height: 100%; object-fit: cover; }
.news-card-body { padding: var(--s-6); flex: 1; display: flex; flex-direction: column; }
.news-category {
  font-size: var(--t-xs);
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--amber-700);
  font-weight: 700;
  margin-bottom: var(--s-2);
}
.news-card h3 { font-size: var(--t-lg); line-height: 1.3; margin-bottom: var(--s-3); }
.news-card h3 a { color: var(--slate-900); }
.news-card h3 a:hover { color: var(--amber-700); }
.news-card-meta {
  margin-top: auto;
  padding-top: var(--s-4);
  border-top: 1px solid var(--line);
  font-size: var(--t-xs);
  color: var(--slate-500);
  display: flex;
  justify-content: space-between;
}

/* ====================== Contact / contact cards ====================== */
.contact-hero {
  display: grid;
  grid-template-columns: 1.2fr 1fr;
  gap: var(--s-12);
  align-items: center;
  padding: var(--s-16) 0;
}
.contact-cards {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--s-4);
  margin-top: var(--s-8);
}
.contact-card {
  padding: var(--s-6);
  background: white;
  border: 1px solid var(--line);
  border-radius: var(--r-lg);
  text-align: left;
}
.contact-card-label {
  font-size: var(--t-xs);
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--amber-700);
  font-weight: 700;
  margin-bottom: var(--s-2);
}
.contact-card-value {
  font-family: var(--font-serif);
  font-size: var(--t-lg);
  color: var(--slate-900);
  overflow-wrap: anywhere;
}
.contact-card-value a { color: inherit; }
.contact-card p { overflow-wrap: anywhere; }

.board-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: var(--s-4);
}
.board-item {
  padding: var(--s-6);
  background: var(--paper-2);
  border-radius: var(--r-md);
  border-left: 3px solid var(--amber-500);
}
.board-role {
  font-size: var(--t-xs);
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--amber-700);
  font-weight: 700;
  margin-bottom: 4px;
}
.board-name { font-family: var(--font-serif); font-size: var(--t-lg); color: var(--slate-900); }

.piiri-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--s-4);
}
.piiri-card {
  padding: var(--s-6);
  background: white;
  border: 1px solid var(--line);
  border-radius: var(--r-md);
  display: flex;
  flex-direction: column;
  gap: var(--s-2);
  transition: transform .2s var(--ease), border-color .2s var(--ease);
}
.piiri-card:hover { transform: translateY(-2px); border-color: var(--amber-500); }
.piiri-card h3 { font-size: var(--t-base); color: var(--slate-900); }

/* ====================== Big CTA section ====================== */
.cta {
  background: var(--slate-900);
  color: var(--paper);
  border-radius: var(--r-xl);
  padding: var(--s-20) var(--s-12);
  text-align: center;
  position: relative;
  overflow: hidden;
}
.cta::before {
  content: "";
  position: absolute; inset: 0;
  background:
    radial-gradient(ellipse 50% 50% at 50% 0%, rgba(217, 140, 44, .35), transparent 60%),
    radial-gradient(ellipse 60% 40% at 100% 100%, rgba(29, 138, 127, .18), transparent 60%);
  pointer-events: none;
}
.cta > * { position: relative; z-index: 1; }
.cta h2 { color: var(--paper); margin-bottom: var(--s-4); }
.cta p { color: var(--slate-200); max-width: 56ch; margin: 0 auto var(--s-8); font-size: var(--t-lg); }
.cta .btn-amber { color: white; }
.cta .btn-ghost { color: var(--paper); border-color: rgba(255,255,255,.3); }
.cta .btn-ghost:hover { border-color: var(--paper); color: var(--paper); background: rgba(255,255,255,.06); }

/* ====================== About strip ====================== */
.about {
  display: grid;
  grid-template-columns: 1fr 1.2fr;
  gap: var(--s-12);
  align-items: start;
}
.about-stats {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: var(--s-4);
  margin-top: var(--s-6);
}
.about-stat {
  padding: var(--s-4) var(--s-6);
  background: var(--paper-2);
  border-radius: var(--r-md);
  border-left: 3px solid var(--amber-500);
}
.about-stat-num { font-family: var(--font-serif); font-size: 1.6rem; color: var(--slate-900); }
.about-stat-label { font-size: var(--t-xs); color: var(--slate-500); letter-spacing: 0.06em; text-transform: uppercase; font-weight: 600; overflow-wrap: anywhere; }
.about p + p { margin-top: var(--s-4); }
.about ul { margin-top: var(--s-4); padding-left: 0; list-style: none; }
.about ul li {
  position: relative;
  padding-left: 28px;
  margin-bottom: var(--s-3);
  color: var(--slate-700);
}
.about ul li::before {
  content: "✓";
  position: absolute;
  left: 0; top: 0;
  width: 20px; height: 20px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: var(--amber-100);
  color: var(--amber-700);
  border-radius: 50%;
  font-size: 12px;
  font-weight: 700;
}

/* ====================== Footer ====================== */
.site-footer {
  background: var(--slate-900);
  color: var(--slate-200);
  padding: var(--s-16) 0 var(--s-8);
  margin-top: var(--s-24);
}
.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr 1fr;
  gap: var(--s-10);
  margin-bottom: var(--s-12);
}
.footer-brand img { height: 44px; width: auto; margin-bottom: var(--s-4); filter: brightness(0) invert(1); opacity: .9; }
.footer-brand p { color: var(--slate-300); font-size: var(--t-sm); max-width: 38ch; line-height: 1.55; }
.footer-col h4 {
  color: var(--paper);
  font-family: var(--font-sans);
  font-size: var(--t-xs);
  letter-spacing: 0.16em;
  text-transform: uppercase;
  font-weight: 700;
  margin-bottom: var(--s-4);
}
.footer-col ul { list-style: none; }
.footer-col li { margin-bottom: var(--s-2); }
.footer-col a { color: var(--slate-300); font-size: var(--t-sm); }
.footer-col a:hover { color: var(--amber-300); }
.footer-bottom {
  border-top: 1px solid rgba(255,255,255,.08);
  padding-top: var(--s-6);
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: var(--s-4);
  font-size: var(--t-xs);
  color: var(--slate-400);
}

/* ====================== Page header (non-home pages) ====================== */
.page-head {
  padding: var(--s-20) 0 var(--s-12);
  background:
    radial-gradient(ellipse 50% 60% at 90% 10%, rgba(217, 140, 44, .12), transparent 60%),
    var(--paper);
  border-bottom: 1px solid var(--line);
}
.page-head h1 { font-size: var(--t-3xl); max-width: 18ch; margin-bottom: var(--s-4); }
.page-head p { max-width: 60ch; color: var(--slate-500); font-size: var(--t-lg); }
.breadcrumbs {
  font-size: var(--t-xs);
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--slate-500);
  margin-bottom: var(--s-4);
  font-weight: 600;
}
.breadcrumbs a { color: var(--slate-500); }
.breadcrumbs a:hover { color: var(--slate-900); }

/* ====================== Notice block ====================== */
.notice {
  background: var(--amber-100);
  border: 1px solid var(--amber-300);
  border-left: 4px solid var(--amber-600);
  padding: var(--s-6) var(--s-8);
  border-radius: var(--r-md);
  color: var(--slate-800);
  margin-bottom: var(--s-8);
}
.notice strong { color: var(--amber-700); }
.notice ul { padding-left: 20px; margin-top: var(--s-2); }
.notice li { margin-bottom: 4px; }

/* ====================== Reveal animation ====================== */
@media (prefers-reduced-motion: no-preference) {
  .reveal {
    opacity: 0;
    transform: translateY(20px);
    transition: opacity .7s var(--ease), transform .7s var(--ease);
  }
  .reveal.is-visible {
    opacity: 1;
    transform: translateY(0);
  }
}

/* ====================== Responsive ====================== */
@media (max-width: 1080px) {
  .nav-links { display: none; }
  .nav-cta { margin-left: auto; }
  .nav-toggle { display: inline-flex; align-items: center; justify-content: center; }
  .nav.open .nav-links {
    display: flex;
    position: absolute;
    top: 100%; left: 0; right: 0;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    background: var(--paper);
    border-top: 1px solid var(--line);
    padding: var(--s-4);
    box-shadow: var(--shadow-md);
  }
  .nav.open .nav-links li { padding: var(--s-3); border-bottom: 1px solid var(--line); }
}

@media (max-width: 960px) {
  .hero-grid { grid-template-columns: 1fr; gap: var(--s-10); }
  .hero-visual { aspect-ratio: 4 / 3; max-width: 100%; }
  .cabin-grid { grid-template-columns: repeat(2, 1fr); }
  .benefits { grid-template-columns: 1fr; }
  .news-grid { grid-template-columns: repeat(2, 1fr); }
  .price-grid { grid-template-columns: repeat(2, 1fr); }
  .gallery-grid { grid-template-columns: repeat(3, 1fr); }
  .board-grid { grid-template-columns: repeat(2, 1fr); }
  .piiri-grid { grid-template-columns: repeat(2, 1fr); }
  .about, .contact-hero { grid-template-columns: 1fr; gap: var(--s-8); }
  .contact-cards { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: repeat(2, 1fr); gap: var(--s-8); }
}

@media (max-width: 640px) {
  .nav { gap: var(--s-2); }
  .nav-brand { gap: var(--s-2); }
  .nav-brand-text { display: none; }
  .nav-cta { display: inline-flex; padding: 10px 14px; }
  .cabin-grid { grid-template-columns: 1fr; }
  .news-grid { grid-template-columns: 1fr; }
  .gallery-grid { grid-template-columns: repeat(2, 1fr); }
  .price-grid { grid-template-columns: 1fr 1fr; }
  .board-grid, .piiri-grid { grid-template-columns: 1fr; }
  .contact-cards { grid-template-columns: 1fr; }
  .section { padding: var(--s-16) 0; }
  .cta { padding: var(--s-12) var(--s-6); }
  .hero { padding: var(--s-16) 0 var(--s-12); }
  .hero .container { width: auto; max-width: 100vw; margin: 0; padding: 0 var(--s-4); }
  .hero-copy, .hero-visual { width: calc(100vw - 32px); max-width: calc(100vw - 32px); }
  .hero-sub { width: 100%; max-width: 100%; }
  .mobile-break { display: block; }
  .hero-title { font-size: clamp(1.7rem, 8.2vw, 2.45rem); letter-spacing: 0; }
  .hero-title em { display: inline; }
  .hero-visual-tag { font-size: 1.05rem; overflow-wrap: anywhere; }
  .hero-meta { gap: var(--s-6); }
  .page-head h1 { font-size: 2.45rem; letter-spacing: 0; overflow-wrap: anywhere; }
  .page-head p, .contact-card, .contact-card p { max-width: 100%; overflow-wrap: anywhere; }
}

.members-only-locked { display: block; }
.members-only-content { display: none; }
body.is-member .members-only-locked { display: none; }
body.is-member .members-only-content { display: block; }

/* Hero variant "b" — full-bleed dramatic hero with panning background.
   Used by WP-skinned cabin pages (Vuokatti, Ruka, Ylläs). Set the background
   image via inline style: <section class="hero-b" style="--hero-bg:url(…)"> */
.hero-b {
  position: relative;
  min-height: clamp(620px, 86vh, 880px);
  overflow: hidden;
  color: var(--paper);
  isolation: isolate;
  border-bottom: 1px solid var(--line);
}
.hero-b::before {
  content: "";
  position: absolute; inset: 0;
  background-image: var(--hero-bg, none);
  background-size: cover;
  background-position: center 35%;
  transform: scale(1.05);
  z-index: -2;
  animation: hero-b-pan 28s ease-in-out infinite alternate;
}
.hero-b::after {
  content: "";
  position: absolute; inset: 0;
  background:
    radial-gradient(ellipse 70% 50% at 75% 15%, rgba(217,140,44,.28), transparent 60%),
    linear-gradient(180deg, rgba(15,26,44,.25) 0%, rgba(15,26,44,.55) 50%, rgba(15,26,44,.95) 100%);
  z-index: -1;
}
@keyframes hero-b-pan {
  from { transform: scale(1.05) translate(0, 0); }
  to   { transform: scale(1.10) translate(-1.5%, -1%); }
}
.hero-b .container {
  position: relative;
  min-height: inherit;
  padding: var(--s-24) 0 var(--s-20);
  display: flex; flex-direction: column;
  justify-content: flex-end;
  gap: var(--s-6);
}
.hero-b-eyebrow {
  display: inline-flex; align-items: center; gap: 12px;
  font-size: 11.5px; font-weight: 700;
  letter-spacing: 0.22em; text-transform: uppercase;
  color: var(--amber-300);
  font-family: var(--font-sans);
}
.hero-b-eyebrow::before {
  content: ""; width: 28px; height: 1px;
  background: var(--amber-300);
}
.hero-b h1 {
  color: var(--paper);
  max-width: 18ch;
  font-size: clamp(3rem, 2rem + 5vw, 6.2rem);
  font-weight: 300;
  line-height: 1.02;
  letter-spacing: -0.028em;
  margin: 0;
}
.hero-b h1 em { color: var(--amber-300); font-style: italic; font-weight: 300; }
.hero-b .hero-b-sub {
  font-family: var(--font-serif);
  font-weight: 300;
  font-size: clamp(1.15rem, 1rem + 0.6vw, 1.5rem);
  line-height: 1.55;
  color: var(--slate-200);
  max-width: 56ch;
  margin: 0;
}
.hero-b-cta {
  display: flex; gap: 12px; flex-wrap: wrap;
  margin-top: var(--s-2);
}
.hero-b-meta {
  display: grid;
  grid-template-columns: repeat(3, auto);
  gap: var(--s-10);
  padding: var(--s-6) 0 0;
  margin-top: var(--s-4);
  border-top: 1px solid rgba(255,255,255,.15);
  max-width: 640px;
}
.hero-b-meta-item { display: flex; flex-direction: column; gap: 2px; }
.hero-b-meta-num {
  font-family: var(--font-serif);
  font-size: 1.8rem;
  color: var(--paper);
  font-weight: 400;
  letter-spacing: -0.02em;
}
.hero-b-meta-label {
  font-size: 11px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--amber-300);
  font-weight: 700;
}
@media (max-width: 640px) {
  .hero-b-meta { grid-template-columns: repeat(3, 1fr); gap: var(--s-4); }
  .hero-b-meta-num { font-size: 1.4rem; }
}
@media (prefers-reduced-motion: reduce) {
  .hero-b::before { animation: none; }
}

/* ====================== Article pages (uutiset/<slug>) ======================
   Centralized here (previously duplicated inline in every article).
   Paper design language (TypeUI "Paper"): tactile paper surfaces, soft layered
   shadows, rounded panels with thin borders, generous whitespace. Scoped to
   article content only - site header/footer/nav are untouched. */
.article-head {
  padding: var(--s-16) 0 var(--s-12);
  background:
    radial-gradient(120% 90% at 50% -10%, #ffffff 0%, var(--paper) 55%, var(--paper-2) 100%);
  border-bottom: 1px solid var(--line);
}
.article-head .breadcrumbs { margin-bottom: var(--s-4); }
.article-category {
  display: inline-flex; align-items: center; gap: 7px;
  font-size: var(--t-xs);
  letter-spacing: 0.14em;
  text-transform: uppercase;
  font-weight: 700;
  padding: 6px 14px 6px 12px;
  border-radius: 999px;
  background: var(--amber-100);
  color: var(--amber-700);
  border: 1px solid var(--amber-300);
  box-shadow: var(--shadow-sm);
  margin-bottom: var(--s-4);
}
.article-category::before {
  content: "";
  width: 7px; height: 7px; border-radius: 50%;
  background: var(--amber-500);
  display: inline-block;
}
.article-category.slate { background: var(--paper-2); color: var(--slate-700); border-color: var(--line); }
.article-category.slate::before { background: var(--slate-500); }
.article-head h1 {
  font-size: clamp(2.2rem, 1.6rem + 3vw, 3.6rem);
  line-height: 1.08; letter-spacing: -0.015em;
  max-width: 24ch; margin-bottom: var(--s-4);
  text-wrap: balance;
}
.article-meta {
  display: flex; gap: var(--s-6); align-items: center; flex-wrap: wrap;
  font-size: var(--t-sm); color: var(--slate-500);
}
.article-meta time { font-family: var(--font-serif); font-size: 1.1rem; color: var(--slate-700); }
.article-meta .author { display: flex; align-items: center; gap: 9px; font-weight: 600; color: var(--slate-700); }
.article-meta .author-dot {
  width: 32px; height: 32px; border-radius: 50%;
  background: linear-gradient(140deg, var(--amber-500), #6f86ff);
  display: inline-flex; align-items: center; justify-content: center;
  font-family: var(--font-serif); font-size: 14px; color: #fff;
  box-shadow: var(--shadow-sm);
}
.article-hero-image {
  width: min(1180px, calc(100% - 32px));
  margin: var(--s-12) auto 0;
  aspect-ratio: 16 / 9;
  overflow: hidden; border-radius: var(--r-xl);
  border: 1px solid var(--line);
  background: var(--slate-100);
  box-shadow: var(--shadow-lg);
}
.article-hero-image img { width: 100%; height: 100%; object-fit: cover; }
/* Logo-card variant: a compact ruled-paper card sized to its content instead of
   a full-width hero band. Used when the "image" is a brand logo or small graphic
   (KTK guest/info articles, board announcements). */
.article-hero-image.is-logo {
  aspect-ratio: auto;
  width: min(680px, calc(100% - 32px));
  height: auto;
  padding: var(--s-10) var(--s-8);
  background:
    repeating-linear-gradient(0deg, transparent 0 31px, rgba(15,26,44,.025) 31px 32px),
    linear-gradient(180deg, #ffffff 0%, var(--paper) 60%, var(--paper-2) 100%);
  display: flex; align-items: center; justify-content: center;
  position: relative;
  box-shadow: var(--shadow-md);
}
.article-hero-image.is-logo::after {
  content: "";
  position: absolute; left: 40px; top: 0; bottom: 0;
  width: 1px;
  background: rgba(52, 82, 255, .16);
}
.article-hero-image.is-logo img {
  width: auto; height: auto;
  max-width: min(380px, 80%); max-height: 220px;
  object-fit: contain;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--r-md);
  padding: var(--s-5) var(--s-7);
  box-shadow: var(--shadow-md);
}
.article-body {
  max-width: 720px; margin: 0 auto;
  padding: var(--s-16) 0 var(--s-12);
  font-size: 1.075rem; line-height: 1.74; color: var(--slate-800);
}
.article-body p { margin-bottom: 1.25em; }
.article-body h2 {
  font-size: clamp(1.5rem, 1.2rem + 1.6vw, 1.95rem);
  line-height: 1.2; letter-spacing: -0.01em;
  margin: 2.2em 0 0.6em;
}
.article-body h2:first-child { margin-top: 0; }
.article-body h3 { font-size: var(--t-xl); margin: var(--s-10) 0 var(--s-4); }
.article-body h4 { font-size: var(--t-lg); margin: var(--s-8) 0 var(--s-3); }
.article-body strong { color: var(--slate-900); }
.article-body em { color: var(--amber-700); font-style: italic; }
.article-body a { font-weight: 600; border-bottom: 1px solid currentColor; }
/* Ordered steps: numbered blue badge markers. Markup carries NO manual numbers. */
.article-body ol {
  list-style: none;
  counter-reset: kri-step;
  padding: 0;
  margin: 1.4em 0 1.6em;
}
.article-body ol li {
  position: relative;
  counter-increment: kri-step;
  padding-left: 2.4em;
  margin-bottom: 0.85em;
  line-height: 1.7;
}
.article-body ol li::before {
  content: counter(kri-step);
  position: absolute; left: 0; top: 0.05em;
  display: flex; align-items: center; justify-content: center;
  width: 1.65em; height: 1.65em;
  font-family: var(--font-sans);
  font-size: 0.82em; font-weight: 700;
  color: var(--amber-700);
  background: var(--amber-100);
  border: 1px solid var(--amber-300);
  border-radius: 50%;
}
/* Prose bullets: clean hanging dots, no card chrome. */
.article-body ul {
  list-style: none;
  padding: 0;
  margin: 1.4em 0 1.6em;
}
.article-body ul li {
  position: relative;
  padding-left: 1.5em;
  margin-bottom: 0.7em;
  line-height: 1.7;
  color: var(--slate-800);
}
.article-body ul li::before {
  content: "";
  position: absolute;
  left: 0.1em; top: 0.74em;
  width: 7px; height: 7px;
  border-radius: 50%;
  background: var(--amber-500);
}
/* Highlight note (aside): brand-blue tint with a left accent - not a pull quote. */
.article-callout {
  max-width: 720px; margin: var(--s-9) auto;
  padding: var(--s-6) var(--s-7);
  background: linear-gradient(180deg, var(--amber-100) 0%, var(--paper) 100%);
  border: 1px solid var(--amber-300);
  border-left: 4px solid var(--amber-500);
  border-radius: var(--r-md);
  box-shadow: var(--shadow-sm);
  font-family: var(--font-serif);
  font-size: clamp(1.1rem, 1rem + 0.6vw, 1.26rem);
  line-height: 1.55;
  color: var(--slate-800);
}
.article-callout p { margin: 0 0 0.6em; }
.article-callout p:last-child { margin-bottom: 0; }
.article-didyouknow {
  max-width: 720px; margin: var(--s-10) auto;
  padding: var(--s-7) var(--s-8);
  background: linear-gradient(180deg, #ffffff 0%, var(--paper) 100%);
  border: 1px solid var(--line);
  border-radius: var(--r-lg);
  box-shadow: var(--shadow-sm);
}
.article-didyouknow .label {
  display: inline-flex; align-items: center; gap: 7px;
  font-size: var(--t-xs);
  letter-spacing: 0.14em;
  text-transform: uppercase;
  font-weight: 700;
  color: var(--amber-700);
  margin-bottom: var(--s-2);
}
.article-didyouknow .label::before {
  content: "";
  width: 14px; height: 14px; border-radius: 50%;
  background: var(--amber-500);
  box-shadow: 0 0 0 4px rgba(52, 82, 255, .14);
  display: inline-block;
}
.article-didyouknow h3 { font-family: var(--font-serif); font-size: var(--t-xl); margin: 0 0 var(--s-3); color: var(--slate-900); }
.article-didyouknow p { margin: 0; font-size: 1.02rem; line-height: 1.7; color: var(--slate-700); }
.article-cta,
.article-feedback {
  max-width: 720px; margin: var(--s-12) auto;
  padding: var(--s-10) var(--s-8);
  background: radial-gradient(120% 120% at 50% 0%, #1b2b4d 0%, var(--slate-900) 70%);
  color: var(--paper);
  border-radius: var(--r-xl);
  text-align: center;
  position: relative;
  overflow: hidden;
  box-shadow: var(--shadow-lg);
}
.article-cta::after,
.article-feedback::after {
  content: "";
  position: absolute; inset: 0;
  background-image: repeating-linear-gradient(0deg, transparent 0 31px, rgba(255,255,255,.03) 31px 32px);
  pointer-events: none;
}
.article-cta > *,
.article-feedback > * { position: relative; z-index: 1; }
.article-cta h2,
.article-feedback h2 {
  color: var(--paper); font-size: clamp(1.6rem, 1.3rem + 1.5vw, 2.2rem);
  margin: 0 0 var(--s-3);
}
.article-cta p,
.article-feedback p { color: var(--slate-200); max-width: 48ch; margin: 0 auto var(--s-6); font-size: 1.02rem; line-height: 1.55; }
.article-signoff {
  max-width: 720px; margin: var(--s-10) auto 0;
  padding-top: var(--s-6);
  border-top: 1px solid var(--line);
  font-family: var(--font-serif);
  font-style: italic;
  font-size: 1.1rem;
  line-height: 1.7;
  color: var(--slate-700);
}
.article-signoff strong {
  display: block;
  font-style: normal;
  font-family: var(--font-sans);
  font-weight: 700;
  font-size: 1.05rem;
  color: var(--slate-900);
  margin-top: 6px;
}
/* Member-gated CTA panel (shown to anonymous visitors on gated articles). */
.members-only {
  max-width: 720px; margin: var(--s-12) auto;
  padding: var(--s-10) var(--s-8);
  background: linear-gradient(160deg, var(--slate-900) 0%, var(--slate-700) 100%);
  color: var(--paper);
  border-radius: var(--r-xl);
  text-align: center;
  position: relative;
  overflow: hidden;
}
.members-only::before {
  content: "";
  position: absolute; inset: 0;
  background: radial-gradient(ellipse 50% 40% at 50% 0%, rgba(217,140,44,.30), transparent 65%);
  pointer-events: none;
}
.members-only > * { position: relative; z-index: 1; }
.members-only .lock {
  display: inline-flex; align-items: center; justify-content: center;
  width: 56px; height: 56px; border-radius: 50%;
  background: rgba(217,140,44,.18); border: 1px solid rgba(217,140,44,.4);
  color: var(--amber-300); font-size: 24px;
  margin-bottom: var(--s-4);
}
.members-only .label {
  font-size: 11.5px; letter-spacing: 0.24em; text-transform: uppercase;
  font-weight: 700; color: var(--amber-300); margin-bottom: var(--s-3);
}
.members-only h2 {
  color: var(--paper); font-size: clamp(1.6rem, 1.3rem + 1.5vw, 2.2rem);
  max-width: 24ch; margin: 0 auto var(--s-4);
}
.members-only h2 em { color: var(--amber-300); }
.members-only p { color: var(--slate-200); max-width: 48ch; margin: 0 auto var(--s-6); font-size: 1.02rem; line-height: 1.55; }
.members-only .actions { display: flex; gap: 12px; justify-content: center; flex-wrap: wrap; }
.article-nav {
  max-width: 1180px; margin: 0 auto;
  padding: var(--s-12) 0 var(--s-8);
  border-top: 1px solid var(--line);
  display: grid; grid-template-columns: 1fr 1fr; gap: var(--s-8);
}
.article-nav a {
  display: block; padding: var(--s-6);
  background: #ffffff;
  border: 1px solid var(--line);
  border-radius: var(--r-lg);
  box-shadow: var(--shadow-sm);
  transition: transform .12s var(--ease), box-shadow .15s var(--ease);
}
.article-nav a:hover { transform: translateY(-2px); box-shadow: var(--shadow-md); }
.article-nav .dir {
  font-size: var(--t-xs); letter-spacing: 0.14em; text-transform: uppercase;
  color: var(--amber-700); font-weight: 700; margin-bottom: var(--s-2);
}
.article-nav .next-link { text-align: right; }
.article-nav .title-preview {
  font-family: var(--font-serif); font-size: var(--t-lg);
  color: var(--slate-900); line-height: 1.3;
}
@media (max-width: 640px) { .article-nav { grid-template-columns: 1fr; } .article-nav .next-link { text-align: left; } }

/* ====================== Lightbox gallery ======================
   Used on /kuvia-lomamajoista/. Progressive enhancement: gallery <a> links open
   the full image directly when JS is off; JS upgrades them to this lightbox. */
.gallery-grid a { cursor: zoom-in; }
.lightbox {
  position: fixed; inset: 0; z-index: 1000;
  display: none; align-items: center; justify-content: center;
  background: rgba(15, 26, 44, .93);
  backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px);
}
.lightbox.open { display: flex; }
.lightbox-stage {
  margin: 0; display: flex; flex-direction: column; align-items: center; gap: var(--s-3);
  max-width: 92vw;
}
.lightbox-img {
  max-width: 92vw; max-height: 84vh; width: auto; height: auto;
  object-fit: contain; border-radius: var(--r-md);
  background: var(--slate-800);
  box-shadow: 0 24px 70px rgba(0, 0, 0, .5);
}
.lightbox-caption { color: var(--slate-200); font-size: var(--t-sm); text-align: center; max-width: 60ch; }
.lightbox-counter {
  position: absolute; top: max(16px, env(safe-area-inset-top)); left: 20px;
  color: var(--slate-200); font-size: var(--t-sm);
  font-variant-numeric: tabular-nums; letter-spacing: .04em;
}
.lightbox-close, .lightbox-prev, .lightbox-next {
  position: absolute;
  background: rgba(255, 255, 255, .10); border: 1px solid rgba(255, 255, 255, .18);
  color: #fff; cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  border-radius: 50%;
  transition: background .15s var(--ease), transform .15s var(--ease);
  -webkit-tap-highlight-color: transparent;
}
.lightbox-close:hover, .lightbox-prev:hover, .lightbox-next:hover { background: rgba(255, 255, 255, .22); }
.lightbox-close:active { transform: scale(.92); }
.lightbox-close { top: max(12px, env(safe-area-inset-top)); right: 16px; width: 44px; height: 44px; font-size: 1.7rem; line-height: 1; }
.lightbox-prev, .lightbox-next { top: 50%; transform: translateY(-50%); width: 52px; height: 52px; font-size: 2rem; line-height: 1; }
.lightbox-prev { left: max(12px, env(safe-area-inset-left)); }
.lightbox-next { right: max(12px, env(safe-area-inset-right)); }
.lightbox-prev:active, .lightbox-next:active { transform: translateY(-50%) scale(.92); }
@media (max-width: 640px) {
  .lightbox-prev, .lightbox-next { width: 42px; height: 42px; font-size: 1.5rem; }
  .lightbox-img { max-height: 76vh; }
}
@media (prefers-reduced-motion: reduce) {
  .lightbox-close, .lightbox-prev, .lightbox-next { transition: none; }
}
