@import url("https://fonts.googleapis.com/css2?family=Orbitron:wght@600;700;800&family=Space+Grotesk:wght@400;500;700&display=swap");

:root{
  --bg:#080d1a;
  --card:#101726;
  --muted:#8faacccc;
  --text:#eaf0ff;
  --primary:#5b8cff;
  --danger:#ff4d4d;
  --border:#1f2e4e;
}

*{box-sizing:border-box}
html{
  -webkit-text-size-adjust:100%;
  text-size-adjust:100%;
}
body{margin:0;font-family:"Space Grotesk","Segoe UI",sans-serif;background:var(--bg);color:var(--text)}
a{color:var(--text);text-decoration:none}
.container{max-width:1200px;margin:0 auto;padding:18px}
.topbar{display:flex;align-items:center;justify-content:space-between;padding:14px 18px;border-bottom:1px solid var(--border);background:#0a0f1e}
.brand a{font-weight:800;letter-spacing:.5px}
.right{display:flex;gap:10px;align-items:center}
.pill{border:1px solid var(--border);padding:6px 10px;border-radius:999px;color:var(--muted)}

.grid{display:grid;grid-template-columns:1fr 1fr;gap:16px}
@media (max-width: 900px){.grid{grid-template-columns:1fr}}

.card{background:var(--card);border:1px solid var(--border);border-radius:16px;padding:16px;box-shadow:0 8px 24px #00000033}
.card.inner{padding:12px}
hr{border:none;border-top:1px solid var(--border);margin:14px 0}

h1,h2,h3{margin:0 0 10px}
.muted{color:var(--muted)}
.small{font-size:12px}
.sr-only{
  position:absolute;
  width:1px;
  height:1px;
  padding:0;
  margin:-1px;
  overflow:hidden;
  clip:rect(0,0,0,0);
  white-space:nowrap;
  border:0;
}

.form{display:flex;flex-direction:column;gap:10px}
input,select,textarea,button{
  font:inherit;
}
input,select,textarea{
  width:100%;padding:10px 12px;border-radius:12px;
  border:1px solid var(--border);background:#0b1430;color:var(--text);
  outline:none;
  transition:border-color .18s ease, box-shadow .18s ease, background-color .18s ease;
}
input:focus,select:focus,textarea:focus{
  border-color:#4260a7;
  box-shadow:0 0 0 4px #5b8cff1f;
}
textarea{
  min-height:110px;
  resize:vertical;
}
.row{display:flex;gap:10px;align-items:center;flex-wrap:wrap}
.row.space{justify-content:space-between}
.row input{flex:1;min-width:120px}
.row label{white-space:nowrap}

.btn{
  border:1px solid var(--border);
  background:#0b1430;color:var(--text);
  padding:10px 12px;border-radius:12px;
  cursor:pointer;white-space:nowrap;
  transition:background .14s,border-color .14s,box-shadow .14s,transform .1s,filter .14s;
}
.btn:hover:not(:disabled){border-color:#3a5080;transform:translateY(-1px);box-shadow:0 4px 12px #00000044}
.btn:active:not(:disabled){transform:translateY(0)}
.btn:disabled{opacity:.55;cursor:not-allowed}
.btn.primary{background:var(--primary);border-color:transparent;color:#07122a;font-weight:800}
.btn.primary:hover:not(:disabled){filter:brightness(1.1);box-shadow:0 6px 18px #5b8cff33}
.btn.danger{background:var(--danger);border-color:transparent;color:#220707;font-weight:800}
.btn.danger:hover:not(:disabled){filter:brightness(1.1)}

.list{display:flex;flex-direction:column;gap:10px}
.editor-shell{display:flex;flex-direction:column;gap:14px}
.toolbar-card{padding:14px}
.toolbar-top{display:flex;justify-content:space-between;gap:12px;align-items:flex-start}
.toolbar-actions{display:flex;gap:10px;flex-wrap:wrap;justify-content:flex-end}
.toolbar-grid{
  margin-top:12px;
  display:grid;
  gap:10px;
  grid-template-columns:2fr 1.2fr .8fr .8fr 1fr 1fr .7fr 1fr 1fr 1fr;
}
.control-pack{display:flex;flex-direction:column;gap:6px}
.control-pack.short{max-width:170px}

.editor-main{
  display:grid;
  grid-template-columns:400px 1fr;
  gap:14px;
}
.left-stack{display:flex;flex-direction:column;gap:14px}
.preview-card{display:flex;flex-direction:column}
.audio-preview{width:100%;margin-top:10px}
.place-suggest{
  display:none;
  margin-top:-4px;
  border:1px solid var(--border);
  border-radius:12px;
  background:#09102a;
  overflow:hidden;
}
.place-suggest.open{display:block}
.place-suggest-item{
  width:100%;
  border:none;
  border-bottom:1px solid #1d2a52;
  background:transparent;
  color:var(--text);
  text-align:left;
  padding:9px 12px;
  cursor:pointer;
}
.place-suggest-item:last-child{border-bottom:none}
.place-suggest-item:hover,.place-suggest-item.active{background:#14204a}
.place-suggest-item .name{display:block;font-weight:700}
.place-suggest-item .meta{display:block;color:var(--muted);font-size:12px;margin-top:2px}
.map-controls-top{
  margin-top:10px;
  display:flex;
  gap:10px;
  align-items:center;
  justify-content:space-between;
  flex-wrap:wrap;
}
.map-controls{
  margin-top:10px;
  display:grid;
  grid-template-columns:1fr;
  gap:8px 10px;
  align-items:center;
  padding:10px;
  border:1px solid var(--border);
  border-radius:12px;
  background:#0b1430;
}
.map-controls.collapsed{display:none}
.timeline-wrap{
  margin-top:12px;
  padding:10px;
  border:1px solid var(--border);
  border-radius:12px;
  background:#0b1430;
}
.timeline-top{display:flex;justify-content:space-between;gap:10px;align-items:center}
.timeline-wrap input[type="range"]{padding:0}
.keyframes-list{margin-top:8px;line-height:1.4}

.list-item{
  display:flex;align-items:center;justify-content:space-between;
  gap:12px;padding:10px;border:1px solid var(--border);border-radius:14px;background:#0b1430;
}
.list-item-main{display:flex;flex-direction:column;gap:8px;min-width:0;flex:1}
.list-item-copy{display:flex;flex-direction:column;gap:4px;min-width:0}
.list-item .title{font-weight:800;max-width:220px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.stop-transport-row{
  display:flex;
  align-items:center;
  gap:10px;
  flex-wrap:wrap;
  padding-top:8px;
  border-top:1px solid #213054;
}
.stop-transport-row label{
  color:var(--muted);
  font-size:12px;
}
.segment-transport-select{
  width:auto;
  min-width:140px;
  max-width:220px;
}
.actions{display:flex;gap:10px;align-items:center}
#stopsList{max-height:330px;overflow:auto;padding-right:4px}
.map-host{
  position:relative;
  width:min(100%, 680px);
  aspect-ratio:16/9;
  margin:0 auto;
  filter:drop-shadow(0 18px 40px #0000005a);
}
.map{
  width:100%;
  max-width:100%;
  height:100%;
  margin:0 auto;
  border-radius:16px;
  border:1px solid var(--border);
  overflow:hidden
}
.map-glow{
  position:absolute;
  inset:0;
  pointer-events:none;
  border-radius:16px;
  border:1px solid #6ea4ff40;
  background:
    radial-gradient(circle at 34% 28%, #ffffff2c 0%, #ffffff10 22%, #00000000 52%),
    radial-gradient(circle at 72% 78%, #00000000 55%, #00000066 100%);
  box-shadow:inset 0 0 40px #00000066;
}
#status{margin-top:10px;min-height:18px}

@media(max-width:1200px){
  .toolbar-grid{grid-template-columns:1fr 1fr 1fr 1fr 1fr}
  .editor-main{grid-template-columns:1fr}
}
@media(max-width:700px){
  .toolbar-top{flex-direction:column}
  .toolbar-actions{justify-content:flex-start}
  .toolbar-grid{grid-template-columns:1fr 1fr}
  .map-controls{grid-template-columns:1fr}
  .map-host{width:min(100%, 460px)}
}

.flash-wrap{margin-bottom:12px}
.flash{padding:10px 12px;border-radius:12px;border:1px solid var(--border);background:#0b1430}
.flash.error{border-color:#ff4d4d66}

@media(max-width:860px){
  .topbar{
    padding:12px 12px;
    gap:10px;
    align-items:flex-start;
    flex-wrap:wrap;
  }
  .brand a{
    font-size:17px;
    line-height:1.15;
  }
  .right{
    width:100%;
    justify-content:flex-start;
    flex-wrap:wrap;
    gap:8px;
  }
  .right .pill{
    max-width:100%;
    white-space:nowrap;
    overflow:hidden;
    text-overflow:ellipsis;
  }
}
@media(max-width:540px){
  .container{
    padding:12px 10px 14px;
  }
  .btn{
    padding:10px 11px;
    font-size:14px;
  }
  .list-item{
    flex-direction:column;
    align-items:flex-start;
  }
  .actions{
    width:100%;
    justify-content:flex-start;
    flex-wrap:wrap;
  }
  .actions .btn{
    min-width:0;
  }
}

body.landing-page{
  background:
    radial-gradient(900px 500px at 18% -10%, #2d5bff4a 0%, #00000000 62%),
    radial-gradient(900px 560px at 86% -12%, #3af1ff2f 0%, #00000000 64%),
    linear-gradient(180deg, #050814 0%, #060b18 46%, #070f22 100%);
  background-repeat:no-repeat,no-repeat,no-repeat;
  background-size:100% 100%,100% 100%,100% 100%;
  background-attachment:fixed,fixed,fixed;
}
body.landing-page .topbar,
body.auth-page .topbar{
  background:rgba(6,11,24,.66);
  border-bottom:1px solid #243253;
  backdrop-filter:blur(12px);
}
body.landing-page .brand a,
body.auth-page .brand a{
  font-family:"Orbitron","Space Grotesk","Segoe UI",sans-serif;
  letter-spacing:.09em;
  font-size:18px;
  text-transform:uppercase;
}
body.landing-page .container{
  max-width:1200px;
  padding:28px 20px 30px;
}
body.landing-page .landing-hero{
  position:relative;
  display:grid;
  grid-template-columns:1.15fr 1fr;
  gap:22px;
  min-height:540px;
  border:1px solid #2a3b63;
  border-radius:28px;
  padding:34px;
  background:
    linear-gradient(155deg, #101a33f4 0%, #0c1428f3 44%, #0a1225f2 100%);
  overflow:hidden;
  box-shadow:0 30px 54px #02050f8a;
}
body.landing-page .landing-hero-copy{
  position:relative;
  z-index:2;
  display:flex;
  flex-direction:column;
  justify-content:center;
  max-width:560px;
}
body.landing-page .hero-kicker{
  margin:0 0 10px;
  color:#9fd5ff;
  font-size:12px;
  letter-spacing:.22em;
  text-transform:uppercase;
}
body.landing-page .landing-hero h1{
  margin:0;
  font-family:"Orbitron","Space Grotesk","Segoe UI",sans-serif;
  line-height:1.06;
  font-size:clamp(34px, 5vw, 58px);
  letter-spacing:.02em;
}
body.landing-page .hero-subtitle{
  margin:16px 0 0;
  max-width:500px;
  color:#c8d4f9;
  font-size:18px;
  line-height:1.5;
}
body.landing-page .hero-actions{
  margin-top:26px;
  display:flex;
  gap:12px;
  flex-wrap:wrap;
}
body.landing-page .hero-cta{
  background:linear-gradient(95deg, #4cc7ff 0%, #5b8cff 48%, #9f69ff 100%);
  color:#f8fbff;
  border:none;
}
body.landing-page .landing-preview{
  position:relative;
  align-self:center;
  justify-self:end;
  width:min(100%, 480px);
  aspect-ratio:1/1;
  border-radius:26px;
  border:1px solid #314572;
  background:
    radial-gradient(circle at 24% 21%, #6f7cff38 0%, #00000000 56%),
    radial-gradient(circle at 80% 78%, #4ce9ff26 0%, #00000000 54%),
    #0a1123;
  overflow:hidden;
  box-shadow:inset 0 0 70px #050a16a8;
}
body.landing-page .preview-grid{
  position:absolute;
  inset:0;
  opacity:.22;
  background:
    linear-gradient(#7e97cf2b 1px, transparent 1px),
    linear-gradient(90deg, #7e97cf2b 1px, transparent 1px);
  background-size:48px 48px;
}
body.landing-page .preview-route{
  position:absolute;
  left:10%;
  right:12%;
  top:18%;
  bottom:20%;
  border-radius:44% 56% 45% 55%;
  border:2px dashed #7fd8ff;
  filter:drop-shadow(0 0 10px #4dc3ff8c);
  animation:orbitPulse 5.2s ease-in-out infinite;
}
body.landing-page .preview-point{
  position:absolute;
  width:14px;
  height:14px;
  border-radius:50%;
  background:#ffffff;
  box-shadow:0 0 0 8px #7cd2ff1f, 0 0 14px #8ee2ff;
}
body.landing-page .point-a{left:18%;top:26%}
body.landing-page .point-b{right:22%;top:34%}
body.landing-page .point-c{left:40%;bottom:22%}
body.landing-page .landing-orbit{
  position:absolute;
  border-radius:50%;
  border:1px solid #5277ce5e;
  pointer-events:none;
}
body.landing-page .orbit-a{
  width:700px;
  height:700px;
  right:-240px;
  top:-420px;
}
body.landing-page .orbit-b{
  width:540px;
  height:540px;
  left:-280px;
  bottom:-360px;
}
body.landing-page .orbit-c{
  width:460px;
  height:460px;
  right:24%;
  bottom:-330px;
}
body.landing-page .landing-strip{
  margin-top:16px;
  display:grid;
  grid-template-columns:repeat(3,minmax(0,1fr));
  gap:12px;
}
body.landing-page .strip-card{
  border:1px solid #2a3b61;
  border-radius:18px;
  padding:18px;
  background:linear-gradient(180deg,#111b35cb 0%, #0c1428c6 100%);
}
body.landing-page .strip-card h3{
  margin:0 0 8px;
  font-family:"Orbitron","Space Grotesk","Segoe UI",sans-serif;
  font-size:18px;
}
body.landing-page .strip-card p{
  margin:0;
  color:#b8c6ed;
  line-height:1.45;
}
body.auth-page{
  min-height:100vh;
  background:
    radial-gradient(780px 480px at 12% -10%, #2e80ff3f 0%, #00000000 64%),
    radial-gradient(880px 520px at 90% -15%, #33e0ff2f 0%, #00000000 66%),
    linear-gradient(180deg, #060b18 0%, #071027 100%);
  background-repeat:no-repeat,no-repeat,no-repeat;
  background-size:100% 100%,100% 100%,100% 100%;
  background-attachment:fixed,fixed,fixed;
}
body.auth-page .container{
  max-width:980px;
  padding:30px 20px 36px;
}
body.auth-page .auth-shell{
  position:relative;
  min-height:72vh;
  display:flex;
  align-items:center;
  justify-content:center;
}
body.auth-page .auth-aurora{
  position:absolute;
  width:min(84vw, 760px);
  aspect-ratio:1/1;
  border-radius:50%;
  background:
    radial-gradient(circle at 36% 30%, #5ab9ff42 0%, #00000000 46%),
    radial-gradient(circle at 66% 68%, #8f5dff38 0%, #00000000 48%),
    radial-gradient(circle at 50% 50%, #2f6bff24 0%, #00000000 70%);
  filter:blur(2px);
}
body.auth-page .auth-card{
  position:relative;
  z-index:2;
  width:min(100%, 560px);
  padding:34px;
  border-radius:24px;
  border:1px solid #334a76;
  background:linear-gradient(160deg, #101b36f4 0%, #0b162de9 100%);
  box-shadow:0 22px 50px #01040d88;
}
body.auth-page .auth-kicker{
  margin:0 0 12px;
  color:#99d8ff;
  font-size:12px;
  letter-spacing:.22em;
  text-transform:uppercase;
}
body.auth-page .auth-card h1{
  margin:0 0 12px;
  font-family:"Orbitron","Space Grotesk","Segoe UI",sans-serif;
  line-height:1.12;
  font-size:clamp(30px, 4vw, 44px);
}
body.auth-page .auth-card .muted{
  color:#c0cdf3;
  font-size:17px;
  line-height:1.5;
}
body.auth-page .auth-google-btn{
  margin-top:18px;
  width:100%;
  text-align:center;
  border-radius:14px;
  padding:12px 14px;
  font-size:16px;
  color:#f8fbff;
  background:linear-gradient(95deg,#3db8ff 0%, #5b8cff 52%, #a56dff 100%);
}
@keyframes orbitPulse{
  0%,100%{transform:scale(1);opacity:.86}
  50%{transform:scale(1.03);opacity:1}
}
@media(max-width:980px){
  body.landing-page,
  body.auth-page,
  body.dashboard-page{
    background-attachment:scroll,scroll,scroll;
  }
  body.landing-page .landing-orbit{
    display:none;
  }
  body.landing-page .landing-hero{
    grid-template-columns:1fr;
    min-height:0;
    padding:24px;
  }
  body.landing-page .landing-preview{
    width:min(100%, 420px);
    justify-self:start;
  }
  body.landing-page .landing-strip{
    grid-template-columns:1fr;
  }
}
@media(max-width:640px){
  body.landing-page .container,
  body.auth-page .container{
    padding:20px 12px 24px;
  }
  body.landing-page .landing-hero,
  body.auth-page .auth-card{
    padding:18px;
    border-radius:18px;
  }
  body.landing-page .hero-subtitle,
  body.auth-page .auth-card .muted{
    font-size:15px;
  }
  body.landing-page .hero-actions{
    width:100%;
    flex-direction:column;
    align-items:stretch;
  }
  body.landing-page .hero-actions .btn{
    width:100%;
    text-align:center;
  }
}

body.dashboard-page{
  background:
    radial-gradient(840px 420px at 14% -10%, #2d61ff2b 0%, #00000000 58%),
    radial-gradient(900px 500px at 88% -15%, #33dfff24 0%, #00000000 60%),
    linear-gradient(180deg, #080f22 0%, #0a1228 100%);
  background-repeat:no-repeat,no-repeat,no-repeat;
  background-size:100% 100%,100% 100%,100% 100%;
  background-attachment:fixed,fixed,fixed;
}
body.dashboard-page .topbar{
  background:rgba(7,12,26,.76);
  border-bottom:1px solid #2a3b61;
  backdrop-filter:blur(10px);
}
body.dashboard-page .container{
  padding:24px 18px 26px;
}
body.dashboard-page .card{
  border-color:#2a3c64;
  background:linear-gradient(170deg, #131f3dcf 0%, #0f1a32cf 100%);
}
body.dashboard-page .list-item{
  border-color:#2f436f;
  background:#152240;
}
body.dashboard-page .btn.primary{
  background:linear-gradient(95deg,#47beff 0%, #5b8cff 52%, #986dff 100%);
  color:#f8fbff;
}

body.editor-page{
  font-family:"Space Grotesk","Segoe UI",sans-serif;
  background:
    radial-gradient(1200px 600px at 50% -10%, #1a2336 0%, #0a0f1e 52%, #070b15 100%);
}
body.editor-page .topbar{
  border-bottom:1px solid #263355;
  background:rgba(7,11,21,.72);
  backdrop-filter:blur(12px);
}
body.editor-page .brand a{
  font-size:24px;
  font-weight:800;
  letter-spacing:.2px;
}
body.editor-page .pill{
  border-color:#2d395a;
  background:#10182f;
  color:#c7d4ff;
}
body.editor-page .container{
  max-width:none;
  height:calc(100vh - 82px);
  min-height:720px;
  padding:12px;
}
body.editor-page .editor-shell{
  --hud-top-offset:132px;
  position:relative;
  height:100%;
  min-height:680px;
  display:block;
}
body.editor-page .toolbar-card{
  position:absolute;
  z-index:35;
  left:14px;
  right:14px;
  top:10px;
  border-radius:18px;
  border-color:#2b3657;
  background:rgba(10,16,29,.82);
  backdrop-filter:blur(14px);
  box-shadow:0 20px 40px #02040966;
}
body.editor-page .toolbar-top{align-items:center}
body.editor-page .toolbar-top h1{
  margin:0 0 4px;
  font-size:24px;
  font-weight:800;
}
body.editor-page .toolbar-actions .btn{
  border-radius:999px;
  padding:10px 16px;
}
body.editor-page .toolbar-actions .btn.primary{
  background:linear-gradient(90deg,#2e8cff,#4fa7ff);
  color:#f6fbff;
  font-weight:800;
}
body.editor-page .advanced-panel{
  margin-top:10px;
  border-top:1px solid #2a3554;
  padding-top:10px;
}
body.editor-page .advanced-panel summary{
  width:40px;
  height:40px;
  display:inline-flex;
  align-items:center;
  justify-content:center;
  cursor:pointer;
  color:#c8d4fa;
  font-weight:700;
  font-size:13px;
  padding:0;
  border:1px solid #2d3c62;
  border-radius:999px;
  background:#111a31;
  list-style:none;
}
body.editor-page .advanced-panel summary .advanced-summary-icon{
  width:19px;
  height:19px;
  display:inline-flex;
}
body.editor-page .advanced-panel summary .advanced-summary-icon svg{
  width:100%;
  height:100%;
  fill:none;
  stroke:currentColor;
  stroke-width:1.6;
  stroke-linecap:round;
  stroke-linejoin:round;
}
body.editor-page .advanced-panel summary::-webkit-details-marker{display:none}
body.editor-page .advanced-panel[open] summary{
  background:#172444;
  color:#e6eeff;
}
body.editor-page .toolbar-grid{
  margin-top:12px;
  grid-template-columns:repeat(5,minmax(130px,1fr));
}
body.editor-page .advanced-panel .export-control{
  display:none;
}
body.editor-page .editor-main{
  position:relative;
  height:100%;
  display:block;
}
body.editor-page .preview-card{
  position:absolute;
  inset:0;
  border-radius:24px;
  padding:0;
  overflow:hidden;
  border-color:#25314e;
  background:#05080f;
}
body.editor-page .preview-card > h3{display:none}
body.editor-page .map-host{
  position:absolute;
  inset:0;
  width:100%;
  height:100%;
  margin:0;
  aspect-ratio:auto;
  filter:none;
}
body.editor-page .map{
  width:100%;
  height:100%;
  border:none;
  border-radius:0;
}
body.editor-page .map-glow{
  border-radius:0;
  border:none;
  background:
    radial-gradient(1200px 760px at 50% -10%, #ffffff15 0%, #00000000 62%),
    linear-gradient(180deg, #0b0f19d6 0%, #00000000 18%, #00000000 70%, #070b15d4 100%);
  box-shadow:none;
}
body.editor-page .left-stack{
  position:absolute;
  z-index:30;
  left:18px;
  top:calc(var(--hud-top-offset) + 12px);
  width:min(360px,calc(100% - 36px));
  max-height:calc(100% - 220px);
  gap:12px;
}
body.editor-page .left-stack > .card{
  border-color:#2a3552;
  background:rgba(11,17,30,.82);
  backdrop-filter:blur(10px);
}
body.editor-page .stops-card{display:flex;flex-direction:column;min-height:0}
body.editor-page #stopsList{
  flex:1;
  max-height:none;
  min-height:120px;
}
body.editor-page .audio-card{
  max-height:210px;
  overflow:auto;
}
body.editor-page .list-item{
  border-radius:18px;
  border-color:#2f3d5f;
  background:#171f34;
}
body.editor-page .list-item .title{
  max-width:165px;
  font-size:18px;
  font-weight:800;
}
body.editor-page .actions .btn{
  padding:8px 10px;
  border-radius:10px;
  font-size:12px;
}
body.editor-page .place-suggest{
  border-color:#34466f;
  background:#111a31;
  box-shadow:0 16px 26px #03060f7a;
}
body.editor-page .place-suggest-item{
  border-bottom-color:#283759;
}
body.editor-page .place-suggest-item:hover,
body.editor-page .place-suggest-item.active{
  background:#1d2c50;
}
body.editor-page .map-controls-top{
  position:absolute;
  z-index:31;
  right:18px;
  top:calc(var(--hud-top-offset) + 12px);
  margin:0;
  padding:8px 10px;
  border:1px solid #2d3958;
  border-radius:14px;
  background:rgba(11,16,28,.78);
  backdrop-filter:blur(8px);
}
body.editor-page .map-controls-top .btn{
  border-radius:999px;
  padding:8px 12px;
}
body.editor-page .map-controls{
  position:absolute;
  z-index:31;
  right:18px;
  top:calc(var(--hud-top-offset) + 68px);
  width:250px;
  margin:0;
  border-color:#2d3a59;
  background:rgba(9,14,25,.84);
  backdrop-filter:blur(8px);
}
body.editor-page .timeline-wrap{
  position:absolute;
  z-index:31;
  left:50%;
  transform:translateX(-50%);
  bottom:18px;
  width:min(920px,calc(100% - 36px));
  margin:0;
  border-radius:16px;
  border-color:#2d3a57;
  background:rgba(13,20,35,.84);
  backdrop-filter:blur(12px);
}
body.editor-page .timeline-top{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:12px;
}
body.editor-page .timeline-top-right{
  display:flex;
  align-items:center;
  gap:8px;
}
body.editor-page .timeline-top-right .btn{
  border-radius:999px;
  padding:6px 10px;
  font-size:12px;
}
body.editor-page .timeline-body{margin-top:8px}
body.editor-page .timeline-wrap.collapsed{
  left:auto;
  right:18px;
  transform:none;
  width:min(350px,calc(100% - 36px));
}
body.editor-page .timeline-wrap.collapsed .timeline-body{
  display:none;
}
body.editor-page .timeline-wrap .row .btn{
  border-radius:10px;
  padding:8px 10px;
}
body.editor-page #status{
  position:absolute;
  z-index:32;
  left:50%;
  transform:translateX(-50%);
  bottom:160px;
  margin:0;
  padding:6px 10px;
  border-radius:10px;
  background:rgba(5,9,16,.6);
  border:1px solid #2a3551;
  min-height:0;
}
body.editor-page .timeline-wrap.collapsed ~ #status{
  bottom:84px;
}
body.editor-page .app-modal{
  position:fixed;
  inset:0;
  z-index:120;
  display:none;
}
body.editor-page .app-modal.open{
  display:block;
}
body.editor-page .app-modal-backdrop{
  position:absolute;
  inset:0;
  background:rgba(2,6,14,.72);
  backdrop-filter:blur(8px);
}
body.editor-page .app-modal-dialog{
  position:relative;
  width:min(720px,calc(100% - 24px));
  margin:56px auto 0;
  padding:18px;
  border-radius:18px;
  border:1px solid #30426c;
  background:linear-gradient(165deg,#101a34f5 0%,#0b152eea 100%);
  box-shadow:0 30px 60px #01040c80;
}
body.editor-page .modal-header-row{
  display:flex;
  align-items:flex-start;
  justify-content:space-between;
  gap:12px;
}
body.editor-page .project-history-toolbar{
  margin-top:14px;
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:12px;
  flex-wrap:wrap;
}
body.editor-page .project-history-list{
  margin-top:14px;
  display:flex;
  flex-direction:column;
  gap:10px;
  max-height:430px;
  overflow:auto;
}
body.editor-page .project-history-item{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:12px;
  padding:12px;
  border:1px solid #30426a;
  border-radius:16px;
  background:#111a31;
}
body.editor-page .project-history-copy{
  min-width:0;
  display:flex;
  flex-direction:column;
  gap:4px;
}
body.editor-page .project-history-title{
  font-size:17px;
  font-weight:800;
  overflow:hidden;
  text-overflow:ellipsis;
  white-space:nowrap;
}
body.editor-page .project-history-meta{
  color:#b6c7f5;
  font-size:12px;
}
body.editor-page .project-history-actions{
  display:flex;
  align-items:center;
  gap:8px;
  flex-wrap:wrap;
  justify-content:flex-end;
}
body.editor-page .auth-required-dialog{
  width:min(500px,calc(100% - 24px));
}
body.editor-page .export-grid{
  margin-top:12px;
  display:grid;
  grid-template-columns:repeat(2,minmax(0,1fr));
  gap:10px;
}
body.editor-page .export-estimate{
  margin-top:12px;
  padding:8px 10px;
  border-radius:10px;
  border:1px solid #2c3d63;
  background:#0d1630;
}
body.editor-page .export-actions{
  justify-content:flex-end;
  margin-top:14px;
}
body.editor-page .export-progress-track{
  width:100%;
  height:13px;
  border-radius:999px;
  overflow:hidden;
  border:1px solid #2e3f67;
  background:#0b1225;
  margin-top:10px;
}
body.editor-page .export-progress-fill{
  width:0%;
  height:100%;
  background:linear-gradient(90deg,#3ec1ff 0%,#5b8cff 55%,#8f7bff 100%);
  box-shadow:0 0 16px #4fa7ff88;
  transition:width .2s ease;
}
body.editor-page .export-progress-value{
  margin-top:10px;
  font-size:34px;
  font-weight:800;
  letter-spacing:.02em;
}
@media(max-width:1280px){
  body.editor-page .toolbar-grid{grid-template-columns:repeat(4,minmax(120px,1fr))}
  body.editor-page .left-stack{max-height:calc(100% - 240px)}
}
@media(max-width:980px){
  body.editor-page .topbar{
    display:none;
  }
  body.editor-page .container{
    max-width:none;
    width:100%;
    height:var(--app-viewport-height, 100dvh);
    min-height:var(--app-viewport-height, 100dvh);
    padding:0;
    padding-top:env(safe-area-inset-top);
    margin:0;
  }
  body.editor-page .editor-shell{
    --hud-top-offset:56px;
    position:relative;
    width:100%;
    height:100%;
    min-height:100%;
    display:block;
  }
  body.editor-page .toolbar-card{
    position:absolute;
    z-index:60;
    left:8px;
    right:8px;
    top:calc(8px + env(safe-area-inset-top));
    padding:8px 10px;
    border-radius:14px;
    border-color:#31446d;
    background:rgba(9,14,25,.78);
    backdrop-filter:blur(10px);
    box-shadow:0 12px 26px #02050d66;
  }
  body.editor-page .toolbar-top{
    display:flex;
    align-items:center;
    justify-content:flex-end;
    gap:8px;
  }
  body.editor-page .toolbar-top > div:first-child{
    display:none;
  }
  body.editor-page .toolbar-actions{
    width:100%;
    display:flex;
    justify-content:flex-end;
    gap:8px;
    flex-wrap:nowrap;
  }
  body.editor-page .toolbar-actions .btn{
    flex:0 0 auto;
    min-width:0;
    min-height:34px;
    padding:7px 10px;
    border-radius:999px;
    font-size:13px;
    line-height:1.1;
  }
  body.editor-page .toolbar-actions #exportBtn{
    order:-1;
    padding:8px 14px;
    font-weight:800;
  }
  body.editor-page .advanced-panel{
    display:none;
  }
  body.editor-page .editor-main{
    position:relative;
    width:100%;
    height:100%;
    display:block;
  }
  body.editor-page .preview-card{
    position:absolute;
    inset:0;
    border:none;
    border-radius:0;
    background:#05080f;
    padding:0;
    overflow:hidden;
  }
  body.editor-page .preview-card > h3{
    display:none;
  }
  body.editor-page .map-host{
    position:absolute;
    inset:0;
    width:100%;
    height:100%;
    filter:none;
  }
  body.editor-page .map{
    width:100%;
    height:100%;
    border:none;
    border-radius:0;
  }
  body.editor-page .map-glow{
    border:none;
    border-radius:0;
    background:
      radial-gradient(900px 420px at 50% -8%, #ffffff12 0%, #00000000 58%),
      linear-gradient(180deg,#0f17289a 0%,#00000000 24%,#00000000 74%,#080d18cc 100%);
  }
  body.editor-page .left-stack{
    position:absolute;
    z-index:55;
    left:8px;
    right:auto;
    top:calc(var(--hud-top-offset) + 10px);
    bottom:auto;
    width:min(360px,calc(100% - 16px));
    max-height:min(38dvh,280px);
    overflow:auto;
    gap:6px;
    overscroll-behavior:contain;
    transition:max-height .22s ease, top .22s ease, bottom .22s ease;
  }
  body.editor-page .left-stack > .card{
    border:none;
    background:transparent;
    backdrop-filter:none;
    box-shadow:none;
    padding:0;
    transition:none;
  }
  body.editor-page .stops-card h3{
    display:none;
  }
  body.editor-page .stops-card .row{
    gap:6px;
    flex-wrap:nowrap;
    align-items:center;
  }
  body.editor-page .stops-card .row input{
    min-width:0;
  }
  body.editor-page .stops-card .row .btn{
    width:auto;
    padding:0 12px;
    min-height:40px;
    font-size:12px;
    border-radius:999px;
  }
  body.editor-page #stopsList{
    max-height:132px;
    overflow:auto;
  }
  body.editor-page .list-item{
    padding:6px 8px;
    border-radius:999px;
    border:none;
    background:rgba(15,20,32,.58);
    backdrop-filter:blur(8px);
    display:grid;
    grid-template-columns:minmax(0,1fr) auto;
    align-items:center;
    gap:8px;
  }
  body.editor-page .list-item-main{
    min-width:0;
  }
  body.editor-page .list-item-copy{
    gap:2px;
  }
  body.editor-page .list-item .title{
    max-width:none;
    font-size:14px;
    white-space:nowrap;
    overflow:hidden;
    text-overflow:ellipsis;
  }
  body.editor-page .actions{
    gap:4px;
    flex-wrap:nowrap;
    margin-left:0;
    justify-self:end;
  }
  body.editor-page .actions .btn{
    min-width:0;
    min-height:26px;
    padding:0 7px;
    border-radius:999px;
    font-size:10px;
  }
  body.editor-page .stop-transport-row{
    gap:6px;
    padding-top:4px;
    border-top:none;
  }
  body.editor-page .stop-transport-row label{
    display:none;
  }
  body.editor-page .segment-transport-select{
    min-width:96px;
    max-width:none;
    width:auto;
    font-size:11px;
    min-height:28px;
    padding:4px 10px;
    border-radius:999px;
  }
  body.editor-page .map-controls-top,
  body.editor-page .map-controls,
  body.editor-page .timeline-wrap{
    display:none !important;
  }
  body.editor-page #status{
    display:none;
  }
  body.editor-page .app-modal-dialog{
    width:min(560px,calc(100% - 16px));
    margin:10px auto 0;
    padding:14px;
    max-height:calc(100dvh - 24px);
    overflow:auto;
    overscroll-behavior:contain;
  }
  body.editor-page .export-grid{
    grid-template-columns:1fr;
  }
  body.editor-page .export-actions{
    flex-wrap:wrap;
  }
  body.editor-page .project-history-item{
    flex-direction:column;
    align-items:flex-start;
  }
  body.editor-page .project-history-actions{
    width:100%;
    justify-content:flex-start;
  }
  body.editor-page .map-glow{
    background:
      radial-gradient(700px 340px at 50% 0%, #ffffff18 0%, #00000000 58%),
      linear-gradient(180deg,#10172a9a 0%,#00000000 24%,#00000000 74%,#080d18c2 100%);
  }
}
@media(max-width:640px){
  body.editor-page .toolbar-card{
    left:6px;
    right:6px;
    top:calc(6px + env(safe-area-inset-top));
    padding:7px 8px;
    border-radius:12px;
  }
  body.editor-page .toolbar-actions{
    gap:6px;
  }
  body.editor-page .toolbar-actions .btn{
    padding:6px 9px;
    min-height:32px;
    font-size:12px;
  }
  body.editor-page .toolbar-actions #exportBtn{
    padding:7px 12px;
  }
  body.editor-page .left-stack{
    left:6px;
    right:auto;
    top:calc(var(--hud-top-offset) + 8px);
    bottom:auto;
    width:calc(100% - 12px);
    max-height:min(34dvh,240px);
  }
  body.editor-page .left-stack > .card{
    padding:0;
  }
  body.editor-page .stops-card p.muted.small{
    display:none;
  }
  body.editor-page .list-item .title{
    font-size:13px;
    max-width:118px;
  }
  body.editor-page .actions .btn{
    min-height:24px;
    padding:0 6px;
    font-size:10px;
  }
  body.editor-page .place-suggest-item .meta{
    font-size:12px;
  }
  body.editor-page .app-modal-dialog{
    width:calc(100% - 10px);
    margin:4px auto 0;
    border-radius:12px;
    padding:10px;
    max-height:calc(100dvh - 12px);
    padding-bottom:calc(12px + env(safe-area-inset-bottom));
  }
  body.editor-page .export-actions{
    flex-direction:column-reverse;
    align-items:stretch;
  }
  body.editor-page .export-actions .btn{
    width:100%;
    text-align:center;
  }
  body.editor-page .export-progress-value{
    font-size:28px;
  }
  body.editor-page .right .pill:last-of-type{
    display:none;
  }
  body.editor-page .modal-header-row,
  body.editor-page .project-history-toolbar{
    flex-direction:column;
    align-items:stretch;
  }
}
/* Landing extras */
body.landing-page .hero-free-note{
  margin:10px 0 0;
  font-size:13px;
  color:#6a88b8;
  letter-spacing:.01em;
}
body.landing-page .landing-social-proof{
  margin-top:14px;
  display:flex;
  gap:8px;
  flex-wrap:wrap;
}
body.landing-page .proof-pill{
  display:inline-flex;
  align-items:center;
  gap:5px;
  padding:5px 12px;
  border:1px solid #22334e;
  border-radius:999px;
  font-size:12px;
  color:#8da8c8;
  background:#0b1628;
}
body.landing-page .landing-footer{
  margin-top:30px;
  padding:16px 0;
  border-top:1px solid #162340;
  display:flex;
  align-items:center;
  justify-content:space-between;
  flex-wrap:wrap;
  gap:8px;
}
body.landing-page .landing-footer span{
  color:#485e80;
  font-size:13px;
}
/* Dashboard improvements */
.empty-state{
  display:flex;
  flex-direction:column;
  align-items:center;
  gap:8px;
  padding:28px 12px;
  text-align:center;
}
.empty-state .empty-icon{font-size:28px;opacity:.4}
.empty-state .empty-title{font-size:15px;font-weight:700}
.empty-state .empty-sub{
  color:var(--muted);
  font-size:13px;
  max-width:220px;
  line-height:1.45;
}
body.dashboard-page .list-item{
  transition:background .14s,border-color .14s,transform .1s;
}
body.dashboard-page .list-item:hover{
  border-color:#374c78;
  background:#1b2d50;
  transform:translateY(-1px);
}
/* Plus plan badge */
.pill-plus{
  border-color:#6c50c266!important;
  color:#c4aaff!important;
  background:#160d30!important;
}
/* Editor: merge play/stop — show stop as a state change on playBtn instead */
body.editor-page #stopBtn{display:none}

@media(max-width:980px){
  input:not([type="range"]):not([type="checkbox"]):not([type="radio"]),
  select,
  textarea{
    font-size:16px;
    line-height:1.25;
  }
  body.editor-page .stops-card{
    gap:8px;
  }
  body.editor-page .stops-card:focus-within{
    background:transparent;
    box-shadow:none;
  }
  body.editor-page .stops-card .row{
    display:grid;
    grid-template-columns:minmax(0,1fr) auto;
    align-items:stretch;
    gap:6px;
  }
  body.editor-page #placeName{
    border-radius:18px;
    padding-left:46px;
    background-image:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23c7d4ff' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='11' cy='11' r='7'/%3E%3Cpath d='m20 20-3.5-3.5'/%3E%3C/svg%3E");
    background-repeat:no-repeat;
    background-position:16px 50%;
    background-size:18px 18px;
  }
  body.editor-page .stops-card .row input{
    min-height:40px;
    padding:10px 14px;
    background-color:rgba(16,23,39,.74);
    border-color:#2a3653;
    box-shadow:none;
  }
  body.editor-page .stops-card .row .btn{
    align-self:stretch;
    min-height:40px;
    padding:0 12px;
    display:inline-flex;
    align-items:center;
    justify-content:center;
    background:rgba(74,139,255,.94);
    color:#eef5ff;
  }
  body.editor-page .place-suggest{
    margin-top:6px;
    max-height:min(28dvh,220px);
    overflow:auto;
    border:none;
    border-radius:18px;
    background:rgba(14,20,34,.72);
    backdrop-filter:blur(10px);
    box-shadow:0 10px 24px #03060f54;
  }
  body.editor-page .place-suggest-item{
    padding:10px 12px;
  }
  body.editor-page.mobile-input-focus .left-stack{
    top:calc(var(--hud-top-offset) + 8px);
    bottom:auto;
    max-height:min(44dvh,320px);
  }
  body.editor-page.mobile-input-focus{
    overflow:hidden;
  }
  body.editor-page.mobile-input-focus .container{
    overflow:hidden;
  }
}
