:root{--bg: #fafafa;--surface: #ffffff;--text: #1a1a2e;--muted: #8a8aa0;--line: #ececf2;--radius: 16px;font-family:-apple-system,BlinkMacSystemFont,SF Pro Rounded,Segoe UI,Roboto,sans-serif}@media (prefers-color-scheme: dark){:root{--bg: #121218;--surface: #1c1c26;--text: #f2f2f7;--muted: #77778c;--line: #2a2a38}}*{box-sizing:border-box;margin:0}button,select,input{touch-action:manipulation}html,body,#root{height:100%}body{background:var(--bg);color:var(--text);overscroll-behavior:none;-webkit-user-select:none;user-select:none}.app{display:flex;flex-direction:column;height:100%}.loading{display:grid;place-items:center;height:100%;color:var(--muted);font-size:20px}.topbar{display:flex;align-items:center;gap:16px;flex-wrap:wrap;padding:14px 20px 10px}.brand{display:flex;align-items:baseline;gap:12px}.brand-name{font-size:22px;font-weight:800;letter-spacing:-.02em}.title{font-size:17px;color:var(--muted);font-weight:600}.demo-badge{font-size:11px;font-weight:700;text-transform:uppercase;letter-spacing:.06em;background:#ffd76e;color:#5c4a00;padding:3px 8px;border-radius:999px}.chips{display:flex;gap:8px;flex:1;justify-content:center;flex-wrap:wrap}.chip{display:flex;align-items:center;gap:7px;border:none;cursor:pointer;font:inherit;font-size:14px;font-weight:700;padding:7px 14px;border-radius:999px;background:color-mix(in srgb,var(--c) 18%,var(--surface));color:var(--text);transition:opacity .15s,transform .15s}.chip:active{transform:scale(.95)}.chip-dot{width:10px;height:10px;border-radius:50%;background:var(--c)}.chip-off{opacity:.35}.controls{display:flex;align-items:center;gap:8px}.tabs{display:flex;background:var(--surface);border-radius:12px;padding:3px;box-shadow:0 1px 3px #00000012}.tab{border:none;background:transparent;cursor:pointer;font:inherit;font-size:14px;font-weight:700;color:var(--muted);padding:7px 14px;border-radius:9px;transition:all .15s}.tab-on{background:var(--text);color:var(--bg)}.nav,.today{border:none;cursor:pointer;font:inherit;font-weight:800;background:var(--surface);color:var(--text);border-radius:12px;padding:7px 14px;font-size:15px;box-shadow:0 1px 3px #00000012}.nav{font-size:20px;line-height:1;padding:5px 13px}.error-bar{background:#ffe3e3;color:#7a1f1f;font-size:13px;font-weight:600;padding:6px 20px}.swipe-area{flex:1;display:flex;flex-direction:column;min-height:0;touch-action:pan-y}.timegrid{flex:1;display:flex;flex-direction:column;min-height:0;padding:0 12px 12px}.tg-header,.tg-allday{display:flex}.tg-gutter{width:52px;flex-shrink:0;position:relative}.tg-dayhead{flex:1;text-align:center;padding:6px 0 10px;display:flex;flex-direction:column;gap:2px}.tg-dayhead .dow{font-size:12px;font-weight:700;text-transform:uppercase;color:var(--muted);letter-spacing:.05em}.tg-dayhead .dom{font-size:24px;font-weight:800}.tg-dayhead.is-today .dom{background:var(--text);color:var(--bg);width:40px;height:40px;line-height:40px;border-radius:50%;margin:0 auto}.tg-allday{padding-bottom:6px}.allday-label{font-size:11px;color:var(--muted);font-weight:700;align-self:center}.tg-allday-cell{flex:1;display:flex;flex-direction:column;gap:3px;padding:0 3px}.allday-pill{border:none;cursor:pointer;font:inherit;font-size:12px;font-weight:700;background:var(--c);color:#fff;border-radius:8px;padding:4px 8px;text-align:left;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.tg-scroll{flex:1;overflow-y:auto;border-radius:var(--radius);background:var(--surface);box-shadow:0 1px 4px #0000000f}.tg-body{display:flex;position:relative}.tg-body .tg-gutter .hour-label{position:absolute;right:8px;transform:translateY(-50%);font-size:11px;font-weight:600;color:var(--muted)}.tg-col{flex:1;position:relative;border-left:1px solid var(--line)}.tg-col.is-today{background:color-mix(in srgb,var(--text) 3%,transparent)}.hour-line{position:absolute;left:0;right:0;height:1px;background:var(--line)}.event-card{position:absolute;border:none;cursor:pointer;font:inherit;background:var(--c);color:#fff;border-radius:10px;padding:5px 8px;display:flex;flex-direction:column;align-items:flex-start;gap:1px;overflow:hidden;text-align:left;box-shadow:0 2px 6px color-mix(in srgb,var(--c) 40%,transparent);transition:transform .12s}.event-card:active{transform:scale(.97)}.ev-title{font-size:13px;font-weight:800;line-height:1.2}.ev-time{font-size:11px;font-weight:600;opacity:.85}.now-line{position:absolute;left:0;right:0;height:2.5px;background:#ff3b30;z-index:5;border-radius:2px}.now-line:before{content:"";position:absolute;left:-4px;top:-4px;width:10px;height:10px;border-radius:50%;background:#ff3b30}.month{flex:1;display:flex;flex-direction:column;min-height:0;padding:0 12px 12px}.month-head{display:grid;grid-template-columns:repeat(7,1fr);padding-bottom:6px}.month-dow{text-align:center;font-size:12px;font-weight:700;text-transform:uppercase;color:var(--muted);letter-spacing:.05em}.month-grid{flex:1;display:grid;grid-template-columns:repeat(7,1fr);grid-template-rows:repeat(6,1fr);gap:6px;min-height:0}.month-cell{border:none;cursor:pointer;font:inherit;text-align:left;background:var(--surface);border-radius:12px;padding:8px;display:flex;flex-direction:column;gap:4px;overflow:hidden;box-shadow:0 1px 3px #0000000d}.month-cell.dim{opacity:.4}.month-num{font-size:15px;font-weight:800}.month-cell.is-today .month-num{background:var(--text);color:var(--bg);width:26px;height:26px;line-height:26px;text-align:center;border-radius:50%}.month-pills{display:flex;flex-direction:column;gap:2px;min-width:0}.month-pill{font-size:10.5px;font-weight:700;color:#fff;background:var(--c);border-radius:5px;padding:1.5px 6px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.month-more{font-size:10.5px;font-weight:700;color:var(--muted)}.sheet-backdrop{position:fixed;top:0;right:0;bottom:0;left:0;background:#00000059;z-index:50;display:grid;place-items:center;animation:fade .15s}.sheet{background:var(--surface);border-radius:22px;padding:26px 28px;width:min(440px,88vw);position:relative;overflow:hidden;animation:pop .22s cubic-bezier(.3,1.4,.5,1);box-shadow:0 18px 50px #00000040}.sheet-accent{position:absolute;top:0;left:0;right:0;height:7px;background:var(--c)}.sheet h2{font-size:24px;font-weight:800;margin:6px 0 8px;letter-spacing:-.01em}.sheet p{margin:5px 0;font-size:15px;color:var(--text)}.sheet-when{font-weight:700}.sheet-member{display:flex;align-items:center;gap:8px;color:var(--muted);font-weight:600}.sheet-member .chip-dot{width:12px;height:12px}.sheet-loc,.sheet-desc{color:var(--muted)}.sheet-close{margin-top:18px;border:none;cursor:pointer;font:inherit;font-weight:800;background:var(--text);color:var(--bg);border-radius:12px;padding:11px 22px;font-size:15px;width:100%}@keyframes fade{0%{opacity:0}}@keyframes pop{0%{opacity:0;transform:scale(.9) translateY(14px)}}.auth-wrap{display:grid;place-items:center;height:100%;padding:20px}.auth-card{background:var(--surface);border-radius:22px;padding:34px 32px;width:min(400px,92vw);display:flex;flex-direction:column;gap:12px;box-shadow:0 12px 40px #0000001f;animation:pop .25s cubic-bezier(.3,1.4,.5,1)}.auth-logo{font-size:34px;font-weight:800;letter-spacing:-.03em;text-align:center;background:linear-gradient(90deg,#ff6b6b,#ffb830,#4ecdc4,#8b7cf6);-webkit-background-clip:text;background-clip:text;color:transparent}.auth-sub{text-align:center;color:var(--muted);font-weight:600;margin-bottom:6px}.auth-card input,.f-input{border:2px solid var(--line);background:var(--bg);color:var(--text);font:inherit;font-size:15px;border-radius:12px;padding:11px 14px;width:100%;outline:none;min-width:0}.auth-card input:focus,.f-input:focus{border-color:var(--muted)}.auth-primary{border:none;cursor:pointer;font:inherit;font-weight:800;background:var(--text);color:var(--bg);border-radius:12px;padding:12px;font-size:15px}.auth-primary:disabled{opacity:.5}.auth-switch{border:none;background:transparent;cursor:pointer;font:inherit;color:var(--muted);font-weight:600;font-size:13px}.auth-msg{font-size:13px;font-weight:600;text-align:center}.auth-msg.err{color:#d33}.auth-msg.ok{color:#2a9d5c}.cal-switcher{border:none;background:transparent;color:var(--text);font:inherit;font-size:22px;font-weight:800;letter-spacing:-.02em;cursor:pointer;outline:none;max-width:40vw}.add-btn{white-space:nowrap}.form-sheet,.admin-sheet{display:flex;flex-direction:column;gap:10px}.admin-sheet{width:min(560px,92vw);max-height:84vh;overflow-y:auto}.f-row{display:flex;gap:8px;align-items:center}.f-dash{color:var(--muted);font-weight:700}.f-check{display:flex;gap:8px;align-items:center;font-size:14px;font-weight:600}.f-check input{width:18px;height:18px;accent-color:var(--text)}.btn-secondary{border:2px solid var(--line);background:transparent;color:var(--text);cursor:pointer;font:inherit;font-weight:700;border-radius:12px;padding:10px 16px;font-size:14px;width:100%}.btn-secondary:disabled{opacity:.4}.btn-danger{margin-top:8px;border:none;cursor:pointer;font:inherit;font-weight:700;background:transparent;color:#d33;border-radius:12px;padding:8px;font-size:14px;width:100%}.admin-tabs{align-self:flex-start}.admin-tab{display:flex;flex-direction:column;gap:10px}.admin-list{list-style:none;display:flex;flex-direction:column;gap:6px}.admin-list li{display:flex;align-items:center;gap:10px;background:var(--bg);border-radius:10px;padding:9px 12px;font-size:14px}.admin-item-name{font-weight:700}.name-btn{border:none;background:transparent;cursor:pointer;font:inherit;color:var(--text);padding:0;text-align:left}.name-btn .edit-hint{color:var(--muted);font-size:12px;opacity:.7}.name-edit{max-width:200px;padding:5px 10px}.admin-url{flex:1;color:var(--muted);font-size:12px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;direction:rtl}.admin-empty{color:var(--muted);font-weight:600;justify-content:center}.admin-x{margin-left:auto;border:none;background:transparent;cursor:pointer;color:var(--muted);font-size:13px;font-weight:700;padding:4px}.admin-note{font-size:13px;color:var(--muted);font-weight:600}.palette{display:flex;gap:5px;flex-wrap:wrap}.swatch{width:24px;height:24px;border-radius:50%;border:2.5px solid transparent;cursor:pointer;padding:0}.swatch-on{border-color:var(--text)}.role-badge{margin-left:auto;font-size:11px;font-weight:800;text-transform:uppercase;letter-spacing:.04em;color:var(--muted)}.role-owner{color:#d4941e}.help-links{display:flex;flex-direction:column;gap:4px}.link{border:none;background:transparent;cursor:pointer;font:inherit;color:var(--muted);font-size:13px;font-weight:700;text-align:left;text-decoration:underline;padding:0}.help-steps{padding-left:20px;font-size:13px;color:var(--muted);display:flex;flex-direction:column;gap:4px}.confirm-sheet{display:flex;flex-direction:column;gap:12px;width:min(380px,88vw)}.confirm-sheet h2{margin:0}.person-picker{display:flex;flex-wrap:wrap;gap:6px}.slot-highlight{position:absolute;left:2px;right:2px;z-index:4;border:2.5px dashed var(--text);background:color-mix(in srgb,var(--text) 10%,transparent);border-radius:10px;pointer-events:none;animation:slot-pulse 1.2s ease-in-out infinite}@keyframes slot-pulse{0%,to{opacity:.9}50%{opacity:.45}}.reminder-backdrop{z-index:90}.reminder-sheet{text-align:center}.reminder-label{font-size:13px;font-weight:800;text-transform:uppercase;letter-spacing:.08em;color:var(--c);margin-top:4px}.reminder-now{animation:pop .25s cubic-bezier(.3,1.4,.5,1),pulse 1.6s ease-in-out 3}@keyframes pulse{0%,to{box-shadow:0 18px 50px #00000040}50%{box-shadow:0 18px 60px color-mix(in srgb,var(--c) 55%,transparent)}}
