/* Bayswater Common HOA — shared styles for every page */
:root {
  --bg: #0b1220;
  --card: #111a2e;
  --text: #e8eefc;
  --muted: #b8c2e0;
  --brand: #34d399;   /* emerald */
  --brand2: #60a5fa;  /* blue */
  --border: rgba(255, 255, 255, .10);
  --shadow: 0 10px 30px rgba(0, 0, 0, .35);
  --radius: 18px;
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  font-family: ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, Arial, "Noto Sans", sans-serif;
  background:
    radial-gradient(1200px 600px at 20% 10%, rgba(96, 165, 250, .25), transparent 55%),
    radial-gradient(900px 500px at 80% 20%, rgba(52, 211, 153, .20), transparent 60%),
    var(--bg);
  background-attachment: fixed;
  color: var(--text);
  line-height: 1.5;
  overflow-wrap: break-word;
}
a { color: inherit; text-decoration: none; }
img { max-width: 100%; }

/* ---------- Header ---------- */
header { padding: 28px 18px 8px; max-width: 1100px; margin: 0 auto; }
.topbar {
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
  padding: 14px 20px;
  border: 1px solid var(--border);
  background: rgba(17, 26, 46, .55);
  backdrop-filter: blur(8px);
  border-radius: 28px;
  box-shadow: var(--shadow);
}
.brand { display: flex; flex-direction: column; align-items: center; text-align: center; }
.logo {
  width: 20vw; max-width: 220px; min-width: 120px; height: auto;
  border-radius: 24px; object-fit: cover; display: block; margin: 0 auto 8px;
}
.brand h1 { margin: 0; font-size: 15px; letter-spacing: .3px; font-weight: 800; }
.brand p { margin: 0; font-size: 12.5px; color: var(--muted); }
nav { display: flex; gap: 6px; flex-wrap: wrap; justify-content: flex-end; }
.navlink {
  padding: 10px 14px; border-radius: 999px; border: 1px solid transparent;
  color: var(--muted); font-weight: 650; font-size: 14px;
}
.navlink:hover, .navlink:focus-visible { border-color: rgba(255, 255, 255, .14); background: rgba(255, 255, 255, .04); color: var(--text); }
.navlink[aria-current="page"] { color: var(--text); border-color: rgba(52, 211, 153, .45); background: rgba(52, 211, 153, .10); }

/* ---------- Layout ---------- */
.container { max-width: 1100px; margin: 0 auto; padding: 18px; }
.hero { margin-top: 18px; display: grid; grid-template-columns: 1.15fr .85fr; gap: 16px; align-items: start; }
.hero.wide-main { grid-template-columns: 1.55fr 1fr; }
.stack { display: grid; gap: 16px; }
.card {
  background: rgba(17, 26, 46, .68);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 22px;
  min-width: 0;
}
.card h2 { margin: 0 0 10px; font-size: 28px; letter-spacing: .2px; line-height: 1.2; }
.card > p, .lead { margin: 0 0 18px; color: var(--muted); max-width: 62ch; font-size: 15.5px; }
.card h3 { margin: 0 0 10px; font-size: 17px; letter-spacing: .2px; }
.card .section-title { margin: 36px 0 12px; padding-top: 26px; border-top: 1px solid var(--border); font-size: 18px; }
.card .section-title:first-of-type { margin-top: 22px; padding-top: 0; border-top: 0; }
.muted { color: var(--muted); }
.small { font-size: 13.5px; }
.pill {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 8px 12px; border-radius: 999px;
  background: rgba(96, 165, 250, .10); border: 1px solid rgba(96, 165, 250, .25);
  color: #dbeafe; font-weight: 700; font-size: 13px; margin-bottom: 14px;
}
.text-link { color: var(--brand2); font-weight: 700; text-decoration: underline; text-underline-offset: 2px; }
.text-link:hover { color: var(--brand); }

/* ---------- Home action cards ---------- */
.grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; margin-top: 14px; }
.action {
  padding: 14px; border-radius: 16px; border: 1px solid var(--border);
  background: rgba(255, 255, 255, .03);
  transition: transform .12s ease, border-color .12s ease, background .12s ease;
  display: flex; gap: 12px; align-items: flex-start;
}
.action:hover, .action:focus-visible { transform: translateY(-2px); border-color: rgba(255, 255, 255, .18); background: rgba(255, 255, 255, .05); }
.icon {
  width: 40px; height: 40px; border-radius: 14px; display: grid; place-items: center;
  background: linear-gradient(135deg, rgba(52, 211, 153, .95), rgba(96, 165, 250, .75));
  color: #06111f; font-weight: 900; flex: 0 0 auto;
}
.action h3 { margin: 0 0 4px; font-size: 14.5px; }
.action p { margin: 0; color: var(--muted); font-size: 13.5px; }

/* ---------- Announcements ---------- */
.announcements-box {
  max-height: 420px; overflow-y: auto; overscroll-behavior: contain;
  margin: 10px 0 0; padding: 0 4px 0 0;
  display: flex; flex-direction: column; gap: 10px;
}
.announcements-box.tall { max-height: 640px; }
.announcement {
  padding: 12px; border-radius: 14px; border: 1px solid var(--border);
  background: rgba(255, 255, 255, .03); font-size: 14px; line-height: 1.6;
}
.announcement-date { color: var(--brand); font-size: 12px; font-weight: 700; margin-bottom: 4px; }
.announcement-title { font-weight: 700; margin-bottom: 4px; }
.announcement-text p { margin: 0 0 6px; }
.announcement-text p:last-child { margin-bottom: 0; }
.announcement-text a { color: var(--brand2); text-decoration: underline; }
.announcement-text a:hover { color: var(--brand); }
.no-announcements { padding: 12px; color: var(--muted); font-size: 13.5px; text-align: center; }
.admin-link { margin-top: 14px; padding-top: 12px; border-top: 1px solid var(--border); text-align: center; }
.admin-link a { color: var(--brand2); font-size: 12.5px; font-weight: 700; }
.admin-link a:hover { color: var(--brand); }

/* ---------- Calendar ---------- */
.calendar-wrap { width: 100%; border: 1px solid var(--border); border-radius: 16px; overflow: hidden; background: rgba(255, 255, 255, .92); }
.calendar-wrap iframe { width: 100%; height: 640px; border: 0; display: block; }

/* ---------- Lists (documents, minutes) ---------- */
.list { margin: 10px 0 0; padding: 0; list-style: none; display: grid; gap: 10px; }
.list li {
  padding: 14px 12px; border-radius: 14px; border: 1px solid var(--border);
  background: rgba(255, 255, 255, .03); color: var(--muted); font-size: 14px;
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
}
.list li b { color: var(--text); }
.doclink {
  white-space: nowrap; padding: 9px 14px; border-radius: 999px;
  border: 1px solid rgba(96, 165, 250, .35); background: rgba(96, 165, 250, .10);
  color: #dbeafe; font-weight: 800; font-size: 13px; flex: 0 0 auto;
}
.doclink:hover { background: rgba(96, 165, 250, .2); }

.minutes-box { max-height: 720px; overflow-y: auto; overscroll-behavior: contain; display: grid; gap: 12px; padding-right: 4px; }
.meeting { padding: 14px; border-radius: 14px; border: 1px solid var(--border); background: rgba(255, 255, 255, .03); }
.meeting-date { color: var(--brand); font-size: 12px; font-weight: 700; }
.meeting-title { font-weight: 700; margin: 2px 0 4px; }
.meeting-notes { color: var(--muted); font-size: 13.5px; margin: 0 0 8px; white-space: pre-line; }
.meeting-items { list-style: none; margin: 8px 0 0; padding: 0; display: grid; gap: 8px; }
.meeting-items a { color: var(--brand2); font-weight: 700; font-size: 14px; text-decoration: underline; text-underline-offset: 2px; }
.meeting-items .kind { display: inline-block; min-width: 46px; font-size: 11px; font-weight: 800; letter-spacing: .4px; color: var(--muted); text-transform: uppercase; }
.meeting-items audio { width: 100%; margin-top: 6px; height: 40px; }

/* ---------- Contact ---------- */
.officers-table { width: 100%; border-collapse: collapse; margin-top: 6px; }
.officers-table th, .officers-table td { text-align: left; padding: 11px 10px; border-bottom: 1px solid rgba(255, 255, 255, .06); font-size: 14px; color: var(--muted); vertical-align: top; }
.officers-table th { color: var(--text); font-weight: 700; font-size: 13.5px; }
.officers-table td:first-child { color: var(--text); font-weight: 600; }
.officers-table a { color: var(--brand2); font-weight: 700; }
.officers-table .phone { white-space: nowrap; }
.contact-list { list-style: none; margin: 6px 0 0; padding: 0; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.contact-list li { padding: 12px 14px; border-radius: 14px; border: 1px solid var(--border); background: rgba(255, 255, 255, .03); font-size: 14px; color: var(--muted); }
.contact-list b { display: block; color: var(--text); margin-bottom: 2px; }
.contact-list a { color: var(--brand2); font-weight: 700; }
.placeholder { padding: 14px; border: 1px dashed rgba(255, 255, 255, .2); border-radius: 14px; color: var(--muted); font-size: 14px; }

/* ---------- Footer ---------- */
footer { padding: 26px 18px 36px; color: var(--muted); text-align: center; font-size: 13px; }
.footerline { max-width: 1100px; margin: 0 auto; padding-top: 18px; border-top: 1px solid rgba(255, 255, 255, .10); }

/* ---------- Tablets ---------- */
@media (max-width: 900px) {
  .hero, .hero.wide-main { grid-template-columns: 1fr; }
  .topbar { flex-direction: column; border-radius: 22px; }
  nav { justify-content: center; }
  .logo { width: 30vw; max-width: 200px; }
  .announcements-box, .announcements-box.tall, .minutes-box { max-height: 480px; }
}

/* ---------- Phones ---------- */
@media (max-width: 560px) {
  header { padding: 14px 12px 4px; }
  .container { padding: 12px; }
  .hero { margin-top: 8px; }
  .card { padding: 16px 14px; border-radius: 14px; }
  .card h2 { font-size: 23px; }
  .card > p, .lead { font-size: 15px; }
  .grid { grid-template-columns: 1fr; }
  nav { display: grid; grid-template-columns: 1fr 1fr; gap: 6px; width: 100%; }
  .navlink { padding: 9px 8px; font-size: 13.5px; text-align: center; border-color: rgba(255, 255, 255, .08); }
  .logo { width: 40vw; max-width: 170px; min-width: 110px; }
  .calendar-wrap iframe { height: 520px; }
  .list li { flex-direction: column; align-items: flex-start; }
  .contact-list { grid-template-columns: 1fr; }
  /* Officers table becomes stacked cards */
  .officers-table thead { position: absolute; left: -9999px; }
  .officers-table, .officers-table tbody, .officers-table tr, .officers-table td { display: block; width: 100%; }
  .officers-table tr { padding: 10px 12px; margin-bottom: 10px; border: 1px solid var(--border); border-radius: 14px; background: rgba(255, 255, 255, .03); }
  .officers-table td { border: 0; padding: 3px 0; }
  .officers-table td[data-label]::before { content: attr(data-label) ": "; color: var(--muted); font-weight: 600; font-size: 12.5px; }
  .officers-table td:first-child { font-size: 15px; }
}

/* Common Requests (prefilled emails) */
.requests { list-style: none; margin: 6px 0 10px; padding: 0; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.requests li { padding: 14px; border-radius: 14px; border: 1px solid var(--border); background: rgba(255, 255, 255, .03); display: flex; flex-direction: column; gap: 6px; align-items: flex-start; }
.requests b { color: var(--text); font-size: 15px; }
.requests span { color: var(--muted); font-size: 14px; flex: 1; }
.requests .doclink { margin-top: 4px; }
@media (max-width: 560px) { .requests { grid-template-columns: 1fr; } }

/* Other Important Numbers: icon cards */
.contact-list li { display: flex; gap: 12px; align-items: flex-start; }
.contact-list li > div { min-width: 0; }
.ci {
  width: 42px; height: 42px; flex: 0 0 auto; border-radius: 14px;
  display: grid; place-items: center; font-size: 20px;
  background: linear-gradient(135deg, rgba(52, 211, 153, .95), rgba(96, 165, 250, .75));
}
.contact-list li.urgent { border-color: rgba(248, 113, 113, .45); background: rgba(248, 113, 113, .08); }
.contact-list li.urgent .ci { background: linear-gradient(135deg, #f87171, #fb923c); }
.contact-list li.urgent a.big { font-size: 22px; color: #fca5a5; }
.contact-list a[href^="tel:"], .officers-table a[href^="tel:"] { white-space: nowrap; }
