
  /* --------- STARTUP ANIMATION --------- */

  #startupScreen {
    position: fixed;
    inset: 0;
    background: black;
    z-index: 5000;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 18px;
    transition: opacity 0.3s ease;
  }

  .startup-bar {
    width: 60%;
    height: 18px;
    border-radius: 14px;
    animation: barFlash 0.9s ease infinite alternate;
  }

  .bar1 { background:#F6A200; }
  .bar2 { background:#F58EA8; }
  .bar3 { background:#9B7DF7; }

  .startup-text {
    color:#F6A200;
    font-family:"Orbitron";
    letter-spacing:3px;
    font-size:0.9rem;
    opacity:0.9;
  }

  @keyframes barFlash {
    from { opacity:0.3; }
    to { opacity:1; }
  }

  /* --------- BASE --------- */

  body {
    font-family: "Rajdhani", sans-serif;
    background: #000;
    color: #e4edf7;          /* softer than pure white */
    min-height: 100vh;
    overflow-x: hidden;
  }

  /* constrain content width so cards aren’t edge-to-edge */
  .container {
    max-width: 1150px;       /* tighten the whole layout */
    margin: 0 auto;
  }

  /* --------- STARFIELD --------- */

  .stars, .moving-stars {
    position: fixed;
    inset: 0;
    pointer-events: none;
    z-index:-2;
  }

  .star {
    position:absolute;
    width:2px;
    height:2px;
    background:#fff;
    border-radius:50%;
    animation: twinkle 3s infinite;
  }

  @keyframes twinkle {
    0%,100% { opacity:0.2; }
    50% { opacity:1; }
  }

  .moving-star {
    position:absolute;
    width:1px;
    height:40px;
    background:linear-gradient(to bottom,transparent,#f6a200,transparent);
    opacity:0.6;
    animation:moveStars 10s linear infinite;
  }

  @keyframes moveStars {
    from { transform:translateY(-110vh) translateX(0); }
    to { transform:translateY(110vh) translateX(-40px); }
  }

  @keyframes drift {
    0%   { transform:translateY(0) scale(1); }
    100% { transform:translateY(250px) scale(1.85); }
  }

  .stars {
    animation: drift 30s linear infinite;
  }


  /* --------- FRAME --------- */

  .lcars-frame {
    display:flex;
    min-height:100vh;
  }

  .lcars-left-rail {
    width:160px;             /* wider rail -> visually narrower content */
    padding:10px 6px;
    display:flex;
    flex-direction:column;
    gap:12px;
  }

  .lcars-pill {
    border-radius:50px 0 0 50px;
    height:50px;
  }

  .pill-top    { background:#F6A200; }
  .pill-mid1   { background:#F58EA8; }
  .pill-mid2   { background:#9B7DF7; }
  .pill-bottom { background:#F6A200; flex-grow:1; }

  .lcars-main {
    flex:1;
    padding:18px 28px 60px 10px;
  }

  /* --------- TOP BAR --------- */

  .top-bar {
    display:grid;
    grid-template-columns:2.5fr 1fr;
    gap:12px;
    margin-bottom:18px;
  }

  .top-bar-left {
    background:#F6A200;
    padding:10px 18px;
    border-radius:0 26px 26px 0;
    display:flex;
    justify-content:space-between;
    align-items:center;
    font-family:"Orbitron";
    color:#000;
    font-weight:700;
    letter-spacing:2px;
  }

  .top-bar-left .title {
    font-size:1rem;
  }

  .top-bar-right {
    display:flex;
    gap:10px;
    align-items:stretch;
  }

  .status-chip {
    background:#F58EA8;
    border-radius:26px;
    padding:8px 22px;        /* balanced padding left/right */
    display:flex;
    align-items:center;
    justify-content:center;
    gap: 6px;
    color:#000;
    font-family:"Orbitron";
    font-size:0.85rem;
    letter-spacing:1px;
    line-height:1;           /* fixes vertical misalignment */
  }

  .status-chip i {
    margin: 0 4px;
    transform: none;
    display: flex;
    align-items: center;
    justify-content: center;
  }


  .status-chip.connected {
    background:#7df79f;
  }

  .status-dot {
    display: inline-block;
    margin-top: 1px;   /* tiny nudge so it lines up with the icon */
    width:10px;
    height:10px;
    flex-shrink:0;           /* prevents squishing that nudges alignment */
    border-radius:50%;
    background:#f44336; /* LCARS red — alt amber: #f6a200 */
    animation:pulse 2s ease-in-out infinite;
  }


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

  /* --------- SEPARATOR BAR --------- */

  .separator-bar {
    height:14px;
    margin-bottom:20px;
    display:grid;
    grid-template-columns:180px 1fr 80px;
    gap:6px;
  }

  .sep-1 { background:#F58EA8; border-radius:0 16px 16px 0; }
  .sep-2 { background:#9B7DF7; border-radius:0 16px 16px 0; }
  .sep-3 { background:#F6A200; border-radius:0 16px 16px 0; }

  /* --------- SECTIONS --------- */

  .section {
    background:rgba(15,15,30,0.9);
    border-radius:0 16px 16px 0;
    margin:32px 0;           /* base spacing between groups */
    box-shadow:0 6px 24px rgba(0,0,0,0.6);
  }

  /* extra spacing between different stages */
  .stage-gap {
    margin-top: 100px !important;   /* bigger gap between stage groups */
  }


  /* smaller top margin when it’s the second/third stage in the same group
     (e.g. Academy – Petit Paris + Academy – Rock Cafe stay close) */
  .section.group-follow {
    margin-top: 18px !important;
  }

  .section-header {
    padding:10px 18px;
    font-family:"Orbitron";
    color:#000;
    display:flex;
    align-items:center;
    gap:10px;
    text-transform:uppercase;
    letter-spacing:1.5px;
    font-weight:800;
    border-radius:0 14px 0 0;   /* ROUNDED TOPS */
  }


  .section-body {
    padding:12px 18px 20px 18px;
  }

  .command-grid {
    display:grid;
    grid-template-columns:repeat(auto-fit,minmax(260px,1fr));
    gap:14px;
  }

  /* --------- COMMAND CARDS --------- */

  .command-btn {
    background:#1a1a2c;
    border:1px solid #6ed6ff;
    border-radius:12px;
    padding:12px;
    text-decoration:none;
    color:#e4edf7;           /* softer text in cards */
    display:block;
    transition:0.2s ease;
    position:relative;
  }

  .command-btn:hover {
    transform:translateY(-2px);
    box-shadow:0 0 20px var(--stageGlow);
    border-color:var(--stageGlow);
  }

  .cmd-top-row {
    display:flex;
    align-items:center;
    margin-bottom:6px;
  }

  .cmd-icon {
    width:30px;
    height:30px;
    background:#F6A200;
    border-radius:50%;
    display:flex;
    align-items:center;
    justify-content:center;
    color:#000;
    font-size:1rem;
  }

  .cmd-label {
    padding-left:10px;
    font-family:"Orbitron";
    font-size:1.25rem;       /* bigger titles like “All Arena Stage Files” */
    font-weight:900;
    letter-spacing:0.5px;
  }

  .cmd-notes {
    font-size:1.2rem;          /* bigger notes: “If there are last-minute uploads…” */
    margin-top:6px;
    color:#9ff7c6;
  }

  /* --------- FOOTER --------- */

  .lcars-footer {
    margin-top:60px;
    height:60px;
    display:grid;
    grid-template-columns:160px 1fr 160px;
    gap:10px;
  }

  .footer-left {
    background:#F6A200;
    border-radius:60px 0 0 60px;
  }

  .footer-right {
    background:#9B7DF7;
    border-radius:0 60px 60px 0;
  }

  .footer-center {
    background:#F58EA8;
    color:#000;
    font-family:"Orbitron";
    letter-spacing:3px;
    font-weight:700;
    display:flex;
    align-items:center;
    justify-content:center;
    border-radius:8px;
  }

  /* --------- SIDEBAR --------- */
  .lcars-command {
    display:flex;
    align-items:flex-start;     /* top aligned */
    justify-content:flex-end;   /* right aligned */
    padding:0 2px 0 6px;    /* push text to right */
    text-align:right;

    font-family:"Orbitron";
    font-weight:800;
    font-size:0.75rem;
    letter-spacing:1px;
    color:#000;
    text-decoration:none;
    cursor:pointer;
    transition:0.2s ease;
  }

  .lcars-command.bottom-align {
    align-items:flex-end;
    justify-content:flex-end;
    padding:18px 2px 2px 6px;   /* increase top padding to push the text DOWN */
    text-align:right;
  }

  .lcars-pill.pill-bottom {
    margin-top: 2px;
  }

  .lcars-command:hover {
    filter:brightness(1.15);
  }

  .lcars-left-rail {
    display:flex;
    flex-direction:column;
    gap:6px;
  }

  .lcars-pill {
    height:56px;
    border-radius:50px 0 0 50px;
  }

  .torpedo-align {
    align-items:flex-start;   /* keep top aligned */
    padding-top:8px;         /* add breathing room above text */
  }


  /* UNIFORM MODE OVERRIDE */
  .uniform-spacing .section {
    margin-top: 100px !important;
  }


  /* =====================================================
     NEW (Vercel version): LOGIN / LOADING
     ===================================================== */

  /* panels reuse .section / .section-header / .section-body */
  .status-panel .section-header i {
    margin-right: 4px;
  }

  .login-form {
    display: flex;
    flex-direction: column;
    gap: 10px;
    padding-top: 6px;
  }

  .login-label {
    font-size: 1.2rem;
    color: #9ff7c6;
  }

  .login-row {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
  }

  .login-row input {
    flex: 1;
    min-width: 200px;
    background: #1a1a2c;
    border: 1px solid #6ed6ff;
    border-radius: 12px;
    padding: 10px 14px;
    color: #e4edf7;
    font-family: "Orbitron";
    font-size: 1rem;
    letter-spacing: 2px;
    outline: none;
  }

  .login-row input:focus {
    border-color: #F6A200;
    box-shadow: 0 0 14px #F6A200;
  }

  .lcars-btn {
    background: #F6A200;
    color: #000;
    border: none;
    border-radius: 26px;
    padding: 10px 26px;
    font-family: "Orbitron";
    font-weight: 800;
    letter-spacing: 2px;
    cursor: pointer;
    transition: 0.2s ease;
  }

  .lcars-btn:hover { filter: brightness(1.15); }
  .lcars-btn:disabled { opacity: 0.5; cursor: wait; }

  .login-error {
    min-height: 1.4em;
    color: #FF6B6B;
    font-family: "Orbitron";
    font-size: 0.85rem;
    letter-spacing: 1px;
  }

  /* loading bars (same look as the startup screen) */
  .loading-bars {
    display: flex;
    flex-direction: column;
    gap: 10px;
    padding: 10px 0;
  }

  .loading-bars .startup-bar {
    width: 100%;
    height: 12px;
  }

  .loading-bars .startup-bar:nth-child(2) { animation-delay: 0.3s; }
  .loading-bars .startup-bar:nth-child(3) { animation-delay: 0.6s; }

  .loading-text {
    font-size: 1.2rem;
    color: #9ff7c6;
    margin-top: 6px;
  }

  .loading-panel.is-error .loading-bars { display: none; }
  .loading-panel.is-error .loading-text { color: #FF6B6B; }

  #retryBtn { margin-top: 12px; }
