/* Appily Thirtyfive — Bloom Express Platform track & support */

.page-track-platform {
  --pf-canopy: #2A3A4A;
  --pf-canopy-light: #3D5266;
  --pf-brass: #B8956A;
  --pf-brass-light: #D4B896;
  --pf-brass-dark: #8B6F47;
  --pf-board: #1A1A1A;
  --pf-flap: #2D2D2D;
  --pf-flap-text: #F4E4A6;
  --pf-cream: #F5F0E8;
  --pf-paper: #FFFCF7;
  --pf-ink: #2A2520;
  --pf-muted: #6B6258;
  --pf-line: #DDD4C8;
  --pf-green: #4CAF6A;
  --pf-rose: #C2557A;
  --pf-orange: #E8913A;
  --pf-forest: #3D5A45;
  background: var(--pf-cream);
}

.page-track-platform .page-main {
  padding-top: 0;
}

.a35-platform {
  padding-bottom: 3.5rem;
}

/* ── Station canopy hero ── */
.a35-platform-canopy {
  position: relative;
  padding: 2.25rem 0 3rem;
  background: linear-gradient(180deg, var(--pf-canopy) 0%, var(--pf-canopy-light) 70%, var(--pf-cream) 100%);
  overflow: hidden;
}

.a35-platform-canopy-arch {
  position: absolute;
  top: 0;
  left: 50%;
  transform: translateX(-50%);
  width: min(900px, 95vw);
  height: 80px;
  border: 3px solid rgba(184, 149, 106, 0.35);
  border-bottom: none;
  border-radius: 50% 50% 0 0 / 100% 100% 0 0;
  pointer-events: none;
}

.a35-platform-clock {
  position: absolute;
  top: 1.25rem;
  right: max(1rem, calc(50% - 520px));
  width: 48px;
  height: 48px;
}

.a35-platform-clock-face {
  display: block;
  width: 100%;
  height: 100%;
  border-radius: 50%;
  background: var(--pf-paper);
  border: 3px solid var(--pf-brass-dark);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

.a35-platform-clock-hand {
  position: absolute;
  top: 50%;
  left: 50%;
  width: 2px;
  height: 14px;
  margin: -14px 0 0 -1px;
  background: var(--pf-canopy);
  transform-origin: bottom center;
  animation: a35PlatformClock 8s linear infinite;
}

@keyframes a35PlatformClock {
  from { transform: rotate(0deg); }
  to { transform: rotate(360deg); }
}

.a35-platform-canopy-inner {
  position: relative;
  max-width: 640px;
  margin: 0 auto;
  text-align: center;
}

.a35-platform-kicker {
  margin: 0 0 0.4rem;
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--pf-brass-light);
}

.a35-platform-canopy-inner h1 {
  margin: 0 0 0.55rem;
  font-family: var(--font-display);
  font-size: clamp(1.85rem, 4vw, 2.65rem);
  font-weight: 600;
  line-height: 1.1;
  color: #fff;
}

.a35-platform-canopy-inner h1 em {
  font-style: italic;
  color: var(--pf-brass-light);
}

.a35-platform-lede {
  margin: 0 auto 1.25rem;
  max-width: 48ch;
  font-size: 0.92rem;
  line-height: 1.6;
  color: rgba(255, 255, 255, 0.85);
}

.a35-platform-indicator {
  display: inline-flex;
  flex-direction: column;
  align-items: center;
  gap: 0.2rem;
  padding: 0.85rem 1.25rem;
  background: var(--pf-board);
  border: 3px solid var(--pf-brass-dark);
  border-radius: 10px;
  box-shadow: 0 10px 28px rgba(0, 0, 0, 0.25);
}

.a35-platform-indicator-lamp {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: #555;
  margin-bottom: 0.15rem;
}

.a35-platform-indicator.is-found .a35-platform-indicator-lamp {
  background: var(--pf-green);
  box-shadow: 0 0 10px var(--pf-green);
  animation: a35PlatformLamp 1.5s ease-in-out infinite;
}

.a35-platform-indicator.is-miss .a35-platform-indicator-lamp {
  background: var(--pf-rose);
  box-shadow: 0 0 8px var(--pf-rose);
}

@keyframes a35PlatformLamp {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.6; }
}

.a35-platform-indicator strong {
  font-family: var(--font-mono, monospace);
  font-size: 1.4rem;
  font-weight: 700;
  color: var(--pf-flap-text);
  line-height: 1;
}

.a35-platform-indicator span:last-child {
  font-size: 0.62rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: rgba(244, 228, 166, 0.75);
}

.a35-platform-indicator.is-found strong {
  color: var(--pf-green);
}

.a35-platform-indicator.is-miss strong {
  color: var(--pf-rose);
}

/* ── Deck: booth + board ── */
.a35-platform-deck {
  display: grid;
  grid-template-columns: minmax(260px, 320px) minmax(0, 1fr);
  gap: 1.5rem;
  align-items: start;
  margin-top: -1.25rem;
  position: relative;
  z-index: 2;
  max-width: 1000px;
}

/* ── Ticket booth ── */
.a35-platform-booth {
  position: relative;
  padding: 1.25rem 1.35rem 1rem;
  background: linear-gradient(165deg, #5C4033 0%, #4A3728 100%);
  border: 4px solid var(--pf-brass-dark);
  border-radius: 12px 12px 4px 4px;
  box-shadow: 0 20px 50px rgba(42, 37, 32, 0.2);
  color: rgba(255, 255, 255, 0.9);
}

.a35-platform-booth-window {
  position: absolute;
  top: -12px;
  left: 50%;
  transform: translateX(-50%);
  width: 70%;
  height: 14px;
  background: var(--pf-brass-dark);
  border-radius: 6px 6px 0 0;
}

.a35-platform-booth-grille {
  display: block;
  width: 100%;
  height: 100%;
  background: repeating-linear-gradient(
    90deg,
    var(--pf-brass) 0,
    var(--pf-brass) 4px,
    transparent 4px,
    transparent 8px
  );
  opacity: 0.6;
}

.a35-platform-booth-head {
  display: flex;
  align-items: flex-start;
  gap: 0.85rem;
  margin-bottom: 1rem;
  padding-top: 0.35rem;
}

.a35-platform-ticket-stub {
  flex-shrink: 0;
  display: grid;
  place-items: center;
  width: 48px;
  height: 56px;
  font-size: 0.58rem;
  font-weight: 800;
  letter-spacing: 0.05em;
  color: var(--pf-brass-dark);
  background: var(--pf-flap-text);
  border-radius: 4px;
  transform: rotate(-4deg);
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.2);
}

.a35-platform-booth-head h2 {
  margin: 0 0 0.2rem;
  font-family: var(--font-display);
  font-size: 1.15rem;
  font-weight: 600;
  color: #fff;
}

.a35-platform-booth-head p {
  margin: 0;
  font-size: 0.78rem;
  color: rgba(255, 255, 255, 0.7);
}

.a35-platform-form {
  display: flex;
  flex-direction: column;
  gap: 0.85rem;
}

.a35-platform-field {
  display: flex;
  flex-direction: column;
  gap: 0.3rem;
}

.a35-platform-field span {
  font-size: 0.62rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--pf-brass-light);
}

.a35-platform-field input {
  padding: 0.6rem 0.7rem;
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: 6px;
  font: inherit;
  font-size: 0.86rem;
  background: rgba(0, 0, 0, 0.25);
  color: #fff;
}

.a35-platform-field input::placeholder {
  color: rgba(255, 255, 255, 0.4);
}

.a35-platform-field input:focus {
  outline: none;
  border-color: var(--pf-brass);
  box-shadow: 0 0 0 2px rgba(184, 149, 106, 0.35);
}

.a35-platform-form-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.55rem;
  margin-top: 0.25rem;
}

.a35-platform-submit {
  padding: 0.55rem 1.15rem;
  border: 0;
  border-radius: 999px;
  font: inherit;
  font-size: 0.82rem;
  font-weight: 700;
  color: var(--pf-ink);
  background: var(--pf-flap-text);
  cursor: pointer;
  transition: background 0.15s, color 0.15s;
}

.a35-platform-submit:hover {
  background: var(--pf-orange);
  color: #fff;
}

.a35-platform-reset {
  display: inline-flex;
  align-items: center;
  padding: 0.55rem 0.85rem;
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--pf-brass-light);
  text-decoration: none !important;
}

.a35-platform-booth-foot {
  display: flex;
  justify-content: space-between;
  margin-top: 1rem;
  padding-top: 0.65rem;
  border-top: 1px solid rgba(255, 255, 255, 0.12);
  font-size: 0.62rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.5);
}

/* ── Flap board + tracker ── */
.a35-platform-board-wrap {
  display: flex;
  flex-direction: column;
  gap: 1.15rem;
}

.a35-platform-flapboard {
  padding: 1.15rem 1.25rem;
  background: var(--pf-board);
  border: 4px solid var(--pf-brass-dark);
  border-radius: 10px;
  box-shadow:
    inset 0 0 30px rgba(0, 0, 0, 0.4),
    0 16px 40px rgba(42, 37, 32, 0.15);
}

.a35-platform-flapboard.is-found {
  animation: a35PlatformFlapFlip 0.6s ease;
}

@keyframes a35PlatformFlapFlip {
  0%, 100% { transform: perspective(400px) rotateX(0); }
  50% { transform: perspective(400px) rotateX(-3deg); }
}

.a35-platform-flapboard-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  margin-bottom: 0.85rem;
  padding-bottom: 0.65rem;
  border-bottom: 1px solid rgba(184, 149, 106, 0.25);
}

.a35-platform-flapboard-head h3 {
  margin: 0;
  font-family: var(--font-display);
  font-size: 1rem;
  font-weight: 600;
  color: var(--pf-brass-light);
}

.a35-platform-flapboard-pill {
  padding: 0.25rem 0.6rem;
  border-radius: 4px;
  font-size: 0.62rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: rgba(244, 228, 166, 0.6);
  background: var(--pf-flap);
}

.a35-platform-flapboard-pill.is-found {
  color: var(--pf-green);
  background: rgba(76, 175, 106, 0.15);
}

.a35-platform-flapboard-pill.is-miss {
  color: var(--pf-rose);
  background: rgba(194, 85, 122, 0.15);
}

.a35-platform-flaps {
  display: flex;
  flex-direction: column;
  gap: 0.45rem;
}

.a35-platform-flap-row {
  display: grid;
  grid-template-columns: 72px 1fr;
  gap: 0.65rem;
  align-items: center;
}

.a35-platform-flap-label {
  font-size: 0.62rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--pf-brass);
}

.a35-platform-flap-value {
  padding: 0.45rem 0.65rem;
  font-family: var(--font-mono, monospace);
  font-size: clamp(0.72rem, 2vw, 0.88rem);
  font-weight: 700;
  letter-spacing: 0.06em;
  color: var(--pf-flap-text);
  background: var(--pf-flap);
  border-radius: 4px;
  box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.3);
  word-break: break-all;
  animation: a35PlatformFlapTick 0.4s ease;
}

.a35-platform-flapboard.is-idle .a35-platform-flap-value {
  opacity: 0.55;
}

@keyframes a35PlatformFlapTick {
  from { transform: rotateX(-90deg); opacity: 0; }
  to { transform: rotateX(0); opacity: 1; }
}

/* ── Railway tracker ── */
.a35-platform-tracker {
  padding: 1.25rem 1.35rem 1.35rem;
  background: var(--pf-paper);
  border: 1px solid var(--pf-line);
  border-radius: 14px;
  box-shadow: 0 12px 32px rgba(42, 37, 32, 0.06);
}

.a35-platform-track-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  margin-bottom: 1.15rem;
}

.a35-platform-track-head h3 {
  margin: 0;
  font-family: var(--font-display);
  font-size: 1.05rem;
  font-weight: 600;
  color: var(--pf-ink);
}

.a35-platform-track-legend {
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--pf-muted);
}

.a35-platform-rail {
  position: relative;
  margin-bottom: 1.25rem;
  padding: 2.5rem 0 0.5rem;
}

.a35-platform-rail-line {
  position: absolute;
  top: 3.25rem;
  left: 8%;
  right: 8%;
  height: 6px;
  background: repeating-linear-gradient(
    90deg,
    var(--pf-brass-dark) 0,
    var(--pf-brass-dark) 12px,
    var(--pf-brass) 12px,
    var(--pf-brass) 24px
  );
  border-radius: 999px;
  box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.15);
}

.a35-platform-rail-progress {
  position: absolute;
  top: 3.25rem;
  left: 8%;
  height: 6px;
  width: calc((var(--a35-step, 0) / 4) * 84%);
  max-width: 84%;
  background: var(--pf-orange);
  border-radius: 999px;
  transition: width 0.6s cubic-bezier(0.34, 1.2, 0.64, 1);
  z-index: 1;
}

.a35-platform-tracker.is-found .a35-platform-rail-progress {
  box-shadow: 0 0 12px rgba(232, 145, 58, 0.45);
}

.a35-platform-train {
  position: absolute;
  top: 2.65rem;
  left: calc(8% + (var(--a35-step, 0) / 4) * 84% - 16px);
  width: 32px;
  height: 22px;
  background: linear-gradient(180deg, var(--pf-forest) 0%, #2F4535 100%);
  border-radius: 6px 6px 4px 4px;
  transition: left 0.6s cubic-bezier(0.34, 1.2, 0.64, 1);
  z-index: 3;
  box-shadow: 0 4px 12px rgba(42, 37, 32, 0.2);
}

.a35-platform-train::before {
  content: '';
  position: absolute;
  top: -6px;
  left: 4px;
  right: 4px;
  height: 8px;
  background: var(--pf-rose);
  border-radius: 4px 4px 0 0;
}

.a35-platform-train::after {
  content: '';
  position: absolute;
  bottom: -4px;
  left: 6px;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #333;
  box-shadow: 14px 0 0 #333;
}

.a35-platform-tracker:not(.is-found) .a35-platform-train {
  opacity: 0;
}

.a35-platform-stops {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 0.5rem;
  position: relative;
  z-index: 2;
}

.a35-platform-stop {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.55rem;
  text-align: center;
}

.a35-platform-stop-pin {
  display: grid;
  place-items: center;
  width: 40px;
  height: 40px;
  border-radius: 8px;
  font-size: 0.65rem;
  font-weight: 800;
  letter-spacing: 0.05em;
  color: var(--pf-muted);
  background: var(--pf-cream);
  border: 2px solid var(--pf-line);
  transition: border-color 0.25s, background 0.25s, transform 0.25s, color 0.25s;
}

.a35-platform-stop.is-passed .a35-platform-stop-pin {
  border-color: var(--pf-forest);
  background: linear-gradient(145deg, #fff, #EEF4EA);
  color: var(--pf-forest);
}

.a35-platform-stop.is-current .a35-platform-stop-pin {
  border-color: var(--pf-orange);
  background: linear-gradient(145deg, #FFF8F0, #FFE8CC);
  color: var(--pf-orange);
  transform: scale(1.1);
  box-shadow: 0 6px 18px rgba(232, 145, 58, 0.3);
  animation: a35PlatformStopPulse 2s ease-in-out infinite;
}

.a35-platform-stop.is-dim .a35-platform-stop-pin {
  opacity: 0.4;
}

@keyframes a35PlatformStopPulse {
  0%, 100% { box-shadow: 0 6px 18px rgba(232, 145, 58, 0.25); }
  50% { box-shadow: 0 8px 24px rgba(232, 145, 58, 0.4); }
}

.a35-platform-stop-copy strong {
  display: block;
  font-size: 0.74rem;
  font-weight: 700;
  line-height: 1.25;
  color: var(--pf-ink);
}

.a35-platform-stop-copy span {
  display: block;
  margin-top: 0.1rem;
  font-size: 0.65rem;
  color: var(--pf-muted);
}

/* ── Manifest / notices ── */
.a35-platform-manifest {
  padding: 1.1rem 1.2rem;
  background: linear-gradient(145deg, #FAF7F2 0%, #fff 100%);
  border: 1px solid var(--pf-line);
  border-radius: 12px;
}

.a35-platform-manifest-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.65rem;
  margin-bottom: 0.55rem;
}

.a35-platform-manifest-tag {
  font-size: 0.62rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--pf-forest);
}

.a35-platform-manifest-status {
  padding: 0.18rem 0.5rem;
  border-radius: 999px;
  font-size: 0.65rem;
  font-weight: 700;
  color: #fff;
  background: var(--pf-forest);
}

.a35-platform-manifest-id {
  margin: 0 0 0.75rem;
  font-family: var(--font-mono, monospace);
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--pf-ink);
  word-break: break-all;
}

.a35-platform-manifest-meta {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.65rem;
  margin: 0 0 1rem;
}

.a35-platform-manifest-meta div {
  padding: 0.5rem 0.6rem;
  background: #fff;
  border-radius: 8px;
  border: 1px solid var(--pf-line);
}

.a35-platform-manifest-meta dt {
  margin: 0 0 0.12rem;
  font-size: 0.6rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--pf-muted);
}

.a35-platform-manifest-meta dd {
  margin: 0;
  font-size: 0.88rem;
  font-weight: 700;
  color: var(--pf-ink);
}

.a35-platform-manifest-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.55rem;
}

.a35-platform-btn {
  display: inline-flex;
  align-items: center;
  padding: 0.5rem 1rem;
  border-radius: 999px;
  font-size: 0.8rem;
  font-weight: 700;
  text-decoration: none !important;
  transition: background 0.15s, color 0.15s;
}

.a35-platform-btn--primary {
  color: #fff !important;
  background: var(--pf-forest);
}

.a35-platform-btn--primary:hover {
  background: var(--pf-orange);
}

.a35-platform-btn--soft {
  color: var(--pf-forest) !important;
  background: rgba(61, 90, 69, 0.08);
  border: 1px solid rgba(61, 90, 69, 0.15);
}

.a35-platform-btn--soft:hover {
  background: rgba(61, 90, 69, 0.14);
}

.a35-platform-notice {
  padding: 1rem 1.1rem;
  border-radius: 12px;
  text-align: center;
}

.a35-platform-notice strong {
  display: block;
  margin-bottom: 0.3rem;
  font-family: var(--font-display);
  font-size: 1.02rem;
  color: var(--pf-ink);
}

.a35-platform-notice p {
  margin: 0 0 0.75rem;
  font-size: 0.86rem;
  line-height: 1.55;
  color: var(--pf-muted);
}

.a35-platform-notice.is-idle {
  background: rgba(61, 90, 69, 0.06);
  border: 1px dashed rgba(61, 90, 69, 0.2);
}

.a35-platform-notice.is-miss {
  background: rgba(194, 85, 122, 0.08);
  border: 1px solid rgba(194, 85, 122, 0.2);
}

.a35-platform-notice.is-miss strong {
  color: var(--pf-rose);
}

/* ── Platform gates ── */
.a35-platform-gates {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 0.65rem;
  margin-top: 2rem;
  max-width: 1000px;
}

.a35-platform-gate {
  display: flex;
  flex-direction: column;
  gap: 0.3rem;
  padding: 0.8rem 0.95rem;
  background: #fff;
  border: 1px solid var(--pf-line);
  border-left: 4px solid var(--pf-brass);
  border-radius: 0 10px 10px 0;
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--pf-ink);
  text-decoration: none !important;
  transition: border-color 0.15s, transform 0.15s, box-shadow 0.15s;
}

.a35-platform-gate:hover {
  border-left-color: var(--pf-orange);
  transform: translateX(4px);
  box-shadow: 0 6px 18px rgba(42, 37, 32, 0.08);
}

.a35-platform-gate-num {
  font-size: 0.6rem;
  font-weight: 800;
  letter-spacing: 0.1em;
  color: var(--pf-brass-dark);
}

/* ── Responsive ── */
@media (max-width: 860px) {
  .a35-platform-deck {
    grid-template-columns: 1fr;
    margin-top: 0;
  }

  .a35-platform-clock {
    display: none;
  }

  .a35-platform-stops {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 1rem 0.5rem;
  }

  .a35-platform-rail-line,
  .a35-platform-rail-progress,
  .a35-platform-train {
    display: none;
  }

  .a35-platform-rail {
    padding-top: 0;
  }

  .a35-platform-manifest-meta {
    grid-template-columns: 1fr;
  }

  .a35-platform-gates {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 480px) {
  .a35-platform-stops {
    grid-template-columns: 1fr;
  }

  .a35-platform-gates {
    grid-template-columns: 1fr;
  }

  .a35-platform-flap-row {
    grid-template-columns: 1fr;
    gap: 0.25rem;
  }

  .a35-platform-track-head,
  .a35-platform-flapboard-head {
    flex-direction: column;
    align-items: flex-start;
  }
}

@media (prefers-reduced-motion: reduce) {
  .a35-platform-clock-hand,
  .a35-platform-indicator.is-found .a35-platform-indicator-lamp,
  .a35-platform-stop.is-current .a35-platform-stop-pin,
  .a35-platform-flapboard.is-found,
  .a35-platform-flap-value {
    animation: none;
  }

  .a35-platform-rail-progress,
  .a35-platform-train {
    transition: none;
  }
}
