/* MKundali /features/ page.
 *
 * Every colour comes from the shared theme tokens in public.css (var(--pub-*)).
 * No hex, rgb(), hsl() or named colours belong in this file, so all five themes
 * (dark, light, paper, minimalist, minimalist-green) apply automatically.
 * Shared header, footer, buttons and theme switching live in public.css / public.js.
 */

@media (prefers-reduced-motion: no-preference) {
  html:has(body.features-page) {
    scroll-behavior: smooth;
  }
}

body.features-page {
  background: var(--pub-bg);
  color: var(--pub-text);
  font-family: var(--font-body);
}

.ft-main {
  display: block;
}

/* Hero */
.ft-hero {
  background: var(--pub-hero-bg);
  color: var(--pub-hero-text);
  border-bottom: 1px solid var(--pub-border);
}

.ft-hero-inner {
  display: grid;
  gap: 28px;
  align-items: center;
  width: min(100% - 24px, 1280px);
  margin-inline: auto;
  padding: 40px 0 44px;
}

.ft-eyebrow,
.ft-kicker {
  margin: 0 0 8px;
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--pub-gold);
}

.ft-hero-copy h1 {
  font-family: var(--font-display);
  font-size: clamp(1.8rem, 3.4vw, 2.6rem);
  line-height: 1.12;
  font-weight: 600;
  margin: 0 0 14px;
  color: var(--pub-hero-title);
}

.ft-lead {
  font-size: 1.08rem;
  margin: 0 0 12px;
  max-width: 38em;
}

.ft-intro {
  margin: 0 0 22px;
  max-width: 38em;
  color: var(--pub-hero-text);
  opacity: 0.92;
}

.ft-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.ft-actions-center {
  justify-content: center;
}

.ft-hero-media:empty {
  display: none;
}

.ft-hero-media img {
  display: block;
  width: 100%;
  height: auto;
  border-radius: 12px;
  border: 1px solid var(--pub-gold-soft);
  background: var(--pub-card);
  box-shadow: 0 16px 36px var(--pub-border);
}

@media (min-width: 900px) {
  .ft-hero-inner {
    grid-template-columns: minmax(320px, 0.95fr) minmax(0, 1.25fr);
    gap: 40px;
    padding: 56px 0 60px;
  }
  .ft-hero-inner:has(.ft-hero-media:empty) {
    grid-template-columns: minmax(0, 46rem);
  }
}

/* Section navigation (sticky under the shared header) */
.ft-subnav {
  position: sticky;
  top: calc(var(--pub-header-h) + env(safe-area-inset-top, 0px));
  z-index: 150;
  background: var(--pub-bg);
  border-bottom: 1px solid var(--pub-border);
}

.ft-subnav-list {
  display: flex;
  gap: 4px;
  list-style: none;
  margin: 0 auto;
  padding: 0 12px;
  max-width: 1280px;
  overflow-x: auto;
  scrollbar-width: none;
  -webkit-overflow-scrolling: touch;
}

.ft-subnav-list::-webkit-scrollbar {
  display: none;
}

.ft-subnav-list a {
  display: block;
  padding: 12px 12px 10px;
  white-space: nowrap;
  font-size: 0.88rem;
  font-weight: 500;
  color: var(--pub-muted);
  text-decoration: none;
}

.ft-subnav-list a:hover {
  color: var(--pub-text);
}

.ft-subnav-list a[aria-current="true"] {
  color: var(--pub-emerald-dark);
  font-weight: 700;
  text-decoration: underline;
  text-decoration-thickness: 2px;
  text-underline-offset: 5px;
  text-decoration-color: var(--pub-gold);
}

.ft-subnav-list a:focus-visible,
.ft-faq-item summary:focus-visible,
.ft-card a:focus-visible {
  outline: 2px solid var(--pub-gold);
  outline-offset: 2px;
}

/* Sections */
.ft-section {
  padding: 48px 0;
  background: var(--pub-bg);
  scroll-margin-top: calc(var(--pub-header-h) + 52px);
}

.ft-section-alt {
  background: var(--pub-bg-alt);
}

@media (min-width: 900px) {
  .ft-section {
    padding: 68px 0;
  }
}

.ft-head {
  max-width: 46em;
  margin: 0 auto 30px;
  text-align: center;
}

.ft-head h2 {
  font-family: var(--font-display);
  font-size: clamp(1.45rem, 3vw, 2rem);
  font-weight: 600;
  margin: 0 0 10px;
  color: var(--pub-text);
}

.ft-head p {
  margin: 0;
  color: var(--pub-muted);
}

.ft-head .ft-kicker {
  margin-bottom: 6px;
}

.ft-subhead {
  font-family: var(--font-display);
  font-size: 1.2rem;
  font-weight: 600;
  margin: 40px 0 6px;
  color: var(--pub-text);
  padding-bottom: 8px;
  border-bottom: 1px solid var(--pub-border);
}

.ft-subintro {
  margin: 0 0 18px;
  color: var(--pub-muted);
}

/* Cards */
.ft-grid {
  display: grid;
  gap: 18px;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 300px), 1fr));
}

.ft-card {
  background: var(--pub-card);
  border: 1px solid var(--pub-border);
  border-top: 3px solid var(--pub-gold);
  border-radius: 12px;
  padding: 20px 20px 18px;
  min-width: 0;
  transition: box-shadow 0.18s ease, border-color 0.18s ease;
}

.ft-card-wide {
  grid-column: 1 / -1;
}

@media (hover: hover) and (prefers-reduced-motion: no-preference) {
  .ft-card:hover {
    box-shadow: 0 8px 20px var(--pub-gold-soft);
    border-color: var(--pub-gold);
  }
}

.ft-card h3 {
  font-family: var(--font-display);
  font-size: 1.08rem;
  font-weight: 600;
  margin: 0 0 10px;
  color: var(--pub-text);
}

.ft-card p {
  margin: 0 0 10px;
  font-size: 0.94rem;
  line-height: 1.6;
  color: var(--pub-muted);
}

.ft-card p:last-child {
  margin-bottom: 0;
}

.ft-card a {
  color: var(--pub-emerald-dark);
  font-weight: 600;
}

.ft-note {
  padding: 8px 12px;
  border-left: 3px solid var(--pub-gold);
  background: var(--pub-bg-alt);
  border-radius: 0 8px 8px 0;
  font-size: 0.86rem;
}

/* Feature chips */
.ft-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  list-style: none;
  padding: 0;
  margin: 4px 0 12px;
}

.ft-chips li {
  padding: 5px 11px;
  font-size: 0.84rem;
  line-height: 1.35;
  color: var(--pub-emerald-dark);
  background: var(--pub-emerald-soft);
  border: 1px solid var(--pub-border);
  border-radius: 999px;
}

/* Screenshots (rendered only when a real file exists).
   Fill the text wrap; on wide screens break out to the 1200px file width. */
.ft-figure {
  margin: 28px auto 0;
  width: 100%;
  max-width: 100%;
}

@media (min-width: 1232px) {
  .ft-figure {
    width: 1200px;
    max-width: none;
    margin-inline: calc(50% - 600px);
  }
}

.ft-figure img {
  display: block;
  width: 100%;
  height: auto;
  border-radius: 12px;
  border: 1px solid var(--pub-border);
  background: var(--pub-card);
}

.ft-figure figcaption {
  margin-top: 8px;
  text-align: center;
  font-size: 0.85rem;
  color: var(--pub-muted);
}

/* Systems */
.ft-grid-systems {
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 320px), 1fr));
}

/* FAQ */
.ft-faq-wrap {
  max-width: 52rem;
}

.ft-faq {
  display: grid;
  gap: 10px;
}

.ft-faq-item {
  background: var(--pub-card);
  border: 1px solid var(--pub-border);
  border-radius: 10px;
  padding: 0 16px;
}

.ft-faq-item summary {
  cursor: pointer;
  padding: 14px 0;
  font-weight: 600;
  color: var(--pub-text);
  list-style: none;
  display: flex;
  align-items: center;
  gap: 12px;
}

.ft-faq-item summary::-webkit-details-marker {
  display: none;
}

.ft-faq-item summary::before {
  content: "";
  flex: 0 0 auto;
  width: 8px;
  height: 8px;
  border-right: 2px solid var(--pub-gold);
  border-bottom: 2px solid var(--pub-gold);
  transform: rotate(-45deg);
  transition: transform 0.15s ease;
}

.ft-faq-item[open] summary::before {
  transform: rotate(45deg);
}

@media (prefers-reduced-motion: reduce) {
  .ft-faq-item summary::before {
    transition: none;
  }
}

.ft-faq-item[open] {
  border-color: var(--pub-gold);
}

.ft-faq-item p {
  margin: 0 0 14px;
  color: var(--pub-muted);
  line-height: 1.6;
}

.ft-faq-item a {
  color: var(--pub-emerald-dark);
  font-weight: 600;
}

/* Closing CTA */
.ft-cta {
  background: linear-gradient(135deg, var(--pub-emerald-dark), var(--pub-emerald));
  color: var(--pub-on-accent);
  padding: 56px 0;
  text-align: center;
}

.ft-cta-inner h2 {
  font-family: var(--font-display);
  font-size: clamp(1.4rem, 3vw, 1.9rem);
  font-weight: 600;
  margin: 0 0 12px;
  color: var(--pub-on-accent);
}

.ft-cta-inner p {
  max-width: 40em;
  margin: 0 auto 22px;
}

.ft-cta-inner .ft-cta-note {
  margin: 22px auto 0;
  font-size: 0.86rem;
  opacity: 0.92;
}

.ft-cta .pub-btn-outline-light {
  background: transparent;
  color: var(--pub-on-accent);
  border-color: var(--pub-on-accent);
}

.ft-cta .pub-btn-outline-light:hover {
  background: var(--pub-on-accent);
  color: var(--pub-emerald-dark);
}

.ft-cta-inner a:not(.pub-btn) {
  color: var(--pub-on-accent);
  text-decoration: underline;
}
