/* Hallmark · macrostructure: Long Document · tone: dignified and reassuring · anchor hue: ink navy
 * audience: families considering grave closure · use: request a no-obligation price estimate
 * theme: studied-DNA (source: user reference image) · enrichment: original generated stills
 * pre-emit critique: P5 H5 E4 S5 R4 V4
 */
@import "./haka-jimai-tokens.css";

.haka-html,
.haka-body {
  overflow-x: clip;
}

.haka-page {
  background: var(--haka-canvas);
  color: var(--haka-ink);
  font-family: var(--haka-font-body);
  font-size: var(--haka-text-base);
  line-height: 1.8;
}

.haka-page *,
.haka-page *::before,
.haka-page *::after { box-sizing: border-box; }

.haka-page img { display: block; max-width: 100%; }

.haka-page a:not(.cta) { color: inherit; }

.haka-page a:focus-visible {
  outline: var(--haka-rule-bold) solid var(--haka-focus);
  outline-offset: var(--haka-space-2xs);
}

.haka-shell {
  width: min(100%, 1024px);
  margin: 0 auto;
  background: var(--haka-paper);
  box-shadow: 0 0 var(--haka-space-lg) var(--haka-shadow-soft);
}

.haka-promote {
  margin: 0;
  padding: var(--haka-space-2xs) var(--haka-space-md);
  background: var(--haka-navy-deep);
  color: var(--haka-paper);
  font-size: var(--haka-text-xs);
  font-weight: 700;
  letter-spacing: 0.06em;
  text-align: center;
}

.hero {
  position: relative;
  min-height: 500px;
  isolation: isolate;
  overflow: hidden;
  border-bottom: var(--haka-rule-bold) solid var(--haka-navy);
}

.hero__image {
  position: absolute;
  inset: 0;
  z-index: -2;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: 66% center;
}

.hero::after {
  position: absolute;
  inset: 0;
  z-index: -1;
  background: linear-gradient(90deg, var(--haka-white-overlay) 0%, var(--haka-white-overlay) 48%, var(--haka-white-faint) 68%, var(--haka-white-clear) 100%);
  content: "";
}

.hero__content {
  width: min(100%, 700px);
  padding: var(--haka-space-2xl) var(--haka-space-xl) var(--haka-space-xl);
}

.hero__eyebrow {
  display: inline-flex;
  align-items: center;
  gap: var(--haka-space-xs);
  margin: 0 0 var(--haka-space-sm);
  color: var(--haka-navy);
  font-size: var(--haka-text-sm);
  font-weight: 800;
}

.hero__eyebrow::before {
  width: var(--haka-space-sm);
  height: var(--haka-space-sm);
  border-radius: var(--haka-radius-pill);
  background: var(--haka-gold-deep);
  content: "";
}

.hero h1,
.section__title,
.idea__quote,
.final-cta__title {
  min-width: 0;
  overflow-wrap: anywhere;
  font-family: var(--haka-font-display);
  font-style: normal;
}

.hero h1 {
  margin: 0;
  color: var(--haka-navy);
  font-size: clamp(var(--haka-text-2xl), 5vw, var(--haka-text-3xl));
  font-weight: 800;
  line-height: 1.35;
  letter-spacing: 0.03em;
}

.hero h1 strong {
  color: var(--haka-red);
  font-size: 1.42em;
  font-weight: 900;
  letter-spacing: 0;
}

.hero__lead {
  margin: var(--haka-space-md) 0 var(--haka-space-lg);
  font-size: var(--haka-text-lg);
  font-weight: 800;
  line-height: 1.65;
}

.cta {
  display: flex;
  width: fit-content;
  min-height: 56px;
  align-items: center;
  justify-content: center;
  padding: var(--haka-space-sm) var(--haka-space-lg);
  border: var(--haka-rule-thin) solid var(--haka-red-deep);
  border-radius: var(--haka-radius-md);
  background: linear-gradient(135deg, var(--haka-red), var(--haka-red-deep));
  box-shadow: 0 var(--haka-space-xs) 0 var(--haka-red-deep), 0 var(--haka-space-sm) var(--haka-space-md) var(--haka-shadow);
  color: var(--haka-paper);
  font-size: var(--haka-text-lg);
  font-weight: 800;
  line-height: 1.3;
  text-align: center;
  text-decoration: none;
  transition: transform var(--haka-dur-standard) var(--haka-ease-out), box-shadow var(--haka-dur-standard) var(--haka-ease-out), filter var(--haka-dur-fast) var(--haka-ease-out);
}

.haka-page .cta { color: var(--haka-paper); }

.cta:hover { filter: brightness(1.08); transform: translateY(-2px); }
.cta:active { box-shadow: 0 var(--haka-space-2xs) 0 var(--haka-red-deep); transform: translateY(var(--haka-space-2xs)); }
.cta[aria-disabled="true"] { cursor: not-allowed; filter: grayscale(1); opacity: 0.55; pointer-events: none; }
.cta::before { width: 0; height: 0; margin-right: var(--haka-space-xs); border-top: var(--haka-space-xs) solid var(--haka-white-clear); border-bottom: var(--haka-space-xs) solid var(--haka-white-clear); border-left: var(--haka-space-sm) solid var(--haka-paper); content: ""; }

.cta--large {
  width: 100%;
  min-height: 68px;
  font-size: var(--haka-text-lg);
  white-space: nowrap;
}

.cta-note {
  display: block;
  margin-top: var(--haka-space-sm);
  color: var(--haka-ink-soft);
  font-size: var(--haka-text-sm);
  font-weight: 700;
}

.trust-row {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  margin-top: var(--haka-space-xl);
  overflow: hidden;
  border: var(--haka-rule-bold) solid var(--haka-navy);
  border-radius: var(--haka-radius-md);
  background: var(--haka-navy);
  color: var(--haka-paper);
}

.trust-row__item {
  display: flex;
  min-height: 62px;
  align-items: center;
  justify-content: center;
  padding: var(--haka-space-xs);
  border-right: var(--haka-rule-thin) solid var(--haka-gold-deep);
  font-size: var(--haka-text-sm);
  font-weight: 800;
  line-height: 1.35;
  text-align: center;
}

.trust-row__item:last-child { border-right: 0; }
.trust-row__item::before { width: var(--haka-space-xs); height: var(--haka-space-xs); margin-right: var(--haka-space-sm); background: var(--haka-gold); content: ""; transform: rotate(45deg); }

.section {
  position: relative;
  padding: var(--haka-space-2xl) var(--haka-space-xl);
  border-bottom: var(--haka-rule-thin) solid var(--haka-rule);
}

.section--pale { background: var(--haka-blue-pale); }

.section__head {
  display: flex;
  align-items: flex-start;
  margin-bottom: var(--haka-space-lg);
}

.section__title {
  margin: 0;
  color: var(--haka-navy);
  font-size: clamp(var(--haka-text-xl), 3.4vw, var(--haka-text-2xl));
  font-weight: 800;
  line-height: 1.5;
  letter-spacing: 0.03em;
}

.section__lead {
  margin: 0 0 var(--haka-space-lg);
  color: var(--haka-ink-soft);
  font-weight: 700;
}

.section p { margin: 0 0 var(--haka-space-md); }
.emphasis { color: var(--haka-red); font-weight: 800; }
.small-source { display: block; color: var(--haka-ink-soft); font-size: var(--haka-text-xs); line-height: 1.6; }

.comfort-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(0, 0.95fr);
  gap: var(--haka-space-xl);
  align-items: center;
}

.comfort-grid__image {
  border: var(--haka-rule-thin) solid var(--haka-rule);
  border-radius: var(--haka-radius-lg);
  box-shadow: 0 var(--haka-space-md) var(--haka-space-xl) var(--haka-shadow-soft);
}

.cost-grid {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: var(--haka-space-xs);
}

.cost-card {
  display: flex;
  min-width: 0;
  flex-direction: column;
  padding: var(--haka-space-md);
  border: var(--haka-rule-thin) solid var(--haka-rule);
  border-radius: var(--haka-radius-md);
  background: var(--haka-paper);
}

.cost-card__num {
  color: var(--haka-blue);
  font-family: var(--haka-font-display);
  font-weight: 800;
}

.cost-card h3 { margin: var(--haka-space-2xs) 0 var(--haka-space-xs); color: var(--haka-navy); font-size: var(--haka-text-base); line-height: 1.5; }
.cost-card p { margin: 0; color: var(--haka-ink-soft); font-size: var(--haka-text-sm); line-height: 1.65; }
.cost-card__price { display: block; margin-bottom: var(--haka-space-xs); color: var(--haka-red); font-weight: 800; }
.cost-card__image { width: 100%; height: 112px; margin-top: auto; object-fit: contain; object-position: center bottom; }

.memorial-table { width: 100%; margin-top: var(--haka-space-sm); border-collapse: collapse; color: var(--haka-ink-soft); font-size: var(--haka-text-sm); }
.memorial-table th, .memorial-table td { padding: var(--haka-space-2xs); border: var(--haka-rule-thin) solid var(--haka-rule); text-align: left; }
.memorial-table th { background: var(--haka-blue-pale); color: var(--haka-navy); }

.alert-box {
  margin-top: var(--haka-space-xl);
  padding: var(--haka-space-md) var(--haka-space-lg);
  border: var(--haka-rule-thin) solid var(--haka-gold-deep);
  border-radius: var(--haka-radius-md);
  background: var(--haka-gold-pale);
  color: var(--haka-ink);
  font-weight: 800;
  line-height: 1.6;
}

.compare {
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(0, 0.95fr);
  gap: var(--haka-space-xl);
  align-items: center;
}

.compare__photo { overflow: hidden; border-radius: var(--haka-radius-lg); box-shadow: 0 var(--haka-space-md) var(--haka-space-xl) var(--haka-shadow); }
.compare__photo img { width: 100%; aspect-ratio: 3 / 2; object-fit: cover; }

.reason-flow { display: flex; flex-wrap: wrap; gap: var(--haka-space-xs); align-items: stretch; margin: var(--haka-space-lg) 0; }
.reason-flow__item { flex: 1 1 120px; padding: var(--haka-space-sm); border: var(--haka-rule-thin) solid var(--haka-rule-strong); border-radius: var(--haka-radius-sm); background: var(--haka-paper); color: var(--haka-navy); font-size: var(--haka-text-sm); font-weight: 800; line-height: 1.45; text-align: center; }
.reason-flow__operator { align-self: center; color: var(--haka-red); font-size: var(--haka-text-lg); font-weight: 900; }

.assurance-layout { display: grid; grid-template-columns: minmax(0, 1fr) minmax(160px, 0.32fr); gap: var(--haka-space-lg); align-items: end; }
.assurance-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: var(--haka-space-md); }
.assurance { padding: var(--haka-space-lg); border: var(--haka-rule-thin) solid var(--haka-rule-strong); border-radius: var(--haka-radius-md); background: var(--haka-paper); }
.assurance__icon { display: block; width: 64px; height: 64px; margin: 0 auto var(--haka-space-md); background-image: url('../haka-jimai/images/assurance-icons.png'); background-repeat: no-repeat; background-size: 300% 300%; }
.assurance__icon--shield { background-position: 0 center; }
.assurance__icon--phone { background-position: 50% center; }
.assurance__icon--support { background-position: 100% center; }
.assurance h3 { margin: 0 0 var(--haka-space-xs); color: var(--haka-navy); font-size: var(--haka-text-lg); line-height: 1.5; }
.assurance p { margin: 0; color: var(--haka-ink-soft); font-size: var(--haka-text-sm); line-height: 1.7; }
.assurance-layout__senior { width: 100%; max-height: 280px; object-fit: contain; object-position: center bottom; }

.idea { padding: var(--haka-space-2xl) var(--haka-space-xl); background: var(--haka-navy-deep); color: var(--haka-paper); }
.idea .section__title { color: var(--haka-gold); }
.idea-grid { display: grid; grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr); gap: var(--haka-space-xl); align-items: center; }
.idea-grid img { width: 100%; border-radius: var(--haka-radius-md); }
.idea__quote { margin: var(--haka-space-md) 0; padding: var(--haka-space-lg); border: var(--haka-rule-thin) solid var(--haka-gold); background: var(--haka-paper); color: var(--haka-ink); font-size: var(--haka-text-xl); font-weight: 800; line-height: 1.6; text-align: center; }
.idea .cta-note { color: var(--haka-paper); }

.steps { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: var(--haka-space-xs); counter-reset: steps; }
.step { position: relative; display: flex; min-height: 290px; flex-direction: column; padding: var(--haka-space-lg) var(--haka-space-sm); border: var(--haka-rule-thin) solid var(--haka-rule-strong); border-radius: var(--haka-radius-md); background: var(--haka-paper); }
.step::before { display: block; margin: calc(var(--haka-space-lg) * -1) calc(var(--haka-space-sm) * -1) var(--haka-space-md); padding: var(--haka-space-xs); border-radius: var(--haka-radius-md) var(--haka-radius-md) 0 0; background: var(--haka-navy); color: var(--haka-paper); content: "STEP " counter(steps); counter-increment: steps; font-size: var(--haka-text-xs); font-weight: 800; letter-spacing: 0.04em; text-align: center; }
.step h3 { margin: 0 0 var(--haka-space-xs); color: var(--haka-navy); font-size: var(--haka-text-base); line-height: 1.5; }
.step p { margin: 0; color: var(--haka-ink-soft); font-size: var(--haka-text-sm); line-height: 1.65; }
.step__image { width: 100%; height: 98px; margin-top: auto; object-fit: contain; object-position: center bottom; }
.steps-note { margin: var(--haka-space-lg) 0 0; color: var(--haka-navy); font-size: var(--haka-text-sm); font-weight: 800; text-align: center; }

.faq-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: var(--haka-space-sm); }
.faq { padding: var(--haka-space-md); border: var(--haka-rule-thin) solid var(--haka-rule); border-radius: var(--haka-radius-md); background: var(--haka-paper); }
.faq h3 { margin: 0 0 var(--haka-space-sm); color: var(--haka-navy); font-size: var(--haka-text-base); line-height: 1.6; }
.faq h3::before { display: inline-grid; width: 1.35em; height: 1.35em; margin-right: var(--haka-space-xs); place-items: center; border-radius: var(--haka-radius-pill); background: var(--haka-navy); color: var(--haka-paper); content: "Q"; font-family: var(--haka-font-body); font-size: var(--haka-text-sm); }
.faq p { margin: 0; color: var(--haka-ink-soft); font-size: var(--haka-text-sm); line-height: 1.7; }

.final-cta { padding: var(--haka-space-lg) var(--haka-space-xl); background: var(--haka-blue-pale); }
.final-cta__title { margin: 0 0 var(--haka-space-2xs); color: var(--haka-navy); font-size: clamp(var(--haka-text-lg), 2.4vw, 1.75rem); font-weight: 800; line-height: 1.35; text-align: center; }
.final-cta__lead { margin: 0 auto var(--haka-space-md); color: var(--haka-ink-soft); font-size: var(--haka-text-sm); font-weight: 700; text-align: center; }
.final-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: var(--haka-space-xl); align-items: center; }
.form-guide { margin: 0; overflow: hidden; border: var(--haka-rule-thin) solid var(--haka-rule-strong); border-radius: var(--haka-radius-md); background: var(--haka-paper); box-shadow: 0 var(--haka-space-md) var(--haka-space-xl) var(--haka-shadow-soft); }
.form-guide__image { width: 100%; aspect-ratio: 3 / 2; object-fit: contain; object-position: center; }
.final-caution { padding: var(--haka-space-lg); border: var(--haka-rule-bold) solid var(--haka-gold-deep); border-radius: var(--haka-radius-md); background: var(--haka-gold-pale); color: var(--haka-ink); font-weight: 800; line-height: 1.65; }
.final-caution strong { color: var(--haka-red); }

.footer { padding: var(--haka-space-xl); background: var(--haka-navy-deep); color: var(--haka-paper); }
.footer p { margin: 0 0 var(--haka-space-sm); font-size: var(--haka-text-xs); line-height: 1.7; }
.footer nav { display: flex; flex-wrap: wrap; gap: var(--haka-space-md); margin-top: var(--haka-space-md); }
.footer a { color: var(--haka-paper); font-size: var(--haka-text-xs); font-weight: 700; }

@media (max-width: 800px) {
  .hero { min-height: 510px; }
  .hero__content { padding: var(--haka-space-xl) var(--haka-space-md) var(--haka-space-lg); }
  .hero::after { background: linear-gradient(180deg, var(--haka-white-overlay) 0%, var(--haka-white-overlay) 50%, var(--haka-white-light) 100%); }
  .hero__image { object-position: 72% center; }
  .section, .idea, .final-cta { padding: var(--haka-space-xl) var(--haka-space-md); }
  .comfort-grid, .compare, .idea-grid, .final-grid, .assurance-layout { grid-template-columns: minmax(0, 1fr); }
  .comfort-grid__image { order: -1; }
  .cost-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .cost-card:last-child { grid-column: 1 / -1; }
  .cost-card__image { height: 148px; }
  .assurance-layout__senior { width: min(100%, 240px); justify-self: center; }
  .steps { grid-template-columns: minmax(0, 1fr); gap: var(--haka-space-sm); }
  .step { padding: var(--haka-space-md); }
  .step::before { margin: calc(var(--haka-space-md) * -1) calc(var(--haka-space-md) * -1) var(--haka-space-sm); }
  .faq-grid { grid-template-columns: minmax(0, 1fr); }
}

@media (max-width: 520px) {
  .hero { min-height: 560px; }
  .hero__lead { font-size: var(--haka-text-base); }
  .cta { width: 100%; padding: var(--haka-space-sm) var(--haka-space-xs); font-size: var(--haka-text-cta-mobile); white-space: nowrap; }
  .cta--large { font-size: var(--haka-text-cta-mobile); }
  .trust-row { grid-template-columns: minmax(0, 1fr); }
  .trust-row__item { min-height: 42px; border-right: 0; border-bottom: var(--haka-rule-thin) solid var(--haka-gold-deep); }
  .trust-row__item:last-child { border-bottom: 0; }
  .cost-grid, .assurance-grid { grid-template-columns: minmax(0, 1fr); }
  .cost-card:last-child { grid-column: auto; }
  .reason-flow { display: grid; grid-template-columns: minmax(0, 1fr); }
  .reason-flow__operator { display: none; }
  .idea__quote { font-size: var(--haka-text-lg); }
}

@media (prefers-reduced-motion: reduce) {
  .cta { transition-duration: 0ms; }
}

