/* =====================
   RESET & BASE
   ===================== */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --font-display: 'Fraunces', Georgia, serif;
  --font-ui: 'Inter', system-ui, -apple-system, 'Segoe UI', Arial, sans-serif;

  --bg: #f8faf7;
  --surface: #ffffff;
  --surface-alt: #eef3ec;

  --text: #1b2a20;
  --text-light: #5f6f63;

  --accent: #3f7d52;
  --accent-dark: #2f6340;
  --accent-soft: #e6f2e8;
  --ink-deep: #1e3527;
  --muted: #93a398;

  --border: #e2eade;
  --border-strong: #cbdcc6;

  /* Tykkayssydan on oma varilinjansa, ei sidottu korostusvariin */
  --like: #c0507a;
  --like-strong: #b03560;
  --like-border: #e8c0c8;
  --like-bg: #fde8f0;

  --shadow: rgba(27, 42, 32, 0.07);
  --shadow-sm: 0 1px 2px rgba(27, 42, 32,.05), 0 2px 6px rgba(27, 42, 32,.04);
  --shadow-md: 0 2px 6px rgba(27, 42, 32,.05), 0 10px 24px rgba(27, 42, 32,.07);
  --shadow-lg: 0 4px 10px rgba(27, 42, 32,.06), 0 24px 48px rgba(27, 42, 32,.12);

  --radius-sm: 10px;
  --radius: 16px;
  --radius-lg: 24px;
  --radius-pill: 999px;

  /* Vanhat nimet kaytossa laajalti — pidetaan aliaksina */
  --cream: var(--bg);
  --card-bg: var(--surface);
}

html { scroll-behavior: smooth; }

/* Kiinnitetty header peittaisi muuten ankkurikohteen ylareunan */
[id] { scroll-margin-top: 120px; }

body {
  font-family: var(--font-ui);
  background: var(--bg);
  color: var(--text);
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

h1, h2, h3 {
  font-family: var(--font-display);
  font-weight: 600;
  letter-spacing: -0.015em;
  line-height: 1.25;
}

:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

.container {
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 24px;
}

/* =====================
   HEADER
   ===================== */
header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(255, 255, 255, 0.88);
  backdrop-filter: saturate(180%) blur(14px);
  -webkit-backdrop-filter: saturate(180%) blur(14px);
  border-bottom: 1px solid var(--border);
  padding: 14px 24px 12px;
  text-align: center;
}

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

.logo {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  margin-bottom: 2px;
}

.logo-icon { font-size: 2.4rem; }
.logo-svg  { height: 52px; width: auto; display: block; }

.pixel-logo {
  font-family: var(--font-display);
  font-size: 2rem;
  font-weight: 600;
  color: var(--ink-deep);
  letter-spacing: -0.03em;
  line-height: 1.1;
}
.logo-heart { color: var(--accent); margin-right: 6px; }
.logo-fi    { color: var(--muted); font-size: 0.55em; font-weight: 400; letter-spacing: 0; }

header h1 {
  font-size: 2rem;
  color: var(--ink-deep);
}

.tagline {
  color: var(--text-light);
  font-size: 0.9rem;
  margin-bottom: 10px;
}

nav { display: flex; justify-content: center; gap: 28px; flex-wrap: wrap; }

nav a {
  color: var(--text-light);
  text-decoration: none;
  font-size: 0.8rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  font-weight: 600;
  font-family: var(--font-ui);
  transition: color 0.2s;
}

nav a:hover { color: var(--accent); }


.btn {
  display: inline-block;
  background: var(--accent);
  color: #fff;
  padding: 13px 32px;
  border-radius: var(--radius-pill);
  text-decoration: none;
  font-family: var(--font-ui);
  font-size: 0.95rem;
  font-weight: 600;
  border: none;
  cursor: pointer;
  box-shadow: var(--shadow-sm);
  transition: background 0.2s, transform 0.15s, box-shadow 0.2s;
}

.btn:hover { background: var(--accent-dark); transform: translateY(-2px); box-shadow: var(--shadow-md); }

/* =====================
   SEARCH & FILTERS
   ===================== */
.controls {
  padding: 28px 24px 24px;
  background: var(--bg);
  border-bottom: 1px solid var(--border);
}

.controls .container { display: flex; flex-direction: column; align-items: center; gap: 16px; }

#search {
  width: 100%;
  max-width: 500px;
  padding: 12px 20px;
  border: 1px solid var(--border);
  border-radius: var(--radius-pill);
  font-size: 0.95rem;
  font-family: var(--font-ui);
  background: var(--surface);
  color: var(--text);
  outline: none;
  box-shadow: var(--shadow-sm);
  transition: border-color 0.2s, box-shadow 0.2s;
}

#search::placeholder { color: var(--muted); }
#search:focus { border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-soft); }

.filters { display: flex; gap: 8px; flex-wrap: wrap; justify-content: center; }

.filter-btn {
  padding: 8px 18px;
  border: 1px solid var(--border);
  border-radius: var(--radius-pill);
  background: var(--surface);
  color: var(--text-light);
  font-family: var(--font-ui);
  font-size: 0.85rem;
  font-weight: 500;
  cursor: pointer;
  transition: background 0.18s, color 0.18s, border-color 0.18s, transform 0.18s;
}

.filter-btn:hover { border-color: var(--accent); color: var(--accent); transform: translateY(-1px); }

.filter-btn.active {
  background: var(--accent);
  border-color: var(--accent);
  color: #fff;
}

.sub-filters { margin-top: 2px; min-height: 0; }

.sub-filter-btn {
  padding: 5px 14px;
  border: 1px solid transparent;
  border-radius: var(--radius-pill);
  background: var(--surface-alt);
  color: var(--text-light);
  font-family: var(--font-ui);
  font-size: 0.78rem;
  cursor: pointer;
  transition: background 0.18s, color 0.18s;
}

.sub-filter-btn:hover { background: var(--accent-soft); color: var(--accent-dark); }

.sub-filter-btn.active {
  background: var(--ink-deep);
  border-color: var(--ink-deep);
  color: #fff;
}

/* =====================
   RECIPE GRID
   ===================== */
.recipe-section { padding: 48px 24px; }

.recipe-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 28px;
}

/* Listanakyma: sama kortti-DOM, mutta tiivis rivi ilman kuvia.
   Toteutettu pelkalla luokanvaihdolla, jotta SSR-kortit ja JS:n
   renderoimat kortit toimivat samalla tavalla. */
.recipe-grid.list-view {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.list-view .recipe-card {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 11px 16px;
  border-radius: var(--radius-sm);
  overflow: visible;
}

.list-view .recipe-card:hover { transform: none; background: var(--accent-soft); }

.list-view .card-img {
  background: none;
  padding: 0;
  height: auto;
  width: 28px;
  flex-shrink: 0;
  font-size: 1.4rem;
  line-height: 1;
}
.list-view .card-has-photo img { display: none; }
.list-view .card-has-photo::after { content: '🍽'; }

.list-view .card-body {
  padding: 0;
  flex: 1;
  min-width: 0;
  display: flex;
  align-items: center;
  gap: 12px;
}

.list-view .card-body h3 {
  font-size: 1rem;
  margin: 0;
  flex: 1;
  min-width: 0;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.list-view .card-body > p { display: none; }
.list-view .category-tag { order: 2; margin: 0; flex-shrink: 0; }
.list-view .card-meta { order: 3; margin: 0; flex-shrink: 0; font-size: 0.78rem; }
.list-view .card-actions { order: 4; margin: 0; flex-shrink: 0; }
.list-view .btn-outline { display: none; }

@media (max-width: 700px) {
  .list-view .category-tag, .list-view .card-meta { display: none; }
}

/* Ruudukko/lista-valitsin */
.view-toggle {
  display: inline-flex;
  gap: 2px;
  padding: 3px;
  background: var(--surface-alt);
  border-radius: var(--radius-pill);
}

.view-btn {
  padding: 6px 16px;
  border: none;
  border-radius: var(--radius-pill);
  background: transparent;
  color: var(--text-light);
  font-family: var(--font-ui);
  font-size: 0.82rem;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.18s, color 0.18s;
}

.view-btn:hover { color: var(--text); }
.view-btn.active { background: var(--surface); color: var(--accent-dark); box-shadow: var(--shadow-sm); }

.controls-row {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 14px;
  flex-wrap: wrap;
}

.recipe-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  transition: transform 0.22s ease, box-shadow 0.22s ease, border-color 0.22s ease;
  cursor: pointer;
}

.recipe-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-md);
  border-color: var(--border-strong);
}

.card-img {
  background: linear-gradient(135deg, var(--surface-alt), var(--border));
  font-size: 4rem;
  text-align: center;
  padding: 32px 0;
}

.card-has-photo {
  padding: 0;
  height: 200px;
  overflow: hidden;
}

.card-has-photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.4s ease;
}

.recipe-card:hover .card-has-photo img { transform: scale(1.04); }

.card-body { padding: 20px; }

.category-tag {
  display: inline-block;
  background: var(--accent-soft);
  color: var(--accent-dark);
  font-size: 0.7rem;
  font-family: var(--font-ui);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  padding: 4px 10px;
  border-radius: var(--radius-pill);
  margin-bottom: 10px;
}

.card-body h3 {
  font-size: 1.2rem;
  color: var(--ink-deep);
  margin-bottom: 8px;
}

.card-body p {
  font-size: 0.92rem;
  color: var(--text-light);
  margin-bottom: 14px;
}

.card-meta {
  display: flex;
  gap: 16px;
  font-size: 0.82rem;
  color: var(--muted);
  font-family: var(--font-ui);
  margin-bottom: 16px;
}

.btn-outline {
  padding: 9px 20px;
  border: 1px solid var(--border);
  border-radius: var(--radius-pill);
  background: var(--surface);
  color: var(--accent-dark);
  font-family: var(--font-ui);
  font-size: 0.85rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s;
}

.btn-outline:hover {
  background: var(--accent);
  color: #fff;
}

.no-results {
  text-align: center;
  color: var(--text-light);
  font-style: italic;
  font-size: 1.1rem;
  padding: 40px 0;
}

/* =====================
   ABOUT
   ===================== */
.about {
  background: var(--ink-deep);
  padding: 64px 24px;
  color: #ded2c6;
}

.about-inner {
  display: flex;
  align-items: center;
  gap: 36px;
  flex-wrap: wrap;
}

.about-emoji { font-size: 5rem; }

.about h2 {
  font-size: 1.9rem;
  color: #fff;
  margin-bottom: 12px;
}

.about p { font-size: 1rem; line-height: 1.8; max-width: 680px; }


/* =====================
   FOOTER
   ===================== */
footer {
  background: var(--ink-deep);
  color: #9a8b7d;
  text-align: center;
  padding: 24px;
  border-top: 1px solid rgba(255,255,255,0.06);
  font-family: var(--font-ui);
  font-size: 0.85rem;
}

/* =====================
   MODAL
   ===================== */
.modal-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(24, 16, 10, 0.5);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
  z-index: 1000;
  justify-content: center;
  align-items: center;
  padding: 20px;
}

.modal-overlay.open { display: flex; }

.modal {
  background: var(--surface);
  border-radius: var(--radius-lg);
  max-width: 600px;
  width: 100%;
  max-height: 85vh;
  overflow-y: auto;
  padding: 36px;
  position: relative;
  box-shadow: var(--shadow-lg);
  animation: modalIn 0.22s ease;
}

@keyframes modalIn {
  from { opacity: 0; transform: translateY(12px) scale(0.985); }
  to   { opacity: 1; transform: none; }
}

.modal-close {
  position: absolute;
  top: 16px;
  right: 20px;
  background: none;
  border: none;
  font-size: 1.4rem;
  cursor: pointer;
  color: var(--text-light);
  transition: color 0.2s;
}

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

.modal h2 { color: var(--ink-deep); font-size: 1.8rem; margin-bottom: 6px; }
.modal .modal-meta { color: var(--text-light); font-size: 0.9rem; font-family: var(--font-ui); margin-bottom: 20px; }
.modal .modal-emoji { font-size: 3.5rem; margin-bottom: 16px; display: block; }
.modal h3 { color: var(--ink-deep); margin: 20px 0 10px; font-size: 1.1rem; }
.modal ul, .modal ol { padding-left: 22px; color: var(--text); }
.modal li { margin-bottom: 6px; font-size: 0.97rem; }

/* =====================
   IMAGE GALLERY
   ===================== */
.img-gallery {
  display: flex;
  gap: 8px;
  margin-bottom: 16px;
  overflow-x: auto;
  border-radius: 8px;
}

.img-gallery img {
  width: 180px;
  height: 140px;
  object-fit: cover;
  border-radius: 8px;
  flex-shrink: 0;
  cursor: zoom-in;
  transition: opacity 0.15s;
}
.img-gallery img:hover { opacity: 0.88; }

/* =====================
   LIGHTBOX
   ===================== */
#lightboxOverlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.92);
  z-index: 9999;
  align-items: center;
  justify-content: center;
  animation: lbFade 0.18s ease;
}
#lightboxOverlay.open { display: flex; }
#lightboxImg {
  max-width: 92vw;
  max-height: 90vh;
  object-fit: contain;
  border-radius: 6px;
  box-shadow: 0 8px 40px rgba(0,0,0,0.6);
}
.lightbox-close {
  position: fixed;
  top: 18px;
  right: 22px;
  background: rgba(255,255,255,0.15);
  border: none;
  color: #fff;
  font-size: 1.6rem;
  width: 42px;
  height: 42px;
  border-radius: 50%;
  cursor: pointer;
  line-height: 1;
  transition: background 0.15s;
}
.lightbox-close:hover { background: rgba(255,255,255,0.3); }
@keyframes lbFade { from { opacity:0 } to { opacity:1 } }

/* =====================
   SUBMIT FORM (in modal)
   ===================== */
.form-group {
  margin-bottom: 14px;
}

.form-group label {
  display: block;
  font-family: var(--font-ui);
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--text-light);
  text-transform: uppercase;
  letter-spacing: 0.06em;
  margin-bottom: 6px;
}

.form-group input,
.form-group select,
.form-group textarea {
  width: 100%;
  padding: 10px 13px;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  font-size: 0.95rem;
  font-family: var(--font-ui);
  background: var(--surface);
  color: var(--text);
  outline: none;
  transition: border-color 0.2s, box-shadow 0.2s;
  resize: vertical;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus { border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-soft); }

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


.submit-btn {
  width: 100%;
  padding: 13px;
  background: var(--accent);
  color: #fff;
  border: none;
  border-radius: var(--radius-sm);
  font-family: var(--font-ui);
  font-size: 0.98rem;
  font-weight: 600;
  cursor: pointer;
  box-shadow: var(--shadow-sm);
  transition: all 0.2s;
  margin-top: 8px;
}

.submit-btn:hover { background: var(--accent-dark); transform: translateY(-2px); }

.sub-error {
  color: #c04040;
  font-size: 0.9rem;
  margin-top: 8px;
  display: none;
}

.add-post-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 11px 26px;
  background: var(--accent);
  color: #fff;
  border: none;
  border-radius: var(--radius-pill);
  font-family: var(--font-ui);
  font-size: 0.92rem;
  font-weight: 600;
  cursor: pointer;
  box-shadow: var(--shadow-sm);
  transition: all 0.2s;
}

.add-post-btn:hover { background: var(--accent-dark); transform: translateY(-2px); box-shadow: var(--shadow-md); }

/* =====================
   IMAGE UPLOAD SLOTS
   ===================== */
.img-upload-slots {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

.img-upload-slot {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
}

.img-upload-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 14px;
  border: 2px dashed var(--border);
  border-radius: 8px;
  color: var(--text-light);
  font-family: var(--font-ui);
  font-size: 0.82rem;
  cursor: pointer;
  transition: all 0.2s;
  background: #fff;
  white-space: nowrap;
  user-select: none;
}

.img-upload-btn:hover {
  border-color: var(--accent);
  color: var(--accent);
}

.img-upload-btn.has-image {
  border-color: var(--accent);
  border-style: solid;
  color: var(--accent-dark);
}

.img-preview {
  width: 100px;
  height: 72px;
  object-fit: cover;
  border-radius: 6px;
  border: 1px solid var(--border);
  display: none;
}

/* =====================
   LANGUAGE TOGGLE
   ===================== */
.lang-toggle {
  padding: 6px 14px;
  border: 1px solid var(--border);
  border-radius: var(--radius-pill);
  background: var(--surface);
  color: var(--text-light);
  font-family: var(--font-ui);
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  cursor: pointer;
  transition: all 0.2s;
}
.lang-toggle:hover { background: var(--surface-alt); color: var(--text); border-color: var(--muted); }

/* =====================
   CARD AUTHOR + ACTIONS
   ===================== */
.validated-badge {
  display: inline-block;
  background: #d4edda;
  color: #2d6a3f;
  font-size: 0.72rem;
  font-style: normal;
  font-weight: bold;
  padding: 1px 7px;
  border-radius: 10px;
  margin-left: 4px;
  vertical-align: middle;
}
.guest-badge {
  display: inline-block;
  background: #f0e8dc;
  color: #7a5c3e;
  font-size: 0.72rem;
  font-style: normal;
  font-family: monospace;
  padding: 1px 7px;
  border-radius: 10px;
  margin-left: 4px;
  vertical-align: middle;
}
.card-author {
  font-size: 0.8rem !important;
  color: var(--muted) !important;
  font-family: var(--font-ui);
  margin-bottom: 4px !important;
  font-style: italic;
}

.card-actions {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 14px;
}

.like-row {
  display: flex;
  align-items: center;
  gap: 6px;
}

.like-btn {
  padding: 7px 14px;
  border: 1px solid var(--like-border);
  border-radius: var(--radius-pill);
  background: var(--surface);
  color: var(--like);
  font-family: var(--font-ui);
  font-size: 0.82rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s;
  white-space: nowrap;
}
.like-btn:hover { background: var(--like-bg); border-color: var(--like); }
.like-btn.liked { background: var(--like-bg); border-color: var(--like); color: var(--like-strong); }

.like-count {
  font-family: var(--font-ui);
  font-size: 0.85rem;
  color: var(--text-light);
  font-weight: bold;
  min-width: 16px;
}

.modal-like-row {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 20px;
}

/* =====================
   POST BODY (non-recipe)
   ===================== */
.post-body { color: var(--text); line-height: 1.8; }
.post-body p { margin-bottom: 12px; }
.post-body ul, .post-body ol { padding-left: 22px; margin-bottom: 12px; }
.post-body li { margin-bottom: 6px; }
.post-body strong { color: var(--ink-deep); }

.empty-note { color: var(--text-light); font-style: italic; font-size: 0.93rem; }

/* =====================
   COMMENTS
   ===================== */
.comments-section {
  margin-top: 28px;
  padding-top: 24px;
  border-top: 1px solid var(--border);
}
.comments-section h3 { color: var(--ink-deep); font-size: 1.1rem; margin-bottom: 14px; }

.comment {
  background: var(--surface-alt);
  border-radius: 10px;
  padding: 12px 16px;
  margin-bottom: 10px;
}
.comment-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 6px;
  font-family: var(--font-ui);
  font-size: 0.85rem;
}
.comment-header strong { color: var(--ink-deep); }
.comment-header span { color: var(--text-light); font-size: 0.78rem; }
.comment p { font-size: 0.93rem; color: var(--text); margin: 0; }

.comment-form {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-top: 14px;
}
.comment-form input,
.comment-form textarea {
  padding: 10px 14px;
  border: 1px solid var(--border);
  border-radius: 8px;
  font-size: 0.93rem;
  font-family: var(--font-ui);
  background: #fff;
  color: var(--text);
  outline: none;
  transition: border-color 0.2s;
  resize: vertical;
}
.comment-form input:focus,
.comment-form textarea:focus { border-color: var(--accent); }

.captcha-row {
  display: flex;
  align-items: center;
  gap: 12px;
  background: var(--surface-alt);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 10px 14px;
}
.captcha-label {
  font-family: var(--font-ui);
  font-size: 0.9rem;
  font-weight: bold;
  color: var(--ink-deep);
  flex: 1;
}
.captcha-row input {
  padding: 7px 10px !important;
  border-radius: 6px !important;
  text-align: center;
  font-weight: bold;
}

/* =====================
   USER AREA (header)
   ===================== */
.user-area {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  margin: 8px 0;
  flex-wrap: wrap;
}

.user-greeting {
  color: var(--text-light);
  font-family: var(--font-ui);
  font-size: 0.85rem;
}

.user-greeting strong { color: var(--text); }

.user-btn {
  padding: 6px 16px;
  border: 1px solid var(--border);
  border-radius: var(--radius-pill);
  background: var(--surface);
  color: var(--text-light);
  font-family: var(--font-ui);
  font-size: 0.8rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s;
}

.user-btn:hover {
  background: var(--surface-alt);
  color: var(--text);
  border-color: var(--muted);
}

.register-btn {
  background: var(--accent);
  border-color: var(--accent);
  color: #fff;
}

.register-btn:hover {
  background: var(--accent-dark);
  border-color: var(--accent-dark);
}

/* =====================
   SEARCH ROW
   ===================== */
.search-row {
  display: flex;
  gap: 10px;
  width: 100%;
  max-width: 600px;
  align-items: center;
}

.search-row #search { flex: 1; }

.likes-filter-btn {
  padding: 8px 18px;
  border: 1px solid var(--like-border);
  border-radius: var(--radius-pill);
  background: var(--surface);
  color: var(--like);
  font-family: var(--font-ui);
  font-size: 0.85rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s;
  white-space: nowrap;
}

.likes-filter-btn:hover {
  background: var(--like-bg);
  border-color: var(--like);
}

.likes-filter-btn.active {
  background: var(--like-bg);
  border-color: var(--like);
  color: var(--like-strong);
}

/* =====================
   AUTH MODAL
   ===================== */
.auth-error {
  color: #c04040;
  font-size: 0.9rem;
  margin-top: 8px;
  display: none;
}

.auth-switch {
  text-align: center;
  margin-top: 14px;
  font-family: var(--font-ui);
  font-size: 0.85rem;
  color: var(--accent);
  cursor: pointer;
  transition: color 0.2s;
}

.auth-switch:hover {
  color: var(--accent-dark);
  text-decoration: underline;
}

/* =====================
   RESPONSIVE
   ===================== */
@media (max-width: 600px) {
  header h1 { font-size: 1.7rem; }
  .about-inner { flex-direction: column; text-align: center; }
  .recipe-grid { grid-template-columns: 1fr; }
  nav { gap: 16px; }
  .form-row { grid-template-columns: 1fr; }
  .search-row { flex-direction: column; }
  .likes-filter-btn { width: 100%; }
  .user-area { font-size: 0.78rem; }
}

/* =====================
   PRINT
   ===================== */
@media print {
  header, footer, nav, .controls, .card-actions, .modal-overlay,
  .add-post-btn, .open-spa-btn, .print-btn, .back-btn,
  .comment-form, .modal-like-row, .lightbox-overlay,
  .breadcrumb, #authOverlay, #submitOverlay { display: none !important; }

  body { background: #fff; color: #000; font-size: 11pt; }
  .recipe-page, .modal { max-width: 100%; padding: 0; box-shadow: none; }
  h1, h2 { color: #000; }
  img { max-width: 100%; page-break-inside: avoid; }
  ul, ol { page-break-inside: avoid; }
}
