/* =============================================================
   Igeret — Design System
   Tokens from the Igeret Design System bundle (Claude Design).
   Warm cream, plum-ink, one raspberry accent, sage + peach-gold
   for positive/in-progress. Hebrew-first, RTL-default.
   ============================================================= */

@import url('https://fonts.googleapis.com/css2?family=Frank+Ruhl+Libre:wght@400;500;700;900&family=Assistant:wght@300;400;500;600;700&family=Cormorant+Garamond:ital,wght@0,400;0,500;0,600;0,700;1,400;1,500&family=JetBrains+Mono:wght@400;500&display=swap');

:root {
  /* Brand palette */
  --rimon:        #D64C5E;
  --rimon-deep:   #B23848;
  --rimon-soft:   #FBE4E7;

  --zayit:        #7FA05A;
  --zayit-deep:   #5F7E3E;
  --zayit-soft:   #E8F0DB;

  --zahav:        #E8A55C;
  --zahav-soft:   #FBEBD4;

  --dyo:          #2A2140;
  --dyo-70:       rgba(42, 33, 64, 0.70);
  --dyo-55:       rgba(42, 33, 64, 0.55);
  --dyo-40:       rgba(42, 33, 64, 0.40);
  --dyo-15:       rgba(42, 33, 64, 0.15);
  --dyo-08:       rgba(42, 33, 64, 0.08);

  --klaf:         #FFF8F0;
  --klaf-deep:    #FBEEDE;
  --chol:         #F5E3CC;
  --chol-deep:    #E9CFAE;
  --paper:        #FFFFFF;
  --paper-line:   #F3E6D3;

  --danger:       #A22635;
  --danger-bg:    #F5DDDF;
  --warning:      #C48A2C;

  /* Compatibility aliases (kept so existing template classes keep working) */
  --ink:          var(--dyo);
  --muted:        var(--dyo-70);
  --line:         var(--paper-line);
  --line-2:       var(--paper-line);
  --seal:         var(--rimon);
  --seal-soft:    var(--rimon-soft);
  --blush:        var(--rimon-soft);
  --brass:        var(--zahav);
  --ok:           var(--zayit);
  --ok-soft:      var(--zayit-soft);
  --surface:      var(--paper);
  --paper-2:      var(--klaf-deep);
  --bg:           var(--klaf);

  /* Type */
  --ff-display: 'Frank Ruhl Libre', 'Cormorant Garamond', 'Times New Roman', Georgia, serif;
  --ff-serif:   'Cormorant Garamond', 'Frank Ruhl Libre', Georgia, serif;
  --ff-ui:      'Assistant', 'Frank Ruhl Libre', system-ui, -apple-system, 'Segoe UI', sans-serif;
  --ff-mono:    'JetBrains Mono', ui-monospace, 'SF Mono', Menlo, monospace;

  /* Radii */
  --r-stamp:  2px;
  --r-input:  4px;
  --r-button: 8px;
  --r-card:   12px;
  --r-xl:     20px;
  --r-pill:   999px;
  --radius:   var(--r-button);

  /* Shadows */
  --shadow-paper: 0 1px 0 rgba(31,42,60,0.04), 0 8px 24px -12px rgba(31,42,60,0.12);
  --shadow-lift:  0 12px 40px -16px rgba(31,42,60,0.22);

  /* Motion */
  --ease-soft: cubic-bezier(0.22, 0.61, 0.36, 1);
  --dur-base: 160ms;

  /* Layout */
  --h-topbar: 64px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: var(--ff-ui);
  font-size: 16px;
  color: var(--dyo);
  background: var(--klaf);
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  font-feature-settings: "kern" 1;
}

a { color: var(--dyo); text-decoration: none; transition: color var(--dur-base) var(--ease-soft); }
a:hover { color: var(--rimon); }

img, svg { max-width: 100%; display: block; }

.container { max-width: 1120px; margin: 0 auto; padding: 0 32px; }

/* =========================================================
   Header
   ========================================================= */
header {
  padding: 16px 0;
  border-bottom: 1px solid var(--paper-line);
  background: var(--klaf);
  position: sticky;
  top: 0;
  z-index: 10;
}
.header-inner { display: flex; align-items: center; justify-content: space-between; gap: 24px; min-height: 48px; }
.brand { display: inline-flex; align-items: center; gap: 10px; color: var(--dyo); }
.brand img { height: 32px; width: auto; }
nav { display: flex; align-items: center; gap: 20px; flex-wrap: wrap; }
nav a, nav .linklike {
  color: var(--dyo-70);
  font-size: 14px;
  font-weight: 500;
  font-family: var(--ff-ui);
  background: none; border: 0; cursor: pointer; padding: 0;
  transition: color var(--dur-base);
}
nav a:hover, nav .linklike:hover { color: var(--dyo); }
nav .nav-cta {
  color: #fff; background: var(--rimon);
  padding: 9px 16px; border-radius: var(--r-button);
  font-size: 13px; font-weight: 600;
  letter-spacing: 0;
  text-transform: none;
  box-shadow: 0 1px 2px rgba(214,76,94,0.25), inset 0 1px 0 rgba(255,255,255,0.18);
  transition: background var(--dur-base), transform var(--dur-base), box-shadow var(--dur-base);
}
nav .nav-cta:hover { background: var(--rimon-deep); color: #fff; transform: translateY(-1px); box-shadow: 0 4px 10px rgba(214,76,94,0.3); }

/* =========================================================
   Hero
   ========================================================= */
.hero { padding: 120px 0 96px; text-align: center; }
.eyebrow {
  font-family: var(--ff-ui);
  font-size: 12px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--zahav);
  font-weight: 700;
  margin-bottom: 24px;
  display: inline-block;
}
.hero h1 {
  font-family: var(--ff-display);
  font-weight: 700;
  font-size: clamp(44px, 6vw, 72px);
  line-height: 1.1;
  margin: 0 0 24px;
  letter-spacing: -0.02em;
  color: var(--dyo);
}
.hero h1 em { font-style: normal; color: var(--rimon); font-weight: 700; }
.hero h1 em::after { content: none; }
.hero .lede {
  max-width: 560px;
  margin: 0 auto 40px;
  font-size: 18px;
  color: var(--dyo-70);
  line-height: 1.55;
}

/* =========================================================
   Buttons
   ========================================================= */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: var(--ff-ui);
  font-weight: 600;
  font-size: 14px;
  padding: 11px 20px;
  background: var(--rimon);
  color: #fff;
  border-radius: var(--r-button);
  border: 0;
  cursor: pointer;
  text-decoration: none;
  line-height: 1.2;
  letter-spacing: 0;
  text-transform: none;
  transition: background var(--dur-base) var(--ease-soft), transform var(--dur-base), box-shadow var(--dur-base);
  box-shadow: 0 1px 2px rgba(214,76,94,0.25), inset 0 1px 0 rgba(255,255,255,0.18);
}
.btn:hover { background: var(--rimon-deep); transform: translateY(-1px); box-shadow: 0 4px 10px rgba(214,76,94,0.3); color: #fff; }
.btn:active { transform: scale(0.98); box-shadow: none; }
.btn.ghost { background: var(--paper); color: var(--dyo); border: 1px solid var(--dyo-15); box-shadow: none; }
.btn.ghost:hover { background: var(--klaf); border-color: var(--dyo-40); color: var(--dyo); transform: none; box-shadow: none; }
.btn.seal { background: var(--rimon); color: #fff; }
.btn.seal:hover { background: var(--rimon-deep); color: #fff; }
.btn.danger { background: var(--danger); color: #fff; }
.btn.danger:hover { background: #7E1B28; color: #fff; }
.btn.small { padding: 7px 14px; font-size: 13px; }

/* =========================================================
   Sections
   ========================================================= */
.section { padding: 88px 0; border-top: 1px solid var(--paper-line); }
.section.alt { background: var(--klaf-deep); }
.section-title {
  font-family: var(--ff-display);
  font-weight: 700;
  font-size: clamp(32px, 3.8vw, 44px);
  text-align: center;
  margin: 0 0 16px;
  letter-spacing: -0.015em;
  color: var(--dyo);
}
.section-intro {
  text-align: center;
  color: var(--dyo-70);
  max-width: 620px;
  margin: 0 auto 56px;
  font-size: 16px;
  line-height: 1.55;
}

.grid-3 { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 32px; }
.feature { padding: 4px 0; }
.feature-num {
  font-family: var(--ff-ui);
  font-size: 11px;
  color: var(--rimon);
  font-weight: 700;
  display: block;
  margin-bottom: 10px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  font-style: normal;
}
.feature h3 {
  font-family: var(--ff-display);
  font-size: 24px;
  font-weight: 700;
  margin: 0 0 8px;
  color: var(--dyo);
  letter-spacing: -0.01em;
}
.feature p { font-size: 15px; color: var(--dyo-70); margin: 0; line-height: 1.55; }

/* =========================================================
   Split / split-hero
   ========================================================= */
.split { display: grid; grid-template-columns: 1fr 1fr; gap: 64px; align-items: center; }
.split h2 {
  font-family: var(--ff-display);
  font-size: clamp(30px, 3.2vw, 40px);
  font-weight: 700;
  margin: 0 0 16px;
  line-height: 1.15;
  letter-spacing: -0.015em;
  color: var(--dyo);
}
.split p { color: var(--dyo-70); margin: 0 0 14px; }
.envelope-art { aspect-ratio: 3/2; }
@media (max-width: 820px) {
  .split { grid-template-columns: 1fr; gap: 40px; }
  .hero { padding: 64px 0 48px; }
  .section { padding: 56px 0; }
  nav a:not(.nav-cta):not(:nth-of-type(-n+2)) { display: none; }
}

/* =========================================================
   Quote
   ========================================================= */
.quote { max-width: 720px; margin: 0 auto; text-align: center; }
.quote p {
  font-family: var(--ff-serif);
  font-style: italic;
  font-size: clamp(22px, 2.4vw, 30px);
  line-height: 1.4;
  color: var(--dyo);
  margin: 0 0 20px;
}
.quote cite {
  display: block; font-style: normal; color: var(--dyo-55);
  font-size: 12px; letter-spacing: 0.14em; text-transform: uppercase; font-weight: 600;
}

/* =========================================================
   Footer
   ========================================================= */
footer {
  padding: 40px 0;
  border-top: 1px solid var(--paper-line);
  background: var(--klaf-deep);
}
.footer-inner { display: flex; justify-content: space-between; align-items: center; gap: 16px; font-size: 13px; color: var(--dyo-55); }
footer a { color: var(--dyo-70); }
footer a:hover { color: var(--rimon); }
@media (max-width: 600px) {
  .footer-inner { flex-direction: column; gap: 8px; text-align: center; }
}

/* =========================================================
   Forms / panels
   ========================================================= */
.panel {
  max-width: 460px; margin: 64px auto;
  background: var(--paper); padding: 40px 40px;
  border: 1px solid var(--paper-line); border-radius: var(--r-card);
  box-shadow: var(--shadow-paper);
}
.panel.wide { max-width: 720px; }
.panel h1 {
  font-family: var(--ff-display);
  font-weight: 700;
  font-size: 32px;
  margin: 0 0 6px;
  letter-spacing: -0.015em;
  color: var(--dyo);
}
.panel .sub { color: var(--dyo-55); margin: 0 0 24px; font-size: 14px; }
.panel .mark-bar {
  width: 32px; height: 3px; background: var(--rimon); margin-bottom: 18px; border-radius: 2px;
}

label {
  display: block;
  font-size: 12px;
  font-weight: 600;
  color: var(--dyo-55);
  margin: 16px 0 6px;
  letter-spacing: 0;
  text-transform: none;
}
label:first-of-type { margin-top: 0; }

input[type=text], input[type=email], input[type=password],
input[type=date], input[type=number], input[type=file],
input[type=tel], input[type=search], textarea, select {
  width: 100%;
  padding: 11px 13px;
  border: 1px solid var(--dyo-15);
  border-radius: var(--r-input);
  background: var(--paper);
  font-family: var(--ff-ui);
  font-size: 15px;
  color: var(--dyo);
  transition: border-color var(--dur-base), box-shadow var(--dur-base);
}
input:focus, textarea:focus, select:focus {
  outline: none;
  border-color: var(--rimon);
  box-shadow: 0 0 0 3px rgba(214,76,94,0.12);
}
textarea { min-height: 100px; resize: vertical; line-height: 1.5; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
@media (max-width: 560px) { .form-row { grid-template-columns: 1fr; } }

.error { color: var(--danger); font-size: 14px; margin: 12px 0; }
.flash {
  background: var(--rimon-soft); color: var(--dyo);
  padding: 12px 16px; border-radius: var(--r-button);
  margin: 0 0 24px; font-size: 14px;
  border-left: 3px solid var(--rimon);
}
.flash.ok { background: var(--zayit-soft); border-color: var(--zayit); }

.submit-row {
  margin-top: 28px; display: flex;
  justify-content: space-between; align-items: center; gap: 16px;
}

/* =========================================================
   Dashboard / page head
   ========================================================= */
.page-head {
  padding: 40px 0 24px;
  display: flex;
  justify-content: space-between;
  align-items: end;
  gap: 20px;
  border-bottom: 1px solid var(--paper-line);
  margin-bottom: 32px;
}
.page-head h1 {
  font-family: var(--ff-display);
  font-weight: 700;
  font-size: clamp(28px, 3.4vw, 40px);
  margin: 0;
  letter-spacing: -0.015em;
  color: var(--dyo);
  line-height: 1.1;
}
.page-head .sub { color: var(--dyo-55); margin-top: 4px; font-size: 14px; }
@media (max-width: 640px) { .page-head { flex-direction: column; align-items: start; } }

/* Event cards */
.event-card {
  display: block;
  padding: 22px 24px;
  margin-bottom: 16px;
  background: var(--paper);
  border: 1px solid var(--paper-line);
  border-radius: var(--r-card);
  color: var(--dyo);
  transition: border-color var(--dur-base), box-shadow var(--dur-base), transform var(--dur-base);
}
.event-card:hover { border-color: var(--dyo-15); color: var(--dyo); box-shadow: var(--shadow-paper); transform: translateY(-1px); }
.event-card h3 {
  font-family: var(--ff-display);
  font-weight: 700;
  font-size: 22px;
  margin: 0 0 4px;
  letter-spacing: -0.01em;
}
.event-card .meta { color: var(--dyo-55); font-size: 13px; }
.stat-row { display: flex; flex-wrap: wrap; gap: 28px; margin-top: 18px; }
.stat { font-size: 11px; color: var(--dyo-55); font-weight: 600; letter-spacing: 0.08em; text-transform: uppercase; }
.stat b {
  display: block;
  font-family: var(--ff-display);
  font-size: 30px;
  font-weight: 700;
  color: var(--dyo);
  margin-bottom: 2px;
  letter-spacing: -0.01em;
  font-variant-numeric: tabular-nums;
}
.stat.ok b { color: var(--zayit-deep); }
.stat.seal b { color: var(--rimon-deep); }
.stat.brass b { color: var(--zahav); }

.empty {
  text-align: center;
  padding: 72px 24px;
  color: var(--dyo-55);
  border: 1px dashed var(--paper-line);
  border-radius: var(--r-card);
  background: var(--paper);
}
.empty p { margin: 0 0 20px; font-size: 15px; }

/* =========================================================
   Event detail
   ========================================================= */
.cols { display: grid; grid-template-columns: 1fr 1.6fr; gap: 28px; }
@media (max-width: 980px) { .cols { grid-template-columns: 1fr; } }

.card {
  background: var(--paper);
  border: 1px solid var(--paper-line);
  padding: 24px 28px;
  border-radius: var(--r-card);
  margin-bottom: 18px;
  box-shadow: 0 1px 2px rgba(42,33,64,0.03);
}
.card h2 {
  font-family: var(--ff-display);
  font-weight: 700;
  font-size: 20px;
  margin: 0 0 12px;
  letter-spacing: -0.01em;
  color: var(--dyo);
}
.card .sub { color: var(--dyo-55); font-size: 14px; margin: 0 0 14px; }
.card.danger { border-color: var(--danger-bg); background: #FCF0F1; }
.card.danger h2 { color: var(--danger); }

/* Guest table */
table.guests { width: 100%; border-collapse: collapse; font-size: 14px; }
table.guests th, table.guests td {
  padding: 12px 10px;
  border-bottom: 1px solid var(--paper-line);
  text-align: start;
  vertical-align: top;
}
table.guests th {
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--dyo-55);
  font-weight: 600;
}
table.guests tr:last-child td { border-bottom: 0; }

.pill {
  display: inline-block;
  padding: 3px 10px;
  border-radius: var(--r-pill);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.04em;
}
.pill.accepted { background: var(--zayit-soft); color: var(--zayit-deep); }
.pill.maybe    { background: var(--zahav-soft); color: var(--warning); }
.pill.declined { background: var(--danger-bg); color: var(--danger); }
.pill.pending  { background: var(--chol); color: var(--dyo-70); }

.link-small { font-size: 12px; color: var(--dyo-55); }
.link-copy {
  font-family: var(--ff-mono);
  font-size: 11px;
  background: var(--klaf);
  padding: 5px 9px;
  border-radius: var(--r-stamp);
  word-break: break-all;
  color: var(--dyo-70);
  border: 1px solid var(--paper-line);
  display: inline-block;
}
.row-actions { display: inline-flex; gap: 10px; align-items: center; }
.inline-form { display: inline; }
button.linklike {
  background: none; border: 0; color: var(--dyo-55); cursor: pointer;
  font-size: 12px; padding: 0; font-family: inherit;
  transition: color var(--dur-base);
}
button.linklike:hover { color: var(--dyo); }
button.linklike.seal { color: var(--rimon); }
button.linklike.seal:hover { color: var(--rimon-deep); }

code.inline {
  font-family: var(--ff-mono);
  font-size: 12px;
  background: var(--klaf);
  padding: 2px 6px;
  border: 1px solid var(--paper-line);
  border-radius: var(--r-stamp);
}

/* =========================================================
   Public RSVP card (the letter)
   ========================================================= */
.rsvp-bg {
  min-height: 100vh;
  background: var(--klaf);
  padding: 48px 20px;
  display: flex;
  align-items: flex-start;
  justify-content: center;
}
.rsvp-envelope {
  max-width: 520px; width: 100%;
  background: var(--paper);
  border: 1px solid var(--paper-line);
  border-radius: var(--r-card);
  padding: 56px 40px 48px;
  text-align: center;
  position: relative;
  box-shadow: var(--shadow-lift);
}
.seal-mark {
  width: 56px; height: 56px;
  margin: 0 auto 24px;
  display: flex; align-items: center; justify-content: center;
  background: var(--rimon);
  color: #FFF8F0;
  border-radius: 50%;
  font-family: var(--ff-display);
  font-weight: 700;
  font-size: 26px;
  line-height: 1;
  box-shadow: 0 4px 12px rgba(214,76,94,0.25), inset 0 0 0 2px rgba(255,248,240,0.25);
}
.rsvp-eyebrow {
  font-size: 11px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--zahav);
  font-weight: 700;
  margin-bottom: 10px;
}
.rsvp-envelope h1 {
  font-family: var(--ff-display);
  font-weight: 700;
  font-size: clamp(32px, 5vw, 40px);
  line-height: 1.1;
  margin: 0 0 10px;
  letter-spacing: -0.015em;
  color: var(--dyo);
}
.rsvp-couple {
  font-family: var(--ff-serif);
  font-style: italic;
  color: var(--rimon);
  font-size: 22px;
  margin-bottom: 24px;
}
.rsvp-when { color: var(--dyo-70); font-size: 15px; margin-bottom: 8px; line-height: 1.7; }
.rsvp-divider {
  width: 100%;
  height: 0;
  border: 0;
  border-top: 1px dashed var(--dyo-40);
  margin: 24px 0;
}
.rsvp-msg { color: var(--dyo-70); margin: 0 auto 24px; font-size: 15px; max-width: 400px; font-style: italic; font-family: var(--ff-serif); }
.rsvp-hello { font-family: var(--ff-display); font-weight: 500; font-size: 22px; color: var(--dyo); margin-bottom: 22px; }

.choice-row { display: flex; gap: 10px; justify-content: center; flex-wrap: wrap; }
.choice-btn {
  flex: 1;
  min-width: 140px;
  max-width: 200px;
  padding: 14px 14px;
  border: 1px solid var(--dyo-15);
  border-radius: var(--r-button);
  background: var(--paper);
  font-family: var(--ff-ui);
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  color: var(--dyo);
  transition: background var(--dur-base), color var(--dur-base), border-color var(--dur-base);
}
.choice-btn:hover { border-color: var(--dyo); }
.choice-btn.active.accept { background: var(--zayit); border-color: var(--zayit); color: #fff; }
.choice-btn.active.maybe  { background: var(--zahav); border-color: var(--zahav); color: var(--dyo); }
.choice-btn.active.decline { background: var(--rimon); border-color: var(--rimon); color: #fff; }
.extras { text-align: start; margin-top: 22px; display: none; }
.extras.show { display: block; }
.rsvp-confirm { color: var(--dyo-70); font-size: 15px; margin-top: 8px; }
.rsvp-confirm strong { color: var(--dyo); }
.rsvp-footer {
  text-align: center;
  color: var(--dyo-55);
  font-size: 12px;
  margin-top: 32px;
  letter-spacing: 0.06em;
  font-weight: 500;
}
.rsvp-footer a { color: var(--dyo-55); text-decoration: underline; text-decoration-color: var(--paper-line); }

/* =========================================================
   Pricing
   ========================================================= */
.pricing-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; max-width: 880px; margin: 0 auto; }
@media (max-width: 720px) { .pricing-grid { grid-template-columns: 1fr; } }
.price-card {
  background: var(--paper);
  border: 1px solid var(--paper-line);
  border-radius: var(--r-card);
  padding: 36px 28px;
  text-align: center;
  position: relative;
  box-shadow: 0 1px 2px rgba(42,33,64,0.03);
}
.price-card.recommended { border-color: var(--rimon); box-shadow: 0 12px 40px -20px rgba(214,76,94,0.35); }
.price-card .badge {
  position: absolute; top: -12px; left: 50%; transform: translateX(-50%);
  background: var(--rimon); color: #fff;
  font-size: 10px; letter-spacing: 0.14em; text-transform: uppercase;
  padding: 5px 14px; border-radius: var(--r-pill);
  font-weight: 700;
}
.price-card h3 {
  font-family: var(--ff-display);
  font-size: 24px;
  font-weight: 700;
  margin: 0 0 12px;
  color: var(--dyo);
}
.price-amount {
  font-family: var(--ff-display);
  font-size: 48px;
  font-weight: 700;
  color: var(--dyo);
  letter-spacing: -0.02em;
}
.price-sub { color: var(--dyo-55); margin-bottom: 20px; font-size: 14px; }
.price-list { list-style: none; padding: 0; margin: 0 0 24px; text-align: start; }
.price-list li { padding: 8px 0; font-size: 14px; border-bottom: 1px solid var(--paper-line); }
.price-list li.ok { color: var(--dyo); }
.price-list li.no { color: var(--dyo-40); text-decoration: line-through; }

/* SEO tables */
.seo-table {
  width: 100%; border-collapse: collapse; margin: 36px 0;
  background: var(--paper); border: 1px solid var(--paper-line);
  border-radius: var(--r-card); overflow: hidden;
}
.seo-table th, .seo-table td { padding: 14px 18px; border-bottom: 1px solid var(--paper-line); text-align: start; font-size: 14px; }
.seo-table th { background: var(--klaf-deep); font-size: 11px; letter-spacing: 0.1em; text-transform: uppercase; color: var(--dyo-55); font-weight: 600; }

/* Loader */
.loader-wrap { min-height: 70vh; display: flex; align-items: center; justify-content: center; padding: 40px 20px; }
.loader-card { text-align: center; max-width: 480px; width: 100%; }
.loader-card h1 { font-family: var(--ff-display); font-weight: 700; font-size: 32px; margin: 20px 0 24px; color: var(--dyo); letter-spacing: -0.015em; }
.loader-bar { height: 3px; background: var(--paper-line); width: 100%; margin-bottom: 20px; overflow: hidden; border-radius: 2px; }
.loader-fill { height: 100%; background: var(--rimon); width: 0%; transition: width 0.5s var(--ease-soft); }
.loader-step { color: var(--dyo-70); font-size: 14px; min-height: 22px; font-family: var(--ff-ui); }

/* Design editor */
.design-grid { display: grid; grid-template-columns: 1fr 1.5fr; gap: 24px; }
@media (max-width: 900px) { .design-grid { grid-template-columns: 1fr; } }

/* Daily chart */
.chart { height: 120px; display: flex; align-items: end; gap: 3px; padding: 10px 0; }
.chart .bar { flex: 1; background: var(--zahav); min-height: 1px; border-radius: 1px; transition: background var(--dur-base); }
.chart .bar:hover { background: var(--rimon); }
.chart .bar[data-empty="1"] { background: var(--paper-line); }
.chart-axis { display: flex; justify-content: space-between; font-size: 10px; color: var(--dyo-55); letter-spacing: 0.1em; text-transform: uppercase; margin-top: 6px; font-weight: 600; }

/* =========================================================
   Envelope-seam divider utility
   ========================================================= */
.seam {
  border: 0;
  border-top: 1px dashed var(--dyo-40);
  margin: 32px 0;
  height: 0;
}

/* =========================================================
   Misc
   ========================================================= */
code, .code { font-family: var(--ff-mono); font-size: 13px; }
hr { border: 0; border-top: 1px solid var(--paper-line); margin: 28px 0; }
:focus-visible { outline: 2px solid var(--rimon); outline-offset: 2px; border-radius: var(--r-input); }

/* Hebrew doesn't need a different font stack — Assistant + Frank Ruhl Libre both ship Hebrew. */

/* ========== Kit components (ported from design bundle) ========== */

/* Compat aliases for imported kit selectors */
:root {
  --fg-1: var(--dyo);
  --fg-2: var(--dyo-70);
  --fg-3: var(--dyo-55);
  --fg-muted: var(--dyo-40);
  --fg-on-rimon: #FFF8F0;
  --fg-on-zayit: #FFF8F0;
  --h-topbar-desktop: 64px;
}

body.app-shell { background: var(--klaf); }

.app { display: grid; grid-template-rows: var(--h-topbar-desktop) 1fr; min-height: 100vh; }

/* ========== TopBar ========== */
.topbar { background: var(--paper); border-bottom: 1px solid var(--paper-line); position: sticky; top: 0; z-index: 10; }
.topbar-inner { height: 68px; max-width: 1440px; margin: 0 auto; padding: 0 32px; display: flex; align-items: center; gap: 28px; }
.brand { display: flex; align-items: center; gap: 10px; }
.brand-mark { width: 36px; height: 36px; }
.brand-text { display: flex; flex-direction: column; line-height: 1; }
.brand-name { font-family: var(--ff-display); font-weight: 700; font-size: 20px; letter-spacing: -0.01em; color: var(--fg-1); }
.brand-sub { font-family: var(--ff-ui); font-size: 10px; font-weight: 600; color: var(--zahav); letter-spacing: 0.18em; margin-top: 2px; }

.wedding-chip { display: flex; align-items: center; gap: 12px; padding: 7px 16px 7px 8px; background: linear-gradient(135deg, var(--klaf) 0%, #FBEEDE 100%); border: 1px solid var(--paper-line); border-radius: 14px; font-size: 13px; color: var(--fg-2); box-shadow: inset 0 1px 0 rgba(255,255,255,0.6); }
.wed-couple { font-weight: 700; color: var(--fg-1); font-family: var(--ff-display); font-size: 15px; letter-spacing: -0.01em; }
.wed-date { color: var(--fg-2); font-weight: 500; }
.wed-sep { color: var(--dyo-15); }
.wed-days { display: inline-flex; align-items: center; gap: 4px; color: var(--rimon); font-weight: 700; background: var(--rimon-soft); padding: 3px 9px; border-radius: 8px; font-size: 12px; }
.wed-days::before { content: ''; width: 5px; height: 5px; border-radius: 50%; background: var(--rimon); }

.topbar-actions { margin-inline-start: auto; display: flex; align-items: center; gap: 6px; }
.icon-btn { background: transparent; border: 0; width: 38px; height: 38px; border-radius: 10px; display: inline-flex; align-items: center; justify-content: center; cursor: pointer; color: var(--fg-2); position: relative; transition: all 160ms var(--ease-soft); }
.icon-btn:hover { background: var(--chol); color: var(--fg-1); }
.icon-btn.sm { width: 30px; height: 30px; border-radius: 8px; }
.dot-notify { position: absolute; top: 8px; inset-inline-end: 9px; width: 7px; height: 7px; border-radius: 50%; background: var(--rimon); border: 2px solid var(--paper); }
.user-chip { display: flex; align-items: center; gap: 8px; padding: 4px 14px 4px 4px; background: var(--klaf); border: 1px solid var(--paper-line); border-radius: var(--r-pill); font-size: 13px; font-weight: 600; color: var(--fg-1); cursor: pointer; transition: border-color 160ms; }
.user-chip:hover { border-color: var(--dyo-15); }
.user-avatar { width: 30px; height: 30px; border-radius: 50%; background: linear-gradient(135deg, var(--rimon) 0%, #B23848 100%); color: #fff; font-family: var(--ff-display); font-weight: 700; display: inline-flex; align-items: center; justify-content: center; font-size: 13px; }

/* ========== Layout ========== */
.workspace { display: grid; grid-template-columns: 248px 1fr 336px; max-width: 1440px; margin: 0 auto; padding: 32px; gap: 32px; align-items: flex-start; }
.sidenav { display: flex; flex-direction: column; gap: 2px; position: sticky; top: calc(var(--h-topbar-desktop) + 32px); }
.nav-section-label { font-family: var(--ff-ui); font-size: 11px; font-weight: 600; color: var(--fg-3); letter-spacing: 0.1em; text-transform: uppercase; padding: 4px 12px 10px; }
.nav-item { display: flex; align-items: center; gap: 11px; padding: 11px 12px; border-radius: 10px; background: transparent; border: 0; color: var(--fg-2); font-family: var(--ff-ui); font-size: 14px; font-weight: 500; cursor: pointer; text-align: start; transition: all 160ms var(--ease-soft); }
.nav-item:hover { background: rgba(245, 227, 204, 0.55); color: var(--fg-1); }
.nav-item.active { background: var(--dyo); color: #fff; box-shadow: 0 2px 8px rgba(42,33,64,0.18); }
.nav-item.active svg { color: #fff; }
.nav-label { flex: 1; }
.nav-badge { font-size: 11px; padding: 2px 8px; border-radius: 999px; background: var(--dyo-08); color: var(--fg-3); font-family: var(--ff-mono); font-weight: 600; }
.nav-item.active .nav-badge { background: rgba(255,255,255,0.16); color: #fff; }

.plan-card { background: linear-gradient(155deg, #FFF8F0 0%, #FBE4E7 100%); border: 1px solid var(--paper-line); border-radius: 16px; padding: 16px; display: flex; flex-direction: column; gap: 4px; align-items: flex-start; position: relative; overflow: hidden; margin-top: 16px; }
.plan-glyph { position: absolute; inset-inline-end: -12px; top: -10px; width: 66px; opacity: 0.22; color: var(--rimon); }
.plan-eyebrow { font-family: var(--ff-ui); font-size: 10px; font-weight: 700; letter-spacing: 0.14em; text-transform: uppercase; color: var(--rimon); }
.plan-title { font-family: var(--ff-display); font-weight: 700; font-size: 17px; color: var(--fg-1); line-height: 1.2; }
.plan-sub { font-size: 12px; color: var(--fg-3); }
.plan-cta { margin-top: 10px; font-family: var(--ff-ui); font-size: 12px; font-weight: 600; color: var(--rimon); display: inline-flex; align-items: center; gap: 4px; cursor: pointer; }

/* ========== Canvas ========== */
.canvas { display: flex; flex-direction: column; gap: 28px; min-width: 0; }

.page-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 24px; padding-bottom: 4px; }
.page-title { display: flex; flex-direction: column; gap: 6px; max-width: 560px; }
.page-title .eyebrow { font-family: var(--ff-ui); font-size: 11px; font-weight: 700; letter-spacing: 0.14em; text-transform: uppercase; color: var(--zahav); }
.page-title h1 { font-family: var(--ff-display); font-weight: 700; font-size: 36px; letter-spacing: -0.015em; color: var(--fg-1); margin: 0; line-height: 1.1; }
.page-title h1 .highlight { color: var(--rimon); }
.page-title p { color: var(--fg-3); font-size: 14px; margin: 0; line-height: 1.55; }
.page-actions { display: flex; gap: 8px; }

.btn.primary { background: var(--rimon); color: #fff; box-shadow: 0 1px 2px rgba(214,76,94,0.25), inset 0 1px 0 rgba(255,255,255,0.18); }
.btn.primary:hover { background: var(--rimon-deep); transform: translateY(-1px); box-shadow: 0 4px 10px rgba(214,76,94,0.3); }
.btn.secondary { background: var(--paper); color: var(--fg-1); border: 1px solid var(--dyo-15); }
.btn.secondary:hover { background: var(--klaf); border-color: var(--dyo-40); }
.btn.success { background: var(--zayit); color: #fff; }
.btn.ghost { background: transparent; color: var(--fg-2); }
.btn.ghost:hover { background: var(--chol); color: var(--fg-1); }

/* ========== Stats ========== */
.stat-row { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; }
.stat-card { background: var(--paper); border: 1px solid var(--paper-line); border-radius: 16px; padding: 18px 20px 16px; display: flex; flex-direction: column; gap: 12px; position: relative; overflow: hidden; transition: transform 180ms var(--ease-soft), box-shadow 180ms; }
.stat-card:hover { transform: translateY(-2px); box-shadow: 0 6px 20px rgba(42,33,64,0.06); }
.stat-card::before { content: ''; position: absolute; top: 0; inset-inline-start: 0; width: 3px; height: 40px; border-radius: 0 3px 3px 0; background: var(--accent, var(--rimon)); }
.stat-top { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; }
.stat-label { font-family: var(--ff-ui); font-size: 12px; font-weight: 600; color: var(--fg-3); letter-spacing: 0.04em; }
.stat-icon-chip { width: 32px; height: 32px; border-radius: 10px; display: inline-flex; align-items: center; justify-content: center; background: var(--accent-bg, var(--rimon-soft)); color: var(--accent, var(--rimon)); }
.stat-value { font-family: var(--ff-display); font-size: 40px; font-weight: 700; line-height: 1; color: var(--fg-1); letter-spacing: -0.02em; display: flex; align-items: baseline; gap: 6px; }
.stat-of { font-size: 14px; color: var(--fg-muted); font-weight: 500; font-family: var(--ff-ui); }
.stat-bar { height: 6px; background: var(--chol); border-radius: 999px; overflow: hidden; }
.stat-fill { height: 100%; border-radius: 999px; background: linear-gradient(90deg, var(--accent, var(--rimon)), var(--accent-2, var(--accent, var(--rimon)))); }
.stat-foot { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.stat-hint { font-size: 12px; color: var(--fg-3); display: inline-flex; align-items: center; gap: 4px; }
.stat-trend { display: inline-flex; align-items: center; gap: 3px; font-size: 11px; font-weight: 700; padding: 2px 7px; border-radius: 999px; background: var(--zayit-soft); color: var(--zayit-deep); font-family: var(--ff-ui); }
.stat-trend.down { background: var(--rimon-soft); color: var(--rimon-deep); }
.stat-trend.neutral { background: var(--chol); color: var(--fg-2); }

/* ========== Cards ========== */
.card { background: var(--paper); border: 1px solid var(--paper-line); border-radius: 18px; box-shadow: 0 1px 2px rgba(42,33,64,0.03); padding: 22px 24px; }
.card-head { display: flex; align-items: flex-start; justify-content: space-between; margin-bottom: 16px; gap: 12px; }
.card-title { font-family: var(--ff-display); font-size: 20px; font-weight: 700; color: var(--fg-1); margin: 0; letter-spacing: -0.01em; }
.card-sub { font-size: 13px; color: var(--fg-3); margin-top: 2px; }

/* ========== Toolbar / Filters ========== */
.toolbar { display: flex; gap: 10px; align-items: center; padding: 2px 0 18px; flex-wrap: wrap; }
.search { flex: 1; min-width: 240px; position: relative; }
.search input { width: 100%; box-sizing: border-box; font-family: var(--ff-ui); font-size: 14px; color: var(--fg-1); background: var(--klaf); border: 1.5px solid transparent; border-radius: 12px; padding: 10px 40px 10px 14px; transition: all 160ms; }
.search input:focus { outline: none; background: #fff; border-color: var(--rimon); box-shadow: 0 0 0 4px rgba(214,76,94,0.12); }
.search input::placeholder { color: var(--fg-muted); }
.search svg { position: absolute; inset-inline-end: 14px; top: 12px; color: var(--fg-3); pointer-events: none; }

.filter-group { display: inline-flex; padding: 4px; background: var(--klaf); border-radius: 12px; gap: 2px; border: 1px solid var(--paper-line); }
.filter-chip { display: inline-flex; align-items: center; gap: 7px; padding: 7px 12px; border-radius: 9px; background: transparent; border: 0; font-family: var(--ff-ui); font-size: 13px; font-weight: 600; color: var(--fg-2); cursor: pointer; transition: all 160ms var(--ease-soft); }
.filter-chip:hover { color: var(--fg-1); }
.filter-chip.on { background: #fff; color: var(--fg-1); box-shadow: 0 1px 3px rgba(42,33,64,0.08); }
.filter-chip .chip-count { font-size: 11px; padding: 1px 7px; border-radius: 999px; background: var(--dyo-08); color: var(--fg-3); font-family: var(--ff-mono); font-weight: 600; }
.filter-chip.on .chip-count { background: var(--rimon-soft); color: var(--rimon); }

/* ========== Guest list ========== */
.list-head { display: grid; grid-template-columns: 40px 1fr 160px 60px 120px 32px; align-items: center; gap: 16px; padding: 0 6px 10px; border-bottom: 1px solid var(--paper-line); margin-bottom: 4px; }
.list-head span { font-family: var(--ff-ui); font-size: 11px; font-weight: 700; color: var(--fg-3); letter-spacing: 0.1em; text-transform: uppercase; }
.guest-list { display: flex; flex-direction: column; }
.guest-row { display: grid; grid-template-columns: 40px 1fr 160px 60px 120px 32px; align-items: center; gap: 16px; padding: 14px 6px; border-bottom: 1px solid var(--paper-line); transition: background 160ms var(--ease-soft); border-radius: 8px; }
.guest-row:hover { background: var(--klaf); }
.guest-row:last-child { border-bottom: 0; }
.avatar { width: 40px; height: 40px; border-radius: 50%; background: linear-gradient(135deg, var(--chol) 0%, #E9CFAE 100%); color: var(--dyo); font-family: var(--ff-display); font-weight: 700; font-size: 16px; display: flex; align-items: center; justify-content: center; }
.avatar.a-1 { background: linear-gradient(135deg, #FBE4E7, #F5C0C7); color: var(--rimon-deep); }
.avatar.a-2 { background: linear-gradient(135deg, #E8F0DB, #CFE0B0); color: var(--zayit-deep); }
.avatar.a-3 { background: linear-gradient(135deg, #FBEBD4, #F0D1A0); color: #8B5E1F; }
.avatar.a-4 { background: linear-gradient(135deg, #E4E0F0, #C7BFE0); color: var(--dyo); }
.guest-name-block { display: flex; flex-direction: column; min-width: 0; }
.guest-name { font-weight: 600; color: var(--fg-1); font-size: 15px; }
.guest-phone { font-size: 12px; color: var(--fg-muted); font-family: var(--ff-mono); margin-top: 1px; }
.ltr { direction: ltr; text-align: end; }
.guest-tag { font-size: 12px; color: var(--fg-2); font-weight: 500; display: inline-flex; align-items: center; gap: 6px; }
.tag-dot { width: 6px; height: 6px; border-radius: 50%; background: var(--zahav); }
.guest-count { font-size: 14px; color: var(--fg-1); font-weight: 600; font-family: var(--ff-mono); }

/* ========== Pills (kit hyphenated variants) ========== */
.pill-dot { width: 6px; height: 6px; border-radius: 50%; }
.pill-accepted { background: var(--zayit-soft); color: var(--zayit-deep); } .pill-accepted .pill-dot { background: var(--zayit); }
.pill-declined { background: var(--rimon-soft); color: var(--rimon-deep); } .pill-declined .pill-dot { background: var(--rimon); }
.pill-sent { background: var(--zahav-soft); color: #8B5E1F; } .pill-sent .pill-dot { background: var(--zahav); }
.pill-pending { background: var(--chol); color: var(--fg-2); } .pill-pending .pill-dot { background: var(--fg-muted); }

/* ========== Right rail ========== */
.rail { display: flex; flex-direction: column; gap: 20px; position: sticky; top: calc(var(--h-topbar-desktop) + 32px); }

/* Campaign */
.campaign-card { padding: 0; overflow: hidden; }
.campaign-banner { background: linear-gradient(135deg, #2A2140 0%, #3B2F5A 100%); color: #fff; padding: 18px 22px; position: relative; overflow: hidden; }
.campaign-banner::after { content: ''; position: absolute; inset-inline-end: -20px; bottom: -20px; width: 120px; height: 120px; border-radius: 50%; background: radial-gradient(circle, rgba(232,165,92,0.25) 0%, transparent 70%); }
.campaign-eyebrow { font-family: var(--ff-ui); font-size: 10px; font-weight: 700; letter-spacing: 0.16em; text-transform: uppercase; color: var(--zahav); }
.campaign-title { font-family: var(--ff-display); font-size: 20px; font-weight: 700; margin-top: 6px; line-height: 1.2; letter-spacing: -0.01em; }
.campaign-meta { display: flex; gap: 14px; margin-top: 10px; font-size: 12px; color: rgba(255,255,255,0.75); }
.campaign-meta strong { color: #fff; font-weight: 600; }
.campaign-body { padding: 18px 22px; display: flex; flex-direction: column; gap: 14px; }
.campaign-preview { background: var(--klaf); border-radius: 12px; padding: 12px 14px; border-inline-start: 3px solid var(--zayit); }
.preview-label { font-family: var(--ff-ui); font-size: 10px; font-weight: 700; letter-spacing: 0.1em; text-transform: uppercase; color: var(--fg-3); margin-bottom: 6px; display: flex; align-items: center; gap: 6px; }
.preview-body { font-size: 13px; color: var(--fg-1); line-height: 1.6; }
.preview-body .var { background: var(--zahav-soft); color: #8B5E1F; padding: 1px 5px; border-radius: 4px; font-family: var(--ff-mono); font-size: 11px; }
.campaign-actions { display: flex; gap: 8px; align-items: center; }
.campaign-actions .btn { flex: 1; justify-content: center; }

/* ========== Activity ========== */
.activity-item { display: flex; gap: 12px; padding: 12px 0; border-bottom: 1px solid var(--paper-line); }
.activity-item:first-child { padding-top: 0; }
.activity-item:last-child { border-bottom: 0; padding-bottom: 0; }
.activity-icon { width: 32px; height: 32px; border-radius: 10px; flex-shrink: 0; display: flex; align-items: center; justify-content: center; }
.activity-icon.accepted { background: var(--zayit-soft); color: var(--zayit-deep); }
.activity-icon.declined { background: var(--rimon-soft); color: var(--rimon-deep); }
.activity-icon.sent { background: var(--zahav-soft); color: #8B5E1F; }
.activity-body { flex: 1; min-width: 0; }
.activity-text { font-size: 13px; color: var(--fg-2); line-height: 1.5; }
.activity-text strong { color: var(--fg-1); font-weight: 600; }
.activity-time { font-size: 11px; color: var(--fg-muted); margin-top: 2px; font-family: var(--ff-ui); }

/* ========== WhatsApp invite preview ========== */
.wa-preview-card { background: linear-gradient(180deg, #EFE6D6 0%, #E6D8BF 100%); border-color: #D9C59C; }
.wa-preview {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  padding: 18px 8px 8px;
}
.wa-bubble {
  width: 100%;
  max-width: 340px;
  background: #FFFDF7;
  border-radius: 10px;
  padding: 6px 6px 22px;
  position: relative;
  box-shadow: 0 1px 1px rgba(0,0,0,0.08), 0 2px 6px rgba(0,0,0,0.06);
  font-family: var(--ff-ui);
  color: #111;
}
.wa-bubble::after {
  content: '';
  position: absolute;
  top: 0;
  inset-inline-start: -6px;
  width: 0;
  height: 0;
  border-top: 8px solid #FFFDF7;
  border-inline-start: 8px solid transparent;
}
html[dir="rtl"] .wa-bubble::after {
  inset-inline-start: auto;
  inset-inline-end: -6px;
  border-inline-start: 0;
  border-inline-end: 8px solid transparent;
}
.wa-image {
  width: 100%;
  display: block;
  border-radius: 6px;
  margin-bottom: 8px;
  height: auto;
  object-fit: contain;
}
.wa-body { padding: 2px 10px 4px; font-size: 13.5px; line-height: 1.45; }
.wa-body p { margin: 0 0 8px; }
.wa-body p:last-child { margin-bottom: 0; }
.wa-body strong { font-weight: 600; color: #111; }
.wa-body em { font-style: normal; font-weight: 600; color: #0A7C47; }
.wa-footer {
  padding: 8px 10px 0;
  font-size: 11px;
  color: #667781;
  border-top: 1px solid rgba(17,17,17,0.06);
  margin-top: 8px;
}
.wa-time {
  position: absolute;
  bottom: 6px;
  inset-inline-end: 12px;
  font-size: 10px;
  color: #667781;
  font-family: var(--ff-ui);
}
.wa-cta {
  width: 100%;
  max-width: 340px;
  background: #FFFDF7;
  color: #0A7C47;
  border: 0;
  padding: 11px 14px;
  font-family: var(--ff-ui);
  font-size: 14px;
  font-weight: 600;
  border-radius: 10px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  box-shadow: 0 1px 1px rgba(0,0,0,0.08);
  cursor: default;
}
.wa-cta:disabled { opacity: 1; }

@media (max-width: 980px) {
  .wa-preview { padding: 12px 0 4px; }
  .wa-bubble, .wa-cta { max-width: 100%; }
  .wa-body { font-size: 13px; }
}

/* ========== Seam divider ========== */
.seam { height: 1px; background: var(--paper-line); margin: 16px 0; }

@keyframes justAccepted { 0% { background: var(--zayit-soft); } 100% { background: transparent; } }
.guest-row.just-accepted { animation: justAccepted 1400ms var(--ease-soft); }

/* ========== Mobile header ========== */
.m-header { padding: 16px 20px 12px; background: var(--klaf); border-bottom: 1px solid var(--paper-line); }
.m-header-top { display: flex; align-items: center; justify-content: space-between; margin-bottom: 10px; }
.m-greeting { display: flex; flex-direction: column; line-height: 1.1; }
.m-hello { font-size: 12px; color: var(--fg-3); font-weight: 500; }
.m-name { font-family: var(--ff-display); font-size: 20px; font-weight: 700; color: var(--fg-1); letter-spacing: -0.01em; }
.m-avatar { width: 40px; height: 40px; border-radius: 50%; background: var(--rimon); color: var(--fg-on-rimon); font-family: var(--ff-display); font-weight: 700; display: flex; align-items: center; justify-content: center; font-size: 16px; }
.m-countdown { display: flex; align-items: center; gap: 8px; padding: 8px 12px; background: var(--paper); border: 1px solid var(--paper-line); border-radius: var(--r-pill); font-size: 12px; color: var(--fg-2); }
.m-countdown strong { color: var(--rimon); font-weight: 700; }

/* ========== Mobile content ========== */
.m-body { flex: 1; overflow-y: auto; padding: 18px 16px 90px; display: flex; flex-direction: column; gap: 16px; }
.m-section-title { font-family: var(--ff-display); font-size: 22px; font-weight: 700; color: var(--fg-1); letter-spacing: -0.01em; margin: 0; }
.m-section-sub { font-size: 12px; color: var(--fg-3); margin: 2px 0 0; }

/* Big stat card */
.m-stat-hero { background: var(--paper); border: 1px solid var(--paper-line); border-radius: var(--r-card); box-shadow: var(--shadow-paper); padding: 18px 20px; position: relative; overflow: hidden; }
.m-stat-glyph { position: absolute; inset-inline-end: -14px; top: -10px; width: 90px; opacity: 0.12; color: var(--rimon); }
.m-stat-eyebrow { font-family: var(--ff-ui); font-size: 10px; font-weight: 700; letter-spacing: 0.14em; text-transform: uppercase; color: var(--zahav); }
.m-stat-num { font-family: var(--ff-display); font-size: 44px; font-weight: 700; color: var(--fg-1); line-height: 1; letter-spacing: -0.02em; margin-top: 6px; }
.m-stat-num .of { font-size: 18px; color: var(--fg-3); margin-inline-start: 6px; font-weight: 500; }
.m-stat-bar { height: 5px; background: var(--chol); border-radius: var(--r-pill); margin-top: 14px; overflow: hidden; }
.m-stat-fill { height: 100%; background: var(--zayit); border-radius: var(--r-pill); }
.m-stat-legend { display: flex; justify-content: space-between; margin-top: 8px; font-size: 11px; color: var(--fg-3); }
.m-stat-legend-dot { display: inline-flex; align-items: center; gap: 4px; }
.m-stat-legend-dot::before { content: ''; width: 6px; height: 6px; border-radius: 50%; background: currentColor; }

/* Two-stat row */
.m-two-stat { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.m-mini-stat { background: var(--paper); border: 1px solid var(--paper-line); border-radius: var(--r-card); padding: 12px 14px; }
.m-mini-num { font-family: var(--ff-display); font-size: 26px; font-weight: 700; color: var(--fg-1); letter-spacing: -0.01em; line-height: 1; }
.m-mini-lbl { font-size: 11px; color: var(--fg-3); margin-top: 4px; }

/* Mobile activity */
.m-activity-card { background: var(--paper); border: 1px solid var(--paper-line); border-radius: var(--r-card); padding: 16px 18px; }
.m-act-row { display: flex; align-items: center; gap: 10px; padding: 10px 0; border-bottom: 1px dashed var(--dyo-15); }
.m-act-row:last-child { border-bottom: 0; }
.m-act-avatar { width: 32px; height: 32px; border-radius: 50%; background: var(--chol); color: var(--fg-2); font-family: var(--ff-display); font-weight: 700; font-size: 13px; display: flex; align-items: center; justify-content: center; flex-shrink: 0; }
.m-act-name { font-size: 13px; color: var(--fg-1); font-weight: 600; }
.m-act-text { font-size: 12px; color: var(--fg-3); }
.m-act-time { margin-inline-start: auto; font-family: var(--ff-mono); font-size: 10px; color: var(--fg-muted); }

/* Mobile pill sizing (smaller than desktop pills) */
.m-body .pill,
.m-header .pill { padding: 3px 8px; font-size: 11px; gap: 4px; }
.m-body .pill .pill-dot,
.m-header .pill .pill-dot { width: 5px; height: 5px; }

/* Reminder banner */
.m-reminder { background: linear-gradient(to bottom, var(--rimon), var(--rimon-deep)); color: var(--fg-on-rimon); border-radius: var(--r-card); padding: 18px 20px; position: relative; overflow: hidden; box-shadow: var(--shadow-paper); }
.m-reminder-seal { position: absolute; inset-inline-end: -8px; bottom: -10px; width: 80px; opacity: 0.18; }
.m-reminder-eye { font-size: 10px; font-weight: 700; letter-spacing: 0.14em; text-transform: uppercase; opacity: 0.8; }
.m-reminder-title { font-family: var(--ff-display); font-size: 20px; font-weight: 700; letter-spacing: -0.01em; margin-top: 4px; }
.m-reminder-sub { font-size: 13px; opacity: 0.85; margin-top: 6px; line-height: 1.4; }
.m-reminder-btn { background: var(--klaf); color: var(--rimon); font-weight: 700; font-size: 13px; padding: 8px 16px; border-radius: var(--r-button); border: 0; margin-top: 12px; font-family: var(--ff-ui); }

/* Tab bar */
.m-tabbar { position: fixed; bottom: 0; left: 0; right: 0; height: 84px; background: rgba(247,241,230,0.92); backdrop-filter: blur(16px); border-top: 1px solid var(--paper-line); display: flex; justify-content: space-around; align-items: flex-start; padding: 10px 16px 0; z-index: 50; }
.m-tab { background: transparent; border: 0; flex: 1; display: flex; flex-direction: column; align-items: center; gap: 3px; color: var(--fg-3); font-family: var(--ff-ui); font-size: 10px; font-weight: 600; cursor: pointer; padding: 4px; }
.m-tab.active { color: var(--rimon); }
.m-tab svg { width: 22px; height: 22px; }

/* FAB */
.m-fab { position: fixed; bottom: 100px; inset-inline-end: 20px; width: 54px; height: 54px; border-radius: 50%; background: var(--rimon); color: var(--fg-on-rimon); border: 0; box-shadow: 0 8px 24px rgba(142,31,47,0.4); display: flex; align-items: center; justify-content: center; cursor: pointer; z-index: 60; }

/* ========== Responsive ========== */
@media (max-width: 980px) {
  .workspace { grid-template-columns: 1fr; padding: 16px 14px; gap: 18px; }
  .sidenav { display: none; }
  .rail { position: static; gap: 14px; }
  .canvas { gap: 18px; }
  .topbar-inner { padding: 0 14px; gap: 10px; height: 56px; }
  .wedding-chip { display: none; }
  .topbar-actions { gap: 2px; }
  .topbar-actions .user-chip span:not(.user-avatar) { display: none; }
  .topbar-actions .user-chip { padding: 4px; }
  body.app-shell { padding-bottom: 96px; }

  /* Page head stacks cleanly; headline shrinks */
  .page-head { flex-direction: column; align-items: stretch; gap: 14px; padding-bottom: 0; }
  .page-title { max-width: none; gap: 4px; }
  .page-title h1 { font-size: 24px; line-height: 1.2; }
  .page-title p { font-size: 13px; }
  .page-title .eyebrow { font-size: 10px; }

  /* Full-width action buttons, wrap-friendly */
  .page-actions { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; width: 100%; }
  .page-actions .btn { width: 100%; justify-content: center; padding: 11px 12px; font-size: 13px; }

  /* 2-up stat grid — roomier, readable on phones */
  .stat-row { grid-template-columns: 1fr 1fr; gap: 10px; margin-top: 0; }
  .stat-card { padding: 14px 14px 12px; gap: 8px; border-radius: 14px; }
  .stat-card::before { height: 28px; }
  .stat-top { gap: 8px; }
  .stat-label { font-size: 11px; }
  .stat-icon-chip { width: 26px; height: 26px; border-radius: 8px; }
  .stat-icon-chip svg { width: 14px; height: 14px; }
  .stat-value { font-size: 28px; }
  .stat-of { font-size: 12px; }
  .stat-bar { height: 5px; }
  .stat-hint { font-size: 11px; }

  /* Cards tighter */
  .card { padding: 16px 16px; border-radius: 16px; }
  .card + .card { margin-top: 0 !important; }
  .card[style*="margin-top"] { margin-top: 0 !important; }
  .card-head { margin-bottom: 12px; }
  .card-title { font-size: 17px; }
  .card-sub { font-size: 12px; }

  /* Campaign card fits narrow width */
  .campaign-banner { padding: 16px 18px; }
  .campaign-title { font-size: 17px; }
  .campaign-body { padding: 14px 16px; gap: 12px; }
  .campaign-actions { flex-direction: column; gap: 8px; }
  .campaign-actions .btn,
  .campaign-actions form { width: 100%; flex: 1 0 auto; }
  .campaign-actions form .btn { width: 100%; }
  .preview-body { font-size: 13px; line-height: 1.55; }

  /* Activity rows tighten */
  .activity-item { gap: 10px; padding: 10px 0; }
  .activity-icon { width: 28px; height: 28px; border-radius: 8px; }
  .activity-text { font-size: 13px; }

  /* Chart lightened */
  #chart-host { min-height: 120px; }

  /* Toolbar (search + filters) */
  .toolbar { gap: 10px; padding: 0 0 14px; }
  .search { flex: 1 1 100%; min-width: 0; }
  .search input { font-size: 15px; padding: 11px 40px 11px 14px; }
  .filter-group {
    flex: 1 1 100%;
    width: 100%;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
    white-space: nowrap;
    flex-wrap: nowrap;
    justify-content: flex-start;
  }
  .filter-group::-webkit-scrollbar { display: none; }
  .filter-chip { flex: 0 0 auto; font-size: 12px; padding: 7px 10px; }

  /* Hide desktop table header; reflow guest rows as cards */
  .list-head { display: none; }
  .guest-list { gap: 8px; }
  .guest-row {
    grid-template-columns: 40px 1fr auto;
    grid-template-areas:
      "avatar name   status"
      "avatar meta   count"
      "actions actions actions";
    gap: 4px 12px;
    padding: 12px 14px;
    border: 1px solid var(--paper-line);
    border-radius: 12px;
    background: var(--paper);
    align-items: center;
  }
  .guest-row:hover { background: var(--paper); }
  .guest-row > .avatar { grid-area: avatar; align-self: start; width: 36px; height: 36px; font-size: 14px; }
  .guest-row > .guest-name-block { grid-area: name; min-width: 0; }
  .guest-name { font-size: 14px; line-height: 1.25; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
  .guest-phone { font-size: 12px; }
  .guest-row > div:nth-child(5) { grid-area: status; justify-self: end; align-self: start; }
  .guest-row > .guest-tag {
    grid-area: meta;
    font-size: 12px;
    color: var(--fg-3);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    min-width: 0;
  }
  .guest-row > .guest-count {
    grid-area: count;
    justify-self: end;
    font-size: 12px;
    color: var(--fg-2);
  }
  .guest-row > .row-actions {
    grid-area: actions;
    display: flex;
    gap: 6px;
    justify-content: flex-end;
    padding-top: 8px;
    margin-top: 6px;
    border-top: 1px dashed var(--dyo-15);
  }
  .row-actions .icon-btn.sm { width: 36px; height: 36px; }
  .pill { font-size: 11px; padding: 4px 8px; }
  .pill .pill-dot { width: 5px; height: 5px; }

  /* Empty state */
  .empty { padding: 40px 16px !important; }

  /* Form rows stack */
  .form-row { grid-template-columns: 1fr !important; gap: 12px; }
  .submit-row { flex-direction: column-reverse; align-items: stretch; }
  .submit-row .btn { width: 100%; justify-content: center; }
}

@media (max-width: 420px) {
  .stat-row { grid-template-columns: 1fr; }
  .page-actions { grid-template-columns: 1fr; }
  .page-title h1 { font-size: 22px; }
}

@media (min-width: 981px) {
  .m-tabbar { display: none; }
  .m-fab { display: none; }
}

/* ========== End kit components ========== */
