/* Sub-pages: the blue shell over the existing page components.
   Loaded after styles.css (legacy components) and site.css (tokens, header, footer). */

:root {
  --bg: var(--paper);
  --bg-alt: var(--white);
  --surface: var(--white);
  --text: var(--ink);
  --text-secondary: var(--ink-2);
  --text-tertiary: var(--ink-3);
  --border: var(--line);
  --border-solid: var(--line-2);
  --accent: var(--blue);
  --accent-hover: var(--blue-2);
  --accent-shadow: rgba(11, 92, 255, 0.2);
  --radius-lg: 24px;
  --font-sans: var(--font);
}

.page-sub {
  background: var(--paper);
  color: var(--ink);
}

.page-sub main {
  background: var(--paper);
}

/* ---------------------------------------------------------------- hero band: electric blue */

.page-hero {
  position: relative;
  overflow: hidden;
  padding: calc(var(--header-h) + clamp(64px, 10vw, 128px)) var(--gutter) clamp(72px, 10vw, 128px);
  background: var(--blue);
  color: #fff;
  isolation: isolate;
}

/* a lotus watermark, drawn with the brand mark, drifts on the right */
.page-hero::before {
  content: "";
  position: absolute;
  right: -6vw;
  bottom: -8vw;
  z-index: -1;
  width: min(62vw, 820px);
  aspect-ratio: 151 / 82;
  background: url("/assets/images/ranchu-mark.svg") center / contain no-repeat;
  opacity: 0.12;
  filter: grayscale(1) brightness(3);
  animation: hero-drift 18s ease-in-out infinite alternate;
}

.page-hero::after {
  content: "";
  position: absolute;
  inset: auto 0 0;
  z-index: -1;
  height: 40%;
  background: linear-gradient(180deg, transparent, rgba(0, 40, 140, 0.35));
  pointer-events: none;
}

@keyframes hero-drift {
  to {
    transform: translate(-2vw, -1.5vw) rotate(-3deg);
  }
}

.page-hero__inner {
  position: relative;
  max-width: 1040px;
  margin-inline: auto;
}

.page-hero .breadcrumb {
  margin-bottom: 32px;
  font-size: 13px;
  color: var(--peri);
}

.page-hero .breadcrumb a {
  color: #fff;
}

.page-hero .breadcrumb a:hover {
  text-decoration: underline;
  text-underline-offset: 3px;
}

.page-hero .section-label {
  margin-bottom: 16px;
  color: var(--peri);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.16em;
}

.page-hero .section-title {
  max-width: 18em;
  color: #fff;
  font-size: clamp(32px, 5vw, 64px);
  font-weight: 700;
  line-height: 1.18;
  letter-spacing: -0.02em;
}

.page-hero .section-lead {
  max-width: 38em;
  margin-top: 26px;
  color: var(--peri-2);
  font-size: clamp(15px, 1.4vw, 18px);
  line-height: 1.9;
}

.page-hero .hero-actions {
  margin-top: 36px;
}

.page-sub .page-hero .button,
.page-sub .page-hero .button.secondary {
  margin-top: 0;
}

.page-sub .page-hero .button {
  background: #fff;
  color: var(--blue);
  border-color: transparent;
}

.page-sub .page-hero .button:hover {
  background: var(--mist-2);
  color: var(--blue);
}

.page-sub .page-hero .button.secondary {
  background: transparent;
  color: #fff;
  border-color: rgba(255, 255, 255, 0.4);
}

.page-sub .page-hero .button.secondary:hover {
  background: rgba(255, 255, 255, 0.1);
}

.page-hero .ai-badges span {
  border-color: rgba(255, 255, 255, 0.24);
  background: rgba(255, 255, 255, 0.08);
  color: #fff;
}

.page-hero--full {
  min-height: 100svh;
  display: grid;
  align-content: center;
  text-align: center;
}

.page-hero--full .section-title,
.page-hero--full .section-lead {
  margin-inline: auto;
}

.page-hero--full .hero-actions {
  justify-content: center;
}

/* ---------------------------------------------------------------- the existing components, in the new tone */

.page-sub .section {
  padding: clamp(72px, 10vw, 128px) 0;
}

.page-sub .section.alt {
  background: var(--mist);
}

.page-sub .section-title {
  font-weight: 700;
  letter-spacing: -0.015em;
  line-height: 1.25;
}

.page-sub main > .section .section-title {
  color: var(--blue);
}

.page-sub .section-label {
  color: var(--ink-3);
  font-weight: 700;
  letter-spacing: 0.16em;
}

.page-sub .button,
.page-sub button[type="submit"] {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  padding: 12px 26px;
  border-radius: 999px;
  border: 1px solid transparent;
  background: var(--blue);
  color: #fff;
  font-weight: 700;
  box-shadow: none;
}

.page-sub .button:hover,
.page-sub button[type="submit"]:hover {
  background: var(--blue-2);
  color: #fff;
  box-shadow: none;
}

.page-sub .button.secondary,
.page-sub .button.ghost {
  background: var(--white);
  color: var(--blue);
  border-color: var(--line-2);
}

.page-sub .button.secondary:hover,
.page-sub .button.ghost:hover {
  border-color: var(--blue);
  background: var(--white);
  color: var(--blue);
}

.page-sub .card,
.page-sub .metric-card,
.page-sub .pricing-card,
.page-sub .media-card,
.page-sub .before-after-card,
.page-sub .form-wrap {
  border-radius: 24px;
  border: 1px solid var(--line);
  background: var(--white);
  box-shadow: none;
  transition: border-color 0.25s var(--ease), box-shadow 0.25s var(--ease), transform 0.25s var(--ease);
}

.page-sub .section.alt .card,
.page-sub .section.alt .metric-card,
.page-sub .section.alt .media-card {
  border-color: transparent;
}

.page-sub a.card:hover,
.page-sub .media-card:hover {
  border-color: rgba(11, 92, 255, 0.3);
  box-shadow: var(--shadow);
  transform: translateY(-2px);
}

.page-sub .card h3 {
  color: var(--ink);
}

.page-sub .card-link {
  color: var(--blue);
  font-weight: 700;
}

.page-sub .badge {
  border: 0;
  background: var(--mist);
  color: var(--blue);
  font-weight: 700;
}

.page-sub .metric-value {
  color: var(--blue);
}

.page-sub .cta-panel {
  position: relative;
  overflow: hidden;
  padding: clamp(56px, 8vw, 96px) clamp(24px, 5vw, 64px);
  border-radius: 32px;
  background: var(--blue);
  color: #fff;
  isolation: isolate;
}

.page-sub .cta-panel::after {
  content: "";
  position: absolute;
  right: -80px;
  bottom: -60px;
  z-index: -1;
  width: 520px;
  aspect-ratio: 151 / 82;
  background: url("/assets/images/ranchu-mark.svg") center / contain no-repeat;
  opacity: 0.14;
  filter: grayscale(1) brightness(3);
  pointer-events: none;
}

.page-sub .cta-panel .section-title,
.page-sub .cta-panel h2 {
  color: #fff;
}

.page-sub .cta-panel .section-label {
  color: var(--peri);
}

.page-sub .cta-panel p {
  color: var(--peri-2);
}

.page-sub .cta-panel .button {
  background: #fff;
  color: var(--blue);
}

.page-sub .cta-panel .button:hover {
  background: var(--mist-2);
}

.page-sub .cta-panel .button.secondary {
  background: transparent;
  color: #fff;
  border-color: rgba(255, 255, 255, 0.4);
}

.page-sub .cta-panel .button.secondary:hover {
  background: rgba(255, 255, 255, 0.1);
}

.page-sub input,
.page-sub select,
.page-sub textarea {
  border-radius: 14px;
  border-color: var(--line-2);
  background: var(--white);
  font-family: var(--font);
}

.page-sub input:focus,
.page-sub select:focus,
.page-sub textarea:focus {
  outline: none;
  border-color: var(--blue);
  box-shadow: 0 0 0 4px rgba(11, 92, 255, 0.14);
}

.page-sub .info-table th,
.page-sub .info-table td {
  border-color: var(--line);
}

.page-sub .info-table th {
  color: var(--ink-3);
}

.page-sub .timeline li {
  border-color: rgba(11, 92, 255, 0.25);
}

.page-sub .faq details {
  border-color: var(--line-2);
}

.page-sub .faq summary::after {
  color: var(--blue);
}

.page-sub .img-placeholder {
  border: 0;
  background: transparent;
}

/* ---------------------------------------------------------------- larger type and calmer cards, closer to the home page */

.page-sub main > .section .section-title {
  font-size: clamp(28px, 3.6vw, 48px);
  line-height: 1.2;
  letter-spacing: -0.025em;
}

.page-sub main > .section .section-label {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 14px;
  font-size: 12px;
  color: var(--blue);
}

.page-sub main > .section .section-label::before {
  content: "";
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--lotus);
}

.page-sub .section-lead {
  max-width: 40em;
  margin-top: 16px;
  font-size: 16px;
}

.page-sub .section-header {
  margin-bottom: clamp(32px, 4vw, 56px);
}

.page-sub .card {
  padding: clamp(24px, 2.4vw, 32px);
}

.page-sub .card h3 {
  font-size: 18px;
  letter-spacing: -0.01em;
  line-height: 1.45;
}

.page-sub .card p {
  font-size: 14.5px;
  line-height: 1.85;
}

.page-sub .card:hover {
  border-color: rgba(11, 92, 255, 0.24);
  box-shadow: var(--shadow);
}

.page-sub .badge,
.page-sub .badge.blue,
.page-sub .badge.green,
.page-sub .badge.purple {
  border: 0;
  background: var(--mist);
  color: var(--blue);
}

.page-sub .section:not(.alt) .badge {
  background: var(--mist);
}

.page-sub .section.alt .badge {
  background: #fff;
}

.page-sub .card-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  transition: gap 0.25s var(--ease);
}

.page-sub a.card:hover .card-link {
  gap: 10px;
}

.page-sub .metric-card {
  padding: clamp(24px, 2.4vw, 32px);
}

.page-sub .metric-value {
  font-size: clamp(32px, 3.6vw, 48px);
  font-weight: 800;
  letter-spacing: -0.03em;
}

.page-sub .recommended-badge {
  background: var(--blue);
  color: #fff;
}

.page-sub .pricing-card.recommended {
  border-color: var(--blue);
  box-shadow: 0 24px 60px rgba(11, 92, 255, 0.14);
}

.page-sub .price {
  color: var(--blue);
}

.page-sub .check-list li::before {
  color: var(--blue);
}

.page-sub .info-table {
  border-radius: 24px;
  overflow: hidden;
  background: #fff;
}

@media (prefers-reduced-motion: reduce) {
  .page-hero::before {
    animation: none;
  }
}
