/* Meadow — Y2K / Frutiger Aero design system.
   Glossy tactile buttons, glass panels, sky + grass, buddy-list presence dots.
   Text is always dark navy on near-white glass for strong contrast. */

/* Brand fonts (see Assets/fonts) */
@font-face { font-family: "Aerobics"; src: url("../Assets/fonts/AerobicsRegular-mLRZP.ttf") format("truetype"); font-display: swap; }
@font-face { font-family: "Myriad"; src: url("../Assets/fonts/MYRIADAT.TTF") format("truetype"); font-weight: 400; font-display: swap; } /* single weight: browser synthesizes bold; now only a fallback */
/* Segoe Alt: body / UI text. Real light, semilight, regular, semibold and bold weights, so no faux bold. */
@font-face { font-family: "Segoe Alt"; font-weight: 300; font-style: normal; font-display: swap; src: url("../Assets/fonts/segoe-alt-cufonfonts/SegoeAltLight.ttf") format("truetype"); }
@font-face { font-family: "Segoe Alt"; font-weight: 300; font-style: italic; font-display: swap; src: url("../Assets/fonts/segoe-alt-cufonfonts/SegoeAltLightItalic.ttf") format("truetype"); }
@font-face { font-family: "Segoe Alt"; font-weight: 350; font-style: normal; font-display: swap; src: url("../Assets/fonts/segoe-alt-cufonfonts/SegoeAltSemilight.ttf") format("truetype"); }
@font-face { font-family: "Segoe Alt"; font-weight: 350; font-style: italic; font-display: swap; src: url("../Assets/fonts/segoe-alt-cufonfonts/SegoeAltSemilightItalic.ttf") format("truetype"); }
@font-face { font-family: "Segoe Alt"; font-weight: 400; font-style: normal; font-display: swap; src: url("../Assets/fonts/segoe-alt-cufonfonts/SegoeAlt.ttf") format("truetype"); }
@font-face { font-family: "Segoe Alt"; font-weight: 400; font-style: italic; font-display: swap; src: url("../Assets/fonts/segoe-alt-cufonfonts/SegoeAltItalic.ttf") format("truetype"); }
@font-face { font-family: "Segoe Alt"; font-weight: 600; font-style: normal; font-display: swap; src: url("../Assets/fonts/segoe-alt-cufonfonts/SegoeAltSemibold.ttf") format("truetype"); }
@font-face { font-family: "Segoe Alt"; font-weight: 600; font-style: italic; font-display: swap; src: url("../Assets/fonts/segoe-alt-cufonfonts/SegoeAltSemiboldItalic.ttf") format("truetype"); }
@font-face { font-family: "Segoe Alt"; font-weight: 700 900; font-style: normal; font-display: swap; src: url("../Assets/fonts/segoe-alt-cufonfonts/SegoeAltBold.ttf") format("truetype"); }
@font-face { font-family: "Segoe Alt"; font-weight: 700 900; font-style: italic; font-display: swap; src: url("../Assets/fonts/segoe-alt-cufonfonts/SegoeAltBoldItalic.ttf") format("truetype"); }
:root {
  --ink: #0b2a4a;
  --ink-soft: #35536f;
  --sky-1: #4aaef2;
  --sky-2: #9ddcff;
  --sky-3: #e6f7ff;
  --grass-1: #6fcf4a;
  --grass-2: #2f9e2f;
  --blue-1: #2b8be0;
  --blue-2: #0a55a3;
  --green-1: #34a83f;
  --green-2: #137224;
  --line: #8dbbe0;
  --glass: rgba(255, 255, 255, 0.66); /* a touch more see-through so the animated sky glows through the panels */
  --glass-strong: rgba(255, 255, 255, 0.84);
  --radius: 16px;
  --shadow: 0 8px 24px rgba(11, 70, 130, 0.25), 0 1px 0 rgba(255, 255, 255, 0.9) inset;
  --font: "Segoe Alt", "Segoe UI", "Myriad", "Frutiger", "Trebuchet MS", Tahoma, Verdana, sans-serif;
}

* { box-sizing: border-box; }
html, body { height: 100%; margin: 0; }
body {
  font-family: var(--font);
  color: var(--ink);
  font-size: 16px;
  line-height: 1.45;
  background: linear-gradient(180deg, #2c9bea 0%, #6cc6fb 45%, #bfeaff 100%) fixed;
  overflow: hidden;
}
h1, h2, h3 { margin: 0 0 8px; line-height: 1.2; }
h1 { font-family: "Aerobics", var(--font); font-weight: 400; letter-spacing: .01em; }
h1 { font-size: 24px; } h2 { font-size: 18px; } h3 { font-size: 15px; }
p { margin: 0 0 8px; }
a { color: #0a5bb5; }
code { background: rgba(10, 85, 163, 0.1); padding: 1px 6px; border-radius: 6px; font-size: 13px; word-break: break-all; }
q { quotes: "“" "”"; }
.hint { color: var(--ink-soft); font-size: 13px; }
.hint.pad-sm { padding: 8px 12px; }
.mono { font-family: Consolas, "Courier New", monospace; font-size: 13px; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip { position: absolute; left: -999px; top: 8px; background: #fff; padding: 8px 12px; border-radius: 8px; z-index: 999; }
.skip:focus { left: 8px; }

:focus-visible { outline: 3px solid #ff9f1a; outline-offset: 2px; }


/* ---------- glass ---------- */
.glass {
  background: linear-gradient(180deg, var(--glass-strong), var(--glass));
  border: 1px solid rgba(255, 255, 255, 0.95);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  backdrop-filter: blur(12px) saturate(1.35);
  -webkit-backdrop-filter: blur(12px) saturate(1.35);
}
/* Vista / Aqua window: a physical pane sitting in front of the sky */
.window.glass, .buddies.glass, .login-card.glass, .modal.glass {
  box-shadow:
    0 22px 48px rgba(8, 50, 100, 0.32),
    0 2px 0 rgba(255, 255, 255, 0.95) inset,
    0 -8px 16px rgba(10, 70, 130, 0.08) inset;
  outline: 1px solid rgba(10, 70, 130, 0.16);
  outline-offset: -1px;
}
.card {
  background: rgba(255, 255, 255, 0.82);
  border: 1px solid rgba(255, 255, 255, 0.95);
  border-radius: 14px;
  box-shadow: 0 4px 14px rgba(11, 70, 130, 0.14), 0 1px 0 #fff inset;
  padding: 14px 16px;
  margin-bottom: 14px;
}

/* ---------- buttons ---------- */
.btn {
  position: relative; overflow: hidden;
  display: inline-flex; align-items: center; gap: 6px; justify-content: center;
  font: inherit; font-weight: 600; color: var(--ink); text-decoration: none; cursor: pointer;
  white-space: nowrap; flex: none;
  padding: 8px 16px; border-radius: 999px;
  border: 1px solid #5b97c9;
  background: linear-gradient(180deg, #ffffff 0%, #dff1ff 48%, #b9defa 52%, #d6eeff 100%);
  box-shadow: 0 3px 0 #5a8bb8, 0 6px 12px rgba(11, 70, 130, 0.28), 0 1px 0 #fff inset, 0 -2px 0 rgba(10, 60, 110, 0.12) inset;
  text-shadow: 0 1px 0 rgba(255, 255, 255, 0.8);
  transition: transform 0.08s, filter 0.15s, box-shadow 0.08s;
}
.btn::before { content: ""; position: absolute; left: 6%; right: 6%; top: 2px; height: 46%; border-radius: 999px 999px 50% 50%; background: linear-gradient(180deg, rgba(255,255,255,.75), rgba(255,255,255,.12)); pointer-events: none; }
.btn:hover:not(:disabled) { filter: brightness(1.06) saturate(1.1); }
.btn:active:not(:disabled) { transform: translateY(2px); box-shadow: 0 1px 0 #5a8bb8, 0 2px 6px rgba(11,70,130,.35) inset; }
.btn:disabled { opacity: 0.55; cursor: not-allowed; }
.btn.primary { color: #fff; border-color: #07407f; text-shadow: 0 1px 1px rgba(0, 30, 70, 0.7); background: linear-gradient(180deg, #4fa8f0 0%, var(--blue-1) 48%, #0f66b8 52%, var(--blue-2) 100%); box-shadow: 0 3px 0 #07407f, 0 6px 12px rgba(11, 70, 130, 0.35), 0 1px 0 rgba(255,255,255,.45) inset; }
.btn.primary::before { background: linear-gradient(180deg, rgba(255,255,255,.5), rgba(255,255,255,.05)); }
.btn.primary:active:not(:disabled) { box-shadow: 0 1px 0 #07407f, 0 2px 6px rgba(7, 40, 80, .45) inset; }
.btn.glossy-green { color: #fff; border-color: #0d5a19; text-shadow: 0 1px 1px rgba(0, 50, 10, 0.7); background: linear-gradient(180deg, #6fd35a 0%, var(--green-1) 48%, #1e8a2b 52%, var(--green-2) 100%); box-shadow: 0 3px 0 #0d5a19, 0 6px 12px rgba(10, 80, 20, 0.3), 0 1px 0 rgba(255,255,255,.4) inset; }
.btn.glossy-green::before { background: linear-gradient(180deg, rgba(255,255,255,.5), rgba(255,255,255,.05)); }
.btn.danger { color: #7a0d0d; border-color: #b05050; background: linear-gradient(180deg, #fff 0%, #ffe3e0 48%, #ffc2bc 52%, #ffd9d5 100%); }
.btn.small { padding: 4px 12px; font-size: 13px; }
.btn.lg { padding: 11px 22px; font-size: 16px; width: 100%; }
.x-btn { border: 0; width: 26px; height: 26px; border-radius: 50%; cursor: pointer; font-size: 16px; line-height: 1; color: #fff; background: radial-gradient(circle at 30% 25%, #ff9a8d, #d83a2b); box-shadow: 0 1px 3px rgba(0,0,0,.35); }
.chip .x-btn { width: 18px; height: 18px; font-size: 13px; margin-left: 4px; }

/* ---------- forms ---------- */
input, select, textarea {
  font: inherit; color: var(--ink); max-width: 100%;
  padding: 7px 10px; border-radius: 10px; border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.96);
  box-shadow: 0 2px 4px rgba(11, 70, 130, 0.12) inset;
}
input[type="checkbox"] { width: 18px; height: 18px; padding: 0; accent-color: var(--blue-1); }
input[type="file"] { max-width: 260px; font-size: 13px; }
textarea { width: 100%; resize: vertical; }
label { display: flex; flex-direction: column; gap: 3px; font-size: 13px; font-weight: 600; }
label.check { flex-direction: row; align-items: center; gap: 6px; font-weight: 500; }
.stack { display: flex; flex-direction: column; gap: 10px; }
.row { display: flex; align-items: center; gap: 10px; }
.row.tight { gap: 6px; } .row.between { justify-content: space-between; } .row.wrap { flex-wrap: wrap; } .row.end { justify-content: flex-end; }
.grow { flex: 1; min-width: 0; }
.spacer { flex: 1; }
.divider { display: flex; align-items: center; gap: 10px; color: var(--ink-soft); font-size: 13px; }
.divider::before, .divider::after { content: ""; flex: 1; height: 1px; background: rgba(11, 70, 130, 0.2); }
.notice { background: #fff6d6; border: 1px solid #e8c95a; border-radius: 10px; padding: 8px 12px; font-size: 13px; }

/* ---------- pills & chips ---------- */
.pill { display: inline-block; font-size: 12px; font-weight: 700; padding: 2px 10px; border-radius: 999px; background: linear-gradient(180deg, #fff, #d9ecfb); border: 1px solid #9cc4e4; color: var(--ink); }
.pill.tiny { font-size: 10px; padding: 0 7px; text-transform: uppercase; letter-spacing: .04em; }
.pill.ok { background: linear-gradient(180deg, #e8ffe4, #b5eeac); border-color: #6bbf5f; color: #0d4a14; }
.pill.warn { background: linear-gradient(180deg, #fff7d9, #ffe08a); border-color: #e0b43a; color: #5a4000; }
.pill.bad { background: linear-gradient(180deg, #ffe9e6, #ffbab2); border-color: #d9857b; color: #7a0d0d; }
.pill.bridge { background: #e6e0ff; border-color: #a99be0; }
.chip { display: inline-flex; align-items: center; gap: 4px; font-size: 12px; font-weight: 600; padding: 2px 9px; border-radius: 999px; background: #e9f3fc; border: 1px solid #b6d3ec; color: var(--ink); font-family: inherit; }
.chip.free { background: #d9f7d4; border-color: #8cd47f; color: #0d4a14; }
.chip.busy { background: #e8ebef; border-color: #b9c0c9; color: #36414d; }
.chip.empty { background: transparent; border-style: dashed; color: var(--ink-soft); }
.chip.person { background: #fff; }
button.chip { cursor: pointer; }
button.chip:hover { background: #d4eaff; }
.chip.toggle.on { background: linear-gradient(180deg, #4fa8f0, var(--blue-2)); color: #fff; border-color: #07407f; }
.chip.link { text-decoration: none; }

.avatar { display: inline-flex; align-items: center; justify-content: center; flex: none; border-radius: 50%; color: #fff; font-weight: 700; text-shadow: 0 1px 2px rgba(0,0,0,.45); border: 2px solid #fff; box-shadow: 0 1px 4px rgba(11,70,130,.4), inset 0 -4px 8px rgba(0,0,0,.12); }
.avatar.placeholder { border-style: dashed; border-color: #8aa; opacity: .75; }
.avatars { display: flex; align-items: center; gap: 2px; flex-wrap: wrap; margin: 4px 0; }
.avatars .avatar { margin-right: -4px; }
.dewey { display: inline-block; flex: none; border-radius: 50%; border: 2px solid #fff; box-shadow: 0 2px 6px rgba(10, 80, 140, .45);
  background: url("../Assets/dewey.png") 50% 42% / 122% no-repeat, #d6efff; image-rendering: pixelated; }

/* ---------- shell ---------- */
.desk { height: 100vh; display: flex; flex-direction: column; gap: 10px; padding: 10px 14px 4px; }
.titlebar { display: flex; align-items: center; gap: 12px; padding: 6px 14px; border-radius: 999px; flex: none; }
.brand { display: flex; align-items: center; gap: 8px; text-decoration: none; color: inherit; }
.wordmark { font-family: "Aerobics", var(--font); font-size: 26px; white-space: nowrap; font-weight: 400; letter-spacing: .02em; color: #08407f; text-shadow: 0 1px 0 #fff, 0 0 8px rgba(255,255,255,.9); }
.logo-img { display: block; flex: none; border-radius: 18%; border: 2px solid #fff; box-shadow: 0 3px 10px rgba(11,70,130,.45), 0 0 0 1px rgba(11,70,130,.25); object-fit: cover; }
.login-hero .logo-img { border-radius: 24px; border-width: 4px; margin-bottom: 8px; max-width: 100%; height: auto; }
.tagline-sm { color: var(--ink-soft); font-size: 13px; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; min-width: 0; }
.layout { flex: 1; min-height: 0; display: grid; grid-template-columns: 68px minmax(0, 1fr) 270px; gap: 12px; }
.window { min-width: 0; min-height: 0; display: flex; flex-direction: column; overflow: hidden; }
.footer { text-align: center; font-size: 12px; color: var(--ink); padding: 2px; text-shadow: 0 1px 0 rgba(255,255,255,.7); flex: none; }

.rail { display: flex; flex-direction: column; align-items: center; gap: 10px; padding: 12px 6px; overflow-y: auto; overflow-x: hidden; }
.rail-btn { width: 48px; height: 48px; flex: none; display: flex; align-items: center; justify-content: center; font-size: 24px; border-radius: 16px; cursor: pointer; text-decoration: none; border: 1px solid #7fb3dd; background: linear-gradient(180deg, #fff 0%, #e7f4ff 46%, #b7dcf7 54%, #cfe8fa 100%); box-shadow: 0 3px 0 #6a9fc8, 0 5px 10px rgba(11,70,130,.32), 0 1px 0 #fff inset; color: var(--ink); font-family: inherit; }
.rail-btn:hover { filter: brightness(1.06); }
.rail-btn.active { background: linear-gradient(180deg, #7cc8ff, #2b8be0); border-color: #07407f; box-shadow: 0 0 0 3px #fff, 0 0 10px 3px rgba(43,139,224,.7); }
.rail-btn.add { font-size: 28px; font-weight: 700; color: #137224; }

.main-scroll { flex: 1; overflow-y: auto; min-height: 0; }
.pad { padding: 16px; }
.two-col { display: grid; grid-template-columns: repeat(auto-fit, minmax(380px, 1fr)); gap: 0 16px; align-content: start; }
.two-col > * { min-width: 0; }

.org-window { display: flex; flex-direction: column; height: 100%; min-height: 0; }
.org-head { padding: 12px 16px 0; border-bottom: 1px solid rgba(11,70,130,.15); background: linear-gradient(180deg, rgba(255,255,255,.7), rgba(255,255,255,0)); flex: none; }
.org-title { display: flex; align-items: center; gap: 10px; margin-bottom: 8px; }
.org-title h1 { margin: 0; }
.org-emoji { font-size: 28px; }
.org-emoji.sm { font-size: 26px; }
.org-body { flex: 1; min-height: 0; display: flex; flex-direction: column; }
.org-body > .main-scroll, .org-body > .chat-layout { flex: 1; min-height: 0; }
.tabs { display: flex; gap: 4px; flex-wrap: wrap; }
.tab { position: relative; text-decoration: none; color: var(--ink); font-weight: 600; padding: 8px 16px; border-radius: 12px 12px 0 0; border: 1px solid transparent; border-bottom: 0; }
.tab:hover { background: rgba(255,255,255,.7); }
.tab.active { background: linear-gradient(180deg, #fff, #e3f3ff); border-color: #9cc4e4; box-shadow: 0 -2px 6px rgba(11,70,130,.12); }
.badge { display: inline-block; min-width: 18px; text-align: center; margin-left: 5px; font-size: 11px; font-weight: 800; color: #fff; background: radial-gradient(circle at 30% 25%, #ff9a8d, #d83a2b); border-radius: 999px; padding: 0 5px; }

/* ---------- login ---------- */
.login { height: 100vh; overflow-y: auto; display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(320px, 440px); gap: 40px; align-items: center; justify-content: center; padding: 40px 6vw; }
.login-hero { text-align: left; }
.login-hero .tagline { font-size: 20px; font-weight: 700; color: #06335f; text-shadow: 0 1px 0 rgba(255,255,255,.8); margin-bottom: 12px; }
.login-hero .lede { font-size: 17px; max-width: 520px; background: rgba(255,255,255,.55); padding: 10px 14px; border-radius: 14px; }
.bullets { list-style: none; padding: 0; margin: 12px 0 0; display: grid; gap: 6px; font-weight: 600; }
.login-card { padding: 22px; display: flex; flex-direction: column; gap: 12px; }
.login-card h2 { margin: 0; }
.profile-list { display: flex; flex-wrap: wrap; gap: 6px; }
.profile { display: inline-flex; align-items: center; gap: 6px; padding: 3px 12px 3px 4px; border-radius: 999px; border: 1px solid #9cc4e4; background: #fff; cursor: pointer; font: inherit; color: var(--ink); }
.profile:hover { background: #e4f3ff; }
.lede { color: var(--ink); }
.wave { display: inline-block; animation: wave 2s ease-in-out infinite; transform-origin: 70% 70%; }
@keyframes wave { 0%, 60%, 100% { transform: rotate(0); } 10%, 30% { transform: rotate(16deg); } 20%, 40% { transform: rotate(-8deg); } }

/* ---------- landing: vertical sine-wave bars ---------- */
.login { position: relative; }
.login > .login-hero, .login > .login-card { position: relative; z-index: 1; }
.wave-bg { position: fixed; left: 0; top: 0; bottom: 0; width: 48vw; z-index: 0; pointer-events: none; overflow: hidden; }
.wave-bg svg { display: block; width: 100%; height: 200%; animation: wave-drift 22s linear infinite; }
@keyframes wave-drift { to { transform: translateY(-16.6667%); } } /* exactly one wave period */
/* signed-in home: same wave, contained in the window */
.home-wrap { position: relative; flex: 1; min-height: 0; display: flex; overflow: hidden; --wave-w: clamp(90px, 16%, 190px); }
.home-wrap .wave-bg { position: absolute; width: var(--wave-w); }
.home-content { position: relative; z-index: 1; flex: 1; padding-left: calc(var(--wave-w) + 10px); }
.wave-bg path { vector-effect: non-scaling-stroke; }
@media (max-width: 960px) { .wave-bg { width: 20vw; opacity: .85; } }

/* ---------- home ---------- */
.steps { list-style: none; padding: 0; margin: 0; display: grid; gap: 10px; }
.steps li { display: flex; align-items: center; gap: 12px; }
.steps li > div { flex: 1; } .steps p { margin: 0; }
.check { width: 28px; height: 28px; flex: none; border-radius: 50%; border: 2px solid #8dbbe0; background: #fff; display: inline-flex; align-items: center; justify-content: center; font-weight: 800; color: #fff; }
.steps li.done .check { background: radial-gradient(circle at 30% 25%, #9be68a, #2f9e2f); border-color: #1e7a1e; }
.org-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(190px, 1fr)); gap: 12px; margin-bottom: 12px; }
.org-card { display: flex; flex-direction: column; gap: 4px; padding: 14px; border-radius: 14px; text-decoration: none; color: var(--ink); border: 1px solid #9cc4e4; background: linear-gradient(180deg, #fff, #e0f1ff); box-shadow: 0 2px 6px rgba(11,70,130,.2); }
.org-card:hover { filter: brightness(1.04); transform: translateY(-1px); }
.org-card .org-emoji { font-size: 34px; }

/* ---------- buddy list ---------- */
.buddies { display: flex; flex-direction: column; min-height: 0; overflow: hidden; }
.buddy-head { padding: 10px 14px; display: flex; justify-content: space-between; align-items: baseline; background: linear-gradient(180deg, #8fd2ff, #3a9be8); color: #04243f; border-radius: 15px 15px 0 0; font-size: 15px; text-shadow: 0 1px 0 rgba(255,255,255,.6); }
.buddy-head .hint { color: #0b3a66; }
.my-status { padding: 10px 12px; display: flex; flex-direction: column; gap: 6px; border-bottom: 1px solid rgba(11,70,130,.15); }
.my-status select { margin-left: auto; }
.my-status p { margin: 0; }
.buddies-scroll { flex: 1; overflow-y: auto; min-height: 0; padding: 6px 8px; }
.bgroup > summary { cursor: pointer; font-weight: 700; font-size: 13px; padding: 4px 4px; color: #06335f; }
.bgroup ul { list-style: none; margin: 0 0 6px; padding: 0; }
.buddy { width: 100%; display: flex; align-items: center; gap: 8px; text-align: left; border: 0; background: transparent; cursor: pointer; font: inherit; color: var(--ink); padding: 5px 6px; border-radius: 10px; }
.buddy:hover { background: rgba(120, 190, 245, 0.3); }
.buddy-main { display: flex; flex-direction: column; flex: 1; min-width: 0; }
.buddy-name { font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.buddy-away { font-size: 12px; color: var(--ink-soft); font-style: italic; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.dot { width: 13px; height: 13px; border-radius: 50%; flex: none; border: 1px solid rgba(0,0,0,.35); box-shadow: 0 1px 2px rgba(0,0,0,.3), inset 0 -3px 4px rgba(0,0,0,.15); }
.dot.online { background: radial-gradient(circle at 30% 25%, #d6ffc9, #2fbf3f); }
.dot.away { background: radial-gradient(circle at 30% 25%, #fff3b8, #f0b21a); }
.dot.offline { background: radial-gradient(circle at 30% 25%, #f4f6f8, #98a3ae); }
.demo-switch { padding: 8px 12px; border-top: 1px solid rgba(11,70,130,.15); font-size: 13px; }
.demo-switch summary { cursor: pointer; font-weight: 700; }
.demo-people { display: flex; flex-wrap: wrap; gap: 4px; }

/* ---------- chat ---------- */
.chat-layout { display: grid; grid-template-columns: 190px minmax(0, 1fr); min-height: 0; }
.channels { padding: 10px; overflow-y: auto; border-right: 1px solid rgba(11,70,130,.15); background: rgba(255,255,255,.35); }
.channels h3 { font-size: 12px; text-transform: uppercase; letter-spacing: .06em; color: var(--ink-soft); margin: 10px 4px 4px; }
.channel { display: flex; flex-direction: column; width: 100%; text-align: left; border: 0; background: transparent; padding: 6px 8px; border-radius: 10px; cursor: pointer; font: inherit; color: var(--ink); font-weight: 600; }
.channel small { color: var(--ink-soft); font-weight: 500; }
.channel:hover { background: rgba(120,190,245,.3); }
.channel.active { background: linear-gradient(180deg, #fff, #cfe8fa); box-shadow: 0 1px 3px rgba(11,70,130,.3); }
.sim { margin-top: 14px; font-size: 13px; }
.sim input, .sim select { width: 100%; margin-top: 4px; }
.sim .btn { margin-top: 6px; }
.chat { display: flex; flex-direction: column; min-width: 0; min-height: 0; height: 100%; }
.chat-head { padding: 8px 16px; display: flex; justify-content: space-between; align-items: baseline; border-bottom: 1px solid rgba(11,70,130,.12); flex: none; }
.chat-log { flex: 1; overflow-y: auto; padding: 12px 16px; display: flex; flex-direction: column; gap: 12px; min-height: 120px; }
.msg { display: flex; gap: 10px; align-items: flex-start; }
.msg-body { min-width: 0; max-width: 100%; }
.msg-meta { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; }
.msg-meta time { font-size: 11px; color: var(--ink-soft); }
.msg-text { overflow-wrap: anywhere; }
.msg.bot .msg-text { background: linear-gradient(180deg, #f2fbff, #d9f1ff); border: 1px solid #a8d6f2; border-radius: 4px 14px 14px 14px; padding: 6px 12px; display: inline-block; }
.msg.mine .msg-text { background: linear-gradient(180deg, #fff, #e6f1fb); border-radius: 4px 14px 14px 14px; padding: 4px 12px; display: inline-block; border: 1px solid #c3dcf1; }
.mention { background: #fff0b8; border-radius: 6px; padding: 0 3px; font-weight: 600; }
.msg-card { margin-top: 6px; background: #fff; border: 1px solid #b6d3ec; border-radius: 12px; padding: 10px 12px; display: flex; flex-direction: column; gap: 6px; max-width: 560px; box-shadow: 0 2px 6px rgba(11,70,130,.12); }
.msg-card.flare { border-color: #f0a36a; background: linear-gradient(180deg, #fffaf2, #ffe9d2); }
.quick { display: flex; gap: 6px; flex-wrap: wrap; padding: 4px 16px; flex: none; }
.chat-form { display: flex; gap: 8px; padding: 10px 16px 14px; flex: none; }
.chat-form input { flex: 1; border-radius: 999px; padding: 9px 16px; }
.chat-embed .chat { height: 420px; }
.chat-embed { padding: 0; overflow: hidden; }
.sugg-row { display: flex; gap: 10px; align-items: flex-start; padding: 6px 0; border-top: 1px solid #e0edf8; }
.sugg-row:first-child { border-top: 0; }
.sugg-main { flex: 1; min-width: 0; }
.score { width: 48px; height: 48px; flex: none; border-radius: 50%; display: flex; flex-direction: column; align-items: center; justify-content: center; line-height: 1; background: radial-gradient(circle at 30% 25%, #e8ffe0, #8fdc7f); border: 2px solid #fff; box-shadow: 0 1px 4px rgba(11,70,130,.4); }
.score b { font-size: 16px; } .score small { font-size: 9px; color: #134c1d; }
.score.big { width: 62px; height: 62px; } .score.big b { font-size: 22px; }
.reasons { margin: 4px 0 0; padding-left: 18px; font-size: 13px; color: var(--ink-soft); }
.nudge { border-top: 1px solid #e0edf8; padding-top: 6px; } .nudge:first-child { border-top: 0; padding-top: 0; }
.nudge p { margin: 4px 0; }

/* ---------- events ---------- */
.seg { display: inline-flex; border-radius: 999px; overflow: hidden; border: 1px solid #5b97c9; box-shadow: 0 2px 4px rgba(11,70,130,.25); }
.seg-btn { border: 0; padding: 7px 14px; font: inherit; font-weight: 600; cursor: pointer; background: linear-gradient(180deg, #fff, #cfe8fa); color: var(--ink); border-right: 1px solid #9cc4e4; }
.seg-btn:last-child { border-right: 0; }
.seg-btn.active { background: linear-gradient(180deg, #4fa8f0, var(--blue-2)); color: #fff; text-shadow: 0 1px 1px rgba(0,30,70,.6); }
.event-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 14px; margin-top: 14px; }
.event-card { display: flex; flex-direction: column; gap: 6px; padding: 14px; border-radius: 14px; text-decoration: none; color: var(--ink); background: linear-gradient(180deg, #fff, #e8f5ff); border: 1px solid #a8cde8; box-shadow: 0 3px 10px rgba(11,70,130,.18); }
.event-card:hover { transform: translateY(-2px); box-shadow: 0 6px 16px rgba(11,70,130,.28); }
.event-card.status-confirmed { border-left: 6px solid #3dbb4a; }
.event-card.status-pending { border-left: 6px solid #f0b21a; }
.event-card.status-cancelled { border-left: 6px solid #c0c7cf; opacity: .75; }
.event-card h3 { margin: 0; font-size: 17px; }
.empty { text-align: center; padding: 40px 10px; }
.back { display: inline-block; margin-bottom: 10px; font-weight: 600; }
.meter { height: 12px; border-radius: 999px; background: #dbe8f3; box-shadow: 0 2px 3px rgba(0,0,0,.18) inset; overflow: hidden; border: 1px solid #b9cfe2; }
.meter.thin { height: 8px; }
.meter i { display: block; height: 100%; border-radius: 999px; background: linear-gradient(180deg, #a6f08f, #3dbb4a 55%, #27922f); box-shadow: 0 1px 0 rgba(255,255,255,.6) inset; transition: width .4s; }
.role { display: flex; gap: 12px; align-items: flex-start; padding: 10px 0; border-top: 1px solid #dbe9f5; }
.role:first-of-type { border-top: 0; }
.role.full { opacity: .85; }
.role-main { flex: 1; min-width: 0; }
.role-actions { display: flex; gap: 6px; flex-wrap: wrap; justify-content: flex-end; }
.claimants { display: flex; flex-wrap: wrap; gap: 4px; margin-top: 4px; align-items: center; align-content: flex-start; }
.cands { margin-top: 6px; display: flex; flex-wrap: wrap; gap: 4px; align-items: center; }
.big-code { font-family: Consolas, monospace; font-size: 34px; font-weight: 800; letter-spacing: .12em; text-align: center; padding: 8px; border-radius: 14px; background: linear-gradient(180deg, #fff, #d9efff); border: 2px dashed #4fa8f0; }
.guestbook { list-style: none; padding: 0; margin: 0 0 10px; display: grid; gap: 8px; }
.guestbook li { background: #fffdf0; border: 1px solid #ecdca0; border-radius: 4px 12px 12px 12px; padding: 8px 12px; }

/* ---------- schedule ---------- */
.finder-form { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 10px; margin: 10px 0; align-items: end; }
.finder-form .days { grid-column: 1 / -1; display: flex; gap: 4px; flex-wrap: wrap; }
.understood { display: flex; gap: 4px; flex-wrap: wrap; align-items: center; margin: 8px 0; }
.roles-chips { display: flex; gap: 6px; flex-wrap: wrap; align-items: center; margin-bottom: 10px; }
.results { margin-top: 10px; }
.result { display: flex; gap: 12px; padding: 12px; border-radius: 14px; background: #fff; border: 1px solid #b6d3ec; margin-bottom: 10px; box-shadow: 0 2px 6px rgba(11,70,130,.12); }
.result.best { border-color: #5cbf4d; box-shadow: 0 0 0 2px rgba(92,191,77,.35), 0 2px 8px rgba(11,70,130,.15); }
.result-main { flex: 1; min-width: 0; }
.result-actions { display: flex; align-items: center; }
.bars { display: grid; grid-template-columns: repeat(auto-fit, minmax(110px, 1fr)); gap: 6px 12px; margin: 6px 0; }
.bar small { display: block; font-size: 11px; color: var(--ink-soft); }
.cover { display: flex; gap: 4px; flex-wrap: wrap; margin-bottom: 4px; }
.heat-wrap { overflow-x: auto; }
.heatmap { border-collapse: separate; border-spacing: 2px; width: 100%; font-size: 12px; text-align: center; }
.heatmap th { font-weight: 700; color: var(--ink-soft); padding: 2px 4px; white-space: nowrap; }
.heatmap th.today { color: #0a55a3; }
.heatmap th[scope="row"] { text-align: right; }
.heat { height: 24px; min-width: 42px; border-radius: 6px; color: var(--ink); font-weight: 700; background: rgba(60, 170, 245, calc(0.08 + var(--r) * 0.72)); }
.heat.has-event { outline: 2px solid #f0a31a; outline-offset: -2px; }
.legend { display: flex; align-items: center; gap: 8px; font-size: 12px; color: var(--ink-soft); }
.legend .grad { width: 120px; height: 10px; border-radius: 999px; background: linear-gradient(90deg, rgba(60,170,245,.08), rgba(60,170,245,.8)); border: 1px solid #b9cfe2; }

/* ---------- role editor ---------- */
.role-editor { display: grid; gap: 6px; }
.role-edit { display: flex; align-items: flex-end; gap: 8px; flex-wrap: wrap; background: rgba(255,255,255,.7); padding: 6px 8px; border-radius: 10px; border: 1px solid #cfe2f2; }
.role-edit input[type="text"], .role-edit > input { width: 150px; }
.role-edit label { flex-direction: row; align-items: center; gap: 4px; font-weight: 500; }
.role-edit input[type="number"] { width: 70px; }

/* ---------- members / board / me ---------- */
.member { display: flex; align-items: center; gap: 10px; padding: 8px 0; border-top: 1px solid #dbe9f5; }
.member:first-child { border-top: 0; }
.invite { display: inline-block; max-width: 100%; }
.flare-card { display: flex; gap: 10px; align-items: center; padding: 10px; border-radius: 12px; border: 1px solid #cbd7e2; background: #f5f8fb; margin-bottom: 8px; }
.flare-card.open { border-color: #f0a36a; background: linear-gradient(180deg, #fffaf2, #ffe9d2); }
.flare-icon { font-size: 26px; }
.tracks { display: grid; gap: 4px; }
.track-row { display: grid; grid-template-columns: 90px 1fr; align-items: center; gap: 8px; font-size: 12px; }
.track { position: relative; height: 16px; border-radius: 999px; background: linear-gradient(180deg, #d4f2cb, #aee69f); border: 1px solid #8cc97d; overflow: hidden; }
.track i { position: absolute; top: 0; bottom: 0; background: repeating-linear-gradient(45deg, #8995a1, #8995a1 4px, #9aa6b2 4px, #9aa6b2 8px); }
.track-scale { display: flex; justify-content: space-between; font-size: 11px; color: var(--ink-soft); margin: 2px 0 0 98px; }
ul.plain { list-style: none; padding: 0; margin: 0 0 10px; display: grid; gap: 6px; }

/* ---------- modal & toast ---------- */
.overlay { position: fixed; inset: 0; z-index: 50; background: rgba(8, 50, 100, 0.35); backdrop-filter: blur(3px); display: flex; align-items: center; justify-content: center; padding: 16px; }
.modal { width: min(560px, 94vw); max-height: 92vh; overflow-y: auto; padding: 0; background: linear-gradient(180deg, #fff, #eaf6ff); }
.modal.wide { width: min(780px, 94vw); }
.modal-title { display: flex; justify-content: space-between; align-items: center; padding: 10px 16px; font-weight: 800; font-size: 17px; background: linear-gradient(180deg, #8fd2ff, #3a9be8); border-radius: 15px 15px 0 0; color: #04243f; text-shadow: 0 1px 0 rgba(255,255,255,.6); }
.modal-body { padding: 16px; }
#toast-root { position: fixed; bottom: 28px; left: 50%; transform: translateX(-50%); z-index: 90; display: flex; flex-direction: column; gap: 8px; align-items: center; pointer-events: none; }
.toast { background: linear-gradient(180deg, #fff, #d4ecff); border: 1px solid #6aa7d6; border-radius: 999px; padding: 8px 18px; font-weight: 600; box-shadow: 0 6px 18px rgba(11,70,130,.4); animation: pop .25s ease-out; max-width: 90vw; }
.toast.out { opacity: 0; transition: opacity .4s; }
@keyframes pop { from { transform: translateY(12px) scale(.95); opacity: 0; } }

/* ---------- responsive ---------- */
@media (max-width: 1100px) {
  .layout { grid-template-columns: 60px minmax(0, 1fr); }
  .buddies { display: none; }
}
@media (max-width: 960px) {
  .login { grid-template-columns: 1fr; height: 100vh; }
}
@media (max-width: 760px) {
  body { overflow: auto; }
  .desk { height: auto; min-height: 100vh; }
  .layout { grid-template-columns: 1fr; }
  .rail { flex-direction: row; padding: 6px; overflow-x: auto; }
  .window { min-height: 70vh; }
  .login { grid-template-columns: 1fr; height: auto; }
  .chat-layout { grid-template-columns: 1fr; }
  .channels { display: flex; gap: 4px; overflow-x: auto; border-right: 0; border-bottom: 1px solid rgba(11,70,130,.15); }
  .channels h3, .sim { display: none; }
  .channel { width: auto; white-space: nowrap; }
  .tagline-sm { display: none; }
  .tab { padding: 6px 10px; }
  }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
  #fx-meadow { transform: none; perspective: none; }
}
@media (prefers-contrast: more) {
  .hint { color: #1a3550; }
  .glass, .card { background: #fff; }
}
/* Shared backend connection and save state. */
.connection-status { position: fixed; bottom: 8px; right: 12px; z-index: 1000; padding: 5px 10px; border-radius: 12px; background: #eef9ed; color: #234c34; font: 12px system-ui, sans-serif; box-shadow: 0 1px 5px #0002; }
.connection-status.error { background: #fff0de; color: #713a08; }

/* Organization pulse: narrow bars preserve room for board content. */
.pulse-chart { display: flex; align-items: end; gap: 3px; height: 90px; margin: 12px 0; border-bottom: 1px solid #aab7bd; }
.pulse-column { height: 100%; flex: 1; display: flex; align-items: end; min-width: 0; }
.pulse-column i { display: block; width: 100%; background: #4c9470; border-radius: 3px 3px 0 0; }
.memory-result { margin: 12px 0; overflow-wrap: anywhere; }
.memory-result p { margin: 4px 0; }

/* =====================================================================
   Frutiger Aero scenery & polish (driven by js/fx.js)
   Layers, back to front: sky 0 · sun/hills 1 · rising bubbles 2 · app 3 · 3D soap bubbles 4
   ===================================================================== */
#fx-sky, #fx-sun, #fx-meadow, #fx-hills, #fx-bubbles { position: fixed; pointer-events: none; }
#fx-sky { inset: 0; z-index: 0; }
#fx-bubbles { inset: 0; z-index: 2; }
#fx-bubbles canvas { display: block; }
#app { position: relative; z-index: 3; }
#fx-orbs { position: fixed; inset: 0; width: 100vw; height: 100vh; z-index: 4; pointer-events: none; }
#fx-burst { position: fixed; inset: 0; z-index: 80; pointer-events: none; overflow: hidden; }
#fx-burst i { position: absolute; border-radius: 50%; border: 1px solid rgba(255,255,255,.95);
  background: radial-gradient(circle at 30% 28%, #fff 0 16%, rgba(196,238,255,.6) 46%, rgba(90,184,242,.38) 100%);
  box-shadow: 0 0 8px rgba(120,205,255,.7); }

/* sun glare + slowly turning rays, top-left like the classic Vista wallpaper */
#fx-sun { z-index: 1; top: -22vmin; left: -22vmin; width: 78vmin; height: 78vmin; mix-blend-mode: screen;
  background: radial-gradient(circle, rgba(255,255,236,.95) 0, rgba(255,248,200,.55) 13%, rgba(255,240,170,.18) 36%, transparent 62%);
  animation: sun-pulse 7s ease-in-out infinite alternate; }
#fx-sun::before { content: ""; position: absolute; inset: -30%; opacity: .5;
  background: repeating-conic-gradient(from 0deg, rgba(255,255,255,.22) 0 3deg, transparent 3deg 13deg);
  -webkit-mask-image: radial-gradient(circle, #000 0, transparent 62%); mask-image: radial-gradient(circle, #000 0, transparent 62%);
  animation: sun-rays 140s linear infinite; }
@keyframes sun-pulse { from { opacity: .8; transform: scale(.97); } to { opacity: 1; transform: scale(1.04); } }
@keyframes sun-rays { to { transform: rotate(360deg); } }

/* 3D meadow under the clouds: a receding grass plane (classic Vista wallpaper) + layered hills */
#fx-meadow {
  inset: 0; z-index: 1; overflow: hidden;
  perspective: 920px; perspective-origin: 50% 58%;
  transform: none;
}
.meadow-haze {
  position: absolute; left: 0; right: 0; bottom: 34vh; height: 18vh;
  background: linear-gradient(180deg, transparent, rgba(210, 240, 255, .55) 40%, rgba(170, 220, 160, .25));
}
.meadow-field {
  position: absolute; left: -28%; right: -28%; bottom: -8%;
  height: 72vh;
  transform: rotateX(58deg);
  transform-origin: 50% 100%;
  border-radius: 50% 50% 0 0 / 10% 10% 0 0;
  background:
    repeating-linear-gradient(90deg, rgba(255,255,255,.16) 0 2px, transparent 2px 52px),
    repeating-linear-gradient(0deg, rgba(255,255,255,.1) 0 2px, transparent 2px 40px),
    linear-gradient(180deg, #c5f59a 0%, #7ee05a 34%, #45c044 70%, #2a8d2a 100%);
  box-shadow: 0 -30px 50px rgba(190, 230, 255, .35) inset, 0 20px 40px rgba(10, 80, 20, .2);
}
/* Bottom scenery: Assets/bottom_small.png (transparent clouds, skyline, trees and grass), pinned to the bottom edge. */
/* The box keeps the image's own 1024:640 shape, so nothing is cropped (a height cap used to slice off the cloud tops). */
#fx-hills { position: absolute; left: 0; right: 0; bottom: 0; aspect-ratio: 1024 / 640;
  background: url("../Assets/bottom_small.png") center bottom / 100% 100% no-repeat; }
.fx-off #fx-sky, .fx-off #fx-sun, .fx-off #fx-bubbles, .fx-off #fx-orbs { display: none; }

/* effects + sound toggles: two little glass orbs, bottom-left */
#fx-controls { position: fixed; left: 12px; bottom: 8px; z-index: 60; display: flex; gap: 6px; }
.fx-btn { position: relative; width: 32px; height: 32px; padding: 0; border-radius: 50%; cursor: pointer; font-size: 15px; line-height: 1; color: var(--ink);
  border: 1px solid #5b97c9; background: radial-gradient(circle at 32% 24%, #fff 0, #dff1ff 38%, #8cc9f4 100%);
  box-shadow: 0 2px 6px rgba(11,70,130,.4), 0 1px 0 #fff inset; transition: transform .25s cubic-bezier(.34,1.56,.64,1), filter .15s; }
.fx-btn:hover { transform: scale(1.15) translateY(-2px); filter: brightness(1.06); }
.fx-btn:active { transform: scale(.95); }
.fx-btn.off { filter: grayscale(.85) brightness(1.05); opacity: .8; }

/* login: floating logo, chip-style bullets so copy stays legible over the live sky */
.logo-tilt { display: inline-block; border-radius: 24px; }
.logo-tilt .logo-img { animation: logo-float 5.5s ease-in-out infinite; }
@keyframes logo-float { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-9px); } }
.login-hero .tagline { display: inline-block; background: rgba(255,255,255,.58); padding: 4px 16px; border-radius: 999px; border: 1px solid rgba(255,255,255,.9); }
.bullets li { width: fit-content; max-width: 100%; background: linear-gradient(180deg, rgba(255,255,255,.82), rgba(214,240,255,.6)); border: 1px solid rgba(255,255,255,.95); border-radius: 999px; padding: 5px 14px; box-shadow: 0 2px 6px rgba(11,70,130,.18); }

/* footer sits over dark hills, so give it a glass pill */
.footer { width: fit-content; max-width: 96vw; margin: 0 auto 4px; padding: 2px 16px; border-radius: 999px; background: rgba(255,255,255,.72); border: 1px solid rgba(255,255,255,.9); }

/* Vista-style diagonal gloss across window chrome */
.titlebar { background-image: linear-gradient(112deg, rgba(255,255,255,.6) 0 24%, rgba(255,255,255,0) 24%), linear-gradient(180deg, var(--glass-strong), var(--glass)); }
.buddy-head { background: linear-gradient(112deg, rgba(255,255,255,.4) 0 30%, rgba(255,255,255,0) 30%), linear-gradient(180deg, #8fd2ff, #3a9be8); }
.modal-title { background: linear-gradient(112deg, rgba(255,255,255,.4) 0 26%, rgba(255,255,255,0) 26%), linear-gradient(180deg, #8fd2ff, #3a9be8); }

/* glossy sheen that sweeps across buttons on hover */
.btn::after { content: ""; position: absolute; top: 0; bottom: 0; left: -70%; width: 45%; pointer-events: none;
  background: linear-gradient(100deg, transparent, rgba(255,255,255,.7), transparent); transform: skewX(-20deg); transition: left .6s ease; }
.btn:hover:not(:disabled)::after { left: 130%; }

/* rail buttons become springy glass orbs */
.rail-btn { position: relative; isolation: isolate; transition: transform .28s cubic-bezier(.34,1.56,.64,1), filter .15s, box-shadow .2s; }
.rail-btn::before { content: ""; position: absolute; z-index: -1; left: 10%; right: 10%; top: 3px; height: 46%; border-radius: 14px 14px 50% 50%; background: linear-gradient(180deg, rgba(255,255,255,.85), rgba(255,255,255,.1)); }
.rail-btn:hover { transform: translateY(-2px) scale(1.1); }
.rail-btn:active { transform: scale(.94); }
.rail-btn.active { animation: orb-glow 2.4s ease-in-out infinite alternate; }
@keyframes orb-glow { from { box-shadow: 0 0 0 3px #fff, 0 0 8px 2px rgba(43,139,224,.6); } to { box-shadow: 0 0 0 3px #fff, 0 0 16px 6px rgba(43,139,224,.85); } }

/* presence dots breathe softly; unread badges bob */
.dot.online { animation: dot-breathe 3s ease-in-out infinite; }
@keyframes dot-breathe { 0%, 100% { box-shadow: 0 1px 2px rgba(0,0,0,.3), inset 0 -3px 4px rgba(0,0,0,.15), 0 0 0 0 rgba(47,191,63,.55); } 50% { box-shadow: 0 1px 2px rgba(0,0,0,.3), inset 0 -3px 4px rgba(0,0,0,.15), 0 0 0 5px rgba(47,191,63,0); } }

/* glossy progress meters: moving highlight */
.meter i { background-image: linear-gradient(180deg, rgba(255,255,255,.55), rgba(255,255,255,0) 55%), linear-gradient(90deg, #a6f08f, #3dbb4a 55%, #27922f); }

/* d3 bubble chart (Org pulse) */
.bubble-chart { display: block; width: 100%; height: auto; max-height: 180px; margin: 8px 0 2px; border-radius: 14px; border: 1px solid #b9d8ee;
  background: linear-gradient(180deg, rgba(255,255,255,.7), rgba(190,235,255,.45)); }
.pb-float { animation: pb-bob 4s ease-in-out infinite alternate; }
@keyframes pb-bob { from { transform: translateY(-3px); } to { transform: translateY(3px); } }

/* vanilla-tilt glare should follow the card's rounded corners */
.org-card, .event-card { will-change: transform; }
.js-tilt-glare { border-radius: inherit; }

@media (max-width: 760px) { #fx-controls { bottom: 52px; left: 8px; } }
.pb-grid { stroke: rgba(11,70,130,.14); stroke-width: 1; stroke-dasharray: 3 5; }

/* Inside the app: bubbles stay behind the panels, the wave bars go away, and the desk sits in 3D in front of the meadow. */
html[data-view="app"] #fx-orbs { z-index: 1; }
html[data-view="app"] #fx-bubbles { opacity: .45; }
html[data-view="app"] .wave-bg { display: none !important; }
html[data-view="app"] .home-content { padding-left: 16px; }

.lede, .hint, .tagline, .tagline-sm { letter-spacing: 0.02em; }
.glass, .card { text-shadow: 0 1px 0 rgba(255, 255, 255, 0.55); }

@media (max-width: 760px) {
  .meadow-field { height: 42vh; }
}
/* Meadow desktop refinement: bright Aero chrome, calm content, sculpted terrain. */
:root { --glass: rgba(246,252,255,.92); --glass-strong: rgba(255,255,255,.97); --radius: 18px; }
body { -webkit-text-stroke: 0; letter-spacing: .01em; }
.aero-icon { display: inline-flex; flex: none; vertical-align: middle; filter: drop-shadow(0 2px 1px #23537228); }
.aero-icon svg { width: 100%; height: 100%; overflow: visible; }
.icon-label, .tab { display: inline-flex; align-items: center; gap: 7px; }
.buddy-icon { display: block; flex: none; object-fit: contain; image-rendering: pixelated; }
#fx-orbs { z-index: 2; opacity: .6; }
#fx-bubbles, #fx-orbs { mask-image: linear-gradient(90deg, #000, transparent 20%, transparent 80%, #000); }
#fx-meadow { inset: 0 -24px; perspective: none; }
.meadow-field { display: none; }
.meadow-haze { bottom: 28vh; height: 24vh; background: radial-gradient(ellipse at center, #e7f6ce65, transparent 70%); }
.wave-bg { width: 13vw; opacity: .32; }
.login { max-width: 1280px; margin: auto; grid-template-columns: minmax(0,1fr) minmax(310px,390px); gap: clamp(28px,5vw,76px); padding: 48px clamp(28px,6vw,80px) 120px; align-content: center; }
.hero-brand { display: flex; align-items: center; gap: 12px; margin-bottom: 25px; }
.hero-brand .wordmark { font-size: clamp(38px, 4.8vw, 52px); }
.hero-brand .logo-img { border-radius: 15px; border-width: 2px; margin: 0; }
.desktop-label { display: inline-flex; align-items: center; gap: 7px; font-size: 12px; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: #154661; margin-bottom: 15px; }
.login-hero .hero-heading { font-family: var(--font); font-size: clamp(36px,4.2vw,59px); font-weight: 700; letter-spacing: -.055em; line-height: 1.04; color: #123d59; text-shadow: 0 2px 0 #ffffffa6; margin-bottom: 18px; }
/* Logo montage: tightly packed tiles panning down and easing to a stop on the wide logo + tagline. */
.login-hero { align-self: stretch; position: relative; min-height: clamp(440px, 76vh, 800px); }
.reel { --tile-w: clamp(140px, 14vw, 210px); --span: min(44vh, 380px); position: absolute; inset: 0; overflow: hidden;
  -webkit-mask-image: linear-gradient(to bottom, transparent 0, #000 16%, #000 84%, transparent 100%);
  mask-image: linear-gradient(to bottom, transparent 0, #000 16%, #000 84%, transparent 100%); }
.reel-pending .reel-col { visibility: hidden; }
.reel-col { position: absolute; left: 0; top: 50%; width: 100%; padding: 4px; transform: translateY(-50%); display: flex; flex-direction: column; gap: 10px; will-change: transform; }
.reel-above { height: var(--span); display: flex; flex-direction: column; justify-content: flex-end; gap: 10px; }
.reel-below-box { height: var(--span); }
.reel-below { display: flex; flex-direction: column; gap: 10px; }
.reel-main-block { display: flex; flex-direction: column; gap: 14px; }
.reel-tile { flex: none; display: block; width: var(--tile-w); height: auto; border-radius: 16px; border: 3px solid #fff; box-shadow: 0 3px 10px rgba(11,70,130,.4), 0 0 0 1px rgba(11,70,130,.25); object-fit: cover; user-select: none; -webkit-user-drag: none; }
.reel-tile.reel-main { width: calc(var(--tile-w) * 1.4); border-radius: 22px; border-width: 4px; }
@media (max-width: 760px) {
  .login-hero { min-height: 0; }
  .reel { position: static; overflow: visible; -webkit-mask-image: none; mask-image: none; }
  .reel-col { position: static; transform: none; padding: 0; }
  .reel-above, .reel-below-box { display: none; }
  .reel-pending .reel-col { visibility: visible; }
}
.login-hero .tagline { display: block; background: none; border: 0; border-radius: 0; padding: 0; margin: 0; max-width: 440px; font-family: var(--font); font-size: clamp(30px, 3.6vw, 48px); font-weight: 700; line-height: 1.12; letter-spacing: -.03em; color: #123d59; text-shadow: 0 2px 0 #ffffffa6; }
.login-hero .tagline .hl { background: #1c5fd0; color: #fff; text-shadow: none; }
.login-hero .lede { background: none; padding: 0; font-size: 18px; max-width: 400px; line-height: 1.5; margin-bottom: 24px; text-shadow: 0 1px #ffffff85; }
.bullets { gap: 9px; }
.bullets li { display: flex; align-items: center; gap: 12px; border-radius: 13px; width: 100%; max-width: 375px; padding: 10px 13px; background: linear-gradient(#ffffffeb,#eaf8ffd9); font-size: 14px; }
.bullets small { display: block; font-size: 12px; font-weight: 400; color: #375871; margin-top: 1px; }
.login-card { padding: 0 25px 23px; gap: 12px; border: 1px solid #f8ffff; border-radius: 19px; background: linear-gradient(145deg,#fffffffa,#e8f7fff5); }
.login-chrome { display: flex; align-items: center; gap: 8px; margin: 0 -25px 9px; padding: 11px 17px; border-radius: 18px 18px 0 0; border-bottom: 1px solid #84bad4; background: linear-gradient(120deg,#ffffff90,transparent 45%),linear-gradient(#d4f1ff,#88c6e9); font-size: 12px; color: #204e70; text-shadow: 0 1px white; }
.login-card h2 { font: 700 28px 'Trebuchet MS',sans-serif; letter-spacing: -.04em; }
.login-card label { font-size: 13px; }
.login-card input { min-height: 43px; }
.login-card .hint { line-height: 1.5; }
.login-card .btn.lg { white-space: normal; min-height: 46px; font-size: 15px; }
.login-card .profiles { max-height: 150px; overflow-y: auto; }
.btn { min-height: 35px; }
.card, .event-card, .org-card, .role { border-radius: 14px; border: 1px solid #aecddd; box-shadow: 0 3px 0 #c3dbe77a,0 6px 15px #17456b0d,inset 0 1px #fff; }
.card, .role { background: #fafdfff5; }
.event-card { position: relative; background: linear-gradient(135deg,#fffef4,#f6fbef); padding-top: 21px; }
.event-card::before { content: ''; position: absolute; top: 7px; left: calc(50% - 4px); width: 8px; height: 8px; border-radius: 50%; background: radial-gradient(circle at 30% 25%,white,#79b2c7 45%,#347493); box-shadow: 0 2px 2px #234b6d55; }
.org-head { background: linear-gradient(120deg,#ffffffa6,transparent 50%),linear-gradient(#cae9f9,#e7f4fb); }
.buddy-head, .modal-title { border-bottom: 1px solid #8cb9cf; }
.titlebar { border-radius: 15px; }
.tab { padding: 9px 12px; font-size: 14px; }
.garden-progress { display: flex; align-items: center; gap: 9px; padding: 9px 0 3px; }
.garden-progress .meter { margin: 0 0 5px; }
.garden-progress small { color: #365d3f; }
.bloom-toast { display: flex; align-items: center; gap: 12px; background: #f5ffeef5; border-color: #a4c88c; }
.bloom-toast .icon-flower { animation: claim-bloom .65s cubic-bezier(.2,.8,.3,1.4) both; transform-origin: bottom; }
@keyframes claim-bloom { from { transform: scale(.25) rotate(-18deg); opacity: 0; } to { transform: scale(1) rotate(0); opacity: 1; } }
.empty .aero-icon { margin-bottom: 10px; }
.rail-btn.active, .dot.online { animation: none; }
.desk { padding: 14px 18px 44px; }
.two-col { grid-template-columns: repeat(auto-fit,minmax(min(100%,340px),1fr)); }
@media (max-width: 1000px) and (min-width: 761px) {
  .login { grid-template-columns: minmax(0,1fr) minmax(300px,350px); gap: 28px; padding: 32px 30px 100px; }
  .login-hero .hero-heading { font-size: 42px; }
}
@media (max-width: 760px) {
  .login { display: flex; flex-direction: column; justify-content: flex-start; align-items: stretch; gap: 25px; padding: 28px 20px 115px; }
  .login-hero { text-align: left; max-width: 440px; width: 100%; margin: auto; }
  .hero-brand { margin-bottom: 18px; }
  .hero-brand .logo-img { width: 72px; height: 72px; }
  .hero-brand .wordmark { font-size: clamp(27px, 7.8vw, 38px); }
  .login-hero .hero-heading { font-size: clamp(34px,8vw,46px); }
  .desktop-label { font-size: 10px; }
  .login-hero .lede { font-size: 16px; margin-bottom: 16px; }
  .bullets { gap: 6px; }
  .bullets li { max-width: none; padding: 8px 12px; }
  .login-card { width: 100%; max-width: 440px; margin: 0 auto; }
  .desk { padding: 8px 8px 80px; }
  .titlebar { flex-wrap: wrap; gap: 7px; }
  .titlebar .tagline-sm { display: none; }
  .titlebar .btn { font-size: 12px; }
  .tabs { flex-wrap: nowrap; overflow-x: auto; }
  .tab { white-space: nowrap; flex: none; padding: 10px; }
  .row.between { flex-wrap: wrap; }
  .footer { display: none; }
  #fx-controls { bottom: 12px; }
  .connection-status { max-width: calc(100vw - 100px); font-size: 11px; }
}
@media (prefers-reduced-motion: reduce) {
  #fx-meadow { transform: none; }
  .bloom-toast .icon-flower { animation: none; }
}
.fx-off #fx-meadow { transform: none; }

/* Keep the top of the welcome screen reachable on short laptop windows. */
@media (min-width: 761px) { .login { align-content: safe center; } }

/* Stationary landscape beneath a higher cloud bank and a smaller Aero sun. */
#fx-sky {
  bottom: auto;
  height: 52vh;
  min-height: 200px;
  mask-image: linear-gradient(to bottom, #000 0%, #000 55%, transparent 100%);
  -webkit-mask-image: linear-gradient(to bottom, #000 0%, #000 55%, transparent 100%);
}
#fx-sun { top: -11vmin; left: -11vmin; width: 46vmin; height: 46vmin; }

/* A quiet ornamental pond, embedded in the foreground hill. */
.pond-koi { animation: koi-glide 9s ease-in-out infinite alternate; }
.koi-two { animation-duration: 12s; animation-delay: -4s; }
.koi-three { animation-duration: 10s; animation-delay: -6s; }
.pond-ripple { opacity: .28; animation: pond-shimmer 6s ease-in-out infinite alternate; }
@keyframes koi-glide { from { transform: translateX(-9px) rotate(-3deg); } to { transform: translateX(12px) rotate(4deg); } }
@keyframes pond-shimmer { from { opacity: .12; } to { opacity: .4; } }
.fx-off .pond-koi, .fx-off .pond-ripple { animation: none; }
@media (prefers-reduced-motion: reduce) { .pond-koi, .pond-ripple { animation: none; } }

/* ---------- auth ---------- */
.login-card .stack label { margin-top: 2px; }
.login-card .hint.small, .google-slot .hint.small { font-size: 12px; margin: 0; }
.switch-mode { text-align: center; margin: 2px 0 0; }
.link-btn { background: none; border: 0; padding: 0; font: inherit; font-weight: 700; color: var(--blue-2, #0b5fae); text-decoration: underline; cursor: pointer; }
.google-slot { display: flex; flex-direction: column; align-items: stretch; gap: 8px; }
/* Google branding guidelines, light theme: do not restyle beyond these values. */
.gsi-button { display: inline-flex; align-items: center; justify-content: center; gap: 10px; height: 40px; padding: 0 12px; width: 100%;
  background: #fff; border: 1px solid #747775; border-radius: 20px; color: #1f1f1f; cursor: pointer;
  font: 500 14px/20px Roboto, Arial, sans-serif; letter-spacing: .25px; box-sizing: border-box; transition: background-color .218s, box-shadow .218s; }
.gsi-button:hover { background: #f8faff; box-shadow: 0 1px 2px 0 rgba(60,64,67,.30), 0 1px 3px 1px rgba(60,64,67,.15); }
.gsi-button:active { background: #eef3fd; }
.gsi-button:focus-visible { outline: 2px solid #0b57d0; outline-offset: 2px; }
.gsi-icon { display: inline-flex; width: 18px; height: 18px; flex: none; }
.gsi-label { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
/* Workspace hierarchy and a quieter, consistent desktop. */
.login-hero .meadow-tagline { font-size: clamp(30px,3.6vw,46px); letter-spacing: -.035em; line-height: 1.16; max-width: 560px; margin: 0 0 22px; }
.window h1, .org-title h1 { font-family: var(--font); font-weight: 700; font-size: 25px; letter-spacing: -.025em; }
.org-title { flex-wrap: wrap; }
.org-head { padding: 18px 20px 0; }
.pad { padding: 22px; }
.section-heading { margin-bottom: 17px; }
.section-heading h2 { font-size: 23px; }
.focus-grid { display: grid; grid-template-columns: repeat(auto-fit,minmax(min(100%,210px),1fr)); gap: 14px; }
.focus-card { display: flex; flex-direction: column; gap: 10px; padding: 18px; }
.focus-card h3 { font-size: 19px; line-height: 1.25; margin: 0; }
.focus-card p { font-size: 14px; color: var(--ink-soft); }
.focus-card .btn { margin-top: auto; align-self: flex-start; }
.eyebrow { display: flex; align-items: center; gap: 7px; font-size: 12px; font-weight: 700; color: #366579; }
.event-card { display: flex; flex-direction: column; gap: 10px; padding: 24px 19px 18px; }
.event-card h3 { font-size: 22px; line-height: 1.2; margin: 0; }
.event-date { font-size: 16px; font-weight: 700; color: #255779; }
.event-cta { margin-top: auto; padding-top: 12px; border-top: 1px solid #aec7a46b; color: #246339; font-weight: 700; }
.chat-log { padding: 20px; }
.role { padding: 17px; margin-bottom: 13px; }
.wave { animation: none; }
@media(max-width:760px) { .pad { padding: 15px; } .org-head { padding: 15px 14px 0; } .org-title h1 { font-size: 22px; } .login-hero .meadow-tagline { font-size: 33px; } }
