/* Premium Mobile-First UI */
:root{
  --bg: #020617;      /* slate-950 */
  --card: rgba(255,255,255,.06);
  --card2: rgba(255,255,255,.08);
  --border: rgba(255,255,255,.10);
  --muted: rgba(226,232,240,.75);
  --muted2: rgba(226,232,240,.6);
  --shadow: 0 18px 60px rgba(0,0,0,.45);
}

html, body { background: var(--bg); }

/* Subtle animated background glow */
.bg-glow{
  position: fixed;
  inset: -20%;
  z-index: -1;
  background:
    radial-gradient(60% 40% at 20% 20%, rgba(99,102,241,.26), transparent 60%),
    radial-gradient(50% 35% at 80% 30%, rgba(236,72,153,.16), transparent 65%),
    radial-gradient(50% 35% at 40% 85%, rgba(34,197,94,.10), transparent 60%);
  filter: blur(20px);
  opacity: .9;
}

.glass{
  background: var(--card);
  border: 1px solid var(--border);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  box-shadow: var(--shadow);
}

.glass-soft{
  background: rgba(255,255,255,.04);
  border: 1px solid var(--border);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
}

.pill{
  border: 1px solid var(--border);
  background: rgba(255,255,255,.06);
  padding: .35rem .6rem;
  border-radius: 999px;
}

.btn{
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 1rem;
  padding: .85rem 1.05rem;
  font-weight: 600;
  letter-spacing: .01em;
  transition: transform .08s ease, opacity .12s ease, background .12s ease;
  user-select: none;
}
.btn:active{ transform: scale(.98); }

.btn-primary{
  background: rgba(99,102,241,.95);
  border: 1px solid rgba(99,102,241,.45);
}
.btn-primary:hover{ background: rgba(99,102,241,1); }

.btn-secondary{
  background: rgba(255,255,255,.06);
  border: 1px solid var(--border);
}
.btn-secondary:hover{ background: rgba(255,255,255,.10); }

.btn-ghost{
  background: transparent;
  border: 1px solid var(--border);
}
.btn-ghost:hover{ background: rgba(255,255,255,.06); }

.kbd{
  font-size: .75rem;
  border-radius: .6rem;
  padding: .2rem .45rem;
  border: 1px solid var(--border);
  background: rgba(255,255,255,.06);
}

.small-muted{ color: var(--muted2); }
.lead-muted{ color: var(--muted); }

.card-hover{
  transition: transform .12s ease, background .12s ease, border-color .12s ease;
}
.card-hover:hover{
  transform: translateY(-2px);
  background: rgba(255,255,255,.08);
  border-color: rgba(255,255,255,.14);
}

/* Nice text rendering */
h1,h2,h3{ text-wrap: balance; }
p{ text-wrap: pretty; }

/* Make forms look consistent everywhere */
input, select, textarea{
  width: 100%;
  border-radius: 1rem;
  background: rgba(15,23,42,.60);
  border: 1px solid var(--border);
  padding: .8rem 1rem;
  outline: none;
}
input:focus, select:focus, textarea:focus{
  box-shadow: 0 0 0 2px rgba(99,102,241,.65);
}

hr.soft{
  border: none;
  height: 1px;
  background: rgba(255,255,255,.10);
}

/* Prevent accidental horizontal scroll on mobile */
html, body { max-width: 100%; overflow-x: hidden; }

/* Mobile nav dropdown: make it readable over the glow */
.mobile-menu{
  background: rgba(2, 6, 23, 0.96);           /* slate-950-ish, nearly opaque */
  border: 1px solid rgba(255,255,255,0.18);
  box-shadow: 0 18px 60px rgba(0,0,0,0.65);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
}

/* Ensure links inside dropdown are full-width and readable */
.mobile-menu a{
  width: 100%;
}

/* Mobile nav dropdown: make it readable over the glow */
.mobile-menu{
  background: rgba(2, 6, 23, 0.96);           /* slate-950-ish, nearly opaque */
  border: 1px solid rgba(255,255,255,0.18);
  box-shadow: 0 18px 60px rgba(0,0,0,0.65);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
}

/* Ensure links inside dropdown are full-width and readable */
.mobile-menu a{
  width: 100%;
}

/* ---------- Global mobile overflow safety ---------- */
html, body { max-width: 100%; overflow-x: hidden; }
main { max-width: 100%; overflow-x: hidden; }

/* Utility: force long text to wrap without breaking layout */
.safe-wrap{
  overflow-wrap: anywhere;
  word-break: break-word;
}

/* Make common containers never exceed viewport */
.glass, .glass-soft { max-width: 100%; }

/* --- Mobile overflow guards --- */
html, body { max-width: 100%; overflow-x: hidden; }
.glass, .glass-soft { overflow: hidden; }
.truncate, .min-w-0 { min-width: 0; }
.break-anywhere { overflow-wrap: anywhere; word-break: break-word; }




