    :root {
      --bg: #07090e;
      --card-bg: rgba(13, 18, 30, 0.82);
      --card-border: rgba(255, 255, 255, 0.08);
      --text: #f8fafc;
      --text-muted: #94a3b8;
      --text-dim: #475569;
      
      /* Cardinal Colors */
      --north-accent: #10b981;
      --north-glow: rgba(16, 185, 129, 0.35);
      --north-bg: rgba(16, 185, 129, 0.08);
      
      --east-accent: #38bdf8;
      --east-glow: rgba(56, 189, 248, 0.35);
      --east-bg: rgba(56, 189, 248, 0.08);
      
      /* South: Emerald Coast Quartz White Sand */
      --south-sand: #ffffff;
      --south-sand-sub: #f8fafc;
      --south-sand-edge: #edf2f7;
      --south-glow: rgba(255, 255, 255, 0.55);
      --south-emerald-mist: rgba(16, 185, 129, 0.2);
      
      --west-accent: #f59e0b;
      --west-glow: rgba(245, 158, 11, 0.35);
      --west-bg: rgba(245, 158, 11, 0.08);
    }

    * {
      box-sizing: border-box;
      margin: 0;
      padding: 0;
    }

    html, body {
      height: 100%;
    }

    body {
      background-color: var(--bg);
      color: var(--text);
      font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
      min-height: 100vh;
      display: flex;
      align-items: center;
      justify-content: center;
      position: relative;
      overflow-x: hidden;
      background-image: 
        radial-gradient(circle at 50% 50%, rgba(20, 29, 48, 0.5) 0%, transparent 68%),
        linear-gradient(rgba(255, 255, 255, 0.018) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255, 255, 255, 0.018) 1px, transparent 1px);
      background-size: 100% 100%, 40px 40px, 40px 40px;
    }

    /* Ambient cursor glow */
    .ambient-glow {
      position: fixed;
      inset: 0;
      pointer-events: none;
      z-index: 0;
      background: radial-gradient(circle at var(--mouse-x, 50%) var(--mouse-y, 50%), rgba(56, 189, 248, 0.06) 0%, transparent 45%);
      transition: background 0.15s ease-out;
    }

    /* Main Stage */
    main {
      position: relative;
      z-index: 5;
      display: flex;
      align-items: center;
      justify-content: center;
      width: 100%;
      padding: 2rem 1.5rem;
    }

    /* Cardinal Stage Wrapper */
    .cardinal-stage {
      position: relative;
      width: 100%;
      max-width: 900px;
      height: 740px;
      display: flex;
      align-items: center;
      justify-content: center;
    }

    /* Rotated Diamond Guide (Square rotated 45 deg) */
    .diamond-rhombus-guide {
      position: absolute;
      width: 440px;
      height: 440px;
      transform: rotate(45deg);
      border: 1.5px dashed rgba(255, 255, 255, 0.1);
      border-radius: 28px;
      pointer-events: none;
      z-index: 1;
      transition: all 0.5s ease;
    }

    .diamond-rhombus-guide::before {
      content: '';
      position: absolute;
      inset: -20px;
      border: 1px solid rgba(255, 255, 255, 0.035);
      border-radius: 36px;
    }

    /* Axis Crosslines */
    .axis-vertical {
      position: absolute;
      top: 30px;
      bottom: 30px;
      left: 50%;
      width: 1px;
      background: linear-gradient(180deg, transparent, rgba(255, 255, 255, 0.12) 20%, rgba(255, 255, 255, 0.12) 80%, transparent);
      pointer-events: none;
      z-index: 1;
    }

    .axis-horizontal {
      position: absolute;
      left: 30px;
      right: 30px;
      top: 50%;
      height: 1px;
      background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.12) 20%, rgba(255, 255, 255, 0.12) 80%, transparent);
      pointer-events: none;
      z-index: 1;
    }

    /* Center Emblem Hub - Interactive Toggle */
    .center-emblem-wrap {
      position: absolute;
      width: 168px;
      height: 168px;
      z-index: 10;
      pointer-events: auto !important;
      cursor: pointer !important;
      display: flex;
      align-items: center;
      justify-content: center;
      filter: drop-shadow(0 0 35px rgba(0, 0, 0, 0.9)) drop-shadow(0 0 20px rgba(56, 189, 248, 0.18));
      transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1), filter 0.4s ease;
      user-select: none;
      -webkit-user-select: none;
      outline: none;
    }

    .center-emblem-wrap:hover {
      transform: scale(1.08);
      filter: drop-shadow(0 0 45px rgba(0, 0, 0, 0.95)) drop-shadow(0 0 30px rgba(56, 189, 248, 0.45));
    }

    .center-emblem-wrap:active {
      transform: scale(0.96);
    }

    .center-emblem-wrap:focus-visible {
      filter: drop-shadow(0 0 45px rgba(56, 189, 248, 0.7));
    }

    .cardinal-stage.is-expanded .center-emblem-wrap {
      filter: drop-shadow(0 0 50px rgba(0, 0, 0, 0.95)) drop-shadow(0 0 35px rgba(56, 189, 248, 0.55));
    }

    .center-emblem-wrap::before {
      content: '';
      position: absolute;
      width: 160px;
      height: 160px;
      border-radius: 50%;
      background: radial-gradient(circle, rgba(56, 189, 248, 0.15) 0%, transparent 70%);
      z-index: -1;
      transition: transform 0.4s ease, opacity 0.4s ease;
    }

    .cardinal-stage.is-expanded .center-emblem-wrap::before {
      transform: scale(1.2);
      opacity: 0.9;
    }

    .center-emblem-img {
      width: 100%;
      height: 100%;
      object-fit: contain;
      display: block;
    }

    /* Cardinal Tiles */
    .cardinal-tile {
      position: absolute;
      width: 210px;
      min-height: 130px;
      border-radius: 18px;
      padding: 1.1rem 1.25rem 1.25rem;
      text-decoration: none;
      color: inherit;
      backdrop-filter: blur(20px);
      transition: all 0.35s cubic-bezier(0.16, 1, 0.3, 1);
      display: flex;
      flex-direction: column;
      justify-content: space-between;
      z-index: 3;
      box-shadow: 0 10px 30px rgba(0, 0, 0, 0.55);
    }

    .cardinal-tile:hover {
      z-index: 8;
    }

    /* NORTH TILE (Top / 12 O'Clock) - Green Accent */
    .tile-north {
      top: 15px;
      left: 50%;
      transform: translateX(-50%);
      background: linear-gradient(145deg, var(--north-bg) 0%, var(--card-bg) 65%);
      border: 1.5px solid rgba(16, 185, 129, 0.35);
      box-shadow: 0 10px 30px rgba(0, 0, 0, 0.55), 0 0 20px rgba(16, 185, 129, 0.12);
    }
    .tile-north:hover {
      transform: translateX(-50%) scale(1.05);
      border-color: rgba(16, 185, 129, 0.7);
      box-shadow: 0 18px 45px -8px var(--north-glow), 0 0 30px rgba(16, 185, 129, 0.25);
    }

    /* EAST TILE (Right / 3 O'Clock) - Blue Accent */
    .tile-east {
      right: 25px;
      top: 50%;
      transform: translateY(-50%);
      background: linear-gradient(145deg, var(--east-bg) 0%, var(--card-bg) 65%);
      border: 1.5px solid rgba(56, 189, 248, 0.35);
      box-shadow: 0 10px 30px rgba(0, 0, 0, 0.55), 0 0 20px rgba(56, 189, 248, 0.12);
    }
    .tile-east:hover {
      transform: translateY(-50%) scale(1.05);
      border-color: rgba(56, 189, 248, 0.7);
      box-shadow: 0 18px 45px -8px var(--east-glow), 0 0 30px rgba(56, 189, 248, 0.25);
    }

    /* SOUTH TILE (Bottom / 6 O'Clock) - Brilliant Emerald Coast White Quartz Sand */
    .tile-south {
      bottom: 15px;
      left: 50%;
      transform: translateX(-50%);
      background: linear-gradient(145deg, var(--south-sand) 0%, var(--south-sand-sub) 45%, var(--south-sand-edge) 100%);
      border: 1.5px solid rgba(255, 255, 255, 0.95);
      box-shadow: 
        0 0 38px rgba(255, 255, 255, 0.45),
        0 0 18px var(--south-emerald-mist),
        0 14px 35px rgba(0, 0, 0, 0.6);
    }
    .tile-south:hover {
      transform: translateX(-50%) scale(1.05);
      border-color: #ffffff;
      box-shadow: 
        0 0 60px rgba(255, 255, 255, 0.7),
        0 0 25px rgba(16, 185, 129, 0.28),
        0 20px 45px rgba(0, 0, 0, 0.7);
    }

    /* WEST TILE (Left / 9 O'Clock) - Amber Accent */
    .tile-west {
      left: 25px;
      top: 50%;
      transform: translateY(-50%);
      background: linear-gradient(145deg, var(--west-bg) 0%, var(--card-bg) 65%);
      border: 1.5px solid rgba(245, 158, 11, 0.35);
      box-shadow: 0 10px 30px rgba(0, 0, 0, 0.55), 0 0 20px rgba(245, 158, 11, 0.12);
    }
    .tile-west:hover {
      transform: translateY(-50%) scale(1.05);
      border-color: rgba(245, 158, 11, 0.7);
      box-shadow: 0 18px 45px -8px var(--west-glow), 0 0 30px rgba(245, 158, 11, 0.25);
    }

    /* Dynamic Active Station Glowing Border */
    .cardinal-tile.is-active-station {
      border-width: 1.5px;
    }
    .tile-north.is-active-station {
      border-color: rgba(16, 185, 129, 0.75);
      box-shadow: 0 0 35px rgba(16, 185, 129, 0.28), 0 10px 30px rgba(0, 0, 0, 0.6);
    }
    .tile-south.is-active-station {
      border-color: #ffffff;
      box-shadow: 
        0 0 55px rgba(255, 255, 255, 0.65),
        0 0 25px var(--south-emerald-mist),
        0 14px 40px rgba(0, 0, 0, 0.65);
    }
    .tile-east.is-active-station {
      border-color: rgba(56, 189, 248, 0.75);
      box-shadow: 0 0 35px rgba(56, 189, 248, 0.28), 0 10px 30px rgba(0, 0, 0, 0.6);
    }
    .tile-west.is-active-station {
      border-color: rgba(245, 158, 11, 0.75);
      box-shadow: 0 0 35px rgba(245, 158, 11, 0.28), 0 10px 30px rgba(0, 0, 0, 0.6);
    }

    /* Top Row (Active pill + Arrow) */
    .tile-top-row {
      display: flex;
      justify-content: space-between;
      align-items: center;
      min-height: 24px;
    }

    .tile-spacer {
      flex: 1;
    }

    /* Active Beacon Pill */
    .active-beacon {
      display: none;
      align-items: center;
      gap: 5px;
      padding: 0.2rem 0.55rem;
      border-radius: 10px;
      font-size: 0.65rem;
      font-family: 'JetBrains Mono', monospace;
      font-weight: 600;
      letter-spacing: 0.04em;
    }

    .cardinal-tile.is-active-station .active-beacon {
      display: inline-flex;
    }

    .tile-north.is-active-station .active-beacon {
      background: rgba(16, 185, 129, 0.18);
      color: #34d399;
      border: 1px solid rgba(16, 185, 129, 0.45);
    }

    /* South Active Beacon: Emerald Waters on White Sand */
    .tile-south.is-active-station .active-beacon {
      background: rgba(16, 185, 129, 0.14);
      color: #047857;
      border: 1px solid rgba(16, 185, 129, 0.38);
    }

    .tile-east.is-active-station .active-beacon {
      background: rgba(56, 189, 248, 0.18);
      color: #38bdf8;
      border: 1px solid rgba(56, 189, 248, 0.45);
    }

    .tile-west.is-active-station .active-beacon {
      background: rgba(245, 158, 11, 0.18);
      color: #fbbf24;
      border: 1px solid rgba(245, 158, 11, 0.45);
    }

    .pulse-dot {
      width: 6px;
      height: 6px;
      border-radius: 50%;
      background: currentColor;
      box-shadow: 0 0 8px currentColor;
      animation: pulse 2s infinite ease-in-out;
    }

    @keyframes pulse {
      0%, 100% { transform: scale(1); opacity: 1; }
      50% { transform: scale(1.4); opacity: 0.6; }
    }

    .tile-arrow {
      width: 16px;
      height: 16px;
      color: var(--text-dim);
      transition: all 0.25s ease;
      margin-left: auto;
    }

    .cardinal-tile:hover .tile-arrow {
      color: #ffffff;
      transform: translate(2px, -2px);
    }

    .tile-south .tile-arrow {
      color: #64748b;
    }
    .tile-south:hover .tile-arrow {
      color: #0b1120;
    }

    /* Center Content (Hero Letter + Sublabel) */
    .tile-center-content {
      display: flex;
      flex-direction: column;
      align-items: center;
      justify-content: center;
      padding: 0.6rem 0 0.2rem;
    }

    .node-letter {
      font-size: 2.75rem;
      font-weight: 800;
      font-family: 'JetBrains Mono', monospace;
      letter-spacing: -0.02em;
      line-height: 1;
      text-align: center;
      transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1);
    }

    .tile-north .node-letter {
      color: var(--north-accent);
      text-shadow: 0 0 25px rgba(16, 185, 129, 0.45);
    }
    .tile-east .node-letter {
      color: var(--east-accent);
      text-shadow: 0 0 25px rgba(56, 189, 248, 0.45);
    }

    /* South Letter: Deep Oceanic Obsidian on Brilliant White Sand */
    .tile-south .node-letter {
      color: #0b1120;
      text-shadow: 0 0 20px rgba(11, 17, 32, 0.12);
    }

    .tile-west .node-letter {
      color: var(--west-accent);
      text-shadow: 0 0 25px rgba(245, 158, 11, 0.45);
    }

    .cardinal-tile:hover .node-letter {
      transform: scale(1.15);
    }

    .node-sublabel {
      font-size: 0.76rem;
      font-family: 'JetBrains Mono', monospace;
      font-weight: 600;
      color: var(--text-muted);
      text-align: center;
      margin-top: 0.5rem;
      letter-spacing: 0.05em;
      min-height: 1.1rem;
      transition: color 0.25s ease;
    }

    .cardinal-tile:hover .node-sublabel {
      color: #ffffff;
    }

    .tile-south .node-sublabel {
      color: #475569;
    }
    .tile-south:hover .node-sublabel {
      color: #0b1120;
    }

    /* ==========================================================================
       Secondary Intercardinal Tiles (NW, NE, SE, SW)
       Revealed when the center emblem is pressed
       ========================================================================== */
    .cardinal-tile.tile-secondary {
      position: absolute;
      width: 210px;
      min-height: 130px;
      opacity: 0;
      pointer-events: none;
      visibility: hidden;
      transition: opacity 0.35s cubic-bezier(0.16, 1, 0.3, 1),
                  transform 0.4s cubic-bezier(0.16, 1, 0.3, 1),
                  visibility 0.35s ease,
                  box-shadow 0.3s ease,
                  border-color 0.3s ease;
      z-index: 4;
    }

    /* Intercardinal Staged Positioning */
    .tile-nw {
      top: 70px;
      left: 60px;
      transform: translate(35px, 35px) scale(0.65);
    }

    .tile-ne {
      top: 70px;
      right: 60px;
      transform: translate(-35px, 35px) scale(0.65);
    }

    .tile-se {
      bottom: 70px;
      right: 60px;
      transform: translate(-35px, -35px) scale(0.65);
    }

    .tile-sw {
      bottom: 70px;
      left: 60px;
      transform: translate(35px, -35px) scale(0.65);
    }

    /* When Expanded */
    .cardinal-stage.is-expanded .cardinal-tile.tile-secondary {
      opacity: 1;
      pointer-events: auto;
      visibility: visible;
      transform: translate(0, 0) scale(1);
    }

    .cardinal-stage.is-expanded .cardinal-tile.tile-secondary:hover {
      transform: translate(0, 0) scale(1.05);
      z-index: 9;
    }

    /* Secondary Tile Always Displays Beacon Pill */
    .tile-secondary .active-beacon {
      display: inline-flex;
    }

    /* NORTHWEST TILE: Apps Catalog (Indigo Accent) */
    .tile-nw {
      background: linear-gradient(145deg, rgba(129, 140, 248, 0.1) 0%, var(--card-bg) 65%);
      border: 1.5px solid rgba(129, 140, 248, 0.35);
      box-shadow: 0 10px 30px rgba(0, 0, 0, 0.55), 0 0 20px rgba(129, 140, 248, 0.12);
    }
    .tile-nw:hover {
      border-color: rgba(129, 140, 248, 0.7);
      box-shadow: 0 18px 45px -8px rgba(129, 140, 248, 0.35), 0 0 30px rgba(129, 140, 248, 0.25);
    }
    .tile-nw .node-letter {
      color: #a5b4fc;
      font-size: 1.85rem;
      letter-spacing: -0.01em;
      text-shadow: 0 0 25px rgba(129, 140, 248, 0.45);
    }
    .tile-nw .active-beacon {
      background: rgba(129, 140, 248, 0.18);
      color: #a5b4fc;
      border: 1px solid rgba(129, 140, 248, 0.45);
    }
    .tile-nw .pulse-dot {
      background: #a5b4fc;
      box-shadow: 0 0 8px #a5b4fc;
    }

    /* NORTHEAST TILE: Internal Portal (Locked / Authorized) */
    .tile-ne {
      background: linear-gradient(145deg, rgba(255, 255, 255, 0.03) 0%, var(--card-bg) 65%);
      border: 1.5px dashed rgba(255, 255, 255, 0.15);
      box-shadow: 0 10px 30px rgba(0, 0, 0, 0.55);
    }
    .tile-ne.tile-locked {
      cursor: default;
    }
    .tile-ne .node-letter {
      color: var(--text-muted);
      font-size: 1.35rem;
      font-weight: 700;
      letter-spacing: -0.01em;
    }
    .tile-ne .tile-arrow {
      opacity: 0.3;
    }
    .tile-ne:hover:not(.tile-locked) .tile-arrow {
      opacity: 1;
    }
    .tile-ne .beacon-locked {
      background: rgba(255, 255, 255, 0.05);
      color: var(--text-muted);
      border: 1px solid rgba(255, 255, 255, 0.12);
    }

    /* Upgraded Authorized Portal State */
    .tile-ne.tile-portal-active {
      background: linear-gradient(145deg, rgba(56, 189, 248, 0.1) 0%, var(--card-bg) 65%);
      border: 1.5px solid rgba(56, 189, 248, 0.45);
      box-shadow: 0 10px 30px rgba(0, 0, 0, 0.55), 0 0 20px rgba(56, 189, 248, 0.15);
      cursor: pointer;
    }
    .tile-ne.tile-portal-active:hover {
      border-color: rgba(56, 189, 248, 0.75);
      box-shadow: 0 18px 45px -8px rgba(56, 189, 248, 0.4), 0 0 30px rgba(56, 189, 248, 0.25);
    }
    .tile-ne.tile-portal-active .node-letter {
      color: #38bdf8;
      font-size: 1.85rem;
      text-shadow: 0 0 25px rgba(56, 189, 248, 0.45);
    }
    .tile-ne.tile-portal-active .active-beacon {
      background: rgba(56, 189, 248, 0.18);
      color: #38bdf8;
      border: 1px solid rgba(56, 189, 248, 0.45);
    }
    .tile-ne.tile-portal-active .pulse-dot {
      background: #38bdf8;
      box-shadow: 0 0 8px #38bdf8;
    }

    /* SOUTHEAST TILE: Properties Subpage (Amber Accent) */
    .tile-se {
      background: linear-gradient(145deg, rgba(245, 158, 11, 0.08) 0%, var(--card-bg) 65%);
      border: 1.5px solid rgba(245, 158, 11, 0.35);
      box-shadow: 0 10px 30px rgba(0, 0, 0, 0.55), 0 0 20px rgba(245, 158, 11, 0.12);
    }
    .tile-se:hover {
      border-color: rgba(245, 158, 11, 0.7);
      box-shadow: 0 18px 45px -8px rgba(245, 158, 11, 0.35), 0 0 30px rgba(245, 158, 11, 0.25);
    }
    .tile-se .node-letter {
      color: #fbbf24;
      font-size: 1.45rem;
      letter-spacing: -0.01em;
      text-shadow: 0 0 25px rgba(245, 158, 11, 0.35);
    }
    .tile-se .active-beacon {
      background: rgba(245, 158, 11, 0.15);
      color: #fbbf24;
      border: 1px solid rgba(245, 158, 11, 0.35);
    }
    .tile-se .pulse-dot {
      background: #fbbf24;
      box-shadow: 0 0 8px #fbbf24;
    }

    /* SOUTHWEST TILE: News (Rose Accent) */
    .tile-sw {
      background: linear-gradient(145deg, rgba(244, 63, 94, 0.1) 0%, var(--card-bg) 65%);
      border: 1.5px solid rgba(244, 63, 94, 0.35);
      box-shadow: 0 10px 30px rgba(0, 0, 0, 0.55), 0 0 20px rgba(244, 63, 94, 0.12);
      cursor: pointer;
    }
    .tile-sw:hover {
      border-color: rgba(244, 63, 94, 0.7);
      box-shadow: 0 18px 45px -8px rgba(244, 63, 94, 0.35), 0 0 30px rgba(244, 63, 94, 0.25);
    }
    .tile-sw .node-letter {
      color: #fda4af;
      font-size: 1.85rem;
      letter-spacing: -0.01em;
      text-shadow: 0 0 25px rgba(244, 63, 94, 0.45);
    }
    .tile-sw .active-beacon {
      background: rgba(244, 63, 94, 0.18);
      color: #fda4af;
      border: 1px solid rgba(244, 63, 94, 0.45);
    }
    .tile-sw .pulse-dot {
      background: #fda4af;
      box-shadow: 0 0 8px #fda4af;
    }
    .tile-sw .tile-arrow {
      opacity: 1;
    }

    /* Shared Secondary Muted/Locked Pulse Dot */
    .pulse-dot-locked {
      width: 6px;
      height: 6px;
      border-radius: 50%;
      background: var(--text-muted);
      box-shadow: 0 0 6px rgba(255, 255, 255, 0.25);
    }

    /* Responsive Stacking */
    @media (max-width: 860px) {
      .cardinal-stage {
        height: auto;
        display: flex;
        flex-direction: column;
        gap: 1.25rem;
        padding: 2rem 0;
      }
      .diamond-rhombus-guide,
      .axis-vertical,
      .axis-horizontal {
        display: none;
      }
      .center-emblem-wrap {
        position: static;
        width: 130px;
        height: 130px;
        margin-bottom: 0.5rem;
        pointer-events: auto !important;
        cursor: pointer !important;
        order: 0;
      }
      .cardinal-tile {
        position: static;
        width: 100%;
        max-width: 320px;
        transform: none !important;
      }
      .tile-north { order: 1; }
      .tile-east { order: 2; }
      .tile-south { order: 3; }
      .tile-west { order: 4; }
      .tile-nw { order: 5; }
      .tile-ne { order: 6; }
      .tile-se { order: 7; }
      .tile-sw { order: 8; }

      .cardinal-tile.tile-secondary {
        display: none;
      }
      .cardinal-stage.is-expanded .cardinal-tile.tile-secondary {
        display: flex;
        opacity: 1;
        visibility: visible;
        transform: none !important;
      }
      .cardinal-stage.is-expanded .cardinal-tile.tile-secondary:hover {
        transform: none !important;
      }
    }

/* ==========================================================================
   Park Four Shared Subpage & Content Extensions
   ========================================================================== */

/* Subpage Top Navigation Bar */
.subpage-nav {
  position: sticky;
  top: 0;
  width: 100%;
  max-width: 900px;
  margin: 0 auto;
  padding: 1.25rem 1.5rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  z-index: 50;
  backdrop-filter: blur(12px);
  background: rgba(7, 9, 14, 0.75);
  border-bottom: 1px solid var(--card-border);
}

.subpage-brand {
  display: inline-flex;
  align-items: center;
  gap: 0.75rem;
  text-decoration: none;
  color: var(--text);
  font-family: 'JetBrains Mono', monospace;
  font-weight: 700;
  font-size: 1rem;
  transition: opacity 0.2s ease;
}

.subpage-brand:hover {
  opacity: 0.85;
}

.subpage-brand img {
  width: 28px;
  height: 28px;
  object-fit: contain;
  filter: drop-shadow(0 0 10px rgba(56, 189, 248, 0.3));
}

.subpage-nav-links {
  display: flex;
  align-items: center;
  gap: 1.25rem;
}

.subpage-link {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.825rem;
  font-family: 'JetBrains Mono', monospace;
  color: var(--text-muted);
  text-decoration: none;
  transition: color 0.2s ease;
}

.subpage-link:hover {
  color: var(--east-accent);
}

/* Page Layout Shell */
.page-shell {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  width: 100%;
  position: relative;
  z-index: 5;
}

.page-content-wrapper {
  display: flex !important;
  flex-direction: column !important;
  align-items: stretch !important;
  justify-content: flex-start !important;
  flex: 1;
  width: 100%;
  max-width: 960px;
  margin: 0 auto;
  padding: 2.5rem 1.5rem 5rem;
}

.page-header {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  margin-bottom: 2.5rem;
  width: 100%;
}

/* Page Hero / Section Header */
.section-kicker {
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.75rem;
  font-weight: 700;
  color: var(--east-accent);
  text-transform: uppercase;
  letter-spacing: 0.12em;
  margin-bottom: 0.6rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.section-kicker::before {
  content: '';
  display: inline-block;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--east-accent);
  box-shadow: 0 0 8px var(--east-accent);
}

.page-title {
  font-size: 2.25rem;
  font-weight: 800;
  letter-spacing: -0.025em;
  color: #ffffff;
  margin-bottom: 0.75rem;
}

.page-subtitle {
  color: var(--text-muted);
  font-size: 1.05rem;
  line-height: 1.6;
  max-width: 640px;
  margin-bottom: 2.5rem;
}

/* Apps Grid & Tiles */
.apps-grid {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
  width: 100%;
}

.app-tile {
  background: var(--card-bg);
  border: 1px solid var(--card-border);
  border-radius: 18px;
  padding: 1.75rem 2rem;
  text-decoration: none;
  color: inherit;
  display: flex;
  flex-direction: column;
  gap: 1rem;
  transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
  position: relative;
  overflow: hidden;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.4);
}

.app-tile::before {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at 100% 0%, var(--east-bg) 0%, transparent 50%);
  opacity: 0;
  transition: opacity 0.3s ease;
  pointer-events: none;
}

.app-tile:hover {
  transform: translateY(-3px);
  border-color: rgba(56, 189, 248, 0.4);
  box-shadow: 0 0 35px rgba(56, 189, 248, 0.15), 0 16px 40px rgba(0, 0, 0, 0.6);
}

.app-tile:hover::before {
  opacity: 1;
}

.app-tile-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
}

.app-badge-active {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 0.25rem 0.65rem;
  border-radius: 10px;
  font-size: 0.7rem;
  font-family: 'JetBrains Mono', monospace;
  font-weight: 600;
  letter-spacing: 0.04em;
  background: rgba(16, 185, 129, 0.15);
  color: #34d399;
  border: 1px solid rgba(16, 185, 129, 0.4);
}

.app-tile-arrow {
  width: 18px;
  height: 18px;
  color: var(--text-dim);
  transition: all 0.25s ease;
}

.app-tile:hover .app-tile-arrow {
  color: var(--east-accent);
  transform: translate(3px, -3px);
}

.app-tile-content {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  flex: 1;
}

.app-tile-title {
  font-family: 'JetBrains Mono', monospace;
  font-size: 1.5rem;
  font-weight: 700;
  color: #ffffff;
  letter-spacing: -0.01em;
}

.app-tile-desc {
  font-size: 0.95rem;
  color: var(--text-muted);
  line-height: 1.6;
}

.app-tile-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
  margin-top: auto;
  padding-top: 0.75rem;
}

.app-tag {
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.72rem;
  color: var(--text-dim);
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.06);
  padding: 0.2rem 0.5rem;
  border-radius: 6px;
}

.app-tile:hover .app-tag {
  color: #94a3b8;
  border-color: rgba(255, 255, 255, 0.1);
}

/* Coming Soon Tile */
.app-tile-coming-soon {
  background: rgba(13, 18, 30, 0.45);
  border: 1.5px dashed rgba(255, 255, 255, 0.12);
  border-radius: 18px;
  padding: 1.75rem;
  display: flex;
  flex-direction: column;
  gap: 1rem;
  height: 100%;
  cursor: default;
  transition: border-color 0.3s ease;
}

.app-tile-coming-soon:hover {
  border-color: rgba(255, 255, 255, 0.22);
}

.app-badge-muted {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 0.25rem 0.65rem;
  border-radius: 10px;
  font-size: 0.7rem;
  font-family: 'JetBrains Mono', monospace;
  font-weight: 600;
  background: rgba(255, 255, 255, 0.05);
  color: var(--text-dim);
  border: 1px solid rgba(255, 255, 255, 0.08);
}

.pulse-dot-muted {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #64748b;
  opacity: 0.8;
}

.coming-soon-title {
  font-family: 'JetBrains Mono', monospace;
  font-size: 1.3rem;
  font-weight: 700;
  color: var(--text-muted);
}

.coming-soon-desc {
  font-size: 0.925rem;
  color: var(--text-dim);
  line-height: 1.6;
}

/* ==========================================================================
   Documentation & Markdown Content View (/apps/evcompanion/index.html)
   ========================================================================== */
.doc-article {
  background: var(--card-bg);
  border: 1px solid var(--card-border);
  border-radius: 20px;
  padding: 3rem 3.5rem;
  box-shadow: 0 16px 45px rgba(0, 0, 0, 0.5);
  position: relative;
  backdrop-filter: blur(12px);
}

@media (max-width: 768px) {
  .doc-article {
    padding: 2rem 1.5rem;
  }
}

.doc-article h1 {
  font-family: 'JetBrains Mono', monospace;
  font-size: 2.25rem;
  font-weight: 800;
  color: #ffffff;
  letter-spacing: -0.02em;
  margin-bottom: 1.25rem;
  padding-bottom: 1rem;
  border-bottom: 1px solid var(--card-border);
}

.doc-article h2 {
  font-family: 'Inter', sans-serif;
  font-size: 1.55rem;
  font-weight: 700;
  color: #ffffff;
  letter-spacing: -0.015em;
  margin-top: 3rem;
  margin-bottom: 1rem;
  padding-bottom: 0.5rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

.doc-article h3 {
  font-family: 'Inter', sans-serif;
  font-size: 1.2rem;
  font-weight: 600;
  color: var(--east-accent);
  margin-top: 2rem;
  margin-bottom: 0.75rem;
}

.doc-article p {
  font-size: 0.98rem;
  line-height: 1.75;
  color: #cbd5e1;
  margin-bottom: 1.25rem;
}

.doc-article ul, .doc-article ol {
  margin-bottom: 1.35rem;
  padding-left: 1.6rem;
}

.doc-article li {
  font-size: 0.98rem;
  line-height: 1.75;
  color: #cbd5e1;
  margin-bottom: 0.45rem;
}

.doc-article strong {
  color: #ffffff;
  font-weight: 600;
}

.doc-article a {
  color: var(--east-accent);
  text-decoration: none;
  border-bottom: 1px dotted rgba(56, 189, 248, 0.4);
  transition: all 0.2s ease;
}

.doc-article a:hover {
  color: #ffffff;
  border-bottom-style: solid;
}

.doc-article code {
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.88em;
  background: rgba(255, 255, 255, 0.07);
  border: 1px solid rgba(255, 255, 255, 0.08);
  padding: 0.2em 0.4em;
  border-radius: 5px;
  color: #e2e8f0;
}

.doc-article pre {
  background: #04060a;
  border: 1px solid var(--card-border);
  border-radius: 12px;
  padding: 1.25rem 1.5rem;
  overflow-x: auto;
  margin: 1.25rem 0 1.5rem;
}

.doc-article pre code {
  background: none;
  border: none;
  padding: 0;
  color: #38bdf8;
  font-size: 0.88rem;
  line-height: 1.55;
}

.doc-article img {
  max-width: 100%;
  height: auto;
  border-radius: 12px;
  border: 1px solid var(--card-border);
  box-shadow: 0 12px 35px rgba(0, 0, 0, 0.55);
  display: block;
  margin: 1rem 0;
}

.doc-article table {
  width: 100%;
  border-collapse: collapse;
  margin: 1.75rem 0;
  border-radius: 12px;
  overflow: hidden;
  border: 1px solid var(--card-border);
}

.table-container {
  width: 100%;
  overflow-x: auto;
  margin: 1.75rem 0;
  -webkit-overflow-scrolling: touch;
  border-radius: 12px;
  border: 1px solid var(--card-border);
}

.table-container table {
  margin: 0;
  border: none;
  border-radius: 0;
}

.doc-article th, .doc-article td {
  border: 1px solid var(--card-border);
  padding: 0.85rem 1.1rem;
  vertical-align: middle;
  background: rgba(13, 18, 30, 0.5);
  text-align: left;
}

.doc-article th {
  font-weight: 600;
  color: #f8fafc;
  background: rgba(255, 255, 255, 0.04);
}

.doc-article td img {
  margin: 0 auto;
}

.doc-article hr {
  border: none;
  height: 1px;
  background: var(--card-border);
  margin: 2.5rem 0;
}

.doc-footer {
  margin-top: 3.5rem;
  padding-top: 1.5rem;
  border-top: 1px solid var(--card-border);
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.8rem;
  color: var(--text-dim);
}

/* Two-Part Tile Layout */
.app-tile-split {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.25rem;
  margin-top: 0.5rem;
}

@media (max-width: 680px) {
  .app-tile-split {
    grid-template-columns: 1fr;
  }
}

.split-card {
  background: rgba(255, 255, 255, 0.025);
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-radius: 12px;
  padding: 1.1rem;
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  transition: all 0.2s ease;
}

.app-tile:hover .split-card {
  border-color: rgba(255, 255, 255, 0.12);
  background: rgba(255, 255, 255, 0.04);
}

.split-kicker {
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

.split-title {
  font-size: 1.05rem;
  font-weight: 700;
  color: #ffffff;
  letter-spacing: -0.01em;
}

.split-desc {
  font-size: 0.85rem;
  color: var(--text-muted);
  line-height: 1.5;
  margin-bottom: 0.5rem;
}

.split-link {
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.72rem;
  color: var(--east-accent);
  margin-top: auto;
}

/* In Development Badge */
.app-badge-dev {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 0.25rem 0.65rem;
  border-radius: 10px;
  font-size: 0.7rem;
  font-family: 'JetBrains Mono', monospace;
  font-weight: 600;
  letter-spacing: 0.04em;
  background: rgba(245, 158, 11, 0.15);
  color: #fbbf24;
  border: 1px solid rgba(245, 158, 11, 0.4);
}

.pulse-dot-dev {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #fbbf24;
  box-shadow: 0 0 8px rgba(245, 158, 11, 0.6);
  animation: pulse 2s infinite ease-in-out;
}

/* Certificate-Gated Holdings Tiles */
.cert-gated-tile {
  display: none !important;
}

.cert-gated-tile.is-revealed {
  display: flex !important;
}

.app-tile.cert-gated-tile {
  border-color: rgba(56, 189, 248, 0.28);
}

.app-tile.cert-gated-tile:hover {
  border-color: rgba(56, 189, 248, 0.65);
  box-shadow: 0 16px 40px -10px rgba(56, 189, 248, 0.25);
}
