:root {
  --ink: #0A0E13;
  --panel: #121821;
  --panel2: #0E141B;
  --card: #161E29;
  --line: #212C39;
  --text: #EAF0F6;
  --muted: #8493A4;
  --dim: #5C6B7C;
  --lime: #C6F24E;
  --teal: #36E6C8;
  --gold: #F2C14E;
  --red: #F2685C;
  --green: #5BD17A;
  --blue: #5BA8F2;
}
* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; background: var(--ink); color: var(--text); font-family: 'Manrope', -apple-system, BlinkMacSystemFont, sans-serif; min-height: 100vh; }
body { font-feature-settings: 'cv02','cv03','cv04','cv11'; }
.fd { font-family: 'Bricolage Grotesque', 'Manrope', sans-serif; letter-spacing: -.01em; }
*::-webkit-scrollbar { height: 8px; width: 8px; }
*::-webkit-scrollbar-thumb { background: var(--line); border-radius: 4px; }
*::-webkit-scrollbar-track { background: transparent; }

a { color: inherit; }
button { cursor: pointer; }
.muted { color: var(--muted); }
.dim { color: var(--dim); }

.container { max-width: 1180px; margin: 0 auto; padding: 0 1rem; }
@media (min-width: 640px) { .container { padding: 0 1.5rem; } }

.btn { display: inline-flex; align-items: center; justify-content: center; gap: .5rem; border-radius: .75rem; padding: .65rem 1.1rem; font-weight: 700; font-size: .9rem; border: 1px solid transparent; transition: transform .12s, background .12s; font-family: inherit; }
.btn:active { transform: scale(.98); }
.btn-primary { background: var(--lime); color: var(--ink); }
.btn-primary:hover { background: #d2ff5a; }
.btn-ghost { background: transparent; color: var(--text); border-color: var(--line); }
.btn-ghost:hover { background: rgba(255,255,255,.04); }
.btn-soft { background: rgba(54,230,200,.1); color: var(--teal); border-color: rgba(54,230,200,.4); }
.btn-soft:hover { background: rgba(54,230,200,.18); }
.btn-danger { background: rgba(242,104,92,.1); color: var(--red); border-color: rgba(242,104,92,.4); }
.btn:disabled { opacity: .45; cursor: not-allowed; }

.card { background: var(--panel); border: 1px solid var(--line); border-radius: 1rem; padding: 1rem; }
.card-tight { padding: .75rem; }
.panel2 { background: var(--panel2); }

.input, select, textarea {
  width: 100%; border-radius: .75rem; padding: .65rem .9rem; font-size: .9rem; outline: none;
  background: var(--panel2); color: var(--text); border: 1px solid var(--line); font-family: inherit;
}
.input:focus { border-color: rgba(198,242,78,.6); }
label.field { display: block; margin-bottom: .9rem; }
label.field > span { display: block; font-size: .72rem; font-weight: 700; color: var(--muted); text-transform: uppercase; letter-spacing: .04em; margin-bottom: .35rem; }

.badge { display: inline-flex; align-items: center; gap: .25rem; border-radius: 9999px; padding: .15rem .55rem; font-size: .7rem; font-weight: 700; border: 1px solid currentColor; }
.badge.b-solid { color: var(--ink); border-color: transparent; }

.grid-courts { display: grid; gap: .5rem; }
.slot-btn { background: var(--panel2); border: 1px solid var(--line); border-radius: .55rem; padding: .55rem .2rem; font-weight: 700; font-size: .75rem; color: var(--text); font-family: inherit; }
.slot-btn.peak { color: var(--gold); border-color: rgba(242,193,78,.4); }
.slot-btn.busy { background: var(--line); color: var(--dim); text-decoration: line-through; cursor: not-allowed; }
.slot-btn.selected { background: var(--lime); color: var(--ink); border-color: var(--lime); }
.slot-btn.in-range { background: rgba(198,242,78,.15); color: var(--lime); border-color: rgba(198,242,78,.4); }
.slot-btn:hover:not(:disabled):not(.busy) { border-color: rgba(198,242,78,.5); }

.header { position: sticky; top: 0; z-index: 40; background: rgba(10,14,19,.82); backdrop-filter: blur(10px); border-bottom: 1px solid var(--line); padding: .75rem 1rem; display: flex; align-items: center; justify-content: space-between; gap: 1rem; }
.brand { display: inline-flex; align-items: center; gap: .6rem; }
.brand-mark { width: 36px; height: 36px; border-radius: .75rem; background: var(--lime); display: grid; place-items: center; color: var(--ink); }
.brand-name { font-family: 'Bricolage Grotesque', sans-serif; font-weight: 800; font-size: 1.2rem; letter-spacing: -.02em; }
.brand-sub { font-size: .65rem; color: var(--dim); margin-top: 1px; }

.hero {
  position: relative; min-height: 540px; display: flex; align-items: center;
  background: linear-gradient(180deg, rgba(10,14,19,.25), rgba(10,14,19,.95)),
              url('/assets/hero.jpg') center/cover no-repeat;
  border-bottom: 1px solid var(--line);
}
.hero-inner { padding: 4rem 1rem 5rem; }
.hero h1 { font-family: 'Bricolage Grotesque', sans-serif; font-weight: 800; font-size: clamp(2.4rem, 6vw, 4.2rem); letter-spacing: -.025em; line-height: 1.02; margin: 0 0 1.2rem; }
.hero h1 .accent { color: var(--lime); }
.hero p.lead { font-size: 1.1rem; color: rgba(234,240,246,.85); max-width: 540px; margin: 0 0 2rem; line-height: 1.55; }

.section { padding: 3rem 0; }
.section h2 { font-family: 'Bricolage Grotesque', sans-serif; font-weight: 800; font-size: clamp(1.7rem, 4vw, 2.4rem); letter-spacing: -.02em; margin: 0 0 .4rem; }
.section .lead { color: var(--muted); margin: 0 0 1.6rem; max-width: 620px; }

.feat-grid { display: grid; gap: 1rem; grid-template-columns: 1fr; }
@media (min-width: 768px) { .feat-grid { grid-template-columns: repeat(3, 1fr); } }

.gallery { display: grid; gap: .75rem; grid-template-columns: repeat(2, 1fr); }
@media (min-width: 768px) { .gallery { grid-template-columns: repeat(4, 1fr); } }
.gallery img { width: 100%; aspect-ratio: 1/1; object-fit: cover; border-radius: .75rem; border: 1px solid var(--line); }

footer { padding: 2rem 1rem; border-top: 1px solid var(--line); color: var(--muted); font-size: .85rem; text-align: center; }
footer a { color: var(--muted); }

.modal-backdrop { position: fixed; inset: 0; z-index: 50; background: rgba(5,8,11,.72); backdrop-filter: blur(4px); display: none; align-items: center; justify-content: center; padding: 1rem; }
.modal-backdrop.open { display: flex; }
.modal { background: var(--panel); border: 1px solid var(--line); border-radius: 1.2rem; max-width: 540px; width: 100%; padding: 1.4rem; max-height: 90vh; overflow-y: auto; }
.modal-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 1rem; }
.modal-head .title { font-family: 'Bricolage Grotesque', sans-serif; font-weight: 700; font-size: 1.15rem; }
.modal-close { background: transparent; color: var(--muted); border: 1px solid var(--line); padding: .35rem; border-radius: .5rem; }

.toast { position: fixed; left: 50%; bottom: 1.5rem; transform: translateX(-50%); background: var(--lime); color: var(--ink); padding: .7rem 1rem; border-radius: .8rem; font-weight: 700; font-size: .9rem; z-index: 80; display: none; box-shadow: 0 8px 30px rgba(0,0,0,.4); }
.toast.show { display: block; animation: fadeUp .3s ease both; }
@keyframes fadeUp { from { opacity: 0; transform: translateX(-50%) translateY(8px); } to { opacity: 1; transform: translateX(-50%) translateY(0); } }

.grid-day { display: grid; gap: 1px; background: var(--line); border-radius: .75rem; overflow: hidden; }
.gd-row { display: grid; background: var(--panel); }
.gd-cell { padding: .4rem .25rem; font-size: .65rem; font-weight: 700; text-align: center; min-height: 32px; display: flex; align-items: center; justify-content: center; cursor: pointer; }
.gd-cell.head { background: var(--panel2); color: var(--muted); cursor: default; }
.gd-cell.label { background: var(--panel2); justify-content: flex-start; padding-left: .65rem; font-size: .75rem; cursor: default; }
.gd-cell.free { background: var(--panel2); color: var(--dim); }
.gd-cell.free:hover { background: rgba(198,242,78,.08); color: var(--lime); }
.gd-cell.court { background: rgba(91,168,242,.18); color: var(--blue); }
.gd-cell.lesson { background: rgba(54,230,200,.18); color: var(--teal); }
.gd-cell.block { background: rgba(92,107,124,.25); color: var(--muted); }
.gd-cell.noshow { background: rgba(242,104,92,.2); color: var(--red); }

.stat { background: var(--panel); border: 1px solid var(--line); border-radius: 1rem; padding: 1rem 1.1rem; }
.stat .l { font-size: .7rem; color: var(--muted); font-weight: 700; text-transform: uppercase; letter-spacing: .04em; margin-bottom: .25rem; }
.stat .v { font-family: 'Bricolage Grotesque', sans-serif; font-weight: 800; font-size: 1.6rem; letter-spacing: -.02em; }
.stat-grid { display: grid; gap: .75rem; grid-template-columns: repeat(2, 1fr); }
@media (min-width: 768px) { .stat-grid { grid-template-columns: repeat(4, 1fr); } }

.bar-row { display: flex; align-items: center; gap: .5rem; margin-bottom: .55rem; }
.bar-row .lbl { width: 80px; font-size: .8rem; color: var(--muted); }
.bar-row .bar { flex: 1; height: 14px; background: var(--panel2); border-radius: 4px; overflow: hidden; }
.bar-row .bar > div { height: 100%; background: var(--lime); border-radius: 4px; }
.bar-row .v { width: 50px; font-size: .8rem; font-weight: 700; text-align: right; }

.tab-bar { display: inline-flex; gap: .25rem; background: var(--panel); border: 1px solid var(--line); padding: .25rem; border-radius: .8rem; }
.tab-bar button { background: transparent; border: 0; color: var(--muted); padding: .4rem .8rem; border-radius: .6rem; font-weight: 700; font-size: .85rem; font-family: inherit; }
.tab-bar button.active { background: var(--lime); color: var(--ink); }

.legend { display: inline-flex; align-items: center; gap: .35rem; font-size: .7rem; color: var(--muted); }
.legend i { width: 12px; height: 12px; border-radius: 3px; display: inline-block; }
