/* "Just Wedding" — dashboard + marketing theme.
   Hand-written CSS (no build step needed on shared hosting) that
   reproduces the look of the original Tailwind-based dashboard:
   cream background, charcoal text, teal accents, pill buttons, cards. */

:root {
  --cream: #faf7f3;
  --cream-soft: #f2ece2;
  --charcoal: #1a1614;
  --charcoal-deep: #12100e;
  --teal: #5b9795;
  --teal-deep: #426d6b;
  --beige: #d6bea3;
  --gold: #c9a883;
  --star-gold: #fbbf24;
  --hub-green: #689e9c;
  --red: #dc2626;
  --red-bg: #fee2e2;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  background: var(--cream);
  color: var(--charcoal);
  font-family: "Figtree", "Segoe UI", system-ui, sans-serif;
  line-height: 1.5;
}

h1, h2, h3, h4 {
  font-family: "EB Garamond", Georgia, serif;
  margin: 0 0 0.25em;
}

a { color: inherit; }

code {
  font-family: ui-monospace, monospace;
}

.app-shell {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

/* ---- Marketing / landing page ---- */
.site-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1.5rem 2rem;
}
.brand-name { font-family: "EB Garamond", serif; font-size: 1.5rem; font-weight: 600; }
.header-nav { display: flex; gap: 0.75rem; }

.hero {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  padding: 0 1.5rem 4rem;
}
.pill {
  display: inline-block;
  background: var(--cream-soft);
  border: 1px solid rgba(26,22,20,0.12);
  border-radius: 999px;
  padding: 0.25rem 1rem;
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.15em;
  margin-top: 1.5rem;
}
.hero h1 {
  max-width: 48rem;
  font-size: 2.75rem;
  line-height: 1.15;
  margin-top: 1.5rem;
}
.hero .lede {
  max-width: 40rem;
  margin-top: 1.25rem;
  font-size: 1.15rem;
  color: rgba(26,22,20,0.7);
}
.hero-actions {
  margin-top: 2rem;
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  justify-content: center;
}
.feature-grid {
  margin-top: 4rem;
  display: grid;
  gap: 1.25rem;
  width: 100%;
  max-width: 64rem;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
}
.feature-grid .card { text-align: left; padding: 1.5rem; }
.feature-dot { width: 2.25rem; height: 2.25rem; border-radius: 999px; background: rgba(91,151,149,0.15); margin-bottom: 0.75rem; }
.site-footer {
  border-top: 1px solid rgba(26,22,20,0.1);
  padding: 1.5rem;
  text-align: center;
  font-size: 0.85rem;
  color: rgba(26,22,20,0.5);
}

/* ---- Auth / onboarding centered forms ---- */
.center-page {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 4rem 1.5rem;
}
.auth-card { width: 100%; max-width: 28rem; padding: 2rem; }
.auth-card h1 { font-size: 1.75rem; }
.auth-card .subtitle { margin-top: 0.5rem; font-size: 0.9rem; color: rgba(26,22,20,0.6); }
.form-stack { display: flex; flex-direction: column; gap: 1rem; margin-top: 1.5rem; }
.form-stack label { display: block; margin-bottom: 0.25rem; font-size: 0.9rem; font-weight: 500; }
.form-row-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 0.75rem; }
.form-footer { margin-top: 1.5rem; text-align: center; font-size: 0.9rem; color: rgba(26,22,20,0.6); }
.form-footer a { font-weight: 600; color: var(--teal-deep); }
.error-text { font-size: 0.9rem; color: var(--red); margin: 0; }

.mode-toggle {
  margin-top: 1.5rem;
  display: flex;
  gap: 0.25rem;
  background: var(--cream-soft);
  border-radius: 999px;
  padding: 0.25rem;
  font-size: 0.9rem;
  font-weight: 600;
}
.mode-toggle a {
  flex: 1;
  text-align: center;
  border-radius: 999px;
  padding: 0.5rem;
  text-decoration: none;
  color: rgba(26,22,20,0.6);
}
.mode-toggle a.active { background: var(--charcoal); color: var(--cream); }

/* ---- Buttons & inputs ---- */
.btn-primary, .btn-secondary, .btn-teal, .btn-danger-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  font-weight: 600;
  font-size: 0.9rem;
  padding: 0.6rem 1.4rem;
  border: none;
  cursor: pointer;
  text-decoration: none;
  transition: background-color .15s ease, transform .15s ease;
}
.btn-primary { background: var(--charcoal); color: var(--cream); }
.btn-primary:hover { background: var(--charcoal-deep); }
.btn-primary:disabled { opacity: 0.6; }
.btn-secondary { background: transparent; color: var(--charcoal); border: 1px solid rgba(26,22,20,0.2); }
.btn-secondary:hover { background: rgba(26,22,20,0.05); }
.btn-teal { background: var(--teal); color: var(--cream); }
.btn-teal:hover { background: var(--teal-deep); }
.btn-block { width: 100%; padding-top: 0.75rem; padding-bottom: 0.75rem; }

.link-danger {
  background: none; border: none; padding: 0; cursor: pointer;
  font-size: 0.75rem; font-weight: 600; color: var(--red);
}

input, select, textarea {
  font: inherit;
  background: #fff;
  border: 1px solid rgba(26,22,20,0.15);
  border-radius: 0.6rem;
  padding: 0.5rem 0.75rem;
  color: var(--charcoal);
}
input:focus, select:focus, textarea:focus {
  outline: none;
  border-color: var(--teal);
  box-shadow: 0 0 0 3px rgba(91,151,149,0.15);
}
.w-20 { width: 5rem; } .w-32 { width: 8rem; }

/* ---- Cards ---- */
.card {
  background: #fff;
  border: 1px solid rgba(26,22,20,0.08);
  border-radius: 1rem;
  box-shadow: 0 1px 2px rgba(26,22,20,0.04), 0 8px 24px rgba(26,22,20,0.05);
  padding: 1.25rem;
}
.card.p-0 { padding: 0; }

/* ---- Dashboard shell ---- */
.dashboard { display: flex; flex: 1; flex-direction: column; }
@media (min-width: 640px) { .dashboard { flex-direction: row; } }
.sidebar {
  display: flex; flex-direction: column; gap: 1.5rem;
  padding: 1.5rem; background: rgba(255,255,255,0.6);
  border-bottom: 1px solid rgba(26,22,20,0.1);
}
@media (min-width: 640px) {
  .sidebar { width: 16rem; border-bottom: none; border-right: 1px solid rgba(26,22,20,0.1); }
}
.sidebar .signed-in { margin-top: 0.25rem; font-size: 0.75rem; color: rgba(26,22,20,0.5); }
.sidebar-couple { font-size: 1.1rem; font-weight: 600; font-family: "EB Garamond", serif; }
.sidebar-meta { font-size: 0.75rem; color: rgba(26,22,20,0.6); margin: 0.1rem 0; }
.nav-links { display: flex; flex: 1; flex-direction: column; gap: 0.15rem; font-size: 0.9rem; }
.nav-links a { border-radius: 0.6rem; padding: 0.5rem 0.75rem; font-weight: 500; text-decoration: none; color: rgba(26,22,20,0.8); }
.nav-links a:hover, .nav-links a.active { background: var(--cream-soft); }
.dashboard-main { flex: 1; padding: 2rem 1.5rem; }
@media (min-width: 640px) { .dashboard-main { padding: 2rem 2.5rem; } }

.stack-8 { display: flex; flex-direction: column; gap: 2rem; }
.stack-6 { display: flex; flex-direction: column; gap: 1.5rem; }
.stack-4 { display: flex; flex-direction: column; gap: 1rem; }
.stack-3 { display: flex; flex-direction: column; gap: 0.75rem; }
.muted { color: rgba(26,22,20,0.6); }
.label-xs { font-size: 0.75rem; text-transform: uppercase; letter-spacing: 0.1em; color: rgba(26,22,20,0.5); }
.stat-value { margin-top: 0.5rem; font-family: "EB Garamond", serif; font-size: 1.9rem; font-weight: 600; }

.stat-grid { display: grid; gap: 1rem; grid-template-columns: 1fr; }
@media (min-width: 640px) { .stat-grid.cols-3 { grid-template-columns: repeat(3, 1fr); } .stat-grid.cols-2 { grid-template-columns: repeat(2, 1fr); } }

.countdown-row { display: flex; flex-wrap: wrap; justify-content: center; gap: 1.5rem; }
@media (min-width: 640px) { .countdown-row { justify-content: flex-start; } }
.countdown-cell { text-align: center; }
.countdown-cell .num { font-family: "EB Garamond", serif; font-size: 1.9rem; font-weight: 600; }

.inline-form { display: flex; flex-wrap: wrap; align-items: flex-end; gap: 0.75rem; }
.field-group label { display: block; margin-bottom: 0.25rem; font-size: 0.75rem; font-weight: 500; color: rgba(26,22,20,0.6); }

table.data-table { width: 100%; text-align: left; font-size: 0.9rem; border-collapse: collapse; }
table.data-table thead tr { border-bottom: 1px solid rgba(26,22,20,0.1); font-size: 0.75rem; text-transform: uppercase; letter-spacing: 0.1em; color: rgba(26,22,20,0.5); }
table.data-table th, table.data-table td { padding: 0.75rem 1.25rem; }
table.data-table tbody tr { border-bottom: 1px solid rgba(26,22,20,0.05); }
table.data-table tbody tr:last-child { border-bottom: none; }

.status-badge { border-radius: 999px; border: none; padding: 0.15rem 0.6rem; font-size: 0.75rem; font-weight: 500; }
.status-pending { background: var(--cream-soft); color: rgba(26,22,20,0.6); }
.status-attending { background: rgba(104,158,156,0.15); color: var(--teal-deep); }
.status-declined { background: var(--red-bg); color: #b91c1c; }

.progress-track { margin-top: 0.75rem; height: 0.5rem; width: 100%; overflow: hidden; border-radius: 999px; background: var(--cream-soft); }
.progress-fill { height: 100%; background: var(--teal); }
.due-pill { border-radius: 999px; padding: 0.1rem 0.5rem; font-size: 0.75rem; font-weight: 500; }
.due-overdue { background: var(--red-bg); color: #b91c1c; }
.due-soon { background: rgba(251,191,36,0.2); color: var(--charcoal); }
.due-future { background: var(--cream-soft); color: rgba(26,22,20,0.6); }

.task-group h2 { font-size: 1.25rem; margin-bottom: 0.5rem; }
.task-row { display: flex; align-items: center; justify-content: space-between; gap: 0.75rem; padding: 0.75rem 1.25rem; border-bottom: 1px solid rgba(26,22,20,0.05); }
.task-row:last-child { border-bottom: none; }
.task-check { height: 1.25rem; width: 1.25rem; flex-shrink: 0; border-radius: 999px; border: 2px solid rgba(26,22,20,0.3); background: none; cursor: pointer; padding: 0; }
.task-check.done { border-color: var(--teal); background: var(--teal); }
.task-done-text { color: rgba(26,22,20,0.4); text-decoration: line-through; }
.task-meta { display: flex; align-items: center; gap: 0.75rem; font-size: 0.75rem; color: rgba(26,22,20,0.5); }

.divide-list > * + * { border-top: 1px solid rgba(26,22,20,0.05); }
.list-row { display: flex; align-items: center; justify-content: space-between; gap: 0.75rem; padding: 0.5rem 0; }

.photo-grid-admin { display: grid; grid-template-columns: repeat(2, 1fr); gap: 0.75rem; }
@media (min-width: 640px) { .photo-grid-admin { grid-template-columns: repeat(4, 1fr); } }
.photo-tile { position: relative; overflow: hidden; border-radius: 0.6rem; }
.photo-tile img { height: 8rem; width: 100%; object-fit: cover; display: block; }
.photo-tile form { position: absolute; top: 0.25rem; right: 0.25rem; }
.photo-tile button { border-radius: 999px; background: rgba(26,22,20,0.7); color: var(--cream); font-size: 0.7rem; padding: 0.1rem 0.5rem; border: none; cursor: pointer; }

.guestbook-admin-entry { border-radius: 0.6rem; background: var(--cream-soft); padding: 0.75rem; display: flex; align-items: flex-start; justify-content: space-between; gap: 0.75rem; }

.error-banner { display: flex; align-items: center; justify-content: space-between; border-radius: 0.8rem; background: var(--red-bg); padding: 0.5rem 1rem; font-size: 0.9rem; color: #b91c1c; }
.error-banner button { margin-left: 0.75rem; border: none; background: none; font-size: 0.75rem; font-weight: 600; cursor: pointer; color: #b91c1c; }

/* ---- Seating board ---- */
.seating-wrap { display: flex; flex-direction: column; gap: 1rem; }
.seating-layout { display: flex; flex-direction: column; gap: 1rem; }
@media (min-width: 1024px) { .seating-layout { flex-direction: row; } }
.unseated-panel { width: 100%; flex-shrink: 0; }
@media (min-width: 1024px) { .unseated-panel { width: 16rem; } }
.unseated-chip { border-radius: 0.6rem; background: var(--cream-soft); padding: 0.5rem 0.75rem; font-size: 0.9rem; cursor: grab; margin-bottom: 0.5rem; }
.seating-board { position: relative; height: 520px; width: 100%; overflow: hidden; background: rgba(242,236,226,0.5); }
.seat-table {
  position: absolute; width: 13rem; user-select: none;
  border: 2px solid rgba(26,22,20,0.15); background: #fff; padding: 0.75rem;
  box-shadow: 0 1px 2px rgba(26,22,20,0.06);
}
.seat-table.round { border-radius: 999px; text-align: center; }
.seat-table.rectangle { border-radius: 1rem; }
.seat-table .table-name { cursor: grab; font-family: "EB Garamond", serif; font-weight: 600; padding-bottom: 0.25rem; }
.seat-table .seats-count { font-size: 0.65rem; color: rgba(26,22,20,0.5); margin-bottom: 0.25rem; }
.seat-table .seated-guests { display: flex; flex-wrap: wrap; justify-content: center; gap: 0.25rem; }
.seat-chip { border-radius: 999px; background: rgba(91,151,149,0.15); color: var(--teal-deep); padding: 0.1rem 0.5rem; font-size: 0.7rem; cursor: pointer; border: none; }
.seat-table form { margin-top: 0.5rem; }
.seat-table .remove-table { font-size: 0.7rem; font-weight: 600; color: var(--red); background: none; border: none; cursor: pointer; padding: 0; }

.invite-code-box { display: inline-block; border-radius: 0.6rem; background: var(--cream-soft); padding: 0.75rem 1rem; font-size: 1.1rem; letter-spacing: 0.2em; margin-top: 0.75rem; }
