/* Cambusdoon Sports Club — annadesign sweep (Family Circle design system v1.0):
   warm cream grounds, glassmorphic cards (24px), sage CTAs, sun-gold accents,
   serif display + humanist UI, 56px touch targets, soft charcoal shadows. */
:root {
  --ground: #f7edda;          /* background/cream */
  --ground-2: #f5e9d0;        /* background/warm */
  --card: #fdfaf5;            /* surface/card */
  --elevated: #fcfcf6;        /* surface/elevated */
  --input: #f9f5ee;           /* surface/input */
  --ink: #2e2c28;             /* text/primary */
  --muted: #8a8884;           /* text/muted */
  --line: #e8e5e0;            /* separator/divider */
  --sage: #869282;            /* cta/sage */
  --sage-dark: #6b7868;       /* cta/sage-dark */
  --gold: #f4be52;            /* brand/sun-gold */
  --amber: #e8b048;           /* brand/sun-amber */
  --sand: #d4a776;            /* accent/sand */
  --error: #c0392b;
  --success: #27ae60;
  --shadow-card: 0 4px 24px 0 rgba(46, 44, 40, 0.08);
  --shadow-card-hover: 0 8px 32px -2px rgba(46, 44, 40, 0.14);
  --shadow-button: 0 2px 12px 0 rgba(134, 146, 130, 0.35);
  --shadow-logo: 0 3px 16px 0 rgba(232, 176, 72, 0.3);
  --serif: "Playfair Display", "Iowan Old Style", Palatino, Georgia, serif;
  --ui: Inter, -apple-system, BlinkMacSystemFont, "SF Pro Text", "Segoe UI", Roboto, "Helvetica Neue", sans-serif;
}
* { box-sizing: border-box; }
[hidden] { display: none !important; }
body {
  margin: 0;
  background: linear-gradient(180deg, var(--ground) 0%, var(--ground-2) 100%);
  min-height: 100vh;
  color: var(--ink);
  font: 16px/1.65 var(--ui);
}
.wrap { max-width: 560px; margin: 0 auto; padding: 0 24px 48px; }

header.app {
  padding: 20px 0 16px;
  margin-bottom: 24px;
  border-bottom: 1px solid var(--line);
  background: rgba(253, 250, 245, 0.75);
  backdrop-filter: blur(8px);
}
header.app .wrap { display: flex; align-items: center; gap: 14px; padding-bottom: 0; }
.crest {
  width: 48px; height: 48px; border-radius: 9999px;
  background: var(--gold);
  box-shadow: var(--shadow-logo);
  display: flex; align-items: center; justify-content: center;
  font-family: var(--serif);
  font-size: 22px; font-weight: 700; color: var(--ink); flex-shrink: 0;
  text-decoration: none;
  border: 3px solid var(--card);
}
header.app h1 {
  font-family: var(--serif);
  font-size: 20px; margin: 0; font-weight: 600; line-height: 1.15; letter-spacing: -0.02em;
}
header.app p { margin: 2px 0 0; font-size: 12px; color: var(--muted); letter-spacing: 0.14em; text-transform: uppercase; }
header.app a { color: inherit; text-decoration: none; }

h2 { font-family: var(--serif); font-size: 28px; margin: 4px 0 14px; font-weight: 600; letter-spacing: -0.02em; line-height: 1.3; }
.sub { color: var(--muted); font-size: 15px; margin: -8px 0 20px; }

.bigbtn {
  display: flex; align-items: center; gap: 16px; width: 100%;
  background: var(--card); border: 1px solid var(--line); border-radius: 24px;
  padding: 20px 24px; margin-bottom: 16px; text-align: left; text-decoration: none;
  color: inherit; font: inherit; cursor: pointer;
  box-shadow: var(--shadow-card);
  min-height: 56px;
  transition: box-shadow 0.15s ease;
}
.bigbtn:hover { box-shadow: var(--shadow-card-hover); }
.bigbtn .ico {
  width: 48px; height: 48px; border-radius: 16px; flex-shrink: 0;
  display: flex; align-items: center; justify-content: center; font-size: 22px;
}
.bigbtn h3 { margin: 0; font-size: 18px; font-weight: 600; }
.bigbtn p { margin: 3px 0 0; font-size: 13px; color: var(--muted); line-height: 1.5; }

.notice {
  background: var(--elevated);
  border: 1px solid var(--line);
  border-left: 4px solid var(--gold);
  border-radius: 16px;
  padding: 14px 18px; margin-bottom: 20px;
  box-shadow: var(--shadow-card);
}
.notice h3 { margin: 0 0 2px; font-size: 12px; color: var(--muted); text-transform: uppercase; letter-spacing: 0.14em; font-weight: 600; }
.notice p { margin: 0; font-size: 14px; color: var(--ink); font-weight: 500; }

.card {
  background: var(--card); border: 1px solid var(--line); border-radius: 24px;
  padding: 24px; margin-bottom: 16px;
  box-shadow: var(--shadow-card);
}
.card h3 { margin: 0 0 4px; font-family: var(--serif); font-size: 18px; font-weight: 600; }
.card p { margin: 0; font-size: 14px; color: var(--muted); line-height: 1.6; }
.card .meta { display: flex; justify-content: space-between; align-items: baseline; margin-bottom: 8px; gap: 10px; }
.card .date { font-size: 13px; font-weight: 600; color: var(--ink); }

.tag {
  font-size: 10px; font-weight: 700; text-transform: uppercase; letter-spacing: 0.12em;
  padding: 4px 10px; border-radius: 9999px; background: rgba(134, 146, 130, 0.16); color: var(--sage-dark);
}
.tag.social { background: rgba(244, 190, 82, 0.22); color: #8a6420; }
.tag.football { background: rgba(134, 146, 130, 0.16); color: var(--sage-dark); }
.tag.bowling { background: rgba(212, 167, 118, 0.22); color: #7d5c38; }
.tag.cricket { background: rgba(134, 146, 130, 0.16); color: var(--sage-dark); }
.tag.club { background: rgba(46, 44, 40, 0.07); color: var(--muted); }
.tag.sample { background: rgba(46, 44, 40, 0.06); color: var(--muted); }

form label { display: block; font-size: 14px; font-weight: 500; margin: 16px 0 6px; }
input[type="text"], input[type="email"], input[type="tel"], input[type="password"],
input[type="date"], select, textarea {
  width: 100%; padding: 16px; font: inherit; font-size: 16px;
  border: 1px solid var(--line); border-radius: 24px; background: var(--input); color: var(--ink);
  min-height: 56px;
}
input::placeholder, textarea::placeholder { color: var(--muted); }
textarea { min-height: 120px; resize: vertical; border-radius: 24px; }
.checks { display: flex; flex-wrap: wrap; gap: 10px; }
.checks label {
  display: flex; align-items: center; gap: 8px; margin: 0;
  background: var(--card); border: 1px solid var(--line); border-radius: 9999px;
  padding: 12px 18px; font-weight: 500; cursor: pointer; min-height: 48px;
  box-shadow: var(--shadow-card);
}
.checks input { accent-color: var(--sage); }
.hp { position: absolute; left: -5000px; width: 1px; height: 1px; overflow: hidden; }

.btn {
  display: inline-block; border: none; cursor: pointer; font: inherit;
  font-size: 16px; font-weight: 600; border-radius: 24px; padding: 16px 24px;
  background: var(--sage); color: #fff; margin-top: 24px;
  min-height: 56px;
  box-shadow: var(--shadow-button);
  text-decoration: none;
  transition: background 0.15s ease;
}
.btn:hover, .btn:active { background: var(--sage-dark); }
.btn.small { font-size: 13px; padding: 9px 16px; min-height: 0; margin: 8px 8px 0 0; }
.btn.ghost { background: transparent; color: var(--sage); border: 1.5px solid var(--sage); box-shadow: none; }
.btn.ghost:hover { background: rgba(134, 146, 130, 0.1); }
.btn.warn { background: var(--amber); color: var(--ink); box-shadow: 0 2px 12px 0 rgba(232, 176, 72, 0.35); }
.btn.warn:hover { background: var(--gold); }
.btn.danger { background: var(--error); }
.btn.danger:hover { background: #a53125; }
.btn:focus-visible, .bigbtn:focus-visible, a:focus-visible, button:focus-visible { outline: 3px solid var(--amber); outline-offset: 2px; }

.ok-box {
  background: var(--elevated); border: 1px solid var(--line); border-radius: 24px;
  padding: 32px 24px; box-shadow: var(--shadow-card);
  position: relative; overflow: hidden;
}
.ok-box h3 { margin: 0 0 6px; font-family: var(--serif); font-size: 22px; color: var(--ink); }
.ok-box p { margin: 0; font-size: 15px; color: var(--muted); }
/* confetti accents per brand sheet §6.1 */
.ok-box::before, .ok-box::after {
  content: ""; position: absolute; border-radius: 50%;
}
.ok-box::before {
  width: 6px; height: 6px; top: 18px; right: 34px;
  background: rgba(232, 176, 72, 0.4);
  box-shadow: -28px 14px 0 -1px rgba(134, 146, 130, 0.35), 14px 30px 0 0 rgba(212, 167, 118, 0.3);
}
.ok-box::after {
  width: 4px; height: 4px; bottom: 20px; left: 28px;
  background: rgba(134, 146, 130, 0.35);
  box-shadow: 22px -10px 0 0 rgba(232, 176, 72, 0.4), 44px 6px 0 -1px rgba(212, 167, 118, 0.3);
}
.err { color: var(--error); font-size: 14px; margin-top: 10px; min-height: 18px; }

.backlink { display: inline-block; font-size: 14px; color: var(--muted); margin-bottom: 12px; text-decoration: none; }
.backlink:hover { color: var(--sage-dark); }

/* floating glass dock (Mobbin: Wabi/Breathwrk pill nav) */
body.has-dock { padding-bottom: 104px; }
.dock {
  position: fixed; left: 50%; bottom: 16px; transform: translateX(-50%);
  display: flex; gap: 2px; padding: 8px;
  background: rgba(253, 250, 245, 0.85);
  backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px);
  border: 1px solid var(--line); border-radius: 9999px;
  box-shadow: 0 8px 32px -2px rgba(46, 44, 40, 0.18);
  z-index: 50; max-width: calc(100% - 24px);
}
.dock a {
  display: flex; flex-direction: column; align-items: center; gap: 1px;
  min-width: 58px; padding: 8px 9px; border-radius: 9999px;
  text-decoration: none; color: var(--muted);
  font-size: 10.5px; font-weight: 600; white-space: nowrap;
}
.dock a .dock-ico { font-size: 19px; line-height: 1.1; position: relative; }
.dock a.on { background: var(--sage); color: #fff; box-shadow: var(--shadow-button); }
.dock-dot {
  position: absolute; top: -2px; right: -6px; width: 9px; height: 9px;
  border-radius: 50%; background: var(--amber); border: 2px solid var(--card);
}
@media (max-width: 360px) { .dock a { min-width: 52px; padding: 8px 6px; } }

/* calendar date tile (Mobbin: Strava club events) */
.datetile {
  width: 52px; flex-shrink: 0; border-radius: 14px; overflow: hidden;
  border: 1px solid var(--line); background: var(--elevated);
  text-align: center; box-shadow: var(--shadow-card);
}
.datetile .m {
  display: block; background: var(--gold); color: var(--ink);
  font-size: 10px; font-weight: 700; text-transform: uppercase; letter-spacing: 0.1em;
  padding: 3px 0;
}
.datetile .d {
  display: block; font-family: var(--serif); font-size: 22px; font-weight: 700;
  line-height: 1.1; padding-top: 3px;
}
.datetile .w { display: block; font-size: 10px; color: var(--muted); padding-bottom: 4px; }
.cardrow { display: flex; gap: 14px; align-items: flex-start; }
.cardrow .grow { flex: 1; min-width: 0; }

/* greeting (Mobbin: Cleo warm hello) */
.greet { margin: 4px 0 18px; }
.greet h2 { margin: 0; font-size: 30px; }
.greet p { margin: 4px 0 0; color: var(--muted); font-size: 15px; }

/* admin */
.tabs { display: flex; flex-wrap: wrap; gap: 8px; margin: 0 0 20px; }
.tabs button {
  font: inherit; font-size: 14px; font-weight: 600; cursor: pointer;
  border: 1px solid var(--line); border-radius: 9999px; padding: 10px 18px;
  background: var(--card); color: var(--muted); min-height: 44px;
  box-shadow: var(--shadow-card);
}
.tabs button.on { background: var(--sage); color: #fff; border-color: var(--sage); box-shadow: var(--shadow-button); }
table.plain { border-collapse: collapse; width: 100%; font-size: 13px; }
table.plain th { text-align: left; font-size: 11px; text-transform: uppercase; letter-spacing: 0.1em; color: var(--muted); padding: 8px; font-weight: 600; }
table.plain td { padding: 9px 8px; border-top: 1px solid var(--line); vertical-align: top; }
.tablewrap { overflow-x: auto; background: var(--card); border: 1px solid var(--line); border-radius: 24px; padding: 8px 12px 12px; box-shadow: var(--shadow-card); }
.pill { font-size: 10.5px; font-weight: 700; padding: 3px 10px; border-radius: 9999px; background: rgba(39, 174, 96, 0.14); color: #1d7a46; }
.pill.off { background: rgba(46, 44, 40, 0.07); color: var(--muted); }
.rowactions button { font-size: 12px; padding: 6px 12px; margin: 2px 6px 0 0; cursor: pointer; border: 1px solid var(--line); border-radius: 9999px; background: var(--input); color: var(--ink); }
.rowactions button:hover { border-color: var(--sage); color: var(--sage-dark); }
