/* Page/family-specific styles. Shared base and components are loaded from sibling CSS files. */
:root {
      --bg: #f8f9fa;
      --card: #ffffff;
      --card-2: #f3f5f7;
      --surface: var(--card);
      --surface-soft: var(--card-2);
      --surface-strong: #ecfdf5;
      --text: #0f172a;
      --muted: #64748b;
      --line: rgba(15, 23, 42, .10);
      --line-2: rgba(15, 23, 42, .16);
      --green: #0f9f76;
      --green-2: #0d8b68;
      --green-dark: var(--green-2);
      --green-soft: rgba(15, 159, 118, .10);
      --blue: #2563eb;
      --blue-soft: rgba(37, 99, 235, .10);
      --warning: #9a6a14;
      --warning-soft: rgba(154, 106, 20, .12);
      --danger: #c94860;
      --danger-soft: rgba(201, 72, 96, .10);
      --shadow: 0 22px 60px -24px rgba(15, 23, 42, .28);
      --shadow-soft: 0 10px 40px -10px rgba(0, 0, 0, .08);
      --shadow-lift: 0 24px 60px -22px rgba(15, 23, 42, .32);
      --glass: rgba(255, 255, 255, .78);
      --glass-strong: rgba(255, 255, 255, .92);
      --overlay: rgba(11, 15, 25, .64);
      --radius: 16px;
      --radius-sm: 12px;
      --max: 1240px;
      --max-wide: 1320px;
      --tool-content-max: 1240px;
      --tool-panel-radius: 16px;
      --tool-card-min-height: 220px;
      --font-body: Inter, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
      --font-numeric: "Space Grotesk", Inter, system-ui, sans-serif;
    }

body.dark {
      --bg: #0b0f19;
      --card: #111827;
      --card-2: #0f172a;
      --surface: var(--card);
      --surface-soft: var(--card-2);
      --surface-strong: #064e3b;
      --text: #e2e8f0;
      --muted: #94a3b8;
      --line: rgba(148, 163, 184, .18);
      --line-2: rgba(148, 163, 184, .26);
      --green: #10b981;
      --green-2: #34d399;
      --green-dark: var(--green);
      --green-soft: rgba(16, 185, 129, .14);
      --blue: #60a5fa;
      --blue-soft: rgba(96, 165, 250, .13);
      --warning: #ffd27a;
      --warning-soft: rgba(255, 210, 122, .12);
      --danger: #ff7d96;
      --danger-soft: rgba(255, 125, 150, .12);
      --shadow: none;
      --shadow-soft: inset 0 1px 0 rgba(255, 255, 255, .04);
      --shadow-lift: inset 0 1px 0 rgba(255, 255, 255, .06), 0 18px 44px -30px rgba(0, 0, 0, .90);
      --glass: rgba(17, 24, 39, .74);
      --glass-strong: rgba(17, 24, 39, .92);
      --overlay: rgba(2, 6, 23, .78);
    }

body {
      font-family: Inter, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
      background:
        radial-gradient(circle at top left, rgba(15, 159, 118, 0.11), transparent 26%),
        radial-gradient(circle at top right, rgba(15, 159, 118, 0.05), transparent 32%),
        var(--bg);
      color: var(--text);
      min-height: 100vh;
      padding: 14px;
      transition: background-color .35s ease, color .35s ease;
    }

button {
      font: inherit;
      cursor: pointer;
      -webkit-tap-highlight-color: transparent;
    }

.nav-link:hover,
    .nav-link.active {
      background: var(--card-2);
      border-color: var(--line);
      color: var(--text);
    }

.hero {
      max-width: 960px;
      margin: 0 auto 24px;
      padding: 30px 10px 22px;
      text-align: center;
    }

.hero h1 {
      margin-bottom: 14px;
      color: var(--text);
      font-size: clamp(2.35rem, 5.6vw, 4.45rem);
      line-height: 1;
      letter-spacing: -3px;
    }

.hero p {
      max-width: 780px;
      margin: 0 auto;
      color: var(--muted);
      font-size: 1.05rem;
      line-height: 1.75;
    }

.article-section,
    .example-section,
    .compare-section,
    .tools-section,
    .faq-section,
    .note-section {
      width: 100%;
      max-width: 1240px;
      margin: 0 auto 16px;
      padding: 24px;
      border: 1px solid var(--line-2);
      border-radius: 30px;
      background: var(--card);
      box-shadow: var(--shadow);
    }

.article-section h2,
    .example-section h2,
    .compare-section h2,
    .tools-section h2,
    .faq-section h2,
    .note-section h2 {
      margin-bottom: 12px;
      color: var(--text);
      font-size: clamp(1.45rem, 2.7vw, 2.15rem);
      letter-spacing: -.8px;
    }

.article-section h3,
    .example-section h3,
    .compare-section h3 {
      margin: 24px 0 10px;
      color: var(--text);
      font-size: 1.22rem;
      letter-spacing: -.35px;
    }

.article-section p,
    .example-section p,
    .compare-section p,
    .tools-section > p,
    .faq-section > p,
    .note-section p {
      color: var(--muted);
      font-size: 1rem;
      line-height: 1.8;
      margin-bottom: 14px;
    }

.article-section p:last-child,
    .example-section p:last-child,
    .compare-section p:last-child,
    .note-section p:last-child {
      margin-bottom: 0;
    }

.article-section > h2,
    .article-section > h3,
    .article-section > p,
    .example-section > h2,
    .example-section > p,
    .note-section > h2,
    .note-section > p {
      max-width: 980px;
    }

.article-section > .formula-box,
    .example-section > .formula-box {
      max-width: 980px;
    }

.formula-box {
      margin: 18px 0;
      padding: 18px;
      border: 1px solid rgba(15, 159, 118, .2);
      border-radius: 20px;
      background: var(--green-soft);
      color: var(--text);
      text-align: center;
    }

.formula-box strong {
      display: block;
      margin-bottom: 8px;
      color: var(--green);
      font-size: .9rem;
      text-transform: uppercase;
      letter-spacing: .12em;
    }

.formula-box span {
      display: block;
      color: var(--text);
      font-size: clamp(1.05rem, 2.4vw, 1.45rem);
      font-weight: 850;
      line-height: 1.5;
    }

.example-grid,
    .compare-grid {
      display: grid;
      grid-template-columns: repeat(3, 1fr);
      gap: 12px;
      margin: 18px 0;
    }

.example-card,
    .compare-card {
      padding: 18px;
      border: 1px solid var(--line);
      border-radius: 20px;
      background: var(--card-2);
    }

.example-card small,
    .compare-card small {
      display: block;
      margin-bottom: 8px;
      color: var(--green);
      font-size: .78rem;
      font-weight: 900;
      letter-spacing: .08em;
      text-transform: uppercase;
    }

.example-card strong,
    .compare-card strong {
      display: block;
      color: var(--text);
      font-size: 1.18rem;
      line-height: 1.35;
    }

.example-card span,
    .compare-card span {
      display: block;
      margin-top: 8px;
      color: var(--muted);
      font-size: .9rem;
      line-height: 1.55;
    }

.step-list {
      display: grid;
      gap: 10px;
      margin-top: 16px;
    }

.step-item {
      display: grid;
      grid-template-columns: 1fr;
      gap: 12px;
      align-items: center;
      padding: 14px;
      border: 1px solid var(--line);
      border-radius: 18px;
      background: var(--card-2);
    }

.step-item .mini-icon {
      display: inline-flex;
      align-items: center;
      justify-content: center;
      width: 38px;
      height: 38px;
      min-width: 38px;
      margin: 0;
      border-radius: 14px;
      line-height: 1;
      text-align: center;
    }

.step-item strong {
      display: block;
      margin-bottom: 4px;
      color: var(--text);
      font-size: .98rem;
    }

.step-item span {
      display: block;
      color: var(--muted);
      font-size: .92rem;
      line-height: 1.6;
    }

.cta-card {
      display: grid;
      grid-template-columns: 1.2fr auto;
      gap: 18px;
      align-items: center;
      margin-top: 20px;
      padding: 20px;
      border: 1px solid rgba(15, 159, 118, .22);
      border-radius: 22px;
      background: linear-gradient(180deg, var(--green-soft), var(--card-2));
    }

.cta-card strong {
      display: block;
      margin-bottom: 6px;
      color: var(--text);
      font-size: 1.12rem;
      letter-spacing: -.35px;
    }

.cta-card p {
      margin-bottom: 0;
      font-size: .95rem;
      line-height: 1.65;
    }

.cta-btn,
    .tool-card a {
      display: inline-flex;
      align-items: center;
      justify-content: center;
      min-height: 46px;
      padding: 11px 18px;
      border-radius: 999px;
      background: var(--green);
      color: white;
      font-weight: 850;
      text-align: center;
      transition: .18s ease;
      white-space: nowrap;
    }

.cta-btn:hover,
    .tool-card a:hover {
      background: var(--green-2);
      transform: translateY(-1px);
    }

.tools-grid {
      display: grid;
      grid-template-columns: repeat(3, 1fr);
      gap: 12px;
      margin-top: 18px;
    }

.tool-card {
      display: flex;
      flex-direction: column;
      justify-content: space-between;
      gap: 18px;
      min-height: 220px;
      padding: 18px;
      border: 1px solid var(--line);
      border-radius: 20px;
      background: var(--card-2);
    }

.mini-icon {
      display: inline-flex;
      align-items: center;
      justify-content: center;
      width: 38px;
      height: 38px;
      min-width: 38px;
      margin-bottom: 12px;
      border-radius: 14px;
      background: var(--green-soft);
      color: var(--green);
      font-size: .82rem;
      font-weight: 900;
    }

.tool-card h3 {
      margin: 0 0 8px;
      color: var(--text);
      font-size: 1.02rem;
      letter-spacing: -.25px;
    }

.tool-card p {
      color: var(--muted);
      font-size: .92rem;
      line-height: 1.65;
    }

.faq-grid {
      display: grid;
      gap: 10px;
      margin-top: 18px;
    }

.faq-item {
      border: 1px solid var(--line);
      border-radius: 18px;
      background: color-mix(in srgb, var(--card) 58%, transparent);
      overflow: hidden;
    }

.faq-item summary {
      list-style: none;
      display: flex;
      align-items: center;
      justify-content: space-between;
      gap: 14px;
      padding: 16px 18px;
      color: var(--text);
      font-size: .98rem;
      font-weight: 850;
      cursor: pointer;
      text-align: left;
    }

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

.faq-item summary::after {
      content: "+";
      display: inline-flex;
      align-items: center;
      justify-content: center;
      width: 26px;
      height: 26px;
      min-width: 26px;
      border-radius: 999px;
      background: var(--green-soft);
      color: var(--green);
      font-size: 1rem;
      font-weight: 900;
    }

.faq-item[open] summary::after {
      content: "−";
    }

.faq-item p {
      padding: 0 18px 16px;
      margin: 0;
      color: var(--muted);
      font-size: .94rem;
      line-height: 1.75;
      text-align: left;
    }

.note-section {
      background:
        linear-gradient(180deg, var(--warning-soft), var(--card));
      border-color: color-mix(in srgb, var(--warning) 26%, var(--line-2));
    }

.note-section strong {
      color: var(--warning);
    }

.mobile-menu-backdrop {
      position: fixed;
      inset: 0;
      z-index: 120;
      display: flex;
      align-items: flex-end;
      justify-content: center;
      padding: 12px;
      background: var(--overlay);
      opacity: 0;
      visibility: hidden;
      transition: .18s ease;
    }

.mobile-menu-backdrop.show {
      opacity: 1;
      visibility: visible;
    }

.mobile-panel {
      width: min(520px, 100%);
      max-height: 88vh;
      overflow: auto;
      padding: 20px;
      border: 1px solid var(--line);
      border-radius: 28px 28px 20px 20px;
      background: var(--card);
      box-shadow: 0 24px 60px rgba(0,0,0,.22);
      transform: translateY(14px);
      transition: .18s ease;
    }

.mobile-menu-backdrop.show .mobile-panel {
      transform: translateY(0);
    }

.mobile-head {
      display: grid;
      grid-template-columns: 1fr auto;
      gap: 14px;
      align-items: start;
      margin-bottom: 16px;
    }

.mobile-head strong {
      display: block;
      margin-bottom: 6px;
      color: var(--text);
      font-size: clamp(1.35rem, 3vw, 2rem);
      letter-spacing: -.8px;
    }

.mobile-head p {
      color: var(--muted);
      font-size: .96rem;
      line-height: 1.65;
    }

.mobile-item {
      width: 100%;
      padding: 15px;
      border: 1px solid var(--line);
      border-radius: 20px;
      background: var(--card-2);
      color: var(--text);
      text-align: left;
      display: grid;
      grid-template-columns: 42px 1fr;
      gap: 12px;
      align-items: center;
      transition: .18s ease;
    }

.mobile-item:hover {
      transform: translateY(-1px);
      border-color: rgba(15, 159, 118, .34);
    }

.mobile-item .mini-icon {
      margin-bottom: 0;
    }

.mobile-item strong {
      display: block;
      margin-bottom: 4px;
      color: var(--text);
      font-size: 1rem;
    }

.mobile-item small {
      display: block;
      color: var(--muted);
      font-size: .9rem;
      line-height: 1.55;
    }

@media (max-width: 980px) {
      .example-grid,
      .compare-grid,
      .tools-grid {
        grid-template-columns: 1fr;
      }

      .tool-card {
        min-height: auto;
      }

      .cta-card {
        grid-template-columns: 1fr;
      }

      .cta-btn {
        width: 100%;
      }
    }

@media (max-width: 760px) {
      body {
        padding: 10px;
      }

      .container,
      main,
      .hero,
      .article-section,
      .example-section,
      .compare-section,
      .tools-section,
      .faq-section,
      .note-section,
      .site-footer {
        width: 100% !important;
        max-width: 100% !important;
        margin-left: auto !important;
        margin-right: auto !important;
      }

      .theme-btn,
      .theme-text {
        display: none !important;
      }

      .mobile-menu-btn span:last-child {
        display: inline !important;
        font-size: .88rem;
        font-weight: 800;
      }

      .hero {
        padding: 20px 4px 16px;
      }

      .hero h1 {
        font-size: 2.32rem !important;
        line-height: 1;
        letter-spacing: -2px;
      }

      .hero p {
        max-width: 100%;
        font-size: .98rem;
        line-height: 1.75;
      }

      .article-section,
      .example-section,
      .compare-section,
      .tools-section,
      .faq-section,
      .note-section,
      .mobile-panel {
        padding: 16px !important;
        border-radius: 22px !important;
      }

      .example-card,
      .compare-card,
      .tool-card {
        padding: 16px;
        border-radius: 18px;
      }

      .footer-actions {
        gap: 14px;
      }
    }

@media (max-width: 420px) {
      .hero h1 {
        font-size: 2.18rem !important;
      }

      .mobile-menu-btn span:last-child {
        display: none !important;
      }
    }

/* InvesteHub real tool screenshots */
    .tool-screenshot-section {
      width: 100%;
      max-width: 1240px;
      margin: 18px auto;
      padding: 24px;
      border: 1px solid var(--line);
      border-radius: 24px;
      background: var(--card);
      box-shadow: var(--shadow-soft);
    }

.tool-screenshot-section h2 {
      margin: 8px 0 10px;
      color: var(--text);
      font-size: clamp(1.45rem, 3vw, 2.15rem);
      line-height: 1.12;
    }

.tool-screenshot-section p {
      max-width: 820px;
      color: var(--muted);
      line-height: 1.75;
    }

.tool-screenshot-frame {
      margin: 18px 0 0;
      padding: 12px;
      border: 1px solid var(--line);
      border-radius: 20px;
      background: color-mix(in srgb, var(--card) 88%, var(--card-2));
    }

.tool-screenshot-frame img {
      display: block;
      width: 100%;
      height: auto;
      border: 1px solid var(--line);
      border-radius: 16px;
      background: var(--card);
    }

.tool-screenshot-frame figcaption {
      margin-top: 10px;
      padding: 11px 13px;
      border: 1px solid rgba(15, 159, 118, .24);
      border-radius: 14px;
      color: var(--muted);
      background: rgba(15, 159, 118, .08);
      font-size: .92rem;
      line-height: 1.55;
    }

.tool-screenshot-frame figcaption strong {
      color: var(--text);
    }

.tool-screenshot-frame figcaption a {
      color: var(--green);
      font-weight: 800;
      text-decoration: none;
    }

@media (max-width: 760px) {
      .tool-screenshot-section {
        padding: 18px;
        border-radius: 20px;
      }

      .tool-screenshot-frame {
        padding: 8px;
        border-radius: 16px;
      }

      .tool-screenshot-frame img {
        border-radius: 12px;
      }
    }

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

.faq-item[open] summary::after {
      content: "-";
    }
