/* ── Reset & Base ── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --sage-50: #f4f7f5;
  --sage-100: #e4ebe6;
  --sage-200: #c9d7cd;
  --sage-300: #a3bca9;
  --sage-400: #7a9e82;
  --sage-500: #5a8463;
  --sage-600: #476a4f;
  --sage-700: #3a5541;
  --sage-800: #314536;
  --sage-900: #293a2e;

  --warm-50: #faf8f6;
  --warm-100: #f3efe9;
  --warm-200: #e8e0d5;
  --warm-300: #d4c5b3;
  --warm-400: #bfa78e;

  --dusk-500: #6b5e7b;
  --dusk-600: #574c65;
  --dusk-700: #443c50;

  --text-primary: #2c2c2c;
  --text-secondary: #5a5a5a;
  --text-muted: #8a8a8a;
  --white: #ffffff;

  --error: #c0392b;
  --error-bg: #fdf0ef;
  --success: #3a5541;
  --success-bg: #edf5ef;

  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 20px;
  --radius-full: 9999px;

  /* Notebook editor */
  --nb-line-height: 30px;
  --nb-paper-bg: #fbf7ef;
  --nb-line-color: rgba(164, 188, 169, 0.25);
  --nb-margin-color: rgba(192, 80, 80, 0.2);
  --nb-margin-left: 60px;
  --nb-ink-color: #2c1810;
  --nb-ink-shadow: rgba(44, 24, 16, 0.08);
}

html { scroll-behavior: smooth; }

body {
  font-family: 'Inter', system-ui, -apple-system, sans-serif;
  color: var(--text-primary);
  line-height: 1.6;
  background: var(--warm-50);
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3 {
  font-family: 'Playfair Display', Georgia, serif;
  line-height: 1.2;
}

/* ── Navigation ── */
.nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  padding: 1rem 2rem;
  transition: background 0.3s, box-shadow 0.3s;
}

.nav.scrolled {
  background: rgba(250, 248, 246, 0.95);
  backdrop-filter: blur(12px);
  box-shadow: 0 1px 3px rgba(0,0,0,0.06);
}

.nav-inner {
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.logo {
  font-family: 'Playfair Display', serif;
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--sage-700);
  text-decoration: none;
  letter-spacing: -0.02em;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 2rem;
  list-style: none;
}

.nav-links a {
  text-decoration: none;
  color: var(--text-secondary);
  font-size: 0.9rem;
  font-weight: 500;
  transition: color 0.2s;
}

.nav-links a:hover { color: var(--sage-600); }

.nav-links a.btn-primary {
  color: var(--white);
}
.nav-links a.btn-primary:hover {
  color: var(--white);
}

/* ── Buttons ── */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.7rem 1.6rem;
  border-radius: var(--radius-full);
  font-family: 'Inter', sans-serif;
  font-size: 0.9rem;
  font-weight: 600;
  text-decoration: none;
  border: none;
  cursor: pointer;
  transition: all 0.25s ease;
}

.btn-primary {
  background: var(--sage-600);
  color: var(--white);
}
.btn-primary:hover {
  background: var(--sage-700);
  transform: translateY(-1px);
  box-shadow: 0 4px 16px rgba(71, 106, 79, 0.3);
}

.btn-primary:disabled {
  opacity: 0.6;
  cursor: not-allowed;
  transform: none;
  box-shadow: none;
}

.btn-secondary {
  background: transparent;
  color: var(--sage-700);
  border: 1.5px solid var(--sage-300);
}
.btn-secondary:hover {
  background: var(--sage-50);
  border-color: var(--sage-400);
}

.btn-large {
  padding: 0.9rem 2.2rem;
  font-size: 1rem;
}

.btn-white {
  background: var(--white);
  color: var(--sage-700);
}
.btn-white:hover {
  transform: translateY(-1px);
  box-shadow: 0 6px 20px rgba(0,0,0,0.15);
}

/* ── Hero ── */
.hero {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 10rem 2rem 6rem;
  position: relative;
  overflow: hidden;
}

.hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse at 20% 50%, rgba(164, 188, 169, 0.15) 0%, transparent 60%),
    radial-gradient(ellipse at 80% 20%, rgba(107, 94, 123, 0.08) 0%, transparent 50%),
    radial-gradient(ellipse at 50% 80%, rgba(191, 167, 142, 0.12) 0%, transparent 50%);
  pointer-events: none;
}

.hero-content {
  max-width: 720px;
  position: relative;
  z-index: 1;
}

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.5rem 1.2rem;
  background: var(--sage-100);
  color: var(--sage-700);
  border-radius: var(--radius-full);
  font-size: 0.8rem;
  font-weight: 600;
  margin-bottom: 2.5rem;
  letter-spacing: 0.03em;
}

.hero h1 {
  font-size: clamp(2.5rem, 5vw, 3.8rem);
  color: var(--sage-800);
  margin-bottom: 1.5rem;
  letter-spacing: -0.02em;
}

.hero h1 em {
  font-style: normal;
  color: var(--sage-500);
}

.hero p {
  font-size: 1.15rem;
  color: var(--text-secondary);
  max-width: 560px;
  margin: 0 auto 3rem;
  line-height: 1.8;
}

.hero-actions {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 1rem;
  flex-wrap: wrap;
}

.hero-note {
  display: block;
  margin-top: 1.5rem;
  font-size: 0.82rem;
  color: var(--text-muted);
}

/* ── Features ── */
.features {
  padding: 8rem 2rem;
  max-width: 1200px;
  margin: 0 auto;
}

.section-header {
  text-align: center;
  max-width: 600px;
  margin: 0 auto 5rem;
}

.section-label {
  display: inline-block;
  font-size: 0.78rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--sage-500);
  margin-bottom: 0.75rem;
}

.section-header h2 {
  font-size: clamp(1.8rem, 3.5vw, 2.6rem);
  color: var(--sage-800);
  margin-bottom: 1rem;
  letter-spacing: -0.01em;
}

.section-header p {
  color: var(--text-secondary);
  font-size: 1.05rem;
  line-height: 1.7;
}

.features-list {
  max-width: 640px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  gap: 0;
}

.feature-row {
  display: flex;
  align-items: flex-start;
  gap: 1.5rem;
  padding: 1.75rem 1.5rem;
  border-radius: var(--radius-md);
  transition: background 0.3s ease, transform 0.3s ease;
}

.feature-row:hover {
  background: var(--sage-50);
  transform: translateX(4px);
}

.feature-icon-wrap {
  width: 44px;
  height: 44px;
  min-width: 44px;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--sage-100);
  color: var(--sage-700);
  transition: background 0.3s ease, color 0.3s ease;
}

.feature-row:hover .feature-icon-wrap {
  background: var(--sage-200);
  color: var(--sage-800);
}

.feature-text {
  flex: 1;
  min-width: 0;
}

.feature-text h3 {
  font-family: 'Inter', sans-serif;
  font-size: 1rem;
  font-weight: 600;
  margin-bottom: 0.3rem;
  color: var(--sage-800);
}

.feature-text p {
  font-size: 0.9rem;
  color: var(--text-muted);
  line-height: 1.6;
}

/* ── How It Works ── */
.how-it-works {
  padding: 8rem 2rem;
  background: var(--sage-50);
}

.how-inner {
  max-width: 900px;
  margin: 0 auto;
}

.steps {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 3rem;
  margin-top: 4rem;
}

.step {
  text-align: center;
  position: relative;
}

.step-number {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: var(--sage-600);
  color: var(--white);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 1rem;
  margin-bottom: 1rem;
}

.step h3 {
  font-family: 'Inter', sans-serif;
  font-size: 1.05rem;
  font-weight: 600;
  margin-bottom: 0.5rem;
}

.step p {
  font-size: 0.9rem;
  color: var(--text-secondary);
  line-height: 1.6;
}

/* ── Testimonial / Quote ── */
.testimonial {
  padding: 6rem 2rem;
  text-align: center;
}

.testimonial-inner {
  max-width: 680px;
  margin: 0 auto;
}

.testimonial blockquote {
  font-family: 'Playfair Display', serif;
  font-size: clamp(1.3rem, 2.5vw, 1.7rem);
  color: var(--sage-700);
  font-weight: 500;
  line-height: 1.6;
  font-style: italic;
  margin-bottom: 1.5rem;
}

.testimonial cite {
  font-style: normal;
  font-size: 0.9rem;
  color: var(--text-muted);
}

/* ── CTA Section ── */
.cta {
  padding: 8rem 2rem;
  text-align: center;
}

.cta-box {
  max-width: 700px;
  margin: 0 auto;
  background: linear-gradient(135deg, var(--sage-700), var(--dusk-600));
  border-radius: var(--radius-lg);
  padding: 5rem 3rem;
  color: var(--white);
}

.cta-box h2 {
  font-size: clamp(1.6rem, 3vw, 2.2rem);
  margin-bottom: 1rem;
}

.cta-box p {
  font-size: 1.05rem;
  opacity: 0.9;
  margin-bottom: 2rem;
  max-width: 480px;
  margin-left: auto;
  margin-right: auto;
  line-height: 1.7;
}

/* ── Footer ── */
.footer {
  padding: 3rem 2rem;
  border-top: 1px solid var(--sage-100);
}

.footer-inner {
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 1rem;
}

.footer-logo {
  font-family: 'Playfair Display', serif;
  font-weight: 700;
  font-size: 1.2rem;
  color: var(--sage-700);
}

.footer-links {
  display: flex;
  gap: 1.5rem;
  list-style: none;
}

.footer-links a {
  font-size: 0.85rem;
  color: var(--text-muted);
  text-decoration: none;
  transition: color 0.2s;
}
.footer-links a:hover { color: var(--sage-600); }

.footer-copy {
  font-size: 0.8rem;
  color: var(--text-muted);
}

/* ── Animations ── */
.fade-in {
  opacity: 0;
  transform: translateY(12px);
  transition: opacity 0.8s ease, transform 0.8s ease;
}

.fade-in.visible {
  opacity: 1;
  transform: translateY(0);
}

/* ── Mobile nav toggle ── */
.nav-toggle {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  padding: 0.5rem;
}

.nav-toggle span {
  display: block;
  width: 22px;
  height: 2px;
  background: var(--text-primary);
  margin: 5px 0;
  transition: all 0.3s;
}

/* ══════════════════════════════════════
   Auth Pages — Forms
   ══════════════════════════════════════ */

.auth-page {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 6rem 1.5rem 3rem;
  position: relative;
}

.auth-page::before {
  content: '';
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse at 30% 40%, rgba(164, 188, 169, 0.12) 0%, transparent 60%),
    radial-gradient(ellipse at 70% 70%, rgba(107, 94, 123, 0.06) 0%, transparent 50%);
  pointer-events: none;
}

.auth-card {
  width: 100%;
  max-width: 440px;
  background: var(--white);
  border: 1px solid var(--sage-100);
  border-radius: var(--radius-lg);
  padding: 2.5rem;
  position: relative;
  z-index: 1;
  box-shadow: 0 4px 24px rgba(0,0,0,0.04);
}

.auth-card h1 {
  font-size: 1.8rem;
  color: var(--sage-800);
  margin-bottom: 0.4rem;
}

.auth-card .auth-subtitle {
  color: var(--text-secondary);
  font-size: 0.95rem;
  margin-bottom: 2rem;
}

.form-group {
  margin-bottom: 1.25rem;
}

.form-group label {
  display: block;
  font-size: 0.85rem;
  font-weight: 500;
  color: var(--text-primary);
  margin-bottom: 0.4rem;
}

.form-group input {
  width: 100%;
  padding: 0.75rem 1rem;
  border: 1.5px solid var(--sage-200);
  border-radius: var(--radius-sm);
  font-family: 'Inter', sans-serif;
  font-size: 0.95rem;
  color: var(--text-primary);
  background: var(--warm-50);
  transition: border-color 0.2s, box-shadow 0.2s;
  outline: none;
}

.form-group input::placeholder {
  color: var(--text-muted);
}

.form-group input:focus {
  border-color: var(--sage-400);
  box-shadow: 0 0 0 3px rgba(122, 158, 130, 0.15);
}

.auth-card .btn {
  width: 100%;
  padding: 0.85rem;
  font-size: 0.95rem;
  margin-top: 0.5rem;
}

.auth-message {
  padding: 0.75rem 1rem;
  border-radius: var(--radius-sm);
  font-size: 0.87rem;
  margin-bottom: 1rem;
  display: none;
}

.auth-message.error {
  background: var(--error-bg);
  color: var(--error);
  border: 1px solid rgba(192, 57, 43, 0.15);
  display: block;
}

.auth-message.success {
  background: var(--success-bg);
  color: var(--success);
  border: 1px solid rgba(58, 85, 65, 0.15);
  display: block;
}

.auth-footer {
  text-align: center;
  margin-top: 1.5rem;
  font-size: 0.88rem;
  color: var(--text-muted);
}

.auth-footer a {
  color: var(--sage-600);
  text-decoration: none;
  font-weight: 500;
}

.auth-footer a:hover {
  color: var(--sage-700);
  text-decoration: underline;
}

/* ══════════════════════════════════════
   Dashboard
   ══════════════════════════════════════ */

.dashboard-nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  padding: 1rem 2rem;
  background: rgba(250, 248, 246, 0.95);
  backdrop-filter: blur(12px);
  box-shadow: 0 1px 3px rgba(0,0,0,0.06);
}

.dashboard-nav .nav-inner {
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.btn-outline-danger {
  background: transparent;
  color: var(--text-secondary);
  border: 1.5px solid var(--sage-200);
  padding: 0.5rem 1.2rem;
  font-size: 0.85rem;
}

.btn-outline-danger:hover {
  border-color: var(--error);
  color: var(--error);
  background: var(--error-bg);
}

.dashboard-content {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 6rem 2rem 3rem;
  text-align: center;
}

.dashboard-welcome {
  max-width: 560px;
}

.dashboard-welcome h1 {
  font-size: clamp(1.6rem, 3vw, 2.2rem);
  color: var(--sage-800);
  margin-bottom: 0.75rem;
}

.dashboard-welcome .user-email {
  font-size: 0.95rem;
  color: var(--sage-600);
  font-weight: 500;
  margin-bottom: 1.5rem;
}

.dashboard-welcome p {
  color: var(--text-secondary);
  font-size: 1rem;
  line-height: 1.7;
}

/* ══════════════════════════════════════
   Create About Them — Form Page
   ══════════════════════════════════════ */

.create-page {
  min-height: 100vh;
  padding: 6rem 1.5rem 3rem;
  position: relative;
}

.create-page::before {
  content: '';
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse at 30% 40%, rgba(164, 188, 169, 0.12) 0%, transparent 60%),
    radial-gradient(ellipse at 70% 70%, rgba(107, 94, 123, 0.06) 0%, transparent 50%);
  pointer-events: none;
}

.create-form {
  width: 100%;
  max-width: 600px;
  margin: 0 auto;
  background: var(--white);
  border: 1px solid var(--sage-100);
  border-radius: var(--radius-lg);
  padding: 2.5rem;
  position: relative;
  z-index: 1;
  box-shadow: 0 4px 24px rgba(0,0,0,0.04);
}

.create-form h1 {
  font-size: 1.8rem;
  color: var(--sage-800);
  margin-bottom: 0.4rem;
}

.create-form .form-subtitle {
  color: var(--text-secondary);
  font-size: 0.95rem;
  margin-bottom: 2rem;
}

.form-group select,
.form-group textarea {
  width: 100%;
  padding: 0.75rem 1rem;
  border: 1.5px solid var(--sage-200);
  border-radius: var(--radius-sm);
  font-family: 'Inter', sans-serif;
  font-size: 0.95rem;
  color: var(--text-primary);
  background: var(--warm-50);
  transition: border-color 0.2s, box-shadow 0.2s;
  outline: none;
}

.form-group select:focus,
.form-group textarea:focus {
  border-color: var(--sage-400);
  box-shadow: 0 0 0 3px rgba(122, 158, 130, 0.15);
}

.form-group textarea {
  min-height: 100px;
  resize: vertical;
  line-height: 1.6;
}

.form-group textarea.large {
  min-height: 150px;
}

.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
}

/* ══════════════════════════════════════
   Dashboard — Profile Cards
   ══════════════════════════════════════ */

.dashboard-page {
  min-height: 100vh;
  padding: 5.5rem 2rem 3rem;
}

.dashboard-header {
  max-width: 900px;
  margin: 0 auto 2rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 1rem;
}

.dashboard-header h1 {
  font-size: clamp(1.4rem, 2.5vw, 1.8rem);
  color: var(--sage-800);
}

.dashboard-header .user-email {
  font-size: 0.85rem;
  color: var(--text-muted);
  font-weight: 400;
  font-family: 'Inter', sans-serif;
  display: block;
  margin-top: 0.25rem;
}

.profiles-grid {
  max-width: 900px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 1.25rem;
}

.profile-card {
  background: var(--white);
  border: 1px solid var(--sage-100);
  border-radius: var(--radius-lg);
  padding: 1.5rem;
  text-decoration: none;
  color: inherit;
  transition: all 0.3s ease;
  display: block;
}

.profile-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 8px 30px rgba(0,0,0,0.06);
  border-color: var(--sage-200);
}

.profile-card h3 {
  font-family: 'Playfair Display', serif;
  font-size: 1.2rem;
  color: var(--sage-800);
  margin-bottom: 0.5rem;
}

.relationship-badge {
  display: inline-block;
  padding: 0.2rem 0.7rem;
  background: var(--sage-100);
  color: var(--sage-700);
  border-radius: var(--radius-full);
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.02em;
}

.profile-card .card-date {
  font-size: 0.8rem;
  color: var(--text-muted);
  margin-top: 0.75rem;
}

/* Profile card with delete button */
.profile-card {
  position: relative;
}

.profile-card-link,
.profile-card-link:hover,
.profile-card-link:visited {
  display: block;
  text-decoration: none;
  color: inherit;
}

.profile-delete-btn {
  position: absolute;
  top: 0.75rem;
  right: 0.75rem;
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: transparent;
  border: none;
  border-radius: var(--radius-sm);
  color: var(--text-muted);
  cursor: pointer;
  opacity: 0;
  transition: all 0.2s ease;
  z-index: 2;
}

.profile-card:hover .profile-delete-btn {
  opacity: 1;
}

.profile-delete-btn:hover {
  background: var(--error-bg);
  color: var(--error);
}

.profile-delete-btn:focus-visible {
  opacity: 1;
  outline: 2px solid var(--error);
  outline-offset: 2px;
}

/* Delete confirmation modal */
.delete-modal-body {
  text-align: center;
  padding: 1rem 0 1.5rem;
}

.delete-warning-icon {
  color: var(--error);
  margin-bottom: 1rem;
}

.delete-warning-name {
  font-size: 1.05rem;
  color: var(--text-primary);
  margin-bottom: 0.75rem;
  line-height: 1.5;
}

.delete-warning-text {
  font-size: 0.9rem;
  color: var(--text-secondary);
  line-height: 1.6;
}

.delete-modal-actions {
  display: flex;
  gap: 0.75rem;
  justify-content: flex-end;
  padding-top: 0.5rem;
  border-top: 1px solid var(--sage-100);
}

.btn-danger {
  background: var(--error);
  color: var(--white);
  border: none;
  padding: 0.7rem 1.25rem;
  border-radius: var(--radius-sm);
  font-family: 'Inter', sans-serif;
  font-size: 0.9rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s ease;
}

.btn-danger:hover {
  background: #a93226;
}

.btn-danger:disabled {
  opacity: 0.6;
  cursor: not-allowed;
}

.empty-state {
  max-width: 900px;
  margin: 0 auto;
  text-align: center;
  padding: 4rem 2rem;
}

.empty-state p {
  color: var(--text-secondary);
  font-size: 1.05rem;
  margin-bottom: 1.5rem;
}

/* ══════════════════════════════════════
   View About Them — Detail Page (Legacy)
   ══════════════════════════════════════ */

.detail-page {
  min-height: 100vh;
  padding: 6rem 1.5rem 3rem;
}

.profile-detail {
  max-width: 680px;
  margin: 0 auto;
  background: var(--white);
  border: 1px solid var(--sage-100);
  border-radius: var(--radius-lg);
  padding: 2.5rem;
  box-shadow: 0 4px 24px rgba(0,0,0,0.04);
}

.profile-detail h1 {
  font-size: clamp(1.6rem, 3vw, 2.2rem);
  color: var(--sage-800);
  margin-bottom: 0.5rem;
}

.profile-detail .detail-meta {
  display: flex;
  align-items: center;
  gap: 1rem;
  margin-bottom: 2rem;
  flex-wrap: wrap;
}

.profile-detail .detail-date {
  font-size: 0.85rem;
  color: var(--text-muted);
}

.detail-section {
  margin-bottom: 1.75rem;
  padding-bottom: 1.75rem;
  border-bottom: 1px solid var(--sage-100);
}

.detail-section:last-child {
  border-bottom: none;
  margin-bottom: 0;
  padding-bottom: 0;
}

.detail-section h2 {
  font-family: 'Inter', sans-serif;
  font-size: 0.8rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--sage-500);
  margin-bottom: 0.5rem;
}

.detail-section p {
  color: var(--text-primary);
  font-size: 0.95rem;
  line-height: 1.7;
  white-space: pre-line;
}

.detail-section.memory {
  background: var(--sage-50);
  border-radius: var(--radius-md);
  padding: 1.5rem;
  border-bottom: none;
}

.detail-section.memory p {
  font-style: italic;
  color: var(--sage-700);
}

/* ══════════════════════════════════════
   Tribute Page — Memorial Redesign
   ══════════════════════════════════════ */

.tribute-page {
  min-height: 100vh;
  padding-top: 4rem;
  background: var(--warm-50);
}

/* ── Tribute Containers ── */
.tribute-container {
  max-width: 960px;
  margin: 0 auto;
  padding: 0 2rem;
}

.tribute-container-narrow {
  max-width: 720px;
}

/* ── Tribute Sections (shared) ── */
.tribute-section {
  padding: 3.5rem 0;
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.7s ease, transform 0.7s ease;
}

.tribute-section-visible {
  opacity: 1;
  transform: translateY(0);
}

.tribute-section-header {
  text-align: center;
  margin-bottom: 2.5rem;
}

.tribute-section-label {
  display: inline-block;
  font-family: 'Playfair Display', serif;
  font-size: 0.85rem;
  font-weight: 400;
  font-style: italic;
  color: var(--sage-400);
  margin-bottom: 0.5rem;
  letter-spacing: 0.02em;
}

.tribute-section-title {
  font-family: 'Playfair Display', serif;
  font-size: clamp(1.6rem, 3vw, 2.2rem);
  color: var(--sage-800);
  letter-spacing: -0.01em;
}

/* ════════════════════════════════
   1. HERO SECTION
   ════════════════════════════════ */

.tribute-hero {
  text-align: center;
  padding: 5rem 2rem 3rem;
  position: relative;
  overflow: hidden;
}

.tribute-hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse at 30% 30%, rgba(164, 188, 169, 0.12) 0%, transparent 60%),
    radial-gradient(ellipse at 70% 60%, rgba(107, 94, 123, 0.06) 0%, transparent 50%),
    radial-gradient(ellipse at 50% 90%, rgba(212, 197, 179, 0.1) 0%, transparent 40%);
  pointer-events: none;
}

.tribute-hero-inner {
  position: relative;
  z-index: 1;
  max-width: 640px;
  margin: 0 auto;
}

.tribute-hero-ornament {
  width: 48px;
  height: 2px;
  background: linear-gradient(90deg, transparent, var(--sage-300), transparent);
  margin: 0 auto 2rem;
}

.tribute-hero-name {
  font-family: 'Playfair Display', serif;
  font-size: clamp(2.4rem, 6vw, 4rem);
  font-weight: 600;
  color: var(--sage-800);
  letter-spacing: -0.02em;
  line-height: 1.1;
  margin-bottom: 1.25rem;
}

.tribute-hero-meta {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 1rem;
  margin-bottom: 1.5rem;
  flex-wrap: wrap;
}

.tribute-relationship {
  display: inline-block;
  padding: 0.3rem 1rem;
  background: var(--sage-100);
  color: var(--sage-700);
  border-radius: var(--radius-full);
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.03em;
}

.tribute-hero-divider {
  width: 4px;
  height: 4px;
  border-radius: 50%;
  background: var(--sage-300);
  display: inline-block;
}

.tribute-hero-date {
  font-size: 0.9rem;
  color: var(--text-muted);
  font-weight: 400;
}

.tribute-hero-tagline {
  font-family: 'Playfair Display', serif;
  font-size: 1.1rem;
  font-style: italic;
  color: var(--sage-400);
  font-weight: 400;
}

/* ════════════════════════════════
   2. MOODBOARD SECTION
   ════════════════════════════════ */

.tribute-moodboard-section {
  padding-top: 0;
}

.tribute-moodboard-frame {
  position: relative;
  background: var(--white);
  border: 1px solid var(--sage-100);
  border-radius: var(--radius-lg);
  padding: 1.25rem;
  box-shadow: 0 4px 24px rgba(0,0,0,0.04);
}

/* ════════════════════════════════
   3. WHO THEY WERE — Favorites
   ════════════════════════════════ */

.tribute-favorites-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1rem;
}

.tribute-favorite-card {
  background: var(--white);
  border: 1px solid var(--sage-100);
  border-radius: var(--radius-lg);
  padding: 1.5rem;
  display: flex;
  gap: 1rem;
  align-items: flex-start;
  transition: all 0.3s ease;
}

.tribute-favorite-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 30px rgba(0,0,0,0.06);
  border-color: var(--sage-200);
}

.tribute-favorite-icon {
  width: 44px;
  height: 44px;
  border-radius: var(--radius-md);
  background: var(--sage-50);
  color: var(--sage-500);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.tribute-favorite-card:nth-child(1) .tribute-favorite-icon {
  background: #fef3e2;
  color: #b8860b;
}

.tribute-favorite-card:nth-child(2) .tribute-favorite-icon {
  background: #e8f0ea;
  color: #4a7c59;
}

.tribute-favorite-card:nth-child(3) .tribute-favorite-icon {
  background: #ede8f3;
  color: #6b5e7b;
}

.tribute-favorite-card:nth-child(4) .tribute-favorite-icon {
  background: #e6eff5;
  color: #4a7c9e;
}

.tribute-favorite-body {
  flex: 1;
  min-width: 0;
}

.tribute-favorite-label {
  font-family: 'Inter', sans-serif;
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--sage-500);
  margin-bottom: 0.4rem;
}

.tribute-favorite-value {
  font-size: 0.95rem;
  color: var(--text-primary);
  line-height: 1.65;
  white-space: pre-line;
}

/* ════════════════════════════════
   3b. FAVORITES — Chips/Pills Design
   ════════════════════════════════ */

.favorites-section-wrap {
  display: flex;
  flex-direction: column;
  gap: 1.75rem;
}

.favorites-category-section {
  background: var(--white);
  border: 1px solid var(--sage-100);
  border-radius: var(--radius-lg);
  padding: 1.5rem 1.75rem;
  transition: all 0.3s ease;
}

.favorites-category-section:hover {
  border-color: var(--sage-200);
  box-shadow: 0 4px 20px rgba(0,0,0,0.04);
}

.favorites-category-header {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin-bottom: 1rem;
}

.favorites-category-icon {
  width: 36px;
  height: 36px;
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.favorites-category-icon--food { background: #fef3e2; color: #b8860b; }
.favorites-category-icon--activity { background: #e8f0ea; color: #4a7c59; }
.favorites-category-icon--music { background: #ede8f3; color: #6b5e7b; }
.favorites-category-icon--place { background: #e6eff5; color: #4a7c9e; }

.favorites-category-label {
  font-family: 'Inter', sans-serif;
  font-size: 0.78rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--sage-500);
}

.favorites-chips-wrap {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  align-items: center;
}

/* Individual Favorite Chip */
.favorite-chip {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.45rem 0.9rem;
  border-radius: var(--radius-full);
  background: var(--warm-50);
  border: 1.5px solid var(--sage-100);
  font-family: 'Inter', sans-serif;
  font-size: 0.85rem;
  font-weight: 500;
  color: var(--text-primary);
  transition: all 0.2s ease;
  position: relative;
  cursor: default;
}

.favorite-chip:hover {
  border-color: var(--sage-300);
  background: var(--white);
  box-shadow: 0 2px 8px rgba(0,0,0,0.06);
}

.favorite-chip--food:hover { border-color: #daa520; }
.favorite-chip--activity:hover { border-color: #4a7c59; }
.favorite-chip--music:hover { border-color: #6b5e7b; }
.favorite-chip--place:hover { border-color: #4a7c9e; }

/* Chip description tooltip */
.favorite-chip-desc {
  display: none;
  position: absolute;
  bottom: calc(100% + 8px);
  left: 50%;
  transform: translateX(-50%);
  background: var(--sage-800);
  color: white;
  padding: 0.5rem 0.85rem;
  border-radius: var(--radius-sm);
  font-size: 0.78rem;
  font-weight: 400;
  white-space: nowrap;
  max-width: 280px;
  overflow: hidden;
  text-overflow: ellipsis;
  z-index: 10;
  pointer-events: none;
  box-shadow: 0 4px 12px rgba(0,0,0,0.15);
}

.favorite-chip-desc::after {
  content: '';
  position: absolute;
  top: 100%;
  left: 50%;
  transform: translateX(-50%);
  border: 5px solid transparent;
  border-top-color: var(--sage-800);
}

.favorite-chip:hover .favorite-chip-desc {
  display: block;
}

/* Chip hover actions (edit/delete) */
.favorite-chip-actions {
  display: none;
  gap: 0.15rem;
  margin-left: 0.15rem;
}

.favorite-chip:hover .favorite-chip-actions {
  display: inline-flex;
}

.favorite-chip-action {
  background: none;
  border: none;
  padding: 0.1rem;
  cursor: pointer;
  color: var(--text-muted);
  opacity: 0.6;
  transition: opacity 0.2s, color 0.2s;
  display: flex;
  align-items: center;
}

.favorite-chip-action:hover {
  opacity: 1;
  color: var(--sage-700);
}

.favorite-chip-action--delete:hover {
  color: var(--error);
}

/* "+ Add" chip button */
.favorite-add-chip {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  padding: 0.42rem 0.85rem;
  border-radius: var(--radius-full);
  border: 1.5px dashed var(--sage-200);
  background: transparent;
  color: var(--sage-400);
  font-family: 'Inter', sans-serif;
  font-size: 0.82rem;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s;
}

.favorite-add-chip:hover {
  border-color: var(--sage-400);
  color: var(--sage-600);
  background: var(--sage-50);
}

/* Empty category state */
.favorites-empty-state {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.5rem 0;
  color: var(--text-muted);
  font-size: 0.85rem;
  font-style: italic;
}

/* Legacy text fallback */
.favorites-legacy-text {
  padding: 0.75rem 1rem;
  background: var(--warm-100);
  border-radius: var(--radius-sm);
  border-left: 3px solid var(--warm-300);
  font-size: 0.9rem;
  color: var(--text-secondary);
  line-height: 1.6;
  white-space: pre-line;
  margin-bottom: 0.5rem;
}

.favorites-legacy-note {
  font-size: 0.75rem;
  color: var(--text-muted);
  font-style: italic;
}

/* ════════════════════════════════
   Favorites Builder — Create & Edit Pages
   ════════════════════════════════ */

.favorites-builder,
.favorites-editor {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.fav-builder-category {
  background: var(--white);
  border: 1px solid var(--sage-100);
  border-radius: var(--radius-md);
  padding: 1rem 1.25rem;
  transition: border-color 0.2s;
}

.fav-builder-category:focus-within {
  border-color: var(--sage-300);
}

.fav-builder-category-header {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  margin-bottom: 0.75rem;
}

.fav-builder-icon {
  width: 32px;
  height: 32px;
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.fav-builder-label {
  font-family: 'Inter', sans-serif;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text-primary);
}

.fav-builder-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  margin-bottom: 0.75rem;
  min-height: 0;
}

.fav-builder-chips:empty {
  margin-bottom: 0;
}

.fav-builder-chip {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  padding: 0.35rem 0.75rem;
  border-radius: var(--radius-full);
  background: var(--sage-50);
  border: 1px solid var(--sage-200);
  font-family: 'Inter', sans-serif;
  font-size: 0.82rem;
  color: var(--text-primary);
  animation: chipIn 0.2s ease;
}

@keyframes chipIn {
  from { opacity: 0; transform: scale(0.9); }
  to { opacity: 1; transform: scale(1); }
}

.fav-builder-chip-remove {
  background: none;
  border: none;
  padding: 0;
  cursor: pointer;
  color: var(--text-muted);
  font-size: 1rem;
  line-height: 1;
  margin-left: 0.1rem;
  display: flex;
  align-items: center;
  transition: color 0.2s;
}

.fav-builder-chip-remove:hover {
  color: var(--error);
}

.fav-builder-input-row {
  display: flex;
  gap: 0.5rem;
}

.fav-builder-input-row input {
  flex: 1;
  padding: 0.5rem 0.85rem;
  border: 1.5px solid var(--sage-200);
  border-radius: var(--radius-sm);
  font-family: 'Inter', sans-serif;
  font-size: 0.88rem;
  outline: none;
  background: var(--warm-50);
  color: var(--text-primary);
  transition: border-color 0.2s, box-shadow 0.2s;
}

.fav-builder-input-row input::placeholder {
  color: var(--text-muted);
}

.fav-builder-input-row input:focus {
  border-color: var(--sage-400);
  box-shadow: 0 0 0 3px rgba(122, 158, 130, 0.15);
}

.fav-builder-add-btn {
  padding: 0.5rem 0.85rem;
  border-radius: var(--radius-sm);
  border: 1.5px solid var(--sage-300);
  background: var(--white);
  color: var(--sage-600);
  font-family: 'Inter', sans-serif;
  font-size: 0.88rem;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s;
  white-space: nowrap;
}

.fav-builder-add-btn:hover {
  background: var(--sage-50);
  border-color: var(--sage-400);
}

/* Favorite Modal — Category indicator */
.favorite-modal-category {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.35rem 0.85rem;
  border-radius: var(--radius-full);
  font-size: 0.8rem;
  font-weight: 600;
  margin-bottom: 1.25rem;
}

.favorite-modal-category--food { background: #fef3e2; color: #b8860b; }
.favorite-modal-category--activity { background: #e8f0ea; color: #4a7c59; }
.favorite-modal-category--music { background: #ede8f3; color: #6b5e7b; }
.favorite-modal-category--place { background: #e6eff5; color: #4a7c9e; }

/* ── Favorites Responsive ── */
@media (max-width: 768px) {
  .favorites-category-section {
    padding: 1.25rem;
  }

  .favorites-chips-wrap {
    gap: 0.4rem;
  }

  .favorite-chip {
    font-size: 0.82rem;
    padding: 0.4rem 0.75rem;
  }

  .favorite-chip-actions {
    display: inline-flex;
    opacity: 0.5;
  }

  .fav-builder-input-row {
    flex-direction: column;
  }

  .fav-builder-add-btn {
    align-self: flex-start;
  }
}

/* ════════════════════════════════
   3b. MUSIC EMBEDS (Spotify / YouTube)
   ════════════════════════════════ */

.music-embeds-wrap {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  margin-bottom: 0.75rem;
}

.music-embed-item {
  border-radius: var(--radius-md);
  overflow: hidden;
  position: relative;
  background: var(--warm-50);
  border: 1px solid var(--sage-100);
  transition: box-shadow 0.3s ease;
}

.music-embed-item:hover {
  box-shadow: 0 4px 16px rgba(0,0,0,0.06);
}

.music-embed-item iframe {
  display: block;
  width: 100%;
  border: none;
}

.music-embed-actions {
  position: absolute;
  top: 0.5rem;
  right: 0.5rem;
  display: none;
  gap: 0.25rem;
  z-index: 5;
}

.music-embed-item:hover .music-embed-actions {
  display: inline-flex;
}

.music-embed-label {
  padding: 0.5rem 0.75rem;
  font-family: 'Inter', sans-serif;
  font-size: 0.82rem;
  font-weight: 500;
  color: var(--text-secondary);
  display: flex;
  align-items: center;
  gap: 0.5rem;
  background: var(--white);
}

.music-embed-source {
  font-size: 0.7rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: #6b5e7b;
  background: #ede8f3;
  padding: 0.15rem 0.5rem;
  border-radius: var(--radius-full);
}

/* Link field in favorite modal (music only) */
.favorite-link-group {
  margin-top: 0.25rem;
}

.favorite-link-hint {
  font-size: 0.78rem;
  color: var(--text-muted);
  margin-top: 0.35rem;
  font-style: italic;
}

.favorite-link-detected {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  font-size: 0.78rem;
  color: var(--sage-600);
  font-weight: 500;
  margin-top: 0.35rem;
}

.favorite-link-detected svg {
  flex-shrink: 0;
}

/* Link icon on builder/editor chips */
.fav-builder-chip-link-icon {
  display: inline-flex;
  align-items: center;
  color: #6b5e7b;
  margin-left: 0.15rem;
}

/* ── Recipe Styles ── */

.favorite-recipe-textarea {
  min-height: 120px;
  resize: vertical;
  white-space: pre-wrap;
  font-family: 'Inter', sans-serif;
  line-height: 1.6;
}

.favorite-recipe-hint {
  font-size: 0.78rem;
  color: var(--text-muted);
  margin-top: 0.35rem;
  font-style: italic;
}

.fav-builder-recipe-wrap {
  margin-top: 0.5rem;
}

.fav-builder-recipe-wrap .favorite-recipe-textarea {
  width: 100%;
  min-height: 80px;
  padding: 0.6rem 0.8rem;
  border: 1.5px solid var(--sage-200);
  border-radius: var(--radius-sm);
  font-size: 0.88rem;
  background: var(--warm-50);
  transition: border-color 0.2s, box-shadow 0.2s;
  outline: none;
}

.fav-builder-recipe-wrap .favorite-recipe-textarea:focus {
  border-color: var(--sage-400);
  box-shadow: 0 0 0 3px rgba(122, 158, 130, 0.15);
}

.favorite-chip-recipe-icon {
  display: inline-flex;
  align-items: center;
  color: #b8860b;
  margin-left: 0.25rem;
  opacity: 0.7;
}

.favorite-recipe-card {
  width: 100%;
  background: #fffdf8;
  border: 1px solid rgba(184, 134, 11, 0.15);
  border-radius: var(--radius-sm);
  padding: 1rem 1.25rem;
  margin-top: 0.5rem;
  margin-bottom: 0.5rem;
}

.favorite-recipe-card-header {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.85rem;
  font-weight: 600;
  color: #b8860b;
  margin-bottom: 0.75rem;
}

.favorite-recipe-card-text {
  font-size: 0.88rem;
  color: var(--text-primary);
  line-height: 1.7;
  white-space: pre-wrap;
  word-wrap: break-word;
  font-family: 'Inter', sans-serif;
  margin: 0;
  background: none;
  border: none;
  padding: 0;
}

/* ══════════════════════════════════════
   EXPAND / COLLAPSE SECTIONS
   ══════════════════════════════════════ */

/* Collapsible wrapper for favorites chips */
.favorites-chips-wrap.collapsible {
  position: relative;
  overflow: hidden;
  transition: max-height 0.45s cubic-bezier(0.4, 0, 0.2, 1);
}

.favorites-chips-wrap.collapsible.collapsed {
  /* JS will set max-height dynamically */
}

/* Collapsible wrapper for music embeds */
.music-embeds-wrap.collapsible {
  position: relative;
  overflow: hidden;
  transition: max-height 0.45s cubic-bezier(0.4, 0, 0.2, 1);
}

.music-embeds-wrap.collapsible.collapsed {
  /* JS will set max-height dynamically */
}

/* Fade overlay on collapsed sections */
.section-fade-overlay {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 80px;
  background: linear-gradient(to bottom, rgba(255,255,255,0) 0%, rgba(255,255,255,0.85) 50%, rgba(255,255,255,1) 100%);
  pointer-events: none;
  z-index: 2;
  opacity: 1;
  transition: opacity 0.3s ease;
}

.section-fade-overlay.hidden {
  opacity: 0;
  pointer-events: none;
}

/* Expand/collapse toggle button */
.section-expand-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  width: 100%;
  padding: 10px 16px;
  margin-top: 8px;
  background: var(--sage-50, #f0f4f1);
  border: 1px dashed var(--sage-200, #c5d1c8);
  border-radius: var(--radius-sm, 8px);
  color: var(--sage-600, #4a7c59);
  font-size: 0.85rem;
  font-weight: 500;
  font-family: 'Inter', sans-serif;
  cursor: pointer;
  transition: all 0.2s ease;
}

.section-expand-btn:hover {
  background: var(--sage-100, #dfe8e1);
  border-color: var(--sage-300, #a8bfad);
  color: var(--sage-700, #3a6347);
}

.section-expand-btn svg {
  transition: transform 0.3s ease;
  flex-shrink: 0;
}

.section-expand-btn.expanded svg {
  transform: rotate(180deg);
}

/* Moodboard collapsible grid */
.masonry-grid.collapsible {
  position: relative;
  overflow: hidden;
  transition: max-height 0.45s cubic-bezier(0.4, 0, 0.2, 1);
}

/* "+X more" overlay on the last visible media item */
.masonry-more-overlay {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(41, 58, 46, 0.55);
  backdrop-filter: blur(2px);
  color: #fff;
  font-family: 'Inter', sans-serif;
  font-size: 1.1rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  z-index: 3;
  pointer-events: none;
  border-radius: inherit;
  transition: opacity 0.3s ease;
}

.masonry-more-overlay.hidden {
  opacity: 0;
}

/* Moodboard expand button */
.moodboard-expand-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  width: 100%;
  padding: 12px 16px;
  margin-top: 12px;
  background: rgba(255,255,255,0.85);
  border: 1px dashed var(--sage-200, #c5d1c8);
  border-radius: var(--radius-sm, 8px);
  color: var(--sage-600, #4a7c59);
  font-size: 0.88rem;
  font-weight: 500;
  font-family: 'Inter', sans-serif;
  cursor: pointer;
  transition: all 0.2s ease;
}

.moodboard-expand-btn:hover {
  background: var(--sage-50, #f0f4f1);
  border-color: var(--sage-300, #a8bfad);
  color: var(--sage-700, #3a6347);
}

.moodboard-expand-btn svg {
  transition: transform 0.3s ease;
  flex-shrink: 0;
}

.moodboard-expand-btn.expanded svg {
  transform: rotate(180deg);
}

@media (max-width: 768px) {
  .section-expand-btn {
    padding: 10px 12px;
    font-size: 0.82rem;
  }
  .moodboard-expand-btn {
    padding: 10px 12px;
    font-size: 0.84rem;
  }
}

/* YouTube click-to-play thumbnail */
.yt-thumb-wrap {
  position: relative;
  cursor: pointer;
  background: #000;
  overflow: hidden;
  border-radius: 0;
}

.yt-thumb-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  opacity: 0.85;
  transition: opacity 0.2s ease;
}

.yt-thumb-wrap:hover .yt-thumb-img {
  opacity: 1;
}

.yt-thumb-play {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  background: none;
  border: none;
  cursor: pointer;
  padding: 0;
  opacity: 0.9;
  transition: opacity 0.2s ease, transform 0.2s ease;
}

.yt-thumb-wrap:hover .yt-thumb-play {
  opacity: 1;
  transform: translate(-50%, -50%) scale(1.1);
}

/* YouTube embed fallback (when video can't be embedded) */
.yt-embed-fallback {
  position: relative;
  background: #1a1a1a;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
}

.yt-embed-fallback .yt-thumb-img {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.3;
}

.yt-fallback-overlay {
  position: relative;
  z-index: 2;
  text-align: center;
  color: #fff;
  padding: 1rem;
}

.yt-fallback-overlay p {
  margin: 0 0 0.75rem;
  font-size: 0.9rem;
  color: rgba(255, 255, 255, 0.8);
  font-family: 'Inter', sans-serif;
}

.yt-fallback-link {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.5rem 1.2rem;
  background: #ff0000;
  color: #fff;
  text-decoration: none;
  border-radius: 2rem;
  font-size: 0.85rem;
  font-weight: 600;
  font-family: 'Inter', sans-serif;
  transition: background 0.2s ease, transform 0.15s ease;
}

.yt-fallback-link:hover {
  background: #cc0000;
  transform: scale(1.05);
}

.yt-fallback-link svg {
  flex-shrink: 0;
}

/* ════════════════════════════════
   3c. MUSIC PLAYER MODE
   ════════════════════════════════ */

/* Play/Shuffle buttons in the category header */
.music-player-header-actions {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  margin-left: auto;
}

.music-player-header-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  padding: 0.3rem 0.7rem;
  border-radius: var(--radius-full, 999px);
  border: 1.5px solid #c9bfda;
  background: #ede8f3;
  color: #6b5e7b;
  font-family: 'Inter', sans-serif;
  font-size: 0.75rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s ease;
}

.music-player-header-btn:hover {
  background: #ddd4eb;
  border-color: #6b5e7b;
  transform: translateY(-1px);
  box-shadow: 0 2px 8px rgba(107, 94, 123, 0.15);
}

.music-player-header-btn svg {
  flex-shrink: 0;
}

/* ── The Player Container ── */
.music-player {
  border-radius: var(--radius-md, 12px);
  overflow: hidden;
  background: var(--warm-50, #fffaf5);
  border: 1.5px solid #c9bfda;
  box-shadow: 0 4px 20px rgba(107, 94, 123, 0.1);
}

.music-player-embed iframe {
  display: block;
  width: 100%;
  border: none;
}

/* ── Controls Bar ── */
.music-player-controls {
  padding: 0.75rem 1rem;
  background: var(--white, #fff);
  border-top: 1px solid var(--sage-100, #e8f0ea);
}

.music-player-track-info {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin-bottom: 0.5rem;
}

.music-player-track-title {
  font-family: 'Inter', sans-serif;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text-primary, #2c3e2d);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  flex: 1;
  min-width: 0;
}

/* ── Transport Row ── */
.music-player-transport {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.music-player-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  border: 1.5px solid var(--sage-200, #d0ddd2);
  background: var(--warm-50, #fffaf5);
  color: var(--text-secondary, #5a6b5d);
  cursor: pointer;
  transition: all 0.2s ease;
  flex-shrink: 0;
  padding: 0;
}

.music-player-btn:hover:not(.disabled):not(:disabled) {
  background: var(--sage-50, #f0f5f1);
  border-color: var(--sage-400, #8ba88f);
  color: var(--sage-700, #3d5e40);
  transform: scale(1.05);
}

.music-player-btn.disabled,
.music-player-btn:disabled {
  opacity: 0.3;
  cursor: not-allowed;
  transform: none;
}

/* Shuffle active state — music purple */
.music-player-btn-shuffle.active {
  background: #ede8f3;
  border-color: #6b5e7b;
  color: #6b5e7b;
}

.music-player-btn-shuffle.active:hover {
  background: #ddd4eb;
}

/* Track counter */
.music-player-counter {
  font-family: 'Inter', sans-serif;
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--text-muted, #8a9b8c);
  padding: 0 0.15rem;
  flex-shrink: 0;
  min-width: 3.5rem;
  text-align: center;
}

/* Close button */
.music-player-btn-close {
  margin-left: auto;
  border-color: transparent;
  background: transparent;
  color: var(--text-muted, #8a9b8c);
}

.music-player-btn-close:hover:not(.disabled):not(:disabled) {
  background: #fde8e8;
  color: #c0392b;
  border-color: transparent;
}

/* Apple Music countdown auto-advance */
.music-player-countdown-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.45rem 1rem;
  background: #ede8f3;
  border-top: 1px solid #d8cfe8;
}

.music-player-countdown {
  font-family: 'Inter', sans-serif;
  font-size: 0.78rem;
  font-weight: 600;
  color: #6b5e7b;
}

.music-player-countdown-skip {
  font-family: 'Inter', sans-serif;
  font-size: 0.73rem;
  font-weight: 600;
  color: #6b5e7b;
  background: transparent;
  border: 1.5px solid #c9bfda;
  border-radius: var(--radius-full, 999px);
  padding: 0.2rem 0.6rem;
  cursor: pointer;
  transition: all 0.2s ease;
}

.music-player-countdown-skip:hover {
  background: #ddd4eb;
  border-color: #6b5e7b;
}

.apple-music-hint {
  text-align: center;
  font-size: 0.82rem;
  color: var(--text-muted);
  padding: 0.5rem 0;
  font-style: italic;
}

/* ── Responsive: Music Player ── */
@media (max-width: 768px) {
  .music-player-header-actions {
    gap: 0.3rem;
  }

  .music-player-header-btn span {
    display: none;
  }

  .music-player-header-btn {
    padding: 0.35rem;
    width: 30px;
    height: 30px;
    justify-content: center;
  }

  .music-player-controls {
    padding: 0.6rem 0.75rem;
  }

  .music-player-transport {
    gap: 0.35rem;
  }

  .music-player-btn {
    width: 30px;
    height: 30px;
  }

  .music-player-counter {
    font-size: 0.72rem;
    min-width: 3rem;
  }
}

/* ════════════════════════════════
   3d. WAYS TO HONOR THEM — Suggestions
   ════════════════════════════════ */

.tribute-suggestions-section {
  background: var(--warm-50);
}

.tribute-suggestions-intro {
  font-size: 0.9rem;
  color: var(--text-secondary);
  line-height: 1.6;
  margin-bottom: 1.5rem;
}

.tribute-suggestions-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1rem;
}

.tribute-suggestion-card {
  background: var(--white);
  border: 1px solid var(--sage-100);
  border-radius: var(--radius-lg);
  padding: 1.5rem;
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
  transition: all 0.3s ease;
}

.tribute-suggestion-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 30px rgba(0,0,0,0.06);
  border-color: var(--sage-200);
}

.tribute-suggestion-match {
  font-size: 0.75rem;
  font-weight: 500;
  color: #6b5e7b;
  font-style: italic;
  line-height: 1.4;
}

.tribute-suggestion-card h3 {
  font-family: 'Playfair Display', serif;
  font-size: 1.05rem;
  color: var(--sage-800);
  line-height: 1.3;
}

.tribute-suggestion-card p {
  font-size: 0.85rem;
  color: var(--text-secondary);
  line-height: 1.6;
  flex: 1;
}

.tribute-suggestion-card .btn {
  align-self: flex-start;
  font-size: 0.82rem;
  padding: 0.45rem 1rem;
}

.tribute-suggestions-empty {
  text-align: center;
  padding: 2rem 1rem;
  color: var(--text-muted);
  font-size: 0.9rem;
  font-style: italic;
}

.tribute-suggestions-footer {
  text-align: center;
  margin-top: 1.25rem;
}

.tribute-suggestions-footer a {
  font-size: 0.85rem;
  color: var(--sage-500);
  text-decoration: none;
  font-weight: 500;
  transition: color 0.2s;
}

.tribute-suggestions-footer a:hover {
  color: var(--sage-700);
}

@media (max-width: 768px) {
  .tribute-suggestions-grid {
    grid-template-columns: 1fr;
  }

  .music-embed-actions {
    display: inline-flex;
    opacity: 0.6;
  }
}

/* ════════════════════════════════
   4. STORIES & MEMORIES
   ════════════════════════════════ */

.tribute-memories-section {
  background: var(--sage-50);
}

.tribute-memory-card {
  background: var(--white);
  border: 1px solid var(--sage-100);
  border-radius: var(--radius-lg);
  padding: 2.5rem 2rem;
  position: relative;
  box-shadow: 0 4px 24px rgba(0,0,0,0.04);
}

.tribute-memory-quote-mark {
  color: var(--sage-300);
  margin-bottom: 0.75rem;
}

.tribute-memory-text {
  font-family: 'Playfair Display', serif;
  font-size: clamp(1.05rem, 2vw, 1.2rem);
  font-style: italic;
  font-weight: 400;
  color: var(--sage-700);
  line-height: 1.8;
  white-space: pre-line;
  border: none;
  padding: 0;
  margin: 0;
}

.tribute-memory-empty {
  text-align: center;
  padding: 2rem;
  background: var(--white);
  border: 2px dashed var(--sage-200);
  border-radius: var(--radius-lg);
}

.tribute-memory-empty p {
  color: var(--text-muted);
  font-size: 0.95rem;
  font-style: italic;
}

.tribute-add-memory-btn {
  display: flex;
  margin: 1.5rem auto 0;
}

/* Memory Cards List */
.tribute-memories-list {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.tribute-memories-list .tribute-memory-card {
  margin-bottom: 0;
}

.tribute-memory-title {
  font-family: 'Playfair Display', serif;
  font-size: 1.15rem;
  font-weight: 600;
  color: var(--sage-800);
  margin-bottom: 0.5rem;
}

.tribute-memory-date {
  display: block;
  margin-top: 1rem;
  font-size: 0.78rem;
  color: var(--text-muted);
  font-weight: 400;
}

/* Memory Card Actions (edit/delete) */
.tribute-memory-actions {
  position: absolute;
  top: 1rem;
  right: 1rem;
  display: flex;
  gap: 0.35rem;
  opacity: 0;
  transition: opacity 0.2s;
}

.tribute-memory-card:hover .tribute-memory-actions {
  opacity: 1;
}

.tribute-memory-action-btn {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  border: 1px solid var(--sage-200);
  background: var(--white);
  color: var(--text-muted);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s;
}

.tribute-memory-action-btn:hover {
  border-color: var(--sage-400);
  color: var(--sage-700);
  background: var(--sage-50);
}

.tribute-memory-action-btn.memory-delete-btn:hover {
  border-color: var(--error);
  color: var(--error);
  background: var(--error-bg);
}

/* ════════════════════════════════
   5. KEEPING MEMORY ALIVE
   ════════════════════════════════ */

.tribute-living-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1rem;
}

.tribute-living-card {
  background: var(--white);
  border: 1px solid var(--sage-100);
  border-radius: var(--radius-lg);
  padding: 1.5rem;
  display: flex;
  align-items: center;
  gap: 1rem;
  text-decoration: none;
  color: inherit;
  transition: all 0.3s ease;
}

.tribute-living-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 30px rgba(0,0,0,0.06);
  border-color: var(--sage-200);
}

.tribute-living-icon {
  width: 52px;
  height: 52px;
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.tribute-living-icon-journal {
  background: #ede8f3;
  color: #6b5e7b;
}

.tribute-living-icon-activities {
  background: #fce4ec;
  color: #c0392b;
}

.tribute-living-body {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
}

.tribute-living-count {
  font-family: 'Playfair Display', serif;
  font-size: 1.6rem;
  font-weight: 600;
  color: var(--sage-800);
  line-height: 1.2;
}

.tribute-living-label {
  font-family: 'Inter', sans-serif;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 0.15rem;
}

.tribute-living-description {
  font-size: 0.78rem;
  color: var(--text-muted);
  line-height: 1.4;
}

.tribute-living-arrow {
  color: var(--text-muted);
  flex-shrink: 0;
  transition: transform 0.2s;
}

.tribute-living-card:hover .tribute-living-arrow {
  transform: translateX(3px);
  color: var(--sage-500);
}

/* ════════════════════════════════
   6. FLOATING EDIT BUTTON
   ════════════════════════════════ */

.tribute-edit-fab {
  position: fixed;
  bottom: 2rem;
  right: 2rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.75rem 1.25rem;
  background: var(--sage-600);
  color: var(--white);
  border: none;
  border-radius: var(--radius-full);
  font-family: 'Inter', sans-serif;
  font-size: 0.85rem;
  font-weight: 600;
  cursor: pointer;
  box-shadow: 0 4px 20px rgba(71, 106, 79, 0.35);
  transition: all 0.25s ease;
  z-index: 50;
}

.tribute-edit-fab:hover {
  background: var(--sage-700);
  transform: translateY(-2px);
  box-shadow: 0 6px 28px rgba(71, 106, 79, 0.4);
}

.tribute-edit-fab svg {
  flex-shrink: 0;
}

/* ════════════════════════════════
   Tribute Responsive
   ════════════════════════════════ */

@media (max-width: 768px) {
  .tribute-hero {
    padding: 4.5rem 1.5rem 2rem;
  }

  .tribute-hero-name {
    font-size: 2.4rem;
  }

  .tribute-favorites-grid {
    grid-template-columns: 1fr;
  }

  .tribute-living-grid {
    grid-template-columns: 1fr;
  }

  .tribute-container {
    padding: 0 1.25rem;
  }

  .tribute-moodboard-frame {
    padding: 0.75rem;
    border-radius: var(--radius-md);
  }

  .tribute-memory-card {
    padding: 1.75rem 1.25rem;
  }

  .tribute-edit-fab {
    bottom: 1.25rem;
    right: 1.25rem;
  }

  .tribute-edit-fab span {
    display: none;
  }

  .tribute-edit-fab {
    padding: 0.85rem;
    border-radius: 50%;
  }
}

@media (max-width: 480px) {
  .tribute-hero-name {
    font-size: 2rem;
  }

  .tribute-hero-meta {
    gap: 0.5rem;
  }

  .tribute-section {
    padding: 2.5rem 0;
  }

  .tribute-favorite-card {
    padding: 1.25rem;
  }
}

.back-link {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.88rem;
  color: var(--sage-600);
  text-decoration: none;
  font-weight: 500;
  margin-bottom: 1.5rem;
}

.back-link:hover {
  color: var(--sage-700);
}

.not-found {
  text-align: center;
  padding: 4rem 2rem;
  max-width: 500px;
  margin: 0 auto;
}

.not-found h1 {
  color: var(--sage-800);
  margin-bottom: 0.75rem;
}

.not-found p {
  color: var(--text-secondary);
  margin-bottom: 1.5rem;
}

/* ══════════════════════════════════════
   Dashboard Nav — Shared Auth Nav
   ══════════════════════════════════════ */

.dashboard-nav .nav-center {
  display: flex;
  align-items: center;
  gap: 1.5rem;
}

.dashboard-nav .nav-center a {
  text-decoration: none;
  color: var(--text-secondary);
  font-size: 0.9rem;
  font-weight: 500;
  transition: color 0.2s;
}

.dashboard-nav .nav-center a:hover,
.dashboard-nav .nav-center a.active {
  color: var(--sage-700);
}

/* ══════════════════════════════════════
   Journal
   ══════════════════════════════════════ */

.journal-entry-card {
  background: var(--white);
  border: 1px solid var(--sage-100);
  border-radius: var(--radius-lg);
  padding: 1.25rem 1.5rem;
  margin-bottom: 1rem;
  cursor: pointer;
  transition: all 0.25s ease;
}

.journal-entry-card:hover {
  border-color: var(--sage-200);
  box-shadow: 0 4px 16px rgba(0,0,0,0.04);
}

.journal-entry-card.expanded {
  box-shadow: 0 6px 24px rgba(0,0,0,0.06);
  border-color: var(--sage-300);
}

.journal-entry-date {
  font-size: 0.78rem;
  color: var(--text-muted);
  margin-bottom: 0.3rem;
}

.journal-entry-title {
  font-family: 'Inter', sans-serif;
  font-size: 1.05rem;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 0.4rem;
}

.journal-entry-preview {
  font-size: 0.9rem;
  color: var(--text-secondary);
  line-height: 1.6;
}

.journal-entry-full {
  display: none;
  font-size: 0.92rem;
  color: var(--text-primary);
  line-height: 1.75;
  white-space: pre-line;
  padding-top: 0.75rem;
  border-top: 1px solid var(--sage-100);
  margin-top: 0.75rem;
}

.journal-entry-card.expanded .journal-entry-preview {
  display: none;
}

.journal-entry-card.expanded .journal-entry-full {
  display: block;
}

/* Edit button — only visible when card is expanded */
.journal-entry-actions {
  display: none;
  padding-top: 0.75rem;
  margin-top: 0.75rem;
  border-top: 1px solid var(--sage-100);
}

.journal-entry-card.expanded .journal-entry-actions {
  display: flex;
}

.journal-edit-btn {
  font-size: 0.82rem;
  padding: 0.45rem 1rem;
}

.journal-entry-badge {
  display: inline-block;
  padding: 0.15rem 0.5rem;
  background: var(--dusk-500);
  color: var(--white);
  border-radius: var(--radius-full);
  font-size: 0.7rem;
  font-weight: 600;
  margin-left: 0.5rem;
  vertical-align: middle;
}

.journal-entries-list {
  max-width: 700px;
  margin: 0 auto;
}

.journal-textarea {
  min-height: 250px;
}

.form-actions {
  display: flex;
  align-items: center;
  gap: 1rem;
  margin-top: 0.5rem;
}

.form-actions .btn {
  flex: 1;
}

.cancel-link {
  text-align: center;
  flex: 0;
  white-space: nowrap;
  color: var(--text-muted);
  text-decoration: none;
  font-size: 0.9rem;
  font-weight: 500;
  padding: 0.85rem 1.5rem;
}

.cancel-link:hover {
  color: var(--text-primary);
}

/* ══════════════════════════════════════
   Notebook Editor
   ══════════════════════════════════════ */

/* Body scroll lock when notebook is open */
body.nb-open {
  overflow: hidden;
}

/* ── Overlay ── */
.nb-overlay {
  position: fixed;
  inset: 0;
  z-index: 250;
  background: rgba(41, 58, 46, 0.3);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 2rem;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s ease;
}

.nb-overlay.open {
  opacity: 1;
  pointer-events: auto;
}

/* ── Paper Page ── */
.nb-page {
  width: 100%;
  max-width: 680px;
  max-height: 90vh;
  max-height: 90dvh; /* modern browsers */
  display: flex;
  flex-direction: column;
  background: var(--nb-paper-bg);
  border-radius: 4px 12px 12px 4px;
  box-shadow:
    0 2px 4px rgba(0, 0, 0, 0.04),
    0 12px 40px rgba(0, 0, 0, 0.1),
    inset 0 0 60px rgba(0, 0, 0, 0.02);
  transform: translateY(20px) scale(0.97);
  transition: transform 0.3s ease;
  overflow: hidden;
  position: relative;
}

.nb-overlay.open .nb-page {
  transform: translateY(0) scale(1);
}

/* Paper grain texture via CSS */
.nb-page::before {
  content: '';
  position: absolute;
  inset: 0;
  background-image:
    url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='0.03'/%3E%3C/svg%3E");
  background-size: 256px 256px;
  pointer-events: none;
  z-index: 0;
  border-radius: inherit;
}

/* ── Header ── */
.nb-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.75rem 1rem 0.75rem var(--nb-margin-left);
  border-bottom: 1px solid var(--nb-line-color);
  position: relative;
  z-index: 1;
  flex-shrink: 0;
}

.nb-title-input {
  font-family: 'Playfair Display', Georgia, serif;
  font-size: 1.3rem;
  font-weight: 600;
  color: var(--nb-ink-color);
  background: transparent;
  border: none;
  outline: none;
  flex: 1;
  padding: 0.25rem 0;
  min-width: 0;
}

.nb-title-input::placeholder {
  color: rgba(44, 24, 16, 0.3);
}

.nb-close {
  background: none;
  border: none;
  font-size: 0.85rem;
  font-weight: 500;
  color: var(--text-muted);
  cursor: pointer;
  padding: 0.4rem 0.8rem;
  border-radius: var(--radius-sm);
  transition: all 0.2s;
  font-family: 'Inter', sans-serif;
  flex-shrink: 0;
  margin-left: 1rem;
}

.nb-close:hover {
  color: var(--text-primary);
  background: rgba(0, 0, 0, 0.04);
}

/* ── Lined Paper Body ── */
.nb-body {
  flex: 1;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  position: relative;
  z-index: 1;
  background:
    repeating-linear-gradient(
      to bottom,
      transparent 0px,
      transparent calc(var(--nb-line-height) - 1px),
      var(--nb-line-color) calc(var(--nb-line-height) - 1px),
      var(--nb-line-color) var(--nb-line-height)
    );
  background-size: 100% var(--nb-line-height);
}

/* Left margin red line */
.nb-body::before {
  content: '';
  position: absolute;
  top: 0;
  bottom: 0;
  left: calc(var(--nb-margin-left) - 2px);
  width: 2px;
  background: var(--nb-margin-color);
  z-index: 1;
  pointer-events: none;
}

/* ── Textarea ── */
.nb-textarea {
  width: 100%;
  min-height: 100%;
  padding: 5px 1.5rem 2rem var(--nb-margin-left);
  background: transparent;
  border: none;
  outline: none;
  resize: none;
  font-family: 'Inter', sans-serif;
  font-size: 0.95rem;
  color: var(--nb-ink-color);
  line-height: var(--nb-line-height);
  text-shadow: 0 0 1px var(--nb-ink-shadow);
  caret-color: var(--nb-ink-color);
  position: relative;
  z-index: 2;
}

.nb-textarea::placeholder {
  color: rgba(44, 24, 16, 0.25);
  text-shadow: none;
}

/* ── Footer ── */
.nb-footer {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 0.75rem 1rem 0.75rem var(--nb-margin-left);
  border-top: 1px solid var(--nb-line-color);
  background: var(--nb-paper-bg);
  position: relative;
  z-index: 1;
  flex-shrink: 0;
}

.nb-footer .btn-primary {
  flex: 0 0 auto;
}

.nb-footer .cancel-link {
  padding: 0.5rem 1rem;
}

.nb-word-count {
  margin-left: auto;
  font-size: 0.78rem;
  color: var(--text-muted);
  font-variant-numeric: tabular-nums;
}

/* ── Collapsed Notebook Preview ── */
.nb-collapsed-wrap {
  position: relative;
  cursor: pointer;
  border-radius: var(--radius-sm);
  overflow: hidden;
  transition: box-shadow 0.25s ease;
}

.nb-collapsed-wrap:hover {
  box-shadow: 0 2px 12px rgba(0, 0, 0, 0.06);
}

.nb-collapsed-wrap .journal-textarea {
  min-height: 180px;
  max-height: 180px;
  background:
    repeating-linear-gradient(
      to bottom,
      transparent 0px,
      transparent 29px,
      var(--nb-line-color) 29px,
      var(--nb-line-color) 30px
    ),
    var(--nb-paper-bg);
  background-size: 100% 30px, 100% 100%;
  line-height: 30px;
  color: var(--nb-ink-color);
  padding-left: var(--nb-margin-left);
  padding-top: 5px;
  font-size: 0.95rem;
  cursor: pointer;
  border: 1.5px solid var(--sage-200);
  text-shadow: 0 0 1px var(--nb-ink-shadow);
}

.nb-collapsed-wrap .journal-textarea:focus {
  border-color: var(--sage-400);
  box-shadow: 0 0 0 3px rgba(122, 158, 130, 0.15);
}

/* Left margin line on collapsed textarea */
.nb-collapsed-wrap::before {
  content: '';
  position: absolute;
  top: 0;
  bottom: 0;
  left: calc(var(--nb-margin-left) - 2px);
  width: 2px;
  background: var(--nb-margin-color);
  z-index: 2;
  pointer-events: none;
}

/* "Click to open" hint overlay */
.nb-collapsed-hint {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  padding: 1.5rem 1rem 0.75rem;
  text-align: center;
  font-size: 0.82rem;
  font-weight: 500;
  color: var(--text-muted);
  background: linear-gradient(transparent, var(--nb-paper-bg) 60%);
  pointer-events: none;
  opacity: 0;
  transition: opacity 0.2s;
}

.nb-collapsed-wrap:hover .nb-collapsed-hint {
  opacity: 1;
}

/* ── Paper-Note Cards (Journal List) ── */
.journal-entry-card.paper-note {
  background: var(--nb-paper-bg);
  border: none;
  border-radius: 2px 8px 8px 2px;
  box-shadow:
    0 1px 3px rgba(0, 0, 0, 0.05),
    0 2px 8px rgba(0, 0, 0, 0.03);
  padding-left: 2.5rem;
  position: relative;
  background-image:
    repeating-linear-gradient(
      to bottom,
      transparent 0px,
      transparent 27px,
      var(--nb-line-color) 27px,
      var(--nb-line-color) 28px
    );
  background-size: 100% 28px;
  background-position: 0 1.25rem;
}

.journal-entry-card.paper-note::before {
  content: '';
  position: absolute;
  top: 0;
  bottom: 0;
  left: 2rem;
  width: 1.5px;
  background: var(--nb-margin-color);
}

.journal-entry-card.paper-note:hover {
  border-color: transparent;
  box-shadow:
    0 2px 6px rgba(0, 0, 0, 0.06),
    0 6px 20px rgba(0, 0, 0, 0.05);
}

.journal-entry-card.paper-note.expanded {
  border-color: transparent;
  box-shadow:
    0 4px 12px rgba(0, 0, 0, 0.06),
    0 8px 30px rgba(0, 0, 0, 0.06);
}

/* ── Read-Only Notebook View (expanded card content) ── */
.journal-entry-full.nb-readonly {
  font-size: 0.92rem;
  color: var(--nb-ink-color);
  line-height: 28px;
  text-shadow: 0 0 1px var(--nb-ink-shadow);
  padding-top: 0.75rem;
  padding-left: 0.5rem;
  background:
    repeating-linear-gradient(
      to bottom,
      transparent 0px,
      transparent 27px,
      var(--nb-line-color) 27px,
      var(--nb-line-color) 28px
    );
  background-size: 100% 28px;
  background-position: 0 0.75rem;
  border-top: 1px solid var(--nb-line-color);
  margin-top: 0.75rem;
}

/* ── Notebook Responsive ── */
@media (max-width: 768px) {
  .nb-overlay {
    padding: 0;
  }

  .nb-page {
    max-width: 100%;
    max-height: 100vh;
    max-height: 100dvh;
    border-radius: 0;
    height: 100%;
  }

  .nb-header {
    padding-left: 1rem;
  }

  .nb-body::before {
    left: 38px;
  }

  .nb-textarea {
    padding-left: 40px;
  }

  .nb-footer {
    padding-left: 1rem;
  }

  .nb-collapsed-wrap .journal-textarea {
    padding-left: 40px;
  }

  .nb-collapsed-wrap::before {
    left: 38px;
  }

  .journal-entry-card.paper-note {
    padding-left: 2rem;
  }

  .journal-entry-card.paper-note::before {
    left: 1.5rem;
  }
}

@media (max-width: 480px) {
  .nb-header {
    padding: 0.5rem 0.75rem;
  }

  .nb-footer {
    padding: 0.5rem 0.75rem;
    flex-wrap: wrap;
  }

  .nb-word-count {
    width: 100%;
    text-align: right;
  }

  .nb-title-input {
    font-size: 1.1rem;
  }
}

/* ══════════════════════════════════════
   Lessons — Library & Article
   ══════════════════════════════════════ */

.lessons-header {
  max-width: 900px;
  margin: 0 auto 1.5rem;
}

.lessons-header h1 {
  font-size: clamp(1.4rem, 2.5vw, 1.8rem);
  color: var(--sage-800);
  margin-bottom: 0.35rem;
}

.lessons-subtitle {
  color: var(--text-secondary);
  font-size: 0.95rem;
  line-height: 1.6;
}

/* Category Filters */
.lessons-filters {
  max-width: 900px;
  margin: 0 auto 1.75rem;
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.filter-chip {
  padding: 0.4rem 1rem;
  border-radius: var(--radius-full);
  border: 1.5px solid var(--sage-200);
  background: var(--white);
  color: var(--text-secondary);
  font-family: 'Inter', sans-serif;
  font-size: 0.82rem;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s;
}

.filter-chip:hover {
  border-color: var(--sage-400);
  color: var(--sage-700);
}

.filter-chip.active {
  background: var(--sage-600);
  border-color: var(--sage-600);
  color: var(--white);
}

/* Lessons Grid */
.lessons-grid {
  max-width: 900px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 1.25rem;
}

.lesson-card {
  background: var(--white);
  border: 1px solid var(--sage-100);
  border-radius: var(--radius-lg);
  padding: 1.75rem;
  text-decoration: none;
  color: inherit;
  transition: all 0.3s ease;
  display: flex;
  gap: 1rem;
  align-items: flex-start;
}

.lesson-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 8px 30px rgba(0,0,0,0.06);
  border-color: var(--sage-200);
}

.lesson-card-icon {
  font-size: 1.8rem;
  line-height: 1;
  flex-shrink: 0;
  margin-top: 0.15rem;
}

.lesson-card-body {
  flex: 1;
  min-width: 0;
}

.lesson-card-category {
  font-size: 0.72rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--sage-500);
  margin-bottom: 0.4rem;
}

.lesson-card h3 {
  font-family: 'Playfair Display', serif;
  font-size: 1.1rem;
  color: var(--sage-800);
  margin-bottom: 0.5rem;
  line-height: 1.3;
}

.lesson-card p {
  font-size: 0.88rem;
  color: var(--text-secondary);
  line-height: 1.6;
  margin-bottom: 0.75rem;
}

.lesson-card-meta {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.lesson-read-time {
  font-size: 0.78rem;
  color: var(--text-muted);
  font-weight: 500;
}

/* Lesson Article (Detail View) */
.lesson-article {
  max-width: 700px;
  margin: 0 auto;
  background: var(--white);
  border: 1px solid var(--sage-100);
  border-radius: var(--radius-lg);
  padding: 2.5rem;
  box-shadow: 0 4px 24px rgba(0,0,0,0.04);
}

.lesson-article-header {
  margin-bottom: 2rem;
  padding-bottom: 1.5rem;
  border-bottom: 1px solid var(--sage-100);
}

.lesson-category-badge {
  display: inline-block;
  padding: 0.25rem 0.75rem;
  background: var(--sage-100);
  color: var(--sage-700);
  border-radius: var(--radius-full);
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.03em;
  margin-bottom: 0.75rem;
}

.lesson-article-header h1 {
  font-size: clamp(1.6rem, 3vw, 2.2rem);
  color: var(--sage-800);
  margin-bottom: 0.75rem;
  line-height: 1.25;
}

.lesson-article-description {
  font-size: 1.05rem;
  color: var(--text-secondary);
  line-height: 1.7;
  font-style: italic;
  margin-bottom: 0.75rem;
}

.lesson-article-meta {
  font-size: 0.85rem;
  color: var(--text-muted);
}

/* Article Content — Blog-Style Typography */
.lesson-article-content {
  font-size: 1rem;
  line-height: 1.85;
  color: var(--text-primary);
}

.lesson-article-content h2 {
  font-family: 'Playfair Display', serif;
  font-size: 1.35rem;
  color: var(--sage-800);
  margin-top: 2rem;
  margin-bottom: 0.75rem;
  line-height: 1.3;
}

.lesson-article-content p {
  margin-bottom: 1.25rem;
}

.lesson-article-content p:last-child {
  margin-bottom: 0;
}

/* Article Footer */
.lesson-article-footer {
  margin-top: 2.5rem;
  padding-top: 1.5rem;
  border-top: 1px solid var(--sage-100);
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 1rem;
}

/* ── Responsive ── */
@media (max-width: 768px) {
  .nav-toggle { display: block; }

  .nav-links {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: rgba(250, 248, 246, 0.98);
    backdrop-filter: blur(12px);
    flex-direction: column;
    padding: 1.5rem 2rem;
    gap: 1.2rem;
    box-shadow: 0 4px 12px rgba(0,0,0,0.06);
  }

  .nav-links.open { display: flex; }

  .hero { padding: 7rem 1.5rem 3rem; }
  .hero h1 { font-size: 2.2rem; }
  .features { padding: 4rem 1.5rem; }
  .cta-box { padding: 3rem 1.5rem; }

  .footer-inner {
    flex-direction: column;
    text-align: center;
  }

  .auth-card { padding: 2rem 1.5rem; }
  .create-form { padding: 2rem 1.5rem; }
  .profile-detail { padding: 2rem 1.5rem; }
  .form-row { grid-template-columns: 1fr; }
  .dashboard-header { flex-direction: column; align-items: flex-start; }
  .lesson-article { padding: 2rem 1.5rem; }
  .lessons-grid { grid-template-columns: 1fr; }
  .activity-article { padding: 2rem 1.5rem; }
  .activities-grid { grid-template-columns: 1fr; }
}

/* ══════════════════════════════════════
   Activities — Library & Detail
   ══════════════════════════════════════ */

.activities-header {
  max-width: 900px;
  margin: 0 auto 1.5rem;
}

.activities-header h1 {
  font-size: clamp(1.4rem, 2.5vw, 1.8rem);
  color: var(--sage-800);
  margin-bottom: 0.35rem;
}

.activities-subtitle {
  color: var(--text-secondary);
  font-size: 0.95rem;
  line-height: 1.6;
}

/* Category Filters */
.activities-filters {
  max-width: 900px;
  margin: 0 auto 1.75rem;
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

/* Activities Grid */
.activities-grid {
  max-width: 900px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 1.25rem;
}

.activity-card {
  background: var(--white);
  border: 1px solid var(--sage-100);
  border-radius: var(--radius-lg);
  padding: 1.75rem;
  text-decoration: none;
  color: inherit;
  transition: all 0.3s ease;
  display: flex;
  gap: 1rem;
  align-items: flex-start;
}

.activity-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 8px 30px rgba(0,0,0,0.06);
  border-color: var(--sage-200);
}

.activity-card-icon {
  width: 48px;
  height: 48px;
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.4rem;
  flex-shrink: 0;
}

.activity-card-icon.creative { background: #fef3e2; color: #b8860b; }
.activity-card-icon.reflective { background: #ede8f3; color: #6b5e7b; }
.activity-card-icon.active { background: #e8f0ea; color: #4a7c59; }
.activity-card-icon.connection { background: #e6eff5; color: #4a7c9e; }

.activity-card-body {
  flex: 1;
  min-width: 0;
}

.activity-card-category {
  font-size: 0.72rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--sage-500);
  margin-bottom: 0.4rem;
}

.activity-card h3 {
  font-family: 'Playfair Display', serif;
  font-size: 1.1rem;
  color: var(--sage-800);
  margin-bottom: 0.5rem;
  line-height: 1.3;
}

.activity-card p {
  font-size: 0.88rem;
  color: var(--text-secondary);
  line-height: 1.6;
  margin-bottom: 0.75rem;
}

.activity-card-meta {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.activity-time {
  font-size: 0.78rem;
  color: var(--text-muted);
  font-weight: 500;
}

/* Activity Article (Detail View) */
.activity-article {
  max-width: 700px;
  margin: 0 auto;
  background: var(--white);
  border: 1px solid var(--sage-100);
  border-radius: var(--radius-lg);
  padding: 2.5rem;
  box-shadow: 0 4px 24px rgba(0,0,0,0.04);
}

.activity-article-header {
  margin-bottom: 2rem;
  padding-bottom: 1.5rem;
  border-bottom: 1px solid var(--sage-100);
}

.activity-category-badge {
  display: inline-block;
  padding: 0.25rem 0.75rem;
  background: var(--sage-100);
  color: var(--sage-700);
  border-radius: var(--radius-full);
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.03em;
  margin-bottom: 0.75rem;
}

.activity-article-header h1 {
  font-size: clamp(1.6rem, 3vw, 2.2rem);
  color: var(--sage-800);
  margin-bottom: 0.75rem;
  line-height: 1.25;
}

.activity-article-description {
  font-size: 1.05rem;
  color: var(--text-secondary);
  line-height: 1.7;
  font-style: italic;
  margin-bottom: 0.75rem;
}

.activity-article-meta {
  font-size: 0.85rem;
  color: var(--text-muted);
}

/* Activity Content */
.activity-article-content {
  font-size: 1rem;
  line-height: 1.85;
  color: var(--text-primary);
  margin-bottom: 2rem;
}

.activity-article-content h2 {
  font-family: 'Playfair Display', serif;
  font-size: 1.35rem;
  color: var(--sage-800);
  margin-top: 2rem;
  margin-bottom: 0.75rem;
  line-height: 1.3;
}

.activity-article-content h2:first-child {
  margin-top: 0;
}

.activity-article-content p {
  margin-bottom: 1.25rem;
}

.activity-article-content p:last-child {
  margin-bottom: 0;
}

/* Why It Helps Section */
.activity-why-section {
  background: var(--sage-50);
  border-radius: var(--radius-md);
  padding: 1.5rem;
  margin-bottom: 2rem;
}

.activity-why-section h2 {
  font-family: 'Inter', sans-serif;
  font-size: 0.8rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--sage-500);
  margin-bottom: 0.5rem;
}

.activity-why-section p {
  color: var(--sage-700);
  font-size: 0.95rem;
  line-height: 1.7;
  font-style: italic;
}

/* Activity Footer */
.activity-article-footer {
  margin-top: 2.5rem;
  padding-top: 1.5rem;
  border-top: 1px solid var(--sage-100);
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 1rem;
}

/* ══════════════════════════════════════
   Community — Feed, Posts & Comments
   ══════════════════════════════════════ */

.community-header {
  max-width: 960px;
  margin: 0 auto 2rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 1rem;
}

.community-header h1 {
  font-size: clamp(1.4rem, 2.5vw, 1.8rem);
  color: var(--sage-800);
  margin-bottom: 0.35rem;
}

.community-subtitle {
  color: var(--text-secondary);
  font-size: 0.95rem;
  line-height: 1.6;
}

/* Feed */
.community-feed {
  max-width: 700px;
  margin: 0 auto;
}

/* Post Card */
.community-post {
  background: var(--white);
  border: 1px solid var(--sage-100);
  border-radius: var(--radius-lg);
  padding: 1.5rem;
  margin-bottom: 1rem;
  transition: border-color 0.2s;
}

.community-post:hover {
  border-color: var(--sage-200);
}

/* Post Header */
.post-header {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin-bottom: 1rem;
}

.post-avatar {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background: var(--sage-200);
  color: var(--sage-700);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 0.9rem;
  flex-shrink: 0;
  text-transform: uppercase;
}

.post-author-info {
  display: flex;
  flex-direction: column;
  flex: 1;
  min-width: 0;
}

.post-author {
  font-family: 'Inter', sans-serif;
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--text-primary);
}

.post-time {
  font-size: 0.75rem;
  color: var(--text-muted);
}

.post-category-tag {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  padding: 0.2rem 0.65rem;
  background: var(--warm-100);
  color: var(--text-secondary);
  border-radius: var(--radius-full);
  font-size: 0.72rem;
  font-weight: 500;
  white-space: nowrap;
}

/* Post Content */
.post-content {
  margin-bottom: 1rem;
}

.post-content p {
  font-size: 0.95rem;
  color: var(--text-primary);
  line-height: 1.7;
  white-space: pre-line;
}

/* Post Footer */
.post-footer {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding-top: 0.75rem;
  border-top: 1px solid var(--sage-50);
}

.post-comment-btn {
  background: none;
  border: none;
  cursor: pointer;
  font-family: 'Inter', sans-serif;
  font-size: 0.82rem;
  font-weight: 500;
  color: var(--text-muted);
  padding: 0.35rem 0.75rem;
  border-radius: var(--radius-full);
  transition: all 0.2s;
}

.post-comment-btn:hover {
  background: var(--sage-50);
  color: var(--sage-700);
}

/* Comments Section */
.post-comments-section {
  margin-top: 1rem;
  padding-top: 1rem;
  border-top: 1px solid var(--sage-100);
}

.comments-list {
  margin-bottom: 0.75rem;
}

.comments-empty {
  text-align: center;
  padding: 0.75rem;
  color: var(--text-muted);
  font-size: 0.85rem;
  font-style: italic;
}

.comment-item {
  display: flex;
  gap: 0.6rem;
  padding: 0.6rem 0;
}

.comment-item + .comment-item {
  border-top: 1px solid var(--sage-50);
}

.comment-avatar {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: var(--warm-200);
  color: var(--text-secondary);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 600;
  font-size: 0.7rem;
  flex-shrink: 0;
  text-transform: uppercase;
  margin-top: 0.1rem;
}

.comment-body {
  flex: 1;
  min-width: 0;
}

.comment-meta {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin-bottom: 0.2rem;
}

.comment-author {
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--text-primary);
}

.comment-time {
  font-size: 0.72rem;
  color: var(--text-muted);
}

.comment-body p {
  font-size: 0.88rem;
  color: var(--text-primary);
  line-height: 1.6;
}

/* Comment Form */
.comment-form {
  display: flex;
  gap: 0.5rem;
  align-items: flex-end;
}

.comment-input {
  flex: 1;
  padding: 0.6rem 0.85rem;
  border: 1.5px solid var(--sage-200);
  border-radius: var(--radius-sm);
  font-family: 'Inter', sans-serif;
  font-size: 0.88rem;
  color: var(--text-primary);
  background: var(--warm-50);
  resize: none;
  outline: none;
  min-height: 0;
  transition: border-color 0.2s, box-shadow 0.2s;
}

.comment-input:focus {
  border-color: var(--sage-400);
  box-shadow: 0 0 0 3px rgba(122, 158, 130, 0.15);
}

.comment-input::placeholder {
  color: var(--text-muted);
}

/* ══════════════════════════════════════
   Community — Filtering & Tags
   ══════════════════════════════════════ */

/* Required star on form labels */
.required-star {
  color: var(--error);
  font-weight: 600;
}

/* Two-column layout: sidebar + feed */
.community-layout {
  max-width: 960px;
  margin: 0 auto;
  display: flex;
  gap: 2rem;
  align-items: flex-start;
}

.community-feed-column {
  flex: 1;
  min-width: 0;
}

.community-layout .community-feed {
  max-width: 100%;
}

/* ── Filter Sidebar ── */
.community-filters {
  width: 240px;
  flex-shrink: 0;
  background: var(--white);
  border: 1px solid var(--sage-100);
  border-radius: var(--radius-lg);
  padding: 1.25rem;
  position: sticky;
  top: 5.5rem;
}

.filter-panel-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 1rem;
}

.filter-panel-header h3 {
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--sage-800);
  margin: 0;
}

.filter-panel-close {
  display: none;
  background: none;
  border: none;
  font-size: 1.4rem;
  color: var(--text-muted);
  cursor: pointer;
  padding: 0;
  line-height: 1;
}

.filter-panel-close:hover {
  color: var(--text-primary);
}

.filter-section {
  margin-bottom: 1.25rem;
  padding-bottom: 1.25rem;
  border-bottom: 1px solid var(--sage-50);
}

.filter-section:last-of-type {
  border-bottom: none;
  margin-bottom: 0.75rem;
  padding-bottom: 0;
}

.filter-section-title {
  font-size: 0.72rem;
  font-weight: 600;
  color: var(--text-secondary);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin: 0 0 0.5rem 0;
}

/* Checkbox list */
.filter-checkbox-label {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.3rem 0;
  cursor: pointer;
  font-size: 0.84rem;
  color: var(--text-primary);
  transition: color 0.15s;
}

.filter-checkbox-label:hover {
  color: var(--sage-700);
}

.filter-checkbox {
  width: 16px;
  height: 16px;
  accent-color: var(--sage-600);
  cursor: pointer;
  flex-shrink: 0;
  margin: 0;
}

.filter-checkbox-text {
  flex: 1;
}

.filter-checkbox-count {
  font-size: 0.72rem;
  color: var(--text-muted);
  font-weight: 400;
}

.filter-actions {
  display: flex;
  gap: 0.5rem;
  padding-top: 0.5rem;
}

.filter-actions .btn {
  flex: 1;
  font-size: 0.8rem;
  text-align: center;
}

/* ── Mobile filter toggle ── */
.community-filter-toggle-wrap {
  max-width: 960px;
  margin: 0 auto 1rem;
  display: none;
  align-items: center;
  gap: 1rem;
}

.community-filter-toggle {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.85rem;
  padding: 0.5rem 1rem;
}

.community-post-count {
  font-size: 0.82rem;
  color: var(--text-muted);
  font-weight: 500;
}

/* ── Active filter chips bar ── */
.community-active-filters {
  max-width: 960px;
  margin: 0 auto 1rem;
}

.active-filters-inner {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.active-filters-label {
  font-size: 0.8rem;
  font-weight: 500;
  color: var(--text-muted);
  white-space: nowrap;
}

.active-filter-chip {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  padding: 0.25rem 0.65rem;
  background: var(--sage-50);
  border: 1px solid var(--sage-200);
  border-radius: var(--radius-full);
  font-size: 0.78rem;
  font-weight: 500;
  color: var(--sage-700);
  animation: chipIn 0.2s ease;
}

.active-filter-remove {
  background: none;
  border: none;
  cursor: pointer;
  font-size: 1rem;
  line-height: 1;
  color: var(--sage-400);
  padding: 0 0 0 0.15rem;
  transition: color 0.15s;
}

.active-filter-remove:hover {
  color: var(--error);
}

.active-filters-clear {
  background: none;
  border: none;
  cursor: pointer;
  font-size: 0.78rem;
  font-weight: 500;
  color: var(--text-muted);
  text-decoration: underline;
  padding: 0.25rem 0.5rem;
  transition: color 0.15s;
  white-space: nowrap;
}

.active-filters-clear:hover {
  color: var(--sage-700);
}

/* ── Post Tags (on post cards) ── */
.post-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  margin-bottom: 0.75rem;
}

.post-tag {
  display: inline-flex;
  align-items: center;
  gap: 0.2rem;
  padding: 0.18rem 0.6rem;
  border-radius: var(--radius-full);
  font-size: 0.7rem;
  font-weight: 500;
  white-space: nowrap;
  letter-spacing: 0.01em;
}

.post-tag--loss {
  background: #fef3e2;
  color: #9a7424;
  border: 1px solid #f0e0b8;
}

.post-tag--age {
  background: var(--sage-50);
  color: var(--sage-600);
  border: 1px solid var(--sage-100);
}

.post-tag--category {
  background: #f0edf5;
  color: var(--dusk-600);
  border: 1px solid #e0dae8;
}

/* ── Responsive: Tablet & Mobile ── */
@media (max-width: 768px) {
  .community-filter-toggle-wrap {
    display: flex;
  }

  .community-filters {
    position: fixed;
    top: 0;
    left: 0;
    bottom: 0;
    width: 280px;
    max-width: 85vw;
    z-index: 150;
    border-radius: 0;
    border: none;
    box-shadow: 4px 0 20px rgba(0,0,0,0.15);
    transform: translateX(-100%);
    transition: transform 0.3s ease;
    overflow-y: auto;
    padding: 1.5rem;
  }

  .community-filters.open {
    transform: translateX(0);
  }

  .filter-panel-close {
    display: block;
  }

  .community-layout {
    display: block;
  }

  .community-feed-column {
    max-width: 100%;
  }

  .active-filters-inner {
    flex-wrap: nowrap;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    padding-bottom: 0.25rem;
  }

  .post-tags {
    gap: 0.3rem;
  }

  .post-tag {
    font-size: 0.67rem;
    padding: 0.12rem 0.5rem;
  }
}

.btn-small {
  padding: 0.5rem 1rem;
  font-size: 0.82rem;
}

/* Modal */
.modal-overlay {
  position: fixed;
  inset: 0;
  z-index: 200;
  background: rgba(0, 0, 0, 0.4);
  backdrop-filter: blur(4px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1.5rem;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.25s ease;
}

.modal-overlay.open {
  opacity: 1;
  pointer-events: auto;
}

.modal-card {
  width: 100%;
  max-width: 560px;
  background: var(--white);
  border-radius: var(--radius-lg);
  padding: 2rem;
  box-shadow: 0 20px 60px rgba(0,0,0,0.12);
  transform: translateY(16px);
  transition: transform 0.25s ease;
}

.modal-overlay.open .modal-card {
  transform: translateY(0);
}

.modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 0.25rem;
}

.modal-header h2 {
  font-size: 1.4rem;
  color: var(--sage-800);
}

.modal-close {
  background: none;
  border: none;
  font-size: 1.6rem;
  color: var(--text-muted);
  cursor: pointer;
  padding: 0.25rem;
  line-height: 1;
  transition: color 0.2s;
}

.modal-close:hover {
  color: var(--text-primary);
}

.modal-subtitle {
  color: var(--text-secondary);
  font-size: 0.9rem;
  margin-bottom: 1.5rem;
}

/* Responsive — community */
@media (max-width: 768px) {
  .community-header {
    flex-direction: column;
    align-items: flex-start;
  }

  .post-header {
    flex-wrap: wrap;
  }

  .post-category-tag {
    order: 3;
    margin-top: 0.25rem;
  }

  .comment-form {
    flex-direction: column;
    align-items: stretch;
  }

  .comment-form .btn-small {
    align-self: flex-end;
  }

  .modal-card {
    padding: 1.5rem;
  }

  .form-row {
    grid-template-columns: 1fr;
  }
}

/* ══════════════════════════════════════
   Media Upload — Dropzone & Preview
   ══════════════════════════════════════ */

.form-hint {
  font-size: 0.82rem;
  color: var(--text-muted);
  margin-bottom: 0.75rem;
}

.media-dropzone,
.media-dropzone-inline {
  border: 2px dashed var(--sage-200);
  border-radius: var(--radius-md);
  padding: 2rem;
  text-align: center;
  cursor: pointer;
  transition: all 0.25s ease;
  background: var(--warm-50);
}

.media-dropzone:hover,
.media-dropzone-inline:hover {
  border-color: var(--sage-400);
  background: var(--sage-50);
}

.media-dropzone.dragover,
.media-dropzone-inline.dragover {
  border-color: var(--sage-500);
  background: var(--sage-50);
  box-shadow: 0 0 0 4px rgba(122, 158, 130, 0.15);
}

.dropzone-content {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.5rem;
}

.dropzone-icon {
  font-size: 2rem;
  line-height: 1;
}

.dropzone-text {
  font-size: 0.9rem;
  color: var(--text-secondary);
}

.dropzone-hint {
  font-size: 0.75rem;
  color: var(--text-muted);
  margin-top: 0.25rem;
}

/* Preview Grid (on create form) */
.media-preview-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
  gap: 0.75rem;
  margin-top: 1rem;
}

.media-preview-item {
  position: relative;
  border-radius: var(--radius-sm);
  overflow: hidden;
  aspect-ratio: 1;
  background: var(--sage-50);
}

.media-preview-item img,
.media-preview-item video {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.media-preview-remove {
  position: absolute;
  top: 4px;
  right: 4px;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: rgba(0,0,0,0.6);
  color: var(--white);
  border: none;
  cursor: pointer;
  font-size: 1rem;
  line-height: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  transition: opacity 0.2s;
}

.media-preview-item:hover .media-preview-remove {
  opacity: 1;
}

.media-preview-play {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--white);
  font-size: 1.5rem;
  background: rgba(0,0,0,0.2);
  pointer-events: none;
}

/* ══════════════════════════════════════
   Moodboard — Pinterest-Style Grid
   ══════════════════════════════════════ */

.moodboard-hero {
  max-width: 900px;
  margin: 0 auto 2rem;
}

.moodboard-header {
  text-align: center;
  margin-bottom: 1.5rem;
}

.moodboard-header h1 {
  font-size: clamp(1.8rem, 3.5vw, 2.6rem);
  color: var(--sage-800);
  margin-bottom: 0.5rem;
}

.moodboard-header .detail-meta {
  justify-content: center;
}

/* Masonry Grid — CSS Columns */
.masonry-grid {
  column-count: 3;
  column-gap: 0.75rem;
}

.masonry-item {
  break-inside: avoid;
  margin-bottom: 0.75rem;
  border-radius: var(--radius-md);
  overflow: hidden;
  position: relative;
  cursor: pointer;
  transition: transform 0.25s, box-shadow 0.25s;
}

.masonry-item:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(0,0,0,0.1);
}

.masonry-item img,
.masonry-item video {
  width: 100%;
  display: block;
  border-radius: var(--radius-md);
}

.masonry-play-icon {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 2.5rem;
  color: var(--white);
  background: rgba(0,0,0,0.25);
  border-radius: var(--radius-md);
  pointer-events: none;
  transition: background 0.2s;
}

.masonry-item:hover .masonry-play-icon {
  background: rgba(0,0,0,0.4);
}

.masonry-remove {
  position: absolute;
  top: 8px;
  right: 8px;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: rgba(0,0,0,0.5);
  color: var(--white);
  border: none;
  cursor: pointer;
  font-size: 1.2rem;
  line-height: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  transition: opacity 0.2s, background 0.2s;
  z-index: 2;
}

.masonry-item:hover .masonry-remove {
  opacity: 1;
}

.masonry-remove:hover {
  background: rgba(192, 57, 43, 0.8);
}

/* Add More Media Tile */
.masonry-add {
  background: var(--white);
  border: 2px dashed var(--sage-200);
  min-height: 180px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.25s;
}

.masonry-add:hover {
  border-color: var(--sage-400);
  background: var(--sage-50);
  transform: none;
  box-shadow: none;
}

.masonry-add-content {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.5rem;
  color: var(--text-muted);
  font-size: 0.85rem;
  font-weight: 500;
}

.masonry-add-icon {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: var(--sage-100);
  color: var(--sage-600);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
  font-weight: 300;
}

/* Profile detail when moodboard is present */
.profile-detail.has-moodboard {
  margin-top: 0;
}

/* Upload status */
.upload-status {
  text-align: center;
  padding: 0.75rem 1rem;
  color: var(--sage-600);
  font-weight: 500;
  font-size: 0.9rem;
  background: var(--sage-50);
  border-radius: var(--radius-sm);
  margin: 0.75rem 0;
}

/* Inline dropzone (on view page, no media yet) */
.media-dropzone-inline {
  margin-bottom: 1.75rem;
}

/* ══════════════════════════════════════
   Lightbox
   ══════════════════════════════════════ */

.lightbox-overlay {
  position: fixed;
  inset: 0;
  z-index: 300;
  background: rgba(0, 0, 0, 0.92);
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s ease;
}

.lightbox-overlay.open {
  opacity: 1;
  pointer-events: auto;
}

.lightbox-close {
  position: absolute;
  top: 1rem;
  right: 1.25rem;
  background: none;
  border: none;
  color: rgba(255,255,255,0.8);
  font-size: 2.2rem;
  cursor: pointer;
  z-index: 2;
  line-height: 1;
  transition: color 0.2s;
}

.lightbox-close:hover {
  color: var(--white);
}

.lightbox-nav {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background: none;
  border: none;
  color: rgba(255,255,255,0.7);
  font-size: 3rem;
  cursor: pointer;
  z-index: 2;
  padding: 1rem;
  transition: color 0.2s;
}

.lightbox-nav:hover {
  color: var(--white);
}

.lightbox-prev { left: 0.5rem; }
.lightbox-next { right: 0.5rem; }

.lightbox-content {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 2rem;
}

/* ── Responsive — moodboard ── */
@media (max-width: 768px) {
  .masonry-grid {
    column-count: 2;
  }

  .masonry-add {
    min-height: 140px;
  }

  .lightbox-nav {
    font-size: 2rem;
    padding: 0.5rem;
  }

  .media-preview-grid {
    grid-template-columns: repeat(auto-fill, minmax(90px, 1fr));
  }
}

@media (max-width: 480px) {
  .masonry-grid {
    column-count: 2;
    column-gap: 0.5rem;
  }

  .masonry-item {
    margin-bottom: 0.5rem;
  }
}

/* ══════════════════════════════════════════════════════════
   LANDING PAGE REDESIGN — Scoped Overrides
   ══════════════════════════════════════════════════════════ */

/* ── Landing Typography (Lora instead of Playfair) ── */
body[data-page="landing"] h1,
body[data-page="landing"] h2,
body[data-page="landing"] h3 {
  font-family: 'Lora', Georgia, serif;
}

body[data-page="landing"] .logo {
  font-family: 'Lora', serif;
}

body[data-page="landing"] .footer-logo {
  font-family: 'Lora', serif;
}

/* ── Landing Button Transitions (softer) ── */
body[data-page="landing"] .btn {
  transition: all 0.35s ease;
}

/* ── Landing Fade-in Override (gentler motion) ── */
body[data-page="landing"] .fade-in {
  transform: translateY(12px);
  transition: opacity 0.8s ease, transform 0.8s ease;
}

/* ── Testimonials Grid (Landing Page) ── */
.testimonials {
  padding: 8rem 2rem;
  background: var(--warm-50);
}

.testimonials-inner {
  max-width: 1100px;
  margin: 0 auto;
}

.testimonial-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 2rem;
  margin-top: 3rem;
}

.testimonial-card {
  background: var(--white);
  border: 1px solid var(--sage-100);
  border-radius: var(--radius-lg);
  padding: 2.5rem;
  transition: all 0.4s ease;
}

.testimonial-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 8px 30px rgba(0, 0, 0, 0.05);
  border-color: var(--sage-200);
}

.testimonial-card blockquote {
  font-family: 'Lora', Georgia, serif;
  font-size: 1.05rem;
  color: var(--sage-700);
  font-style: italic;
  line-height: 1.75;
  margin-bottom: 1.5rem;
}

.testimonial-author {
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
}

.testimonial-name {
  font-weight: 600;
  font-size: 0.9rem;
  color: var(--text-primary);
}

.testimonial-detail {
  font-size: 0.82rem;
  color: var(--text-muted);
}

/* ── Landing Page Responsive (mobile) ── */
@media (max-width: 768px) {
  body[data-page="landing"] .hero {
    padding: 8rem 1.5rem 4rem;
  }

  body[data-page="landing"] .features,
  body[data-page="landing"] .how-it-works,
  body[data-page="landing"] .cta {
    padding: 5rem 1.5rem;
  }

  .testimonials {
    padding: 5rem 1.5rem;
  }

  .feature-row {
    padding: 1.25rem 0.75rem;
    gap: 1rem;
  }

  .feature-row:hover {
    transform: none;
  }

  .testimonial-grid {
    grid-template-columns: 1fr;
  }

  body[data-page="landing"] .cta-box {
    padding: 3rem 1.5rem;
  }
}

/* ══════════════════════════════════════ */
/*          PRICING PAGE                 */
/* ══════════════════════════════════════ */

/* ── Pricing Hero ── */
.pricing-hero {
  padding: 10rem 2rem 4rem;
  text-align: center;
  background:
    radial-gradient(ellipse 80% 60% at 50% 0%, rgba(228, 235, 230, 0.5) 0%, transparent 70%),
    var(--warm-50);
}

.pricing-hero-content h1 {
  font-family: 'Lora', Georgia, serif;
  font-size: clamp(2rem, 4vw, 2.8rem);
  font-weight: 600;
  color: var(--sage-800);
  margin-bottom: 0.8rem;
  letter-spacing: -0.01em;
}

.pricing-hero-content p {
  font-size: 1.1rem;
  color: var(--text-secondary);
  max-width: 500px;
  margin: 0 auto;
  line-height: 1.7;
}

/* ── Billing Toggle ── */
.pricing-toggle-wrap {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.8rem;
  padding: 2rem 1rem 3rem;
  background: var(--warm-50);
}

.pricing-toggle-label {
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--text-muted);
  transition: color 0.3s ease;
  user-select: none;
}

.pricing-toggle-label.active {
  color: var(--sage-700);
  font-weight: 600;
}

.pricing-toggle-save {
  display: inline-block;
  background: var(--sage-100);
  color: var(--sage-700);
  font-size: 0.72rem;
  font-weight: 700;
  padding: 0.2em 0.6em;
  border-radius: var(--radius-full);
  margin-left: 0.3rem;
  letter-spacing: 0.02em;
}

.pricing-toggle {
  position: relative;
  width: 48px;
  height: 26px;
  background: var(--sage-200);
  border: none;
  border-radius: 13px;
  cursor: pointer;
  transition: background 0.3s ease;
  padding: 0;
  flex-shrink: 0;
}

.pricing-toggle[aria-checked="true"] {
  background: var(--sage-500);
}

.pricing-toggle-knob {
  position: absolute;
  top: 3px;
  left: 3px;
  width: 20px;
  height: 20px;
  background: var(--white);
  border-radius: 50%;
  transition: transform 0.3s ease;
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.15);
}

.pricing-toggle[aria-checked="true"] .pricing-toggle-knob {
  transform: translateX(22px);
}

/* ── Pricing Grid ── */
.pricing-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 1.5rem;
  max-width: 1120px;
  margin: 0 auto;
  padding: 0 2rem 2rem;
}

/* ── Pricing Card ── */
.pricing-card {
  background: var(--white);
  border: 1px solid var(--sage-100);
  border-radius: var(--radius-md);
  padding: 2.5rem 2rem;
  display: flex;
  flex-direction: column;
  transition: transform 0.3s ease, box-shadow 0.3s ease, border-color 0.3s ease;
  position: relative;
}

.pricing-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 8px 30px rgba(0, 0, 0, 0.06);
  border-color: var(--sage-200);
}

/* Popular card highlight */
.pricing-card--popular {
  border-color: var(--sage-400);
  box-shadow: 0 4px 20px rgba(71, 106, 79, 0.1);
}

.pricing-card--popular:hover {
  border-color: var(--sage-500);
  box-shadow: 0 12px 40px rgba(71, 106, 79, 0.15);
}

.pricing-popular-badge {
  position: absolute;
  top: -12px;
  left: 50%;
  transform: translateX(-50%);
  background: var(--sage-600);
  color: var(--white);
  font-size: 0.72rem;
  font-weight: 700;
  padding: 0.35em 1.2em;
  border-radius: var(--radius-full);
  letter-spacing: 0.04em;
  text-transform: uppercase;
  white-space: nowrap;
}

/* Card header */
.pricing-card-header {
  margin-bottom: 1.5rem;
}

.pricing-card-header h3 {
  font-family: 'Lora', Georgia, serif;
  font-size: 1.35rem;
  font-weight: 600;
  color: var(--sage-800);
  margin-bottom: 0.4rem;
}

.pricing-card-desc {
  font-size: 0.88rem;
  color: var(--text-muted);
  line-height: 1.5;
}

/* Price display */
.pricing-card-price {
  display: flex;
  align-items: baseline;
  gap: 0.3rem;
  margin-bottom: 2rem;
  padding-bottom: 1.5rem;
  border-bottom: 1px solid var(--sage-100);
}

.pricing-amount {
  font-family: 'Inter', sans-serif;
  font-size: 2.5rem;
  font-weight: 700;
  color: var(--sage-800);
  letter-spacing: -0.03em;
  line-height: 1;
}

.pricing-period {
  font-size: 0.88rem;
  color: var(--text-muted);
  font-weight: 400;
}

/* Feature list */
.pricing-features {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  margin-bottom: 2rem;
  flex-grow: 1;
}

.pricing-features li {
  display: flex;
  align-items: flex-start;
  gap: 0.6rem;
  font-size: 0.88rem;
  color: var(--text-secondary);
  line-height: 1.5;
}

.pricing-features li svg {
  flex-shrink: 0;
  color: var(--sage-500);
  margin-top: 2px;
}

/* CTA button at card bottom */
.pricing-cta {
  width: 100%;
  text-align: center;
  padding: 0.8rem 1.5rem;
  font-size: 0.9rem;
  margin-top: auto;
}

/* ── Reassurance Line ── */
.pricing-reassurance {
  text-align: center;
  font-size: 0.88rem;
  color: var(--text-muted);
  padding: 1.5rem 2rem 4rem;
  background: var(--warm-50);
}

/* ── FAQ Section ── */
.pricing-faq {
  background: var(--sage-50);
  padding: 6rem 2rem;
}

.pricing-faq-inner {
  max-width: 700px;
  margin: 0 auto;
}

.pricing-faq-inner h2 {
  font-family: 'Lora', Georgia, serif;
  font-size: clamp(1.5rem, 3vw, 2rem);
  font-weight: 600;
  color: var(--sage-800);
  text-align: center;
  margin-bottom: 3rem;
}

.faq-list {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.faq-item {
  background: var(--white);
  border: 1px solid var(--sage-100);
  border-radius: var(--radius-md);
  overflow: hidden;
  transition: border-color 0.3s ease, box-shadow 0.3s ease;
}

.faq-item:hover {
  border-color: var(--sage-200);
}

.faq-item[open] {
  border-color: var(--sage-300);
  box-shadow: 0 2px 12px rgba(0, 0, 0, 0.04);
}

.faq-item summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1.25rem 1.5rem;
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--sage-800);
  cursor: pointer;
  list-style: none;
  user-select: none;
  transition: color 0.2s ease;
}

.faq-item summary::-webkit-details-marker {
  display: none;
}

.faq-item summary::after {
  content: '+';
  font-size: 1.3rem;
  font-weight: 400;
  color: var(--sage-400);
  transition: transform 0.3s ease, color 0.3s ease;
  flex-shrink: 0;
  margin-left: 1rem;
  line-height: 1;
}

.faq-item[open] summary::after {
  content: '−';
  color: var(--sage-600);
}

.faq-item summary:hover {
  color: var(--sage-600);
}

.faq-item p {
  padding: 0 1.5rem 1.25rem;
  font-size: 0.9rem;
  color: var(--text-secondary);
  line-height: 1.75;
}

/* ── Pricing Responsive ── */
@media (max-width: 1024px) {
  .pricing-grid {
    grid-template-columns: repeat(2, 1fr);
    max-width: 680px;
  }
}

@media (max-width: 768px) {
  .pricing-hero {
    padding: 8rem 1.5rem 3rem;
  }

  .pricing-grid {
    grid-template-columns: 1fr;
    max-width: 420px;
    padding: 0 1.5rem 2rem;
  }

  .pricing-card {
    padding: 2rem 1.5rem;
  }

  .pricing-faq {
    padding: 4rem 1.5rem;
  }

  .pricing-faq-inner h2 {
    margin-bottom: 2rem;
  }

  .faq-item summary {
    padding: 1rem 1.25rem;
    font-size: 0.9rem;
  }

  .faq-item p {
    padding: 0 1.25rem 1rem;
    font-size: 0.85rem;
  }
}

@media (max-width: 480px) {
  .pricing-hero-content h1 {
    font-size: 1.7rem;
  }

  .pricing-amount {
    font-size: 2rem;
  }

  .pricing-toggle-wrap {
    gap: 0.5rem;
  }

  .pricing-toggle-label {
    font-size: 0.82rem;
  }
}

/* ── Pricing Fade-In Animations ── */
.pricing-hero .fade-in,
.pricing-toggle-wrap.fade-in,
.pricing-grid .fade-in,
.pricing-reassurance.fade-in,
.pricing-faq .fade-in,
.pricing-faq-inner .fade-in {
  opacity: 0;
  transform: translateY(12px);
  transition: opacity 0.8s ease, transform 0.8s ease;
}

.pricing-hero .fade-in.visible,
.pricing-toggle-wrap.fade-in.visible,
.pricing-grid .fade-in.visible,
.pricing-reassurance.fade-in.visible,
.pricing-faq .fade-in.visible,
.pricing-faq-inner .fade-in.visible {
  opacity: 1;
  transform: translateY(0);
}

/* ══════════════════════════════════════ */
/*          ONBOARDING WIZARD            */
/* ══════════════════════════════════════ */

/* ── Page container ── */
.onboarding-page {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 100vh;
  padding: 3rem 1.5rem;
  position: relative;
  background:
    radial-gradient(ellipse at 20% 50%, rgba(201, 215, 205, 0.3) 0%, transparent 50%),
    radial-gradient(ellipse at 80% 20%, rgba(107, 94, 123, 0.08) 0%, transparent 40%),
    var(--warm-50);
}

/* ── Card ── */
.onboarding-card {
  width: 100%;
  max-width: 540px;
  background: var(--white);
  border: 1px solid var(--sage-100);
  border-radius: var(--radius-lg);
  padding: 2.5rem;
  position: relative;
  z-index: 1;
  box-shadow: 0 4px 24px rgba(0, 0, 0, 0.04);
}

/* ── Progress indicator ── */
.onboarding-progress {
  margin-bottom: 2rem;
}

.onboarding-step-text {
  display: block;
  text-align: center;
  font-size: 0.82rem;
  font-weight: 500;
  color: var(--text-muted);
  margin-bottom: 0.5rem;
}

.onboarding-progress-bar {
  height: 3px;
  background: var(--sage-100);
  border-radius: var(--radius-full);
  overflow: hidden;
}

.onboarding-progress-fill {
  height: 100%;
  background: var(--sage-400);
  border-radius: var(--radius-full);
  transition: width 0.4s ease;
}

/* ── Step visibility & animation ── */
.onboarding-step {
  display: none;
}

.onboarding-step.active {
  display: block;
  animation: obFadeIn 0.4s ease;
}

@keyframes obFadeIn {
  from { opacity: 0; transform: translateY(8px); }
  to   { opacity: 1; transform: translateY(0); }
}

/* ── Typography ── */
.onboarding-step h1 {
  font-family: 'Playfair Display', Georgia, serif;
  font-size: 1.8rem;
  color: var(--sage-800);
  margin-bottom: 0.6rem;
  line-height: 1.3;
}

.onboarding-step h2 {
  font-family: 'Playfair Display', Georgia, serif;
  font-size: 1.4rem;
  color: var(--sage-800);
  margin-bottom: 0.5rem;
  line-height: 1.3;
}

.onboarding-subtext {
  color: var(--text-secondary);
  font-size: 1rem;
  line-height: 1.6;
  margin-bottom: 2rem;
}

.onboarding-hint {
  color: var(--text-muted);
  font-size: 0.88rem;
  margin-bottom: 1.25rem;
  line-height: 1.5;
}

.onboarding-prompt {
  color: var(--text-secondary);
  font-size: 0.95rem;
  font-style: italic;
  margin-bottom: 1rem;
  line-height: 1.6;
}

/* ── Continue button (full width) ── */
.onboarding-step .btn {
  width: 100%;
  margin-top: 0.5rem;
}

/* ── Radio options (Step 3) ── */
.ob-radio-group {
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
  margin-bottom: 1.5rem;
}

.ob-radio-option {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.85rem 1rem;
  border: 1.5px solid var(--sage-200);
  border-radius: var(--radius-sm);
  cursor: pointer;
  transition: all 0.2s ease;
  background: var(--warm-50);
}

.ob-radio-option:hover {
  border-color: var(--sage-400);
  background: var(--sage-50);
}

.ob-radio-option.selected {
  border-color: var(--sage-500);
  background: var(--sage-50);
  box-shadow: 0 0 0 3px rgba(122, 158, 130, 0.15);
}

.ob-radio-option input[type="radio"] {
  accent-color: var(--sage-600);
  width: 16px;
  height: 16px;
  flex-shrink: 0;
}

.ob-radio-label {
  font-size: 0.95rem;
  color: var(--text-primary);
}

/* ── Multi-select chips (Steps 4 & 5) ── */
.ob-chip-group {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-bottom: 1.5rem;
}

.ob-chip {
  padding: 0.55rem 1.1rem;
  border: 1.5px solid var(--sage-200);
  border-radius: var(--radius-full);
  font-family: 'Inter', sans-serif;
  font-size: 0.88rem;
  color: var(--text-primary);
  background: var(--warm-50);
  cursor: pointer;
  transition: all 0.2s ease;
  user-select: none;
}

.ob-chip:hover {
  border-color: var(--sage-400);
  background: var(--sage-50);
}

.ob-chip.selected {
  background: var(--sage-600);
  color: var(--white);
  border-color: var(--sage-600);
}

.ob-chip.selected:hover {
  background: var(--sage-700);
  border-color: var(--sage-700);
}

/* ── Photo upload (Step 2) ── */
.ob-photo-dropzone {
  border: 2px dashed var(--sage-200);
  border-radius: var(--radius-sm);
  padding: 1.5rem;
  text-align: center;
  cursor: pointer;
  transition: border-color 0.2s, background 0.2s;
  background: var(--warm-50);
}

.ob-photo-dropzone:hover,
.ob-photo-dropzone.dragover {
  border-color: var(--sage-400);
  background: var(--sage-50);
}

.ob-dropzone-content {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.3rem;
}

.ob-dropzone-text {
  font-size: 0.88rem;
  color: var(--text-secondary);
}

.ob-dropzone-hint {
  font-size: 0.78rem;
  color: var(--text-muted);
  margin-top: 0.2rem;
}

.ob-photo-preview {
  margin-top: 0.5rem;
}

.ob-preview-thumb {
  display: inline-block;
  position: relative;
}

.ob-preview-thumb img {
  width: 80px;
  height: 80px;
  object-fit: cover;
  border-radius: var(--radius-sm);
  border: 1px solid var(--sage-100);
}

.ob-photo-remove {
  position: absolute;
  top: -6px;
  right: -6px;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: var(--error);
  color: var(--white);
  border: 2px solid var(--white);
  font-size: 14px;
  line-height: 16px;
  text-align: center;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0;
}

.ob-photo-remove:hover {
  background: #a93226;
}

/* ── "Other" relationship input ── */
.ob-other-input {
  margin-top: 0.5rem;
}

/* ── Notebook textarea (Step 6) ── */
.ob-notebook-wrap {
  border-radius: var(--radius-sm);
  overflow: hidden;
  border: 1.5px solid var(--sage-200);
  margin-bottom: 0.5rem;
  transition: border-color 0.2s, box-shadow 0.2s;
}

.ob-notebook-wrap:focus-within {
  border-color: var(--sage-400);
  box-shadow: 0 0 0 3px rgba(122, 158, 130, 0.15);
}

.ob-notebook-textarea {
  width: 100%;
  min-height: 200px;
  padding: 5px 1rem 1rem 50px;
  background:
    repeating-linear-gradient(
      to bottom,
      transparent 0px,
      transparent 29px,
      var(--nb-line-color) 29px,
      var(--nb-line-color) 30px
    ),
    var(--nb-paper-bg);
  background-size: 100% 30px, 100% 100%;
  line-height: 30px;
  color: var(--nb-ink-color);
  text-shadow: 0 0 1px var(--nb-ink-shadow);
  font-family: 'Inter', sans-serif;
  font-size: 0.95rem;
  border: none;
  outline: none;
  resize: vertical;
}

.ob-notebook-textarea::placeholder {
  color: rgba(44, 24, 16, 0.25);
  text-shadow: none;
}

.ob-autosave-note {
  font-size: 0.78rem;
  color: var(--text-muted);
  display: block;
  margin-bottom: 0.75rem;
  min-height: 1.2em;
}

/* ── Recommendations (Step 7) ── */
.ob-recommendations {
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
  margin-bottom: 1.5rem;
}

.ob-rec-item {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  padding: 0.85rem 1rem;
  background: var(--sage-50);
  border-radius: var(--radius-sm);
  border: 1px solid var(--sage-100);
  transition: background 0.2s;
}

.ob-rec-icon {
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--white);
  border-radius: var(--radius-sm);
  flex-shrink: 0;
  color: var(--sage-600);
}

.ob-rec-text h4 {
  font-family: 'Inter', sans-serif;
  font-size: 0.92rem;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 0.15rem;
}

.ob-rec-text p {
  font-size: 0.82rem;
  color: var(--text-muted);
  line-height: 1.4;
}

/* ── Step 8: Finish ── */
.ob-finish-icon {
  text-align: center;
  margin-bottom: 1rem;
}

.ob-plans-link {
  display: block;
  text-align: center;
  margin-top: 1rem;
  color: var(--sage-600);
  font-size: 0.88rem;
  font-weight: 500;
  text-decoration: none;
  transition: color 0.2s;
}

.ob-plans-link:hover {
  color: var(--sage-700);
  text-decoration: underline;
}

/* ── Onboarding Responsive ── */
@media (max-width: 768px) {
  .onboarding-page {
    padding: 2rem 1rem;
    align-items: flex-start;
    padding-top: 3rem;
  }

  .onboarding-card {
    padding: 2rem 1.5rem;
    max-width: 100%;
  }

  .onboarding-step h1 {
    font-size: 1.5rem;
  }

  .onboarding-step h2 {
    font-size: 1.25rem;
  }
}

@media (max-width: 480px) {
  .onboarding-card {
    padding: 1.5rem 1.25rem;
  }

  .onboarding-step h1 {
    font-size: 1.35rem;
  }

  .ob-notebook-textarea {
    min-height: 160px;
    padding-left: 40px;
  }

  .ob-chip {
    font-size: 0.82rem;
    padding: 0.5rem 0.9rem;
  }
}

/* ══════════════════════════════════════ */
/*     LANDING PAGE — NEW SECTIONS       */
/* ══════════════════════════════════════ */

/* ── Section Divider ── */
.section-divider {
  width: 48px;
  height: 2px;
  background: var(--sage-300);
  margin: 3rem auto 0;
  border-radius: var(--radius-full);
}

/* ── Empathy Bridge ── */
.empathy-bridge {
  padding: 6rem 2rem 5rem;
  background: var(--white);
}

.empathy-inner {
  max-width: 680px;
  margin: 0 auto;
  text-align: center;
}

.empathy-inner .section-label {
  margin-bottom: 1rem;
}

.empathy-inner h2 {
  font-family: 'Lora', Georgia, serif;
  font-size: clamp(1.6rem, 3vw, 2.2rem);
  color: var(--sage-800);
  margin-bottom: 2rem;
  letter-spacing: -0.01em;
}

.empathy-inner p {
  font-size: 1rem;
  color: var(--text-secondary);
  line-height: 1.85;
  margin-bottom: 1.5rem;
  text-align: left;
}

.empathy-inner p:last-of-type {
  margin-bottom: 0;
}

.empathy-closing {
  margin-top: 0.5rem;
  text-align: center !important;
}

.empathy-closing strong {
  color: var(--sage-700);
  font-size: 1.02rem;
}

/* ── Testimonial Note ── */
.testimonial-note {
  text-align: center;
  font-size: 0.82rem;
  color: var(--text-muted);
  max-width: 560px;
  margin: 2.5rem auto 0;
  line-height: 1.6;
}

/* ── Honest Note (What Grievly Is and Isn't) ── */
.honest-note {
  padding: 6rem 2rem 5rem;
  background: var(--white);
}

.honest-note-inner {
  max-width: 680px;
  margin: 0 auto;
  text-align: center;
}

.honest-note-inner h2 {
  font-family: 'Lora', Georgia, serif;
  font-size: clamp(1.4rem, 2.5vw, 1.8rem);
  color: var(--sage-800);
  margin-bottom: 2rem;
  letter-spacing: -0.01em;
}

.honest-note-inner p {
  font-size: 0.95rem;
  color: var(--text-secondary);
  line-height: 1.85;
  margin-bottom: 1.25rem;
  text-align: left;
}

.honest-note-link {
  color: var(--sage-600);
  text-decoration: underline;
  text-underline-offset: 2px;
  font-weight: 500;
  transition: color 0.2s;
}

.honest-note-link:hover {
  color: var(--sage-800);
}

.honest-note-closing {
  text-align: center !important;
  margin-top: 0.5rem;
}

.honest-note-closing strong {
  color: var(--sage-700);
}

/* ── Founding Members CTA ── */
.founding-cta {
  padding: 6rem 2rem;
  background: linear-gradient(145deg, var(--sage-800), var(--dusk-700));
  text-align: center;
}

.founding-cta-inner {
  max-width: 600px;
  margin: 0 auto;
}

.founding-badge {
  display: inline-block;
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--sage-800);
  background: rgba(255, 255, 255, 0.9);
  padding: 0.35em 1.2em;
  border-radius: var(--radius-full);
  margin-bottom: 1.5rem;
}

.founding-cta-inner h2 {
  font-family: 'Lora', Georgia, serif;
  font-size: clamp(1.6rem, 3.5vw, 2.4rem);
  color: var(--white);
  margin-bottom: 1rem;
  letter-spacing: -0.01em;
}

.founding-subtext {
  font-size: 1rem;
  color: rgba(255, 255, 255, 0.85);
  line-height: 1.75;
  margin-bottom: 2.5rem;
}

.founding-form {
  display: flex;
  gap: 0.75rem;
  max-width: 440px;
  margin: 0 auto 1.25rem;
}

.founding-email {
  flex: 1;
  padding: 0.85rem 1.2rem;
  border: 1.5px solid rgba(255, 255, 255, 0.25);
  border-radius: var(--radius-full);
  background: rgba(255, 255, 255, 0.1);
  color: var(--white);
  font-family: 'Inter', sans-serif;
  font-size: 0.9rem;
  outline: none;
  transition: border-color 0.2s, background 0.2s;
}

.founding-email::placeholder {
  color: rgba(255, 255, 255, 0.5);
}

.founding-email:focus {
  border-color: rgba(255, 255, 255, 0.5);
  background: rgba(255, 255, 255, 0.15);
}

.founding-submit {
  white-space: nowrap;
  padding: 0.85rem 1.8rem;
  font-weight: 600;
}

.founding-note {
  font-size: 0.78rem;
  color: rgba(255, 255, 255, 0.5);
  line-height: 1.5;
}

/* ── Landing New Sections Responsive ── */
@media (max-width: 768px) {
  .empathy-bridge,
  .honest-note {
    padding: 4rem 1.5rem 3.5rem;
  }

  .founding-cta {
    padding: 4rem 1.5rem;
  }

  .founding-form {
    flex-direction: column;
  }

  .founding-email {
    text-align: center;
  }

  .founding-submit {
    width: 100%;
  }
}

@media (max-width: 480px) {
  .empathy-inner h2,
  .honest-note-inner h2 {
    font-size: 1.4rem;
  }

  .founding-cta-inner h2 {
    font-size: 1.5rem;
  }
}

/* ════════════════════════════════════════════
   THEIR VOICE (Voicemails Section)
   ════════════════════════════════════════════ */

.tribute-section-subtext {
  font-size: 0.95rem;
  color: var(--text-muted);
  line-height: 1.7;
  max-width: 520px;
  margin: 0.75rem auto 0;
}

/* Empty state */
.voicemail-empty {
  text-align: center;
  padding: 3rem 2rem;
  color: var(--text-muted);
}

.voicemail-empty-icon {
  margin-bottom: 1rem;
  opacity: 0.4;
}

.voicemail-empty-icon svg {
  stroke: var(--sage-400);
}

.voicemail-empty p {
  font-size: 0.92rem;
  line-height: 1.6;
  max-width: 380px;
  margin: 0 auto;
}

/* Voicemail list */
.voicemail-list {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

/* Individual voicemail card */
.voicemail-card {
  position: relative;
  background: var(--warm-50, #faf8f5);
  border: 1px solid var(--sage-100, #e8e5df);
  border-radius: 12px;
  padding: 1.5rem;
  transition: box-shadow 0.2s ease;
}

.voicemail-card:hover {
  box-shadow: 0 2px 12px rgba(0, 0, 0, 0.04);
}

/* Card actions */
.voicemail-actions {
  position: absolute;
  top: 1rem;
  right: 1rem;
  display: flex;
  gap: 0.35rem;
  opacity: 0;
  transition: opacity 0.2s ease;
}

.voicemail-card:hover .voicemail-actions {
  opacity: 1;
}

.voicemail-action-btn {
  width: 30px;
  height: 30px;
  border: none;
  background: var(--sage-100, #e8e5df);
  border-radius: 6px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-muted);
  transition: background 0.15s ease, color 0.15s ease;
}

.voicemail-action-btn:hover {
  background: var(--sage-200, #d5d0c8);
  color: var(--sage-800);
}

.voicemail-delete-btn:hover {
  background: #fde8e8;
  color: var(--error);
}

/* Caption */
.voicemail-caption {
  font-family: 'Playfair Display', serif;
  font-size: 1.05rem;
  font-weight: 500;
  color: var(--sage-800);
  margin: 0 0 1rem;
  padding-right: 4rem;
}

/* Audio player */
.voicemail-player {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.voicemail-play-btn {
  width: 40px;
  height: 40px;
  min-width: 40px;
  border: none;
  background: var(--sage-700, #4a5548);
  border-radius: 50%;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  transition: background 0.15s ease, transform 0.1s ease;
}

.voicemail-play-btn:hover {
  background: var(--sage-800, #3a4438);
  transform: scale(1.05);
}

.voicemail-play-btn:active {
  transform: scale(0.97);
}

.voicemail-play-btn svg {
  margin-left: 2px;
}

.voicemail-pause-icon {
  margin-left: 0 !important;
}

.voicemail-progress-wrap {
  flex: 1;
  min-width: 0;
}

.voicemail-progress-bar {
  height: 6px;
  background: var(--sage-100, #e8e5df);
  border-radius: 3px;
  cursor: pointer;
  position: relative;
  overflow: hidden;
}

.voicemail-progress-fill {
  height: 100%;
  background: var(--sage-500, #6b7a68);
  border-radius: 3px;
  width: 0%;
  transition: width 0.1s linear;
}

.voicemail-time {
  display: flex;
  justify-content: space-between;
  margin-top: 0.35rem;
  font-size: 0.75rem;
  color: var(--text-muted);
  font-variant-numeric: tabular-nums;
}

/* Date */
.voicemail-date {
  display: block;
  font-size: 0.8rem;
  color: var(--sage-400);
  margin-top: 0.75rem;
  font-style: italic;
}

/* Context note */
.voicemail-context {
  font-size: 0.88rem;
  color: var(--text-secondary, #6b7280);
  line-height: 1.6;
  margin: 0.5rem 0 0;
  padding-top: 0.75rem;
  border-top: 1px solid var(--sage-100, #e8e5df);
}

/* Upload area */
.voicemail-upload-area {
  text-align: center;
  margin-top: 1.5rem;
}

.voicemail-upload-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
}

.voicemail-upload-btn svg {
  opacity: 0.7;
}

.voicemail-upload-hint {
  font-size: 0.75rem;
  color: var(--text-muted);
  margin-top: 0.5rem;
  opacity: 0.7;
}

/* Upload status */
.voicemail-upload-status {
  text-align: center;
  padding: 0.75rem 1rem;
  margin-top: 1rem;
  border-radius: 8px;
  font-size: 0.88rem;
  background: var(--sage-50, #f5f4f0);
  color: var(--text-secondary);
}

.voicemail-upload-status.success {
  background: #ecf7ec;
  color: #2d6a2d;
}

.voicemail-upload-status.error {
  background: #fde8e8;
  color: var(--error, #c53030);
}

/* ── Mobile: always show voicemail actions ── */
@media (max-width: 768px) {
  .voicemail-actions {
    opacity: 1;
  }

  .voicemail-card {
    padding: 1.25rem;
  }

  .voicemail-caption {
    font-size: 0.95rem;
  }

  .voicemail-play-btn {
    width: 36px;
    height: 36px;
    min-width: 36px;
  }

  .voicemail-play-btn svg {
    width: 15px;
    height: 15px;
  }

  .tribute-section-subtext {
    font-size: 0.88rem;
  }
}

@media (max-width: 480px) {
  .voicemail-empty {
    padding: 2rem 1rem;
  }

  .voicemail-card {
    padding: 1rem;
  }

  .voicemail-player {
    gap: 0.5rem;
  }
}

/* ════════════════════════════════════════
   Daily Journal Prompts
   ════════════════════════════════════════ */

/* ── Prompt Card (journal.html) ── */

.daily-prompt-card {
  background: var(--nb-paper-bg);
  border: 1.5px solid var(--sage-300);
  border-radius: 12px;
  padding: 1.5rem;
  margin-bottom: 1.5rem;
  max-width: 700px;
  margin-left: auto;
  margin-right: auto;
}

.daily-prompt-card.prompt-completed {
  opacity: 0.65;
  border-color: var(--warm-200);
}

.prompt-top-row {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  flex-wrap: wrap;
  margin-bottom: 0.75rem;
}

.prompt-day-badge {
  display: inline-block;
  padding: 0.2rem 0.65rem;
  background: var(--sage-600);
  color: var(--white);
  border-radius: var(--radius-full);
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.02em;
}

.prompt-category {
  display: inline-block;
  padding: 0.2rem 0.6rem;
  background: var(--warm-200);
  color: var(--text-secondary);
  border-radius: var(--radius-full);
  font-size: 0.72rem;
  font-weight: 500;
}

.prompt-intensity-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  display: inline-block;
  flex-shrink: 0;
}

.prompt-text {
  font-family: 'Playfair Display', Georgia, serif;
  font-size: 1.1rem;
  color: var(--text-primary);
  line-height: 1.55;
  border-left: 3px solid var(--sage-400);
  padding-left: 1rem;
  background: rgba(255,255,255,0.4);
  border-radius: 0 6px 6px 0;
  padding: 0.75rem 1rem;
  margin-bottom: 1rem;
}

.prompt-progress-wrap {
  margin-bottom: 1rem;
}

.prompt-progress-label {
  font-size: 0.78rem;
  color: var(--text-muted);
  margin-bottom: 0.35rem;
}

.prompt-progress-bar {
  height: 4px;
  background: var(--sage-100);
  border-radius: var(--radius-full);
  overflow: hidden;
}

.prompt-progress-fill {
  height: 100%;
  background: var(--sage-400);
  border-radius: var(--radius-full);
  transition: width 0.4s ease;
}

.prompt-actions {
  display: flex;
  gap: 0.75rem;
  align-items: center;
  flex-wrap: wrap;
}

.prompt-completed-text {
  font-size: 0.88rem;
  color: var(--sage-600);
  font-weight: 500;
}

.prompt-celebration {
  text-align: center;
  padding: 1rem 0;
}

.prompt-celebration h3 {
  font-family: 'Playfair Display', Georgia, serif;
  font-size: 1.2rem;
  color: var(--sage-600);
  margin-bottom: 0.35rem;
}

.prompt-celebration p {
  font-size: 0.92rem;
  color: var(--text-secondary);
}

/* ── Prompt Inspiration Block (journal-new.html) ── */

.prompt-inspiration-block {
  background: var(--nb-paper-bg);
  border: 1.5px solid var(--sage-300);
  border-radius: 10px;
  padding: 1.25rem;
  margin-bottom: 1.5rem;
}

.prompt-inspiration-block .prompt-text {
  margin-bottom: 0;
}

/* ── Response Tabs ── */

.response-tabs {
  display: flex;
  border-bottom: 1.5px solid var(--warm-200);
  margin-bottom: 1.25rem;
  gap: 0;
}

.response-tab {
  padding: 0.6rem 1rem;
  font-size: 0.88rem;
  font-weight: 500;
  color: var(--text-muted);
  background: none;
  border: none;
  border-bottom: 2.5px solid transparent;
  cursor: pointer;
  transition: color 0.2s, border-color 0.2s;
  white-space: nowrap;
}

.response-tab:hover {
  color: var(--text-primary);
}

.response-tab.active {
  color: var(--sage-600);
  border-bottom-color: var(--sage-600);
}

.response-panel {
  display: none;
  animation: fadeInPanel 0.25s ease;
}

.response-panel.active {
  display: block;
}

@keyframes fadeInPanel {
  from { opacity: 0; transform: translateY(4px); }
  to   { opacity: 1; transform: translateY(0); }
}

/* ── Photo Panel ── */

.photo-upload-area {
  border: 2px dashed var(--warm-200);
  border-radius: 10px;
  padding: 2rem 1rem;
  text-align: center;
  cursor: pointer;
  transition: border-color 0.2s, background 0.2s;
  margin-bottom: 1rem;
}

.photo-upload-area:hover {
  border-color: var(--sage-400);
  background: rgba(90,132,99,0.04);
}

.photo-upload-area p {
  font-size: 0.92rem;
  color: var(--text-muted);
  margin: 0;
}

.photo-preview-wrap {
  margin-bottom: 1rem;
  text-align: center;
}

.photo-preview-wrap img {
  max-height: 240px;
  max-width: 100%;
  border-radius: 8px;
  border: 1px solid var(--warm-200);
}

.photo-preview-wrap .photo-remove-btn {
  display: inline-block;
  margin-top: 0.5rem;
  font-size: 0.82rem;
  color: var(--error, #c53030);
  cursor: pointer;
  background: none;
  border: none;
  text-decoration: underline;
}

/* ── Voice Panel ── */

.voice-record-area {
  text-align: center;
  padding: 1.5rem 1rem;
}

.record-btn {
  width: 64px;
  height: 64px;
  border-radius: 50%;
  background: var(--sage-600);
  color: var(--white);
  border: none;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: background 0.2s, transform 0.15s;
  margin-bottom: 0.5rem;
}

.record-btn:hover {
  background: var(--sage-500);
  transform: scale(1.05);
}

.record-btn.recording {
  background: var(--error, #c53030);
  animation: recordBtnPulse 1.2s ease-in-out infinite;
}

@keyframes recordBtnPulse {
  0%, 100% { transform: scale(1); }
  50%      { transform: scale(1.08); }
}

.record-btn svg {
  width: 24px;
  height: 24px;
  fill: currentColor;
}

.recording-indicator {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.88rem;
  color: var(--error, #c53030);
  font-variant-numeric: tabular-nums;
  margin-top: 0.25rem;
}

.recording-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--error, #c53030);
  animation: recordPulse 1s ease-in-out infinite;
}

@keyframes recordPulse {
  0%, 100% { opacity: 1; transform: scale(1); }
  50%      { opacity: 0.4; transform: scale(0.8); }
}

.voice-preview {
  margin-top: 1rem;
}

.voice-preview audio {
  width: 100%;
  height: 40px;
  border-radius: 8px;
}

.voice-rerecord-btn {
  display: inline-block;
  margin-top: 0.5rem;
  font-size: 0.82rem;
  color: var(--sage-600);
  cursor: pointer;
  background: none;
  border: none;
  text-decoration: underline;
}

.caption-input {
  margin-top: 1rem;
}

.caption-input textarea {
  width: 100%;
  min-height: 60px;
  resize: vertical;
  border: 1.5px solid var(--warm-200);
  border-radius: 8px;
  padding: 0.6rem 0.75rem;
  font-size: 0.92rem;
  font-family: 'Inter', sans-serif;
}

.caption-input label {
  font-size: 0.82rem;
  color: var(--text-muted);
  margin-bottom: 0.25rem;
  display: block;
}

/* ── Entry Enhancements (journal.html list) ── */

.journal-day-badge {
  display: inline-block;
  padding: 0.12rem 0.45rem;
  background: var(--sage-500);
  color: var(--white);
  border-radius: var(--radius-full);
  font-size: 0.65rem;
  font-weight: 600;
  margin-left: 0.4rem;
  vertical-align: middle;
}

.journal-entry-thumb {
  margin-top: 0.5rem;
}

.journal-entry-thumb img {
  max-height: 200px;
  max-width: 100%;
  border-radius: 8px;
  border: 1px solid var(--warm-200);
}

.journal-entry-audio {
  margin-top: 0.5rem;
}

.journal-entry-audio audio {
  width: 100%;
  height: 36px;
  border-radius: 6px;
}

/* ── Dashboard Prompt Teaser ── */

.prompt-teaser-card {
  background: var(--nb-paper-bg);
  border: 1.5px solid var(--sage-300);
  border-radius: 12px;
  padding: 1.25rem 1.5rem;
  max-width: 700px;
  margin: 0 auto 1.5rem;
  display: flex;
  align-items: center;
  gap: 1rem;
  flex-wrap: wrap;
}

.prompt-teaser-card .prompt-day-badge {
  flex-shrink: 0;
}

.prompt-teaser-text {
  flex: 1;
  font-size: 0.94rem;
  color: var(--text-secondary);
  min-width: 140px;
}

.prompt-teaser-card .btn {
  flex-shrink: 0;
}

.prompt-teaser-card.prompt-completed {
  opacity: 0.7;
  border-color: var(--warm-200);
}

/* ── Prompt text in journal entry cards ── */

.journal-entry-prompt {
  font-size: 0.85rem;
  color: var(--text-muted);
  font-style: italic;
  border-left: 2px solid var(--sage-300);
  padding-left: 0.75rem;
  margin: 0.35rem 0 0.25rem;
}

/* ── Responsive: Prompts ── */

@media (max-width: 480px) {
  .daily-prompt-card {
    padding: 1.15rem;
  }

  .prompt-text {
    font-size: 1rem;
    padding: 0.6rem 0.85rem;
  }

  .response-tabs {
    flex-wrap: wrap;
  }

  .response-tab {
    font-size: 0.82rem;
    padding: 0.5rem 0.75rem;
  }

  .prompt-teaser-card {
    padding: 1rem 1.15rem;
    gap: 0.75rem;
  }

  .prompt-teaser-text {
    font-size: 0.88rem;
  }

  .record-btn {
    width: 56px;
    height: 56px;
  }

  .voice-record-area {
    padding: 1rem 0.5rem;
  }
}
