* { box-sizing: border-box; }
  html { scroll-behavior: smooth; }
  body {
    margin: 0;
    background: var(--surface-page);
    color: var(--text-primary);
    font-family: var(--font-sans);
    -webkit-font-smoothing: antialiased;
  }
  #root { min-height: 100vh; }

  .wrap { width: 100%; max-width: 1180px; margin: 0 auto; padding: 0 24px; }

  .stencil {
    text-transform: uppercase;
    letter-spacing: var(--tracking-stencil);
    font-weight: var(--weight-bold);
  }
  .label {
    text-transform: uppercase;
    letter-spacing: var(--tracking-wider);
    font-weight: var(--weight-bold);
    font-size: var(--text-2xs);
  }
  .mono { font-family: var(--font-mono); }

  image-slot {
    display: block;
    box-shadow: var(--shadow-sm);
  }

  a.plainlink { color: inherit; text-decoration: none; }
  a.plainlink:hover { color: var(--gp-amber); }

  /* Calculator tool cards — feature tiles that lift on hover. */
  .toolcard {
    transition: transform 0.15s ease, box-shadow 0.15s ease, border-color 0.15s ease;
  }
  a.plainlink:hover .toolcard {
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
    border-color: var(--gp-amber);
  }
  a.plainlink:hover .toolcard .toolcard-go { transform: translateX(3px); }
  .toolcard-go { transition: transform 0.15s ease; }

  /* Newsroom feed — horizontal carousel showing three cards at a time. */
  .news-track { min-width: 0; }
  .news-track > * { min-width: 0; }

  /* Sticky footer on short content pages (e.g. imprint): fill the viewport
     so the footer sits at the bottom. */
  body.sticky-footer { display: flex; flex-direction: column; min-height: 100vh; }
  body.sticky-footer > main { flex: 1 0 auto; }

  /* Spam-safe "Show email / Show phone" reveal buttons. */
  .reveal-btn {
    appearance: none; background: none; border: none; padding: 0; margin: 0;
    cursor: pointer; font: inherit; color: var(--text-link);
    display: inline-flex; align-items: center; gap: 6px;
  }
  .reveal-btn:hover { text-decoration: underline; }

  /* Clickable news cards (posts with an external link). */
  .news-card-link { transition: border-color 0.15s ease, box-shadow 0.15s ease; }
  .news-card-link:hover { border-color: var(--gp-amber); box-shadow: var(--shadow-md); }

  /* Carousel arrow buttons (gallery + news). */
  .slider-btn {
    appearance: none; cursor: pointer; width: 44px; height: 44px;
    border-radius: var(--radius-sm); border: 1px solid var(--border-default);
    background: var(--surface-card); color: var(--text-primary);
    display: inline-flex; align-items: center; justify-content: center;
    box-shadow: var(--shadow-xs);
  }

  /* Fluid display type — scales with the viewport so nothing overflows on
     phones while keeping the full size on desktop (clamp caps at the token). */
  .hero-title { font-size: clamp(2.5rem, 11vw, 5rem) !important; overflow-wrap: break-word; }
  .hero-price { font-size: clamp(2.25rem, 12vw, 3.75rem) !important; }

  /* Grid tracks default to min-width:auto, so a wide child stops `1fr` from
     shrinking and the column overflows on narrow screens. Let them shrink. */
  .hero-grid { min-width: 0; }
  .hero-grid > * { min-width: 0; }
  .facts-grid { min-width: 0; }
  .facts-grid > * { min-width: 0; }

  /* Belt-and-suspenders: never let anything force a horizontal scrollbar.
     `clip` (not `hidden`) so it doesn't break the sticky header. */
  body { overflow-x: clip; }
  img { max-width: 100%; }

  @media (max-width: 900px) {
    .hero-grid { grid-template-columns: 1fr !important; }
    .facts-grid { grid-template-columns: repeat(2, 1fr) !important; }
    .gallery-track { grid-auto-columns: 85% !important; }
    .news-track { grid-auto-columns: 85% !important; }
    .contact-grid { grid-template-columns: 1fr !important; }
    .hero-slot { min-height: 300px !important; }
  }

  /* Boarding-gate style indicator — blinking green LEDs, replaces the sale badge. */
  .boarding-ind {
    display: inline-flex;
    align-items: center;
    gap: 9px;
    font-family: var(--font-mono, monospace);
    font-size: var(--text-xs);
    letter-spacing: 0.16em;
    text-transform: uppercase;
    font-weight: var(--weight-bold);
    color: var(--text-inverse);
  }
  .boarding-ind .dots { display: inline-flex; gap: 6px; }
  .boarding-ind .dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: #35D07F;
    box-shadow: 0 0 7px rgba(53, 208, 127, 0.9);
    animation: boarding-blink 1.35s steps(1, end) infinite;
  }
  /* Second dot runs half a cycle out of phase, so the two alternate. */
  .boarding-ind .dot:nth-child(2) { animation-delay: -0.675s; }
  @keyframes boarding-blink {
    0%, 49%    { opacity: 1; }
    50%, 100%  { opacity: 0.18; }
  }
  @media (prefers-reduced-motion: reduce) {
    .boarding-ind .dot { animation: none; opacity: 1; }
  }

  /* Phones: free up the header row and tighten the logo tracking. */
  @media (max-width: 600px) {
    .topbar-badge { display: none; }
    .topbar-logo { font-size: var(--text-sm) !important; letter-spacing: var(--tracking-wider); }
    /* Shrink the big stat numbers so long values (O-360-A4K, PowerFlow) fit two columns. */
    .stat-value { font-size: 20px !important; }
    /* Comfier touch target for the CHF/EUR/USD segmented toggle. */
    .cur-btn { min-height: 38px; padding: 8px 14px !important; }
  }
