:root {
  --bg: #0b120e;
  --bg-2: #111c16;
  --card: linear-gradient(160deg, rgba(255,255,255,.085), rgba(255,255,255,.035));
  --card-flat: rgba(255,255,255,.06);
  --glass: rgba(22, 16, 52, .62);
  --line: rgba(255,255,255,.09);
  --line-2: rgba(255,255,255,.16);
  --ink: #f5f2e6;
  --muted: #a9b3a0;
  --brand: #7f9e78;
  --brand-2: #c9dcbc;
  --violet: #4f6a4b;
  --gold: #f2c66d;
  --gold-2: #e39b45;
  --good: #3ddc84;
  --bad: #ff6b6b;
  --radius: 22px;
  --ease: cubic-bezier(.2, .8, .2, 1);
  --spring: cubic-bezier(.34, 1.56, .64, 1);
  --shadow: 0 1px 0 rgba(255,255,255,.07) inset, 0 20px 40px -24px rgba(0,0,0,.6);
  --c-camp: #3ddc84; --c-halaqah: #a78bfa; --c-event: #ffa94d; --c-hike: #d6a76c;
  --c-bbq: #ff6b6b; --c-meeting: #4dabf7; --c-other: #adb5bd;
  color-scheme: dark;
  font-family: Jost, -apple-system, BlinkMacSystemFont, "SF Pro Display", "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}
* { box-sizing: border-box; }
html, body { margin: 0; background: var(--bg); color: var(--ink); font-size: 16px; -webkit-font-smoothing: antialiased; }
body { min-height: 100vh; }
button, input, select, textarea { font: inherit; color: inherit; }
a { color: var(--brand-2); }
[hidden] { display: none !important; }
::selection { background: rgba(176,201,160,.4); }

/* ---------- living background ---------- */
.aurora { position: fixed; inset: 0; z-index: 0; overflow: hidden; pointer-events: none; background: radial-gradient(1200px 800px at 80% -10%, #1d3324 0%, transparent 60%), radial-gradient(900px 700px at -10% 110%, #15271c 0%, transparent 60%), var(--bg); }
.aurora i { position: absolute; border-radius: 50%; filter: blur(80px); opacity: .55; will-change: transform; }
.aurora i:nth-child(1) { width: 520px; height: 520px; background: #4f6a4b; top: -160px; right: -120px; animation: drift1 22s ease-in-out infinite alternate; }
.aurora i:nth-child(2) { width: 420px; height: 420px; background: #e39b45; bottom: -180px; left: 10%; opacity: .22; animation: drift2 26s ease-in-out infinite alternate; }
.aurora i:nth-child(3) { width: 360px; height: 360px; background: #e5d9b6; top: 40%; left: -140px; opacity: .16; animation: drift3 30s ease-in-out infinite alternate; }
.grain { position: fixed; inset: 0; z-index: 1; pointer-events: none; opacity: .05; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.9' numOctaves='3'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E"); }
#root { position: relative; z-index: 2; }
@keyframes drift1 { to { transform: translate(-180px, 140px) scale(1.15); } }
@keyframes drift2 { to { transform: translate(220px, -120px) scale(1.2); } }
@keyframes drift3 { to { transform: translate(160px, -180px) scale(.9); } }

.splash { min-height: 100vh; display: grid; place-items: center; }
.logo-mark { width: 40px; height: 40px; border-radius: 13px; background: linear-gradient(145deg, #2c432f, #0f1913); color: var(--gold); display: grid; place-items: center; font-size: 21px; flex: none; box-shadow: 0 0 0 1px rgba(255,255,255,.1) inset, 0 0 24px rgba(242,198,109,.25); text-shadow: 0 0 12px rgba(242,198,109,.8); }
.logo-mark.big { width: 72px; height: 72px; border-radius: 22px; font-size: 38px; animation: pulseGlow 2.4s ease-in-out infinite; }
@keyframes pulseGlow { 50% { box-shadow: 0 0 0 1px rgba(255,255,255,.1) inset, 0 0 50px rgba(242,198,109,.45); } }

/* ---------- 3D orb ---------- */
.orb3d { position: relative; width: 150px; height: 150px; perspective: 600px; transform-style: preserve-3d; flex: none; }
.orb3d .core { position: absolute; inset: 30px; border-radius: 50%; background: radial-gradient(circle at 32% 28%, #fffbea 0%, #f6dc9c 16%, #d9a557 38%, #5d8a5f 72%, #17301f 100%); box-shadow: 0 0 40px rgba(242,198,109,.55), 0 0 90px rgba(176,201,160,.45), inset -10px -14px 30px rgba(20,8,60,.6); animation: float 6s ease-in-out infinite; }
.orb3d .core::after { content: ""; position: absolute; inset: 8% 40% 55% 14%; border-radius: 50%; background: radial-gradient(circle, rgba(255,255,255,.9), transparent 70%); filter: blur(2px); }
.orb3d .ring { position: absolute; inset: 6px; border-radius: 50%; border: 1.5px solid rgba(247,220,154,.6); box-shadow: 0 0 18px rgba(242,198,109,.35); transform-style: preserve-3d; }
.orb3d .r1 { animation: spinA 9s linear infinite; }
.orb3d .r2 { inset: -6px; border-color: rgba(214,226,196,.45); box-shadow: 0 0 18px rgba(176,201,160,.35); animation: spinB 13s linear infinite; }
.orb3d .r1::before, .orb3d .r2::before { content: ""; position: absolute; width: 9px; height: 9px; border-radius: 50%; top: -5px; left: 50%; background: #fff; box-shadow: 0 0 12px 3px var(--gold); }
.orb3d .r2::before { box-shadow: 0 0 12px 3px var(--brand); }
.orb3d .spark { position: absolute; right: 4px; top: 2px; color: var(--gold); font-size: 22px; text-shadow: 0 0 14px var(--gold); animation: twinkle 3s ease-in-out infinite; }
.orb3d.sm { width: 110px; height: 110px; }
.orb3d.sm .core { inset: 22px; }
@keyframes float { 50% { transform: translateY(-7px); } }
@keyframes spinA { from { transform: rotateX(72deg) rotateZ(0); } to { transform: rotateX(72deg) rotateZ(360deg); } }
@keyframes spinB { from { transform: rotateX(64deg) rotateY(18deg) rotateZ(360deg); } to { transform: rotateX(64deg) rotateY(18deg) rotateZ(0); } }
@keyframes twinkle { 50% { opacity: .35; transform: scale(.75) rotate(20deg); } }

/* ---------- layout ---------- */
.app { display: flex; min-height: 100vh; }
.side { width: 250px; flex: none; background: rgba(9, 16, 12, .55); backdrop-filter: blur(24px) saturate(1.4); -webkit-backdrop-filter: blur(24px) saturate(1.4); border-right: 1px solid var(--line); padding: 22px 14px; position: sticky; top: 0; height: 100vh; display: flex; flex-direction: column; gap: 4px; }
.side .brand { display: flex; align-items: center; gap: 12px; padding: 4px 8px 26px; font-weight: 800; font-size: 19px; letter-spacing: -.01em; }
.side .brand small { display: block; font-weight: 500; font-size: 12px; color: var(--muted); letter-spacing: .02em; }
.side a { position: relative; display: flex; align-items: center; gap: 12px; padding: 12px 14px; border-radius: 14px; color: var(--muted); text-decoration: none; font-weight: 600; transition: color .25s, background .25s; }
.side a:hover { background: rgba(255,255,255,.05); color: var(--ink); }
.side a.on { color: #fff; background: linear-gradient(90deg, rgba(176,201,160,.28), rgba(176,201,160,.06)); box-shadow: 0 0 0 1px rgba(214,226,196,.18) inset, 0 8px 30px -10px rgba(176,201,160,.6); }
.side a.on::before { content: ""; position: absolute; left: -14px; top: 10px; bottom: 10px; width: 4px; border-radius: 4px; background: var(--gold); box-shadow: 0 0 12px var(--gold); }
.side .ico { font-size: 20px; width: 24px; text-align: center; }
.side .spacer { flex: 1; }
.main { flex: 1; min-width: 0; padding: 28px 36px 120px; max-width: 1120px; }
.top { display: flex; align-items: center; gap: 12px; margin-bottom: 22px; }
.top h1 { font-size: 32px; margin: 0; flex: 1; letter-spacing: -.03em; background: linear-gradient(180deg, #fff, #e5e1ce); -webkit-background-clip: text; background-clip: text; color: transparent; }
.top .help-btn { width: 44px; height: 44px; border-radius: 50%; border: 1px solid var(--line-2); background: var(--card-flat); font-size: 17px; font-weight: 800; cursor: pointer; transition: box-shadow .3s, transform .3s var(--spring); }
.top .help-btn:hover { box-shadow: 0 0 24px rgba(176,201,160,.5); transform: scale(1.06); }
.top a .av { box-shadow: 0 0 0 2px rgba(255,255,255,.15), 0 0 20px rgba(176,201,160,.45); }
.tabbar { display: none; }
.fab { display: none; }

@media (max-width: 820px) {
  .side { display: none; }
  .main { padding: 18px 16px 120px; }
  .top h1 { font-size: 27px; }
  .tabbar { display: flex; position: fixed; left: 12px; right: 12px; bottom: calc(10px + env(safe-area-inset-bottom)); background: rgba(14, 24, 18, .78); backdrop-filter: blur(22px) saturate(1.5); -webkit-backdrop-filter: blur(22px) saturate(1.5); border: 1px solid var(--line-2); border-radius: 24px; padding: 6px; z-index: 40; box-shadow: 0 20px 40px -10px rgba(0,0,0,.6); }
  .tabbar a { position: relative; flex: 1; text-align: center; text-decoration: none; color: var(--muted); font-size: 10.5px; font-weight: 700; padding: 6px 0 5px; border-radius: 18px; transition: color .25s, background .25s; }
  .tabbar a .ico { display: block; font-size: 21px; line-height: 1.3; filter: grayscale(1) brightness(1.4); opacity: .55; transition: transform .35s var(--spring), filter .25s, opacity .25s; }
  .tabbar a.on { color: #fff; background: rgba(176,201,160,.2); box-shadow: 0 0 0 1px rgba(214,226,196,.15) inset; }
  .tabbar a.on .ico { filter: drop-shadow(0 0 8px rgba(242,198,109,.6)); opacity: 1; transform: translateY(-2px) scale(1.12); }
  .fab { display: grid; place-items: center; position: fixed; right: 20px; bottom: calc(92px + env(safe-area-inset-bottom)); width: 60px; height: 60px; border-radius: 20px; background: linear-gradient(145deg, #f7dc9a, var(--gold-2)); color: #1b2416; font-size: 32px; font-weight: 600; border: 0; box-shadow: 0 0 0 1px rgba(255,255,255,.35) inset, 0 12px 30px -6px rgba(227,155,69,.7), 0 0 40px rgba(242,198,109,.35); z-index: 41; cursor: pointer; transition: transform .3s var(--spring); }
  .fab:active { transform: scale(.9) rotate(90deg); }
}

/* ---------- glass cards ---------- */
.card { position: relative; background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); padding: 20px; margin-bottom: 16px; }
.card h2 { font-size: 18px; margin: 0 0 14px; display: flex; align-items: center; gap: 8px; letter-spacing: -.01em; }
.card h2 .more { margin-left: auto; font-size: 14px; font-weight: 600; text-decoration: none; color: var(--brand-2); }
.grid2 { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
@media (max-width: 820px) { .grid2 { grid-template-columns: 1fr; } }
.muted { color: var(--muted); }
.small { font-size: 13px; }
.empty { text-align: center; color: var(--muted); padding: 20px 8px; }
.empty .big { font-size: 36px; display: block; margin-bottom: 8px; filter: drop-shadow(0 0 14px rgba(242,198,109,.35)); animation: float 5s ease-in-out infinite; }
.row { display: flex; align-items: center; gap: 10px; }
.wrap { flex-wrap: wrap; }
.grow { flex: 1; min-width: 0; }
.right { margin-left: auto; }
.sec-title { font-size: 12px; font-weight: 800; text-transform: uppercase; letter-spacing: .12em; color: var(--muted); margin: 22px 0 10px; }

/* ---------- buttons ---------- */
.btn { position: relative; overflow: hidden; display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 48px; padding: 0 20px; border-radius: 15px; border: 0; background: linear-gradient(135deg, var(--violet), var(--brand)); color: #fff; font-weight: 700; font-size: 16px; cursor: pointer; text-decoration: none; box-shadow: 0 0 0 1px rgba(255,255,255,.18) inset, 0 10px 26px -10px rgba(90,122,88,.8); transition: transform .25s var(--spring), box-shadow .3s, filter .2s; }
.btn::after { content: ""; position: absolute; top: 0; left: -120%; width: 60%; height: 100%; background: linear-gradient(100deg, transparent, rgba(255,255,255,.35), transparent); transform: skewX(-20deg); transition: left .7s var(--ease); pointer-events: none; }
.btn:hover::after { left: 140%; }
.btn:hover { transform: translateY(-1px); filter: brightness(1.08); }
.btn:active { transform: scale(.97); }
.btn.gold { background: linear-gradient(135deg, #f7dc9a, var(--gold) 45%, var(--gold-2)); color: #1b2416; box-shadow: 0 0 0 1px rgba(255,255,255,.4) inset, 0 12px 30px -10px rgba(227,155,69,.75), 0 0 30px -8px rgba(242,198,109,.5); }
.btn.soft { background: rgba(176,201,160,.14); color: #e3ecd8; box-shadow: 0 0 0 1px rgba(214,226,196,.22) inset; }
.btn.ghost { background: rgba(255,255,255,.03); color: var(--ink); box-shadow: 0 0 0 1px var(--line-2) inset; }
.btn.danger { background: rgba(255,107,107,.12); color: #ff9b9b; box-shadow: 0 0 0 1px rgba(255,107,107,.25) inset; }
.btn.sm { min-height: 38px; padding: 0 14px; font-size: 14px; border-radius: 12px; }
.btn.block { width: 100%; }
.btn[disabled] { opacity: .5; }
.btn.big-cta { min-height: 60px; font-size: 18px; border-radius: 18px; margin-bottom: 16px; }

/* ---------- forms ---------- */
label.f { display: block; font-weight: 700; font-size: 14px; margin: 16px 0 7px; color: #e8e6d8; }
label.f .hint { font-weight: 500; color: var(--muted); }
.in { width: 100%; min-height: 50px; padding: 12px 14px; border-radius: 14px; border: 1px solid var(--line-2); background: rgba(255,255,255,.045); font-size: 16px; outline: none; transition: border-color .2s, box-shadow .25s, background .2s; }
.in::placeholder { color: rgba(169,179,160,.6); }
.in:focus { border-color: var(--brand); background: rgba(176,201,160,.08); box-shadow: 0 0 0 4px rgba(176,201,160,.18), 0 0 24px rgba(176,201,160,.25); }
select.in option { background: #16241b; color: var(--ink); }
textarea.in { min-height: 100px; resize: vertical; }
.check-line { display: flex; gap: 10px; align-items: flex-start; margin-top: 16px; font-size: 15px; padding: 14px; border-radius: 14px; background: rgba(242,198,109,.07); border: 1px solid rgba(242,198,109,.2); }
.check-line input { width: 22px; height: 22px; margin-top: 1px; accent-color: var(--gold); flex: none; }
.err { background: rgba(255,107,107,.12); color: #ffb0b0; border: 1px solid rgba(255,107,107,.3); border-radius: 12px; padding: 10px 14px; margin-top: 12px; font-weight: 600; font-size: 14px; animation: shake .4s; }
@keyframes shake { 25% { transform: translateX(-6px); } 75% { transform: translateX(6px); } }

/* ---------- pills ---------- */
.pill { display: inline-flex; align-items: center; gap: 4px; padding: 3px 10px; border-radius: 99px; font-size: 12px; font-weight: 700; background: rgba(176,201,160,.15); color: #dbe8cf; white-space: nowrap; border: 1px solid rgba(214,226,196,.15); }
.pill.overdue { background: rgba(255,107,107,.14); color: #ffa3a3; border-color: rgba(255,107,107,.3); box-shadow: 0 0 14px -4px rgba(255,107,107,.6); }
.pill.today { background: rgba(242,198,109,.15); color: var(--gold); border-color: rgba(242,198,109,.3); box-shadow: 0 0 14px -4px rgba(242,198,109,.6); }
.pill.done { background: rgba(61,220,132,.14); color: var(--good); border-color: rgba(61,220,132,.3); }

/* ---------- avatars ---------- */
.av { border-radius: 50%; display: inline-grid; place-items: center; color: #fff; font-weight: 800; flex: none; object-fit: cover; background: #444; overflow: hidden; box-shadow: 0 0 0 2px rgba(255,255,255,.1); }
.av-empty { box-shadow: none; border: 1.5px dashed rgba(255,255,255,.25); background: rgba(255,255,255,.03); color: var(--muted); font-weight: 600; transition: border-color .2s, color .2s; }
.who-btn:hover .av-empty { border-color: var(--gold); color: var(--gold); }

/* ---------- to-do rows ---------- */
.todo { display: flex; align-items: center; gap: 12px; padding: 13px 4px; border-bottom: 1px solid var(--line); transition: background .2s; border-radius: 10px; }
.todo:last-child { border-bottom: 0; }
.tick { position: relative; width: 30px; height: 30px; border-radius: 50%; border: 2px solid rgba(255,255,255,.25); background: rgba(255,255,255,.03); flex: none; cursor: pointer; display: grid; place-items: center; color: #0b2a18; font-size: 16px; font-weight: 900; padding: 0; transition: border-color .2s, box-shadow .25s, transform .3s var(--spring); }
.tick:hover { border-color: var(--good); box-shadow: 0 0 16px rgba(61,220,132,.45); transform: scale(1.08); }
.tick.on { background: radial-gradient(circle at 35% 30%, #8dffc0, var(--good)); border-color: var(--good); box-shadow: 0 0 18px rgba(61,220,132,.55); animation: pop .45s var(--spring); }
@keyframes pop { 0% { transform: scale(.6); } 100% { transform: scale(1); } }
.todo .t { flex: 1; min-width: 0; cursor: pointer; }
.todo .t .title { font-weight: 600; line-height: 1.35; transition: color .3s; }
.todo.is-done .t .title { text-decoration: line-through; color: var(--muted); }
.todo .meta { display: flex; gap: 6px; flex-wrap: wrap; margin-top: 5px; }
.who-btn { background: none; border: 0; padding: 0; cursor: pointer; transition: transform .3s var(--spring); }
.who-btn:hover { transform: scale(1.1); }
.add-line { display: flex; gap: 8px; margin-top: 10px; }
.add-line .in { min-height: 46px; }

/* burst when ticking */
.burst { position: fixed; z-index: 300; pointer-events: none; width: 0; height: 0; }
.burst i { position: absolute; width: 7px; height: 7px; border-radius: 50%; background: var(--k); box-shadow: 0 0 10px var(--k); animation: burst .75s var(--ease) forwards; }
@keyframes burst { from { transform: translate(-50%, -50%) scale(1); opacity: 1; } to { transform: translate(calc(-50% + var(--x)), calc(-50% + var(--y))) scale(0); opacity: 0; } }

/* ---------- event cards ---------- */
.ev-card { position: relative; display: flex; gap: 14px; align-items: center; padding: 15px 16px 15px 20px; border-radius: 20px; background: var(--card); border: 1px solid var(--line); box-shadow: var(--shadow); margin-bottom: 12px; text-decoration: none; color: inherit; cursor: pointer; overflow: hidden; }
.ev-card::before { content: ""; position: absolute; left: 0; top: 14px; bottom: 14px; width: 4px; border-radius: 0 4px 4px 0; background: var(--c, #999); box-shadow: 0 0 14px var(--c, #999); }
.ev-card::after { content: ""; position: absolute; inset: 0; background: radial-gradient(400px 120px at 0% 50%, color-mix(in srgb, var(--c, #999) 14%, transparent), transparent 70%); pointer-events: none; }
.ev-card .date-box { width: 56px; text-align: center; flex: none; padding: 6px 0; border-radius: 14px; background: rgba(255,255,255,.05); border: 1px solid var(--line); }
.ev-card .date-box .d { font-size: 23px; font-weight: 800; line-height: 1.05; color: #fff; }
.ev-card .date-box .m { font-size: 11px; font-weight: 800; text-transform: uppercase; color: var(--c, var(--muted)); letter-spacing: .05em; }
.ev-card .name { font-weight: 800; font-size: 17px; letter-spacing: -.01em; }
.bar { position: relative; height: 7px; border-radius: 99px; background: rgba(255,255,255,.08); overflow: hidden; margin-top: 9px; }
.bar > i { position: relative; display: block; height: 100%; width: var(--w, 0%); background: linear-gradient(90deg, #2bd4a0, var(--good)); border-radius: 99px; box-shadow: 0 0 12px rgba(61,220,132,.6); animation: grow 1.1s var(--ease) both; animation-delay: calc(var(--i, 0) * 50ms + 150ms); overflow: hidden; }
.bar > i::after { content: ""; position: absolute; inset: 0; background: linear-gradient(90deg, transparent, rgba(255,255,255,.55), transparent); animation: shimmer 2.6s ease-in-out infinite; transform: translateX(-100%); }
@keyframes grow { from { width: 0; } }
@keyframes shimmer { 60%, 100% { transform: translateX(100%); } }

/* tilt + glare (desktop) */
.tilt { transform: perspective(900px) rotateX(var(--rx, 0deg)) rotateY(var(--ry, 0deg)) translateY(var(--ty, 0)); transition: transform .5s var(--ease), box-shadow .4s, border-color .3s; transform-style: preserve-3d; }
.tilt.hot { transition: transform .08s linear, box-shadow .4s, border-color .3s; --ty: -3px; border-color: var(--line-2); box-shadow: 0 1px 0 rgba(255,255,255,.1) inset, 0 30px 50px -24px rgba(0,0,0,.8), 0 0 40px -16px color-mix(in srgb, var(--c, #7f9e78) 70%, transparent); }
.tilt .glare { position: absolute; inset: 0; border-radius: inherit; pointer-events: none; background: radial-gradient(300px circle at var(--gx, 50%) var(--gy, 50%), rgba(255,255,255,.13), transparent 60%); opacity: 0; transition: opacity .3s; z-index: 1; }
.tilt.hot .glare { opacity: 1; }

/* ---------- hero ---------- */
.hello { position: relative; overflow: hidden; border-radius: 28px; padding: 26px; margin-bottom: 16px; background: radial-gradient(500px 260px at 85% 20%, rgba(227,155,69,.28), transparent 60%), radial-gradient(600px 300px at 10% 120%, rgba(229,217,182,.10), transparent 60%), linear-gradient(140deg, #2c432f, #18291e 60%, #0f1913); border: 1px solid rgba(255,255,255,.12); box-shadow: 0 1px 0 rgba(255,255,255,.12) inset, 0 30px 60px -30px rgba(90,122,88,.7); display: flex; align-items: center; gap: 20px; }
.hello .txt { flex: 1; min-width: 0; position: relative; z-index: 1; }
.hello h2 { margin: 0 0 6px; font-size: 27px; letter-spacing: -.02em; }
.hello p { margin: 0; color: #d6dcc8; }
.hello .orb3d { margin: -10px -6px -10px 0; }
.quick { display: flex; gap: 10px; margin-top: 18px; flex-wrap: wrap; }
.quick .btn { min-height: 46px; }
.stats { display: flex; gap: 10px; margin-top: 18px; flex-wrap: wrap; }
.stat { padding: 10px 14px; border-radius: 16px; background: rgba(255,255,255,.07); border: 1px solid rgba(255,255,255,.1); min-width: 92px; backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px); }
.stat b { display: block; font-size: 24px; line-height: 1.1; font-variant-numeric: tabular-nums; }
.stat small { color: #d6dcc8; font-weight: 600; font-size: 12px; }
@media (max-width: 600px) {
  .hello { padding: 20px; border-radius: 24px; }
  .hello h2 { font-size: 22px; }
  .hello .orb3d { position: absolute; right: -24px; top: -20px; opacity: .85; }
  .hello .txt { padding-right: 70px; }
  .stats .stat { flex: 1; min-width: 0; }
}

/* ---------- start here ---------- */
.steps .step { display: flex; align-items: center; gap: 12px; padding: 10px 0; border-bottom: 1px solid var(--line); }
.steps .step:last-child { border-bottom: 0; }
.steps .num { width: 30px; height: 30px; border-radius: 50%; background: rgba(176,201,160,.16); color: #e3ecd8; display: grid; place-items: center; font-weight: 800; flex: none; border: 1px solid rgba(214,226,196,.22); }
.steps .step.ok .num { background: radial-gradient(circle at 35% 30%, #8dffc0, var(--good)); color: #0b2a18; border-color: transparent; box-shadow: 0 0 14px rgba(61,220,132,.5); }
.steps .step.ok .label { color: var(--muted); text-decoration: line-through; }
.steps .label { flex: 1; font-weight: 600; }

/* ---------- type picker ---------- */
.type-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(130px, 1fr)); gap: 12px; }
.type-tile { position: relative; overflow: hidden; border: 1px solid var(--line-2); background: var(--card); border-radius: 20px; padding: 20px 10px; text-align: center; cursor: pointer; font-weight: 800; }
.type-tile::before { content: ""; position: absolute; inset: auto -20% -60% -20%; height: 90%; background: radial-gradient(closest-side, color-mix(in srgb, var(--c, #7f9e78) 45%, transparent), transparent); opacity: .45; transition: opacity .3s, transform .4s var(--ease); }
.type-tile:hover::before { opacity: .9; transform: translateY(-14%); }
.type-tile:hover { border-color: color-mix(in srgb, var(--c, #7f9e78) 60%, transparent); }
.type-tile .e { position: relative; font-size: 40px; display: block; margin-bottom: 8px; filter: drop-shadow(0 6px 14px rgba(0,0,0,.4)); transition: transform .4s var(--spring); }
.type-tile:hover .e { transform: translateY(-4px) scale(1.12) rotate(-6deg); }
.type-tile small { position: relative; display: block; font-weight: 500; color: var(--muted); font-size: 12px; margin-top: 4px; }

/* ---------- event page ---------- */
.ev-head { position: relative; overflow: hidden; border-radius: 28px; padding: 22px; color: #fff; margin-bottom: 16px; background: radial-gradient(500px 240px at 90% 0%, color-mix(in srgb, var(--c) 55%, transparent), transparent 65%), linear-gradient(145deg, color-mix(in srgb, var(--c) 42%, #0f1913), #0d1611 75%); border: 1px solid color-mix(in srgb, var(--c) 35%, transparent); box-shadow: 0 1px 0 rgba(255,255,255,.12) inset, 0 30px 60px -30px color-mix(in srgb, var(--c) 80%, transparent); }
.ev-head .big-emoji { position: absolute; right: 18px; bottom: -18px; font-size: 120px; opacity: .2; transform: rotate(-12deg); filter: blur(.5px); animation: float 7s ease-in-out infinite; pointer-events: none; }
.ev-head .back { color: #fff; opacity: .8; text-decoration: none; font-weight: 700; font-size: 14px; }
.ev-head h1 { position: relative; margin: 10px 0 8px; font-size: 28px; display: flex; gap: 10px; align-items: center; letter-spacing: -.02em; }
.ev-head .facts { position: relative; display: flex; flex-wrap: wrap; gap: 8px 16px; font-weight: 600; color: rgba(255,255,255,.88); }
.ev-head .bar > i { background: linear-gradient(90deg, #fff, color-mix(in srgb, var(--c) 40%, #fff)); box-shadow: 0 0 14px rgba(255,255,255,.6); }
.ev-head select { background: rgba(255,255,255,.12); color: #fff; border: 1px solid rgba(255,255,255,.2); border-radius: 99px; padding: 7px 12px; font-weight: 700; backdrop-filter: blur(8px); }
.ev-head select option { background: #16241b; color: var(--ink); }
.tabs { display: flex; gap: 8px; overflow-x: auto; padding: 2px 2px 8px; margin-bottom: 12px; scrollbar-width: none; }
.tabs::-webkit-scrollbar { display: none; }
.tabs button { flex: none; border: 1px solid var(--line); background: rgba(255,255,255,.05); padding: 10px 16px; border-radius: 99px; font-weight: 700; cursor: pointer; white-space: nowrap; color: #dfe3d4; transition: all .3s var(--ease); }
.tabs button:hover { background: rgba(255,255,255,.09); }
.tabs button.on { background: linear-gradient(135deg, var(--violet), var(--brand)); color: #fff; border-color: transparent; box-shadow: 0 8px 24px -8px rgba(90,122,88,.8), 0 0 0 1px rgba(255,255,255,.2) inset; }
.tabs .count { opacity: .6; font-weight: 600; }

.line-row { display: flex; align-items: center; gap: 12px; padding: 13px 4px; border-bottom: 1px solid var(--line); cursor: pointer; border-radius: 10px; transition: background .2s; }
.line-row:hover, .todo:hover { background: rgba(255,255,255,.025); }
.line-row:last-child { border-bottom: 0; }
.line-row .time { width: 120px; flex: none; font-weight: 800; color: var(--gold); font-size: 14px; text-shadow: 0 0 12px rgba(242,198,109,.35); }
@media (max-width: 600px) { .line-row .time { width: 84px; } }
.money { display: flex; align-items: center; gap: 10px; padding: 8px 0; border-bottom: 1px solid var(--line); }
.money .in.amt { width: 120px; text-align: right; min-height: 44px; }
.totals { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; margin-bottom: 14px; }
.totals div { background: var(--card); border: 1px solid var(--line); border-radius: 18px; box-shadow: var(--shadow); padding: 16px 10px; text-align: center; }
.totals b { display: block; font-size: 24px; font-variant-numeric: tabular-nums; }
.totals small { color: var(--muted); font-weight: 700; }
.glow-good { color: var(--good); text-shadow: 0 0 18px rgba(61,220,132,.45); }
.glow-bad { color: var(--bad); text-shadow: 0 0 18px rgba(255,107,107,.45); }

/* ---------- calendar ---------- */
.cal-head { display: flex; align-items: center; gap: 8px; margin-bottom: 14px; }
.cal-head h2 { margin: 0; flex: 1; font-size: 24px; letter-spacing: -.02em; }
.cal { display: grid; grid-template-columns: repeat(7, 1fr); gap: 5px; }
.cal .dow { text-align: center; font-size: 11px; font-weight: 800; color: var(--muted); padding: 4px 0; letter-spacing: .08em; text-transform: uppercase; }
.cal .day { min-height: 94px; background: rgba(255,255,255,.035); border-radius: 14px; padding: 6px; cursor: pointer; border: 1px solid var(--line); overflow: hidden; transition: background .2s, border-color .2s, transform .3s var(--spring); }
.cal .day:hover { background: rgba(255,255,255,.07); transform: translateY(-2px); }
.cal .day.out { opacity: .35; }
.cal .day.today .n { background: linear-gradient(135deg, #f7dc9a, var(--gold-2)); color: #1b2416; box-shadow: 0 0 16px rgba(242,198,109,.7); }
.cal .day.sel { border-color: var(--brand); background: rgba(176,201,160,.12); box-shadow: 0 0 0 1px var(--brand) inset, 0 0 24px -6px rgba(176,201,160,.7); }
.cal .n { display: inline-grid; place-items: center; width: 26px; height: 26px; border-radius: 50%; font-weight: 800; font-size: 13px; }
.cal .chip { display: block; font-size: 11px; font-weight: 700; color: var(--c); background: color-mix(in srgb, var(--c) 18%, transparent); border-left: 3px solid var(--c); border-radius: 6px; padding: 2px 5px; margin-top: 3px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.cal .dots { display: none; gap: 3px; justify-content: center; margin-top: 4px; flex-wrap: wrap; }
.cal .dots i { width: 7px; height: 7px; border-radius: 50%; box-shadow: 0 0 8px currentColor; }
.cal .todo-count { font-size: 10px; font-weight: 700; color: var(--muted); margin-top: 2px; }
@media (max-width: 820px) {
  .cal { gap: 3px; }
  .cal .day { min-height: 54px; padding: 4px 2px; text-align: center; border-radius: 12px; }
  .cal .chip { display: none; }
  .cal .dots { display: flex; }
  .cal .todo-count { display: none; }
}
.legend { display: flex; flex-wrap: wrap; gap: 6px 14px; margin-top: 14px; font-size: 13px; font-weight: 600; color: var(--muted); }
.legend i { display: inline-block; width: 9px; height: 9px; border-radius: 50%; margin-right: 6px; box-shadow: 0 0 8px currentColor; }

/* ---------- team ---------- */
.team-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 14px; }
.member { position: relative; overflow: hidden; background: var(--card); border: 1px solid var(--line); border-radius: 24px; box-shadow: var(--shadow); padding: 24px 20px 20px; text-align: center; cursor: pointer; }
.member::before { content: ""; position: absolute; left: 50%; top: -60px; width: 220px; height: 160px; transform: translateX(-50%); background: radial-gradient(closest-side, color-mix(in srgb, var(--mc, #7f9e78) 50%, transparent), transparent); opacity: .5; pointer-events: none; }
.member .av { position: relative; box-shadow: 0 0 0 3px rgba(255,255,255,.12), 0 0 30px color-mix(in srgb, var(--mc, #7f9e78) 60%, transparent); }
.member .name { position: relative; font-weight: 800; font-size: 17px; margin-top: 12px; }
.member .title { color: var(--muted); font-weight: 600; margin-top: 2px; }
.member .stats-line { margin-top: 10px; font-size: 13px; color: var(--muted); }
.member.off { opacity: .45; }

/* ---------- modal ---------- */
.backdrop { position: fixed; inset: 0; background: rgba(4, 8, 6, .62); backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px); z-index: 100; display: flex; align-items: center; justify-content: center; padding: 16px; animation: fade .25s; }
.sheet { position: relative; background: linear-gradient(170deg, rgba(30, 48, 36, .93), rgba(11, 19, 14, .96)); border: 1px solid var(--line-2); box-shadow: 0 1px 0 rgba(255,255,255,.12) inset, 0 40px 80px -20px rgba(0,0,0,.8), 0 0 80px -30px rgba(176,201,160,.6); backdrop-filter: blur(30px); -webkit-backdrop-filter: blur(30px); border-radius: 28px; width: 100%; max-width: 520px; max-height: 90vh; overflow-y: auto; padding: 24px; animation: pop-in .45s var(--spring); }
.sheet h2 { margin: 0 0 6px; font-size: 23px; letter-spacing: -.02em; }
.sheet .actions { display: flex; gap: 10px; margin-top: 20px; flex-wrap: wrap; }
.sheet .actions .btn { flex: 1; }
@media (max-width: 600px) {
  .backdrop { align-items: flex-end; padding: 0; }
  .sheet { border-radius: 28px 28px 0 0; padding-bottom: calc(24px + env(safe-area-inset-bottom)); animation: sheet-up .45s var(--ease); }
  .sheet::before { content: ""; display: block; width: 44px; height: 5px; border-radius: 5px; background: rgba(255,255,255,.25); margin: -8px auto 14px; }
}
.pick-list .pick { display: flex; align-items: center; gap: 12px; padding: 12px; border-radius: 16px; cursor: pointer; font-weight: 700; background: rgba(255,255,255,.05); margin-bottom: 8px; border: 1px solid var(--line); transition: background .2s, border-color .2s, transform .25s var(--spring); }
.pick-list .pick:hover { background: rgba(255,255,255,.09); transform: translateX(4px); }
.pick-list .pick.on { border-color: var(--brand); background: rgba(176,201,160,.15); box-shadow: 0 0 20px -6px rgba(176,201,160,.7); }
@keyframes fade { from { opacity: 0; } }
@keyframes pop-in { from { transform: translateY(18px) scale(.96); opacity: 0; } }
@keyframes sheet-up { from { transform: translateY(100%); } }

.toast { position: fixed; left: 50%; bottom: 110px; transform: translateX(-50%); background: rgba(22, 36, 27, .9); backdrop-filter: blur(16px); -webkit-backdrop-filter: blur(16px); border: 1px solid var(--line-2); color: #fff; padding: 13px 22px; border-radius: 16px; font-weight: 700; z-index: 200; box-shadow: 0 20px 40px -10px rgba(0,0,0,.6), 0 0 30px -10px rgba(176,201,160,.7); max-width: 90vw; text-align: center; animation: toast-in .45s var(--spring); }
@keyframes toast-in { from { transform: translate(-50%, 20px) scale(.9); opacity: 0; } }

/* ---------- auth ---------- */
.auth { min-height: 100vh; display: grid; place-items: center; padding: 20px; }
.auth .box { position: relative; width: 100%; max-width: 430px; background: linear-gradient(165deg, rgba(34, 54, 40, .72), rgba(11, 19, 14, .84)); border: 1px solid var(--line-2); backdrop-filter: blur(30px); -webkit-backdrop-filter: blur(30px); border-radius: 30px; padding: 30px 28px; box-shadow: 0 1px 0 rgba(255,255,255,.12) inset, 0 40px 100px -30px rgba(0,0,0,.8), 0 0 120px -40px rgba(176,201,160,.8); }
.auth .orb3d { margin: -90px auto 0; }
.auth h1 { margin: 6px 0 4px; font-size: 28px; text-align: center; letter-spacing: -.02em; }
.auth .lead { text-align: center; color: var(--muted); margin: 0 0 6px; }
.auth .avatar-pick { display: flex; align-items: center; gap: 14px; margin-top: 8px; }

/* ---------- help ---------- */
.lesson::before { content: ""; position: absolute; left: 0; top: 18px; bottom: 18px; width: 3px; border-radius: 0 3px 3px 0; background: var(--gold); box-shadow: 0 0 12px var(--gold); }
.lesson .mins { font-size: 12px; font-weight: 800; color: var(--gold); background: rgba(242,198,109,.12); border: 1px solid rgba(242,198,109,.25); padding: 3px 10px; border-radius: 99px; }
.lesson ol, .lesson ul { padding-left: 20px; line-height: 1.65; margin: 8px 0 0; color: #e8e6d8; }
.lesson li { margin-bottom: 4px; }
.kbd { display: inline-block; padding: 1px 8px; border-radius: 8px; background: rgba(176,201,160,.18); border: 1px solid rgba(214,226,196,.25); font-weight: 700; font-size: 14px; }
.copy-box { display: flex; gap: 8px; margin-top: 10px; }
.copy-box .in { font-size: 13px; }

/* ---------- entrance motion ---------- */
.fx { animation: fadeUp .7s var(--ease) both; animation-delay: calc(var(--i, 0) * 55ms); }
@keyframes fadeUp { from { opacity: 0; transform: translateY(18px); filter: blur(6px); } to { opacity: 1; transform: none; filter: none; } }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; }
  .aurora i { animation: none; }
}

/* ---------- LOH brand layer ---------- */
h1, h2, .hello h2, .serif { font-family: Lora, Georgia, "Times New Roman", serif; font-weight: 600; }
.card h2, .sheet h2 { font-family: Lora, Georgia, serif; }
.top h1 { background: linear-gradient(180deg, #fbf8ee, #d9d2b6); -webkit-background-clip: text; background-clip: text; }
.splash-mark { width: 96px; filter: drop-shadow(0 0 22px rgba(242,198,109,.55)); animation: breathe 2.4s ease-in-out infinite; }
@keyframes breathe { 50% { filter: drop-shadow(0 0 40px rgba(242,198,109,.85)); transform: scale(1.04); } }
.brand-mark { width: 44px; height: 44px; flex: none; border-radius: 14px; display: grid; place-items: center; background: radial-gradient(circle at 35% 25%, #33503a, #13211a 75%); box-shadow: 0 0 0 1px rgba(229,225,206,.18) inset, 0 0 24px rgba(242,198,109,.22); }
.brand-mark img { width: 30px; filter: drop-shadow(0 0 6px rgba(242,198,109,.6)); }
.side .brand { font-family: Lora, Georgia, serif; font-weight: 600; font-size: 18px; line-height: 1.15; }
.side .brand small { font-family: Jost, sans-serif; text-transform: uppercase; letter-spacing: .14em; font-size: 10.5px; margin-top: 3px; }
.arabic { font-family: "Geeza Pro", "Noto Naskh Arabic", serif; direction: rtl; }

/* the light orb: green glass sphere, glowing kufic mark, orbiting rings of light */
.orb3d .core { background: radial-gradient(circle at 32% 26%, #6f9a70 0%, #3d5e44 30%, #1d3326 62%, #0c1510 100%); box-shadow: 0 0 0 1px rgba(229,225,206,.15) inset, 0 0 50px rgba(242,198,109,.35), 0 0 110px rgba(127,158,120,.35), inset -12px -16px 30px rgba(0,0,0,.55); display: grid; place-items: center; }
.orb3d .core::after { inset: 7% 46% 60% 12%; background: radial-gradient(circle, rgba(255,255,255,.55), transparent 70%); }
.orb3d .core img { position: relative; z-index: 1; width: 52%; filter: drop-shadow(0 0 8px rgba(247,220,154,.9)) drop-shadow(0 0 22px rgba(242,198,109,.5)); animation: markGlow 3.2s ease-in-out infinite; }
@keyframes markGlow { 50% { filter: drop-shadow(0 0 12px rgba(255,236,180,1)) drop-shadow(0 0 34px rgba(242,198,109,.75)); } }
.orb3d .halo { position: absolute; inset: -30px; border-radius: 50%; background: radial-gradient(closest-side, rgba(242,198,109,.28), transparent 70%); animation: breatheHalo 4s ease-in-out infinite; pointer-events: none; }
@keyframes breatheHalo { 50% { transform: scale(1.12); opacity: .7; } }
.orb3d.lg { width: 190px; height: 190px; }
.orb3d.lg .core { inset: 36px; }
.auth .orb3d { margin: -110px auto 4px; }
.auth .brand-line { text-align: center; text-transform: uppercase; letter-spacing: .2em; font-size: 11px; color: var(--muted); font-weight: 600; }
.auth .wordmark { width: 220px; display: block; margin: 0 auto 6px; opacity: .95; }
.hello .eyebrow { font-size: 11px; text-transform: uppercase; letter-spacing: .18em; color: var(--gold); font-weight: 700; margin-bottom: 6px; }
.fx2 { animation: fadeUp2 .6s var(--ease) both; animation-delay: calc(var(--i, 0) * 40ms + 80ms); }
@keyframes fadeUp2 { from { opacity: 0; transform: translateY(14px); } }
@media (max-width: 600px) {
  .hello .txt { padding-right: 0; }
  .hello .eyebrow, .hello h2, .hello p { padding-right: 84px; }
  .stat { padding: 10px 12px; }
  .stat b { font-size: 22px; }
  .auth .box { padding: 26px 20px; }
}
.auth h1 { margin-top: 18px; }
