/* ============================================================
   CoffeeColumn — Main Stylesheet
   Color system: 5-layer palette from coffee-colors-code.docx
   ============================================================ */

/* 1. Custom Properties ---------------------------------------- */
:root {
  /* Primary brand */
  --teal:        #1BA39C;
  --teal-dark:   #158a84;
  --teal-light:  #d0f0ee;
  --brown:       #4B2E2B;
  --brown-dark:  #3A241F;

  /* Secondary accent */
  --cream:       #F5E9D3;
  --mocha:       #7A4F3A;
  --mocha-dark:  #5e3c2a;
  --mint:        #A8E6CF;

  /* Neutral */
  --charcoal:    #2A2A2A;
  --gray:        #EAEAEA;
  --warm-white:  #FFFCF7;
  --divider:     #D0D0D0;
  --shadow-br:   #3A241F;

  /* Semantic */
  --success:     #2ECC71;
  --warning:     #F1C40F;
  --error:       #E74C3C;

  /* UI */
  --font-head:   'Playfair Display', Georgia, serif;
  --font-body:   'Lato', system-ui, sans-serif;
  --radius:      8px;
  --radius-lg:   14px;
  --shadow-sm:   0 1px 4px rgba(58,36,31,.10);
  --shadow-md:   0 4px 16px rgba(58,36,31,.14);
  --shadow-lg:   0 8px 32px rgba(58,36,31,.18);
  --transition:  .18s ease;
  --container:   1140px;
}

/* 2. Reset + Base -------------------------------------------- */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html { font-size: 16px; scroll-behavior: smooth; }

body {
  font-family: var(--font-body);
  background: var(--warm-white);
  color: var(--charcoal);
  line-height: 1.7;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

img { max-width: 100%; display: block; }
a  { color: var(--teal); text-decoration: none; transition: color var(--transition); }
a:hover { color: var(--teal-dark); }

/* 3. Typography ---------------------------------------------- */
h1, h2, h3, h4 {
  font-family: var(--font-head);
  color: var(--brown);
  line-height: 1.25;
}
h1 { font-size: clamp(1.8rem, 4vw, 2.8rem); }
h2 { font-size: clamp(1.4rem, 3vw, 2rem); }
h3 { font-size: clamp(1.1rem, 2vw, 1.4rem); }
h4 { font-size: 1.05rem; }

p { margin-bottom: .9rem; }
p:last-child { margin-bottom: 0; }

/* 4. Layout -------------------------------------------------- */
.container {
  width: 100%;
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 1.25rem;
}

.page-body { flex: 1; padding: 2.5rem 0 4rem; }

/* 5. Navigation ---------------------------------------------- */
.nav {
  background: var(--brown);
  box-shadow: 0 2px 8px rgba(0,0,0,.25);
  position: sticky;
  top: 0;
  z-index: 100;
}

.nav__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 62px;
  gap: 1.5rem;
}

.nav__brand {
  font-family: var(--font-head);
  font-size: 1.45rem;
  font-weight: 700;
  color: var(--cream) !important;
  letter-spacing: .02em;
  white-space: nowrap;
}
.nav__brand:hover { color: var(--mint) !important; }
.nav__brand-icon { margin-right: .35rem; }

.nav__links {
  display: flex;
  align-items: center;
  gap: .25rem;
  list-style: none;
  flex: 1;
}

.nav__links a {
  color: rgba(245,233,211,.82);
  font-size: .9rem;
  font-weight: 500;
  padding: .4rem .75rem;
  border-radius: var(--radius);
  transition: background var(--transition), color var(--transition);
}
.nav__links a:hover,
.nav__links a.active {
  background: rgba(255,255,255,.12);
  color: var(--cream);
}

.nav__brew-menu { position: relative; }
.nav__brew-menu:hover .brew-dropdown { display: block; }

.brew-dropdown {
  display: none;
  position: absolute;
  top: 100%;
  left: 0;
  background: var(--brown-dark);
  border-radius: var(--radius);
  min-width: 170px;
  padding: .4rem 0;
  box-shadow: var(--shadow-lg);
  z-index: 200;
}
.brew-dropdown a {
  display: block;
  padding: .45rem 1rem;
  font-size: .85rem;
  color: rgba(245,233,211,.85) !important;
  border-radius: 0;
}
.brew-dropdown a:hover { background: rgba(255,255,255,.1); color: var(--cream) !important; }

.nav__auth {
  display: flex;
  gap: .5rem;
  flex-shrink: 0;
}

/* 6. Buttons ------------------------------------------------- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: .4rem;
  padding: .55rem 1.25rem;
  border-radius: var(--radius);
  font-family: var(--font-body);
  font-size: .9rem;
  font-weight: 600;
  cursor: pointer;
  border: 2px solid transparent;
  transition: all var(--transition);
  line-height: 1;
  white-space: nowrap;
}
.btn-primary {
  background: var(--teal);
  color: #fff;
  border-color: var(--teal);
}
.btn-primary:hover {
  background: var(--teal-dark);
  border-color: var(--teal-dark);
  color: #fff;
  transform: translateY(-1px);
  box-shadow: var(--shadow-sm);
}
.btn-secondary {
  background: var(--mocha);
  color: #fff;
  border-color: var(--mocha);
}
.btn-secondary:hover {
  background: var(--mocha-dark);
  border-color: var(--mocha-dark);
  color: #fff;
  transform: translateY(-1px);
}
.btn-outline {
  background: transparent;
  color: var(--cream);
  border-color: rgba(245,233,211,.5);
}
.btn-outline:hover {
  background: rgba(245,233,211,.12);
  border-color: var(--cream);
  color: var(--cream);
}
.btn-sm { padding: .35rem .85rem; font-size: .82rem; }
.btn-lg { padding: .75rem 2rem; font-size: 1rem; }

/* 7. Hero ---------------------------------------------------- */
.hero {
  background: var(--brown);
  background-image: linear-gradient(135deg, var(--brown) 0%, #2d1a18 100%);
  color: var(--cream);
  padding: 5rem 0 4.5rem;
  text-align: center;
  position: relative;
  overflow: hidden;
}
.hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background: url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%23ffffff' fill-opacity='0.03'%3E%3Ccircle cx='30' cy='30' r='20'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
  pointer-events: none;
}
.hero__tag {
  display: inline-block;
  background: rgba(27,163,156,.25);
  border: 1px solid rgba(27,163,156,.5);
  color: var(--mint);
  font-size: .8rem;
  font-weight: 700;
  letter-spacing: .12em;
  text-transform: uppercase;
  padding: .3rem .9rem;
  border-radius: 999px;
  margin-bottom: 1.25rem;
}
.hero h1 {
  color: var(--cream);
  font-size: clamp(2.2rem, 5vw, 3.5rem);
  max-width: 680px;
  margin: 0 auto .75rem;
}
.hero__sub {
  font-size: 1.1rem;
  color: rgba(245,233,211,.75);
  max-width: 520px;
  margin: 0 auto 2rem;
}
.hero__actions { display: flex; gap: .75rem; justify-content: center; flex-wrap: wrap; }

/* 8. Section headers ----------------------------------------- */
.section-header {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 1.75rem;
  padding-bottom: .75rem;
  border-bottom: 2px solid var(--divider);
}
.section-header h2 { margin: 0; }
.section-header a { font-size: .88rem; color: var(--teal); font-weight: 600; }

.section { margin-bottom: 4rem; }

/* 9. Room Cards ---------------------------------------------- */
.rooms-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(310px, 1fr));
  gap: 1.5rem;
}

.room-card {
  background: #fff;
  border-radius: var(--radius-lg);
  border: 1px solid var(--divider);
  border-left: 4px solid var(--teal);
  padding: 1.5rem;
  transition: box-shadow var(--transition), transform var(--transition);
  display: flex;
  flex-direction: column;
}
.room-card:hover {
  box-shadow: var(--shadow-md);
  transform: translateY(-3px);
}
.room-card__icon {
  font-size: 1.8rem;
  margin-bottom: .6rem;
}
.room-card__name {
  font-family: var(--font-head);
  font-size: 1.2rem;
  color: var(--brown);
  margin-bottom: .4rem;
}
.room-card__desc {
  font-size: .9rem;
  color: #555;
  flex: 1;
  margin-bottom: 1rem;
  line-height: 1.6;
}
.room-card__footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: auto;
  padding-top: .75rem;
  border-top: 1px solid var(--gray);
}
.room-card__meta { font-size: .8rem; color: #888; }
.room-card__bean {
  font-size: .78rem;
  background: var(--cream);
  color: var(--mocha);
  padding: .2rem .55rem;
  border-radius: 999px;
  font-weight: 700;
}

/* Room icons map */
.icon-quiet-table::before   { content: '🤫'; }
.icon-fiction-booth::before { content: '📖'; }
.icon-poetry-counter::before{ content: '✍️'; }
.icon-debate-table::before  { content: '🗣️'; }
.icon-midnight-table::before{ content: '🌙'; }

/* 10. Post Cards --------------------------------------------- */
.posts-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(290px, 1fr));
  gap: 1.25rem;
}

.post-card {
  background: #fff;
  border-radius: var(--radius-lg);
  border: 1px solid var(--divider);
  padding: 1.25rem 1.4rem;
  transition: box-shadow var(--transition), transform var(--transition);
  display: flex;
  flex-direction: column;
}
.post-card:hover { box-shadow: var(--shadow-md); transform: translateY(-2px); }

.post-card__badges { display: flex; gap: .4rem; flex-wrap: wrap; margin-bottom: .65rem; }
.post-card__title {
  font-family: var(--font-head);
  font-size: 1.05rem;
  color: var(--charcoal);
  margin-bottom: .4rem;
  line-height: 1.35;
}
.post-card__title a { color: inherit; }
.post-card__title a:hover { color: var(--teal); }
.post-card__excerpt {
  font-size: .875rem;
  color: #666;
  flex: 1;
  margin-bottom: .85rem;
  line-height: 1.55;
  overflow: hidden;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
}
.post-card__footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: .78rem;
  color: #999;
  padding-top: .65rem;
  border-top: 1px solid var(--gray);
}
.post-card__author { color: var(--mocha); font-weight: 600; }

/* 11. Badges -------------------------------------------------- */
.badge {
  display: inline-flex;
  align-items: center;
  gap: .25rem;
  font-size: .72rem;
  font-weight: 700;
  letter-spacing: .04em;
  padding: .22rem .6rem;
  border-radius: 999px;
  text-transform: uppercase;
}
.badge-teal    { background: var(--teal-light); color: var(--teal-dark); }
.badge-cream   { background: var(--cream); color: var(--mocha); }
.badge-mint    { background: #d0f7e8; color: #1a7a4a; }
.badge-brown   { background: #ede0d8; color: var(--brown); }
.badge-dark    { background: var(--charcoal); color: var(--cream); }
.badge-mocha   { background: #f0e0d5; color: var(--mocha); }

/* Brew type badge colors */
.brew-espresso   { background: #2d1a18; color: #f5e9d3; }
.brew-macchiato  { background: #7a4f3a; color: #fff; }
.brew-flat_white { background: var(--cream); color: var(--brown); }
.brew-latte      { background: #d9c4a3; color: var(--brown-dark); }
.brew-cold_brew  { background: #1a2d40; color: #b8d4f0; }
.brew-affogato   { background: var(--teal); color: #fff; }

/* 12. Room detail layout ------------------------------------- */
.room-layout {
  display: grid;
  grid-template-columns: 1fr 300px;
  gap: 2.5rem;
  align-items: start;
}
@media (max-width: 820px) {
  .room-layout { grid-template-columns: 1fr; }
  .room-sidebar { order: -1; }
}

.room-header {
  background: var(--brown);
  background-image: linear-gradient(120deg, var(--brown) 0%, var(--mocha) 100%);
  color: var(--cream);
  padding: 2.5rem 0 2rem;
  margin-bottom: 2.5rem;
}
.room-header__icon { font-size: 2.8rem; margin-bottom: .5rem; }
.room-header h1 { color: var(--cream); margin-bottom: .5rem; }
.room-header p  { color: rgba(245,233,211,.8); max-width: 560px; }

/* 13. Sidebar ------------------------------------------------ */
.sidebar-card {
  background: var(--cream);
  border-radius: var(--radius-lg);
  border: 1px solid #e0cdb5;
  padding: 1.25rem 1.35rem;
  margin-bottom: 1.25rem;
}
.sidebar-card h4 {
  color: var(--brown);
  margin-bottom: .85rem;
  font-size: .95rem;
  display: flex;
  align-items: center;
  gap: .4rem;
}
.rule-item {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  font-size: .83rem;
  padding: .35rem 0;
  border-bottom: 1px solid #e0cdb5;
}
.rule-item:last-child { border-bottom: none; }
.rule-label { color: #7a6a5a; }
.rule-value { font-weight: 700; color: var(--brown); }

.brew-pill {
  display: inline-block;
  font-size: .72rem;
  padding: .15rem .5rem;
  border-radius: 999px;
  margin: .15rem .1rem;
  background: #fff;
  color: var(--mocha);
  border: 1px solid #d0b898;
  font-weight: 600;
}

/* 14. Post detail -------------------------------------------- */
.post-header {
  background: var(--cream);
  padding: 2.5rem 0 2rem;
  margin-bottom: 2.5rem;
  border-bottom: 3px solid var(--teal);
}
.post-header h1 {
  margin-bottom: .75rem;
  line-height: 1.2;
}
.post-meta {
  display: flex;
  flex-wrap: wrap;
  gap: .6rem;
  align-items: center;
  font-size: .85rem;
  color: #777;
  margin-bottom: 1rem;
}
.post-meta strong { color: var(--mocha); }
.post-meta-sep::before { content: '·'; }

.post-content {
  background: #fff;
  border-radius: var(--radius-lg);
  border: 1px solid var(--divider);
  padding: 2.5rem;
  max-width: 780px;
  font-size: 1.05rem;
  line-height: 1.85;
  color: #333;
}
.post-content p     { margin-bottom: 1.25rem; }
.post-content h2,
.post-content h3    { margin: 1.5rem 0 .75rem; }

.post-word-count {
  font-size: .78rem;
  color: #999;
  margin-top: 1.25rem;
  padding-top: .75rem;
  border-top: 1px solid var(--gray);
}

/* 15. Brew type page ----------------------------------------- */
.brew-hero {
  background: var(--charcoal);
  color: var(--cream);
  padding: 3rem 0 2.5rem;
  margin-bottom: 2.5rem;
}
.brew-hero h1 { color: var(--cream); }
.brew-hero__desc { color: rgba(245,233,211,.75); margin-top: .4rem; }
.brew-hero__range {
  display: inline-block;
  background: rgba(27,163,156,.2);
  border: 1px solid rgba(27,163,156,.4);
  color: var(--mint);
  font-size: .85rem;
  padding: .25rem .75rem;
  border-radius: 999px;
  margin-top: .75rem;
  font-weight: 600;
}

/* 16. Pagination --------------------------------------------- */
.pagination {
  display: flex;
  justify-content: center;
  gap: .4rem;
  margin-top: 2.5rem;
  flex-wrap: wrap;
}
.pagination > * {
  min-width: 2.25rem;
  height: 2.25rem;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--radius);
  font-size: .875rem;
  font-weight: 600;
}
.pagination .page-item .page-link {
  background: #fff;
  border: 1px solid var(--divider);
  color: var(--charcoal);
  padding: 0 .75rem;
  transition: all var(--transition);
  border-radius: var(--radius);
}
.pagination .page-item .page-link:hover {
  background: var(--teal-light);
  border-color: var(--teal);
  color: var(--teal-dark);
}
.pagination .page-item.active .page-link {
  background: var(--teal);
  border-color: var(--teal);
  color: #fff;
}

/* 17. Empty state -------------------------------------------- */
.empty-state {
  text-align: center;
  padding: 4rem 1.5rem;
  color: #999;
}
.empty-state__icon { font-size: 3.5rem; margin-bottom: 1rem; }
.empty-state h3 { color: var(--brown); margin-bottom: .5rem; }

/* 18. Footer ------------------------------------------------- */
.footer {
  background: var(--brown-dark);
  color: rgba(245,233,211,.7);
  padding: 2.5rem 0;
  margin-top: auto;
  font-size: .875rem;
}
.footer__inner {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 1rem;
}
.footer__brand {
  font-family: var(--font-head);
  color: var(--cream);
  font-size: 1.1rem;
}
.footer__links { display: flex; gap: 1.25rem; }
.footer__links a { color: rgba(245,233,211,.6); font-size: .83rem; }
.footer__links a:hover { color: var(--cream); }

/* 19. Utilities ---------------------------------------------- */
.text-teal   { color: var(--teal); }
.text-brown  { color: var(--brown); }
.text-mocha  { color: var(--mocha); }
.text-muted  { color: #888; }
.mt-1 { margin-top: .5rem; }
.mt-2 { margin-top: 1rem; }
.mt-3 { margin-top: 1.5rem; }
.mb-1 { margin-bottom: .5rem; }
.mb-2 { margin-bottom: 1rem; }
.mb-3 { margin-bottom: 1.5rem; }

/* 20. Responsive --------------------------------------------- */
@media (max-width: 768px) {
  .nav__links { display: none; }
  .hero { padding: 3rem 0; }
  .rooms-grid, .posts-grid { grid-template-columns: 1fr; }
  .post-content { padding: 1.5rem; }
  .footer__inner { flex-direction: column; text-align: center; }
}


/* ── Section 4: Feedback System ──────────────────────────── */

/* Heatmap marks */
mark.hm-tag {
  border-radius: 3px;
  padding: 0 2px;
  cursor: help;
}

/* Roast mode radio cards */
.roast-cards { display: flex; gap: .75rem; flex-wrap: wrap; }
.roast-card  { flex: 1; min-width: 140px; }
.roast-card input[type=radio] { display: none; }
.roast-card label {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: .35rem;
  padding: 1rem .75rem;
  border: 2px solid var(--divider);
  border-radius: var(--radius-lg);
  cursor: pointer;
  text-align: center;
  transition: all var(--transition);
  background: #fff;
  font-size: .85rem;
  color: #555;
}
.roast-card label .roast-icon { font-size: 1.8rem; }
.roast-card label .roast-name { font-weight: 700; color: var(--charcoal); font-size: .9rem; }
.roast-card label .roast-desc { font-size: .75rem; color: #888; line-height: 1.3; }
.roast-card input:checked + label {
  border-color: var(--teal);
  background: var(--teal-light);
}
.roast-card.roast-dark input:checked + label {
  border-color: var(--charcoal);
  background: #f0ece8;
}

/* Aroma tag toggles */
.aroma-grid { display: flex; flex-wrap: wrap; gap: .5rem; }
.aroma-tag  { position: relative; }
.aroma-tag input[type=checkbox] { display: none; }
.aroma-tag label {
  display: inline-flex;
  align-items: center;
  gap: .3rem;
  padding: .4rem .9rem;
  border: 2px solid var(--divider);
  border-radius: 999px;
  cursor: pointer;
  font-size: .83rem;
  font-weight: 600;
  color: #666;
  background: #fff;
  transition: all var(--transition);
  user-select: none;
}
.aroma-tag input:checked + label {
  border-color: var(--teal);
  background: var(--teal-light);
  color: var(--teal-dark);
}

/* Heatmap annotation zone */
.heatmap-zone {
  background: #fff;
  border: 2px dashed var(--divider);
  border-radius: var(--radius-lg);
  padding: 1.5rem;
  font-size: 1rem;
  line-height: 1.85;
  color: #333;
  position: relative;
  cursor: text;
  max-height: 320px;
  overflow-y: auto;
  white-space: pre-wrap;
  word-wrap: break-word;
}
.heatmap-zone.active-zone {
  border-color: var(--teal);
  box-shadow: 0 0 0 3px rgba(27,163,156,.12);
}

/* Tag picker popup */
.tag-picker {
  display: none;
  position: absolute;
  background: var(--brown-dark);
  border-radius: var(--radius-lg);
  padding: .5rem;
  box-shadow: var(--shadow-lg);
  z-index: 500;
  gap: .35rem;
  flex-wrap: wrap;
  max-width: 260px;
}
.tag-picker.visible { display: flex; }
.tag-pick-btn {
  padding: .3rem .7rem;
  border-radius: 999px;
  border: none;
  font-size: .78rem;
  font-weight: 700;
  cursor: pointer;
  color: #fff;
  transition: opacity var(--transition);
}
.tag-pick-btn:hover { opacity: .85; }
.tag-pick-btn[data-tag=warm]   { background: #D97706; }
.tag-pick-btn[data-tag=bitter] { background: #6366F1; }
.tag-pick-btn[data-tag=smooth] { background: #059669; }
.tag-pick-btn[data-tag=bold]   { background: #DC2626; }
.tag-pick-btn[data-tag=sweet]  { background: #DB2777; }
.tag-pick-btn[data-tag=smoky]  { background: #6B7280; }
.tag-pick-cancel {
  background: rgba(255,255,255,.15);
  color: rgba(255,255,255,.7);
  padding: .3rem .6rem;
  border-radius: 999px;
  font-size: .75rem;
  cursor: pointer;
  border: none;
}

/* Highlight chips (showing added highlights) */
.highlight-chips { display: flex; flex-wrap: wrap; gap: .35rem; margin-top: .6rem; }
.highlight-chip {
  display: inline-flex;
  align-items: center;
  gap: .3rem;
  font-size: .75rem;
  padding: .2rem .55rem;
  border-radius: 999px;
  color: #fff;
  font-weight: 600;
}
.highlight-chip button {
  background: none;
  border: none;
  color: rgba(255,255,255,.7);
  cursor: pointer;
  font-size: .8rem;
  line-height: 1;
  padding: 0;
}

/* Review cards */
.review-card {
  background: #fff;
  border: 1px solid var(--divider);
  border-radius: var(--radius-lg);
  padding: 1.25rem 1.4rem;
  margin-bottom: 1rem;
}
.review-card__header {
  display: flex;
  align-items: center;
  gap: .65rem;
  margin-bottom: .85rem;
}
.reviewer-avatar {
  width: 36px; height: 36px;
  border-radius: 50%;
  background: var(--cream);
  display: flex; align-items: center; justify-content: center;
  font-size: 1rem;
  flex-shrink: 0;
  color: var(--mocha);
  font-weight: 700;
}
.review-card__meta { font-size: .8rem; color: #999; }
.review-card__comment { font-size: .9rem; color: #444; line-height: 1.65; }
.review-card__tags { display: flex; flex-wrap: wrap; gap: .35rem; margin-top: .65rem; }
.aroma-chip {
  font-size: .72rem;
  font-weight: 700;
  padding: .18rem .55rem;
  border-radius: 999px;
  color: #fff;
}

/* Brew score bars */
.score-card {
  background: var(--cream);
  border-radius: var(--radius-lg);
  border: 1px solid #e0cdb5;
  padding: 1.5rem;
  margin-bottom: 1.5rem;
}
.score-total {
  font-family: var(--font-head);
  font-size: 4rem;
  color: var(--brown);
  line-height: 1;
  margin-bottom: .25rem;
}
.score-label { font-size: .8rem; color: #888; text-transform: uppercase; letter-spacing: .08em; }

.score-bars { display: flex; flex-direction: column; gap: .85rem; margin-top: 1.25rem; }
.score-bar-row { display: flex; flex-direction: column; gap: .3rem; }
.score-bar-label {
  display: flex;
  justify-content: space-between;
  font-size: .82rem;
  font-weight: 600;
  color: var(--charcoal);
}
.score-bar-track {
  height: 8px;
  background: var(--divider);
  border-radius: 999px;
  overflow: hidden;
}
.score-bar-fill {
  height: 100%;
  border-radius: 999px;
  background: var(--teal);
  transition: width .6s ease;
}

/* Feedback form wrapper */
.feedback-form {
  background: var(--cream);
  border: 1px solid #e0cdb5;
  border-radius: var(--radius-lg);
  padding: 2rem;
  margin-top: 2.5rem;
}
.feedback-form h3 {
  margin-bottom: 1.5rem;
  font-size: 1.2rem;
}
.form-group { margin-bottom: 1.5rem; }
.form-label {
  display: block;
  font-size: .85rem;
  font-weight: 700;
  color: var(--brown);
  margin-bottom: .5rem;
  letter-spacing: .02em;
}
.form-textarea {
  width: 100%;
  padding: .75rem 1rem;
  border: 2px solid var(--divider);
  border-radius: var(--radius);
  font-family: var(--font-body);
  font-size: .9rem;
  color: var(--charcoal);
  background: #fff;
  resize: vertical;
  transition: border-color var(--transition);
  line-height: 1.6;
}
.form-textarea:focus {
  outline: none;
  border-color: var(--teal);
  box-shadow: 0 0 0 3px rgba(27,163,156,.12);
}
.form-error { color: var(--error); font-size: .82rem; margin-top: .3rem; }
.alert-success {
  background: #d1fae5;
  border: 1px solid #34d399;
  color: #065f46;
  border-radius: var(--radius);
  padding: .75rem 1.1rem;
  margin-bottom: 1.5rem;
  font-size: .9rem;
  font-weight: 600;
}


/* ── Section 5: Dashboard, Write Form, Quests, Beans ──────────────────────── */

/* Dashboard */
.dashboard-wrap { max-width: 1000px; margin: 0 auto; padding: 2rem 1rem; }

.dashboard-header {
    display: flex; align-items: flex-start; gap: 1.5rem;
    background: var(--warm-white); border-radius: 12px;
    padding: 1.5rem; margin-bottom: 2rem;
    border: 1px solid rgba(75,46,43,.1);
}
.dashboard-avatar {
    width: 72px; height: 72px; border-radius: 50%; overflow: hidden;
    background: var(--brown); display: flex; align-items: center;
    justify-content: center; flex-shrink: 0;
}
.dashboard-avatar img  { width: 100%; height: 100%; object-fit: cover; }
.dashboard-avatar span { color: #fff; font-size: 1.8rem; font-weight: 700; }
.dashboard-identity    { flex: 1; }
.dashboard-identity h1 { margin: 0 0 .25rem; font-size: 1.4rem; }
.dashboard-handle      { margin: 0 0 .25rem; color: var(--mocha); font-size: .9rem; }
.dashboard-bio         { margin: 0; font-size: .9rem; color: #666; }

.bean-badge-large {
    display: flex; flex-direction: column; align-items: center;
    background: var(--cream); border-radius: 10px; padding: .75rem 1.25rem;
    border: 1px solid rgba(27,163,156,.3);
}
.bean-icon  { font-size: 1.6rem; line-height: 1; }
.bean-count { font-size: 1.8rem; font-weight: 700; color: var(--brown); line-height: 1.1; }
.bean-label { font-size: .75rem; color: #888; text-transform: uppercase; letter-spacing: .05em; }

/* Stats row */
.stats-row {
    display: grid; grid-template-columns: repeat(4, 1fr);
    gap: 1rem; margin-bottom: 2rem;
}
.stat-card {
    background: var(--warm-white); border-radius: 10px;
    padding: 1.25rem; text-align: center;
    border: 1px solid rgba(75,46,43,.08);
    display: flex; flex-direction: column; gap: .25rem;
}
.stat-card.highlight { background: var(--teal); color: #fff; }
.stat-card.highlight .stat-label { color: rgba(255,255,255,.8); }
.stat-number { font-size: 2rem; font-weight: 700; color: var(--brown); line-height: 1; }
.stat-card.highlight .stat-number { color: #fff; }
.stat-label  { font-size: .8rem; color: #888; text-transform: uppercase; letter-spacing: .05em; }

/* Dashboard columns */
.dashboard-columns { display: grid; grid-template-columns: 1fr 1fr; gap: 2rem; }
.dash-col {}
.dash-section {
    background: var(--warm-white); border-radius: 12px;
    padding: 1.5rem; margin-bottom: 1.5rem;
    border: 1px solid rgba(75,46,43,.08);
}
.dash-section h2 { margin: 0 0 1rem; font-size: 1.1rem; color: var(--brown); }
.dash-section h3.quest-subhead { font-size: .85rem; text-transform: uppercase; letter-spacing: .08em; color: #999; margin: 1rem 0 .5rem; }

/* Recent posts list */
.dash-post-row {
    display: flex; justify-content: space-between; align-items: center;
    padding: .6rem 0; border-bottom: 1px solid rgba(75,46,43,.06);
    text-decoration: none; color: inherit;
}
.dash-post-row:last-child { border-bottom: none; }
.dash-post-row:hover .dash-post-title { color: var(--teal); }
.dash-post-info    { display: flex; flex-direction: column; gap: .2rem; }
.dash-post-title   { font-weight: 600; font-size: .95rem; }
.dash-post-meta    { font-size: .8rem; color: #888; }
.dash-post-date    { font-size: .75rem; color: #aaa; white-space: nowrap; padding-left: 1rem; }

/* Bean log */
.bean-log-row {
    display: flex; justify-content: space-between;
    padding: .5rem 0; border-bottom: 1px solid rgba(75,46,43,.06);
    font-size: .9rem;
}
.bean-log-row:last-child { border-bottom: none; }
.bean-log-reason  { color: #555; }
.bean-log-amount.positive { color: var(--teal); font-weight: 600; }
.bean-log-amount.negative { color: #e55; font-weight: 600; }

/* Quest cards */
.quest-card {
    display: flex; align-items: flex-start; gap: .75rem;
    padding: .75rem 0; border-bottom: 1px solid rgba(75,46,43,.06);
}
.quest-card:last-child { border-bottom: none; }
.quest-done .quest-info .quest-title { text-decoration: line-through; color: #aaa; }
.quest-check {
    width: 24px; height: 24px; border-radius: 50%;
    background: var(--teal); color: #fff;
    display: flex; align-items: center; justify-content: center;
    font-size: .9rem; flex-shrink: 0;
}
.quest-info       { flex: 1; display: flex; flex-direction: column; gap: .15rem; }
.quest-title      { font-weight: 600; font-size: .9rem; }
.quest-desc       { font-size: .8rem; color: #777; }
.quest-reward     { font-size: .85rem; color: var(--mocha); font-weight: 600; white-space: nowrap; }
.quest-progress-bar {
    height: 4px; background: rgba(75,46,43,.1); border-radius: 2px;
    margin-top: .35rem; overflow: hidden;
}
.quest-progress-fill { height: 100%; background: var(--teal); border-radius: 2px; }
.quest-progress-label { font-size: .75rem; color: #aaa; }

.empty-state { color: #aaa; font-size: .9rem; font-style: italic; }

/* Write page */
.write-wrap { max-width: 780px; margin: 0 auto; padding: 2rem 1rem; }
.write-wrap h1 { margin-bottom: .25rem; }
.write-subtitle { color: #888; margin-bottom: 2rem; }
.write-form { display: flex; flex-direction: column; gap: 1.25rem; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 1.25rem; }
.form-row-3 { grid-template-columns: 1fr 1fr 1fr; }
.form-group { display: flex; flex-direction: column; gap: .4rem; }
.form-group label { font-size: .875rem; font-weight: 600; color: var(--brown); }
.form-select, .form-input {
    border: 1.5px solid rgba(75,46,43,.2); border-radius: 8px;
    padding: .6rem .9rem; font-size: .95rem; background: #fff;
    transition: border-color .2s;
}
.form-select:focus, .form-input:focus {
    outline: none; border-color: var(--teal);
}
.write-textarea { min-height: 320px; resize: vertical; }
.word-count-badge {
    font-size: .75rem; font-weight: 400; color: #888;
    background: rgba(75,46,43,.06); padding: .15rem .5rem; border-radius: 20px;
    margin-left: .5rem;
}
.form-check-group { justify-content: flex-end; }
.check-label { display: flex; align-items: center; gap: .5rem; font-size: .9rem; cursor: pointer; }
.check-label input[type=checkbox] { accent-color: var(--teal); width: 16px; height: 16px; }

.form-actions { display: flex; gap: 1rem; align-items: center; padding-top: .5rem; }
.alert.alert-error {
    background: #fef2f2; border: 1px solid #fecaca; border-radius: 8px;
    padding: 1rem; color: #b91c1c; font-size: .9rem;
}
.alert.alert-error p { margin: .2rem 0; }

/* Room info banner */
.room-info-banner {
    display: flex; flex-wrap: wrap; gap: .5rem;
    background: rgba(27,163,156,.06); border: 1px solid rgba(27,163,156,.2);
    border-radius: 8px; padding: .75rem 1rem;
    font-size: .85rem; color: var(--brown);
}
.room-info-banner span {
    background: rgba(27,163,156,.12); border-radius: 20px;
    padding: .2rem .75rem;
}

/* Nav additions */
.nav-link-write {
    background: var(--teal); color: #fff !important;
    border-radius: 20px; padding: .35rem .9rem !important;
}
.nav-link-write:hover { background: var(--mocha); }

@media (max-width: 700px) {
    .stats-row        { grid-template-columns: repeat(2,1fr); }
    .dashboard-columns { grid-template-columns: 1fr; }
    .form-row          { grid-template-columns: 1fr; }
    .form-row-3        { grid-template-columns: 1fr; }
    .dashboard-header  { flex-wrap: wrap; }
}


/* ── Section 6: Collections, Exports, Weekly Menu ─────────────────────────── */

/* Collections index */
.collections-wrap  { max-width: 960px; margin: 0 auto; padding: 2rem 1rem; }
.collections-header {
    display: flex; justify-content: space-between; align-items: flex-start;
    margin-bottom: 2rem;
}
.collections-header h1 { margin: 0 0 .25rem; }
.collections-header .sub { color: #888; margin: 0; }

.collection-grid {
    display: grid; grid-template-columns: repeat(3, 1fr);
    gap: 1.5rem;
}
.collection-card {
    background: var(--warm-white); border-radius: 12px;
    padding: 1.5rem; text-decoration: none; color: inherit;
    border: 1px solid rgba(75,46,43,.1);
    transition: box-shadow .2s, transform .2s;
    display: flex; flex-direction: column; gap: .5rem;
}
.collection-card:hover { box-shadow: 0 4px 16px rgba(75,46,43,.12); transform: translateY(-2px); }
.collection-card h2  { font-size: 1.1rem; color: var(--brown); margin: 0; }
.col-desc { font-size: .875rem; color: #666; margin: 0; flex: 1; }
.col-meta { display: flex; justify-content: space-between; font-size: .8rem; color: #aaa; margin-top: auto; }

/* Collection show */
.collection-show-wrap { max-width: 860px; margin: 0 auto; padding: 2rem 1rem; }
.collection-show-header {
    display: flex; justify-content: space-between; align-items: flex-start;
    gap: 1.5rem; margin-bottom: 2.5rem;
    background: var(--warm-white); border-radius: 12px; padding: 1.75rem;
    border: 1px solid rgba(75,46,43,.1);
}
.collection-show-info h1   { margin: 0 0 .5rem; }
.collection-show-desc      { color: #666; font-style: italic; margin: 0 0 .75rem; }
.collection-show-meta      { font-size: .85rem; color: #999; }

.export-menu { display: flex; align-items: center; gap: .5rem; flex-shrink: 0; flex-wrap: wrap; }
.export-label { font-size: .8rem; color: #aaa; text-transform: uppercase; letter-spacing: .06em; }

/* Collection post list */
.collection-post-list { display: flex; flex-direction: column; gap: .5rem; }
.collection-post-item {
    display: flex; align-items: flex-start; gap: 1rem;
    background: var(--warm-white); border-radius: 10px; padding: 1rem 1.25rem;
    border: 1px solid rgba(75,46,43,.08);
}
.col-post-num {
    font-size: 1.5rem; font-weight: 700; color: rgba(75,46,43,.15);
    width: 2rem; flex-shrink: 0; line-height: 1.2;
}
.col-post-body    { flex: 1; display: flex; flex-direction: column; gap: .3rem; }
.col-post-title   { font-size: 1rem; font-weight: 600; color: var(--brown); text-decoration: none; }
.col-post-title:hover { color: var(--teal); }
.col-post-meta    { font-size: .8rem; color: #999; }
.col-post-preview { font-size: .875rem; color: #777; margin: 0; }
.col-post-exports { display: flex; flex-direction: column; gap: .35rem; flex-shrink: 0; }
.export-chip {
    font-size: .75rem; padding: .2rem .6rem; border-radius: 20px;
    background: rgba(75,46,43,.06); color: #777; text-decoration: none;
    text-align: center; transition: background .15s;
}
.export-chip:hover { background: var(--teal); color: #fff; }

/* Post picker in create form */
.post-picker { display: flex; flex-direction: column; gap: .5rem; }
.post-pick-item {
    display: flex; align-items: flex-start; gap: .75rem; cursor: pointer;
    padding: .75rem 1rem; border-radius: 8px;
    border: 1.5px solid rgba(75,46,43,.12); background: #fff;
    transition: border-color .2s;
}
.post-pick-item:has(input:checked) { border-color: var(--teal); background: rgba(27,163,156,.04); }
.post-pick-item input[type=checkbox] { margin-top: .15rem; accent-color: var(--teal); }
.post-pick-info   { display: flex; flex-direction: column; gap: .2rem; }
.post-pick-title  { font-weight: 600; font-size: .95rem; }
.post-pick-meta   { font-size: .8rem; color: #999; }
.field-opt        { font-size: .8rem; color: #aaa; font-weight: 400; }

/* Weekly menu */
.menu-wrap { max-width: 900px; margin: 0 auto; padding: 2rem 1rem; }
.menu-header {
    text-align: center; padding: 3rem 2rem;
    background: var(--brown); border-radius: 16px; color: #fff;
    margin-bottom: 3rem;
}
.menu-eyebrow  { font-size: .8rem; text-transform: uppercase; letter-spacing: .15em; opacity: .6; margin-bottom: .5rem; }
.menu-title    { font-size: 2.4rem; margin: 0 0 .5rem; color: var(--cream); }
.menu-dates    { font-size: 1rem; opacity: .7; margin-bottom: 1rem; }
.menu-tagline  { font-style: italic; opacity: .8; font-size: .95rem; }

.menu-section      { margin-bottom: 2.5rem; }
.menu-section-title {
    font-size: 1rem; text-transform: uppercase; letter-spacing: .1em;
    color: #888; border-bottom: 2px solid var(--cream); padding-bottom: .5rem;
    margin-bottom: 1rem; display: flex; gap: 1rem; align-items: baseline;
}
.menu-brew-name { color: var(--brown); }
.menu-brew-desc { font-size: .8rem; font-weight: 400; color: #aaa; text-transform: none; letter-spacing: 0; }

.menu-rooms { display: flex; flex-wrap: wrap; gap: .5rem; }
.menu-room-chip {
    padding: .35rem 1rem; border-radius: 20px; font-size: .875rem;
    background: rgba(75,46,43,.06); color: #777; text-decoration: none;
    display: flex; align-items: center; gap: .4rem;
    transition: background .15s;
}
.menu-room-chip:hover { background: var(--cream); }
.menu-room-active { background: var(--cream); color: var(--brown); font-weight: 600; }
.menu-room-count {
    background: var(--teal); color: #fff; border-radius: 20px;
    font-size: .7rem; padding: .05rem .45rem; font-weight: 700;
}

.menu-post-list { display: flex; flex-direction: column; gap: .5rem; }
.menu-post-item {
    display: flex; flex-direction: column; gap: .2rem;
    padding: .9rem 1.25rem; border-radius: 8px;
    background: var(--warm-white); border: 1px solid rgba(75,46,43,.08);
    text-decoration: none; color: inherit; transition: border-color .15s;
}
.menu-post-item:hover { border-color: var(--teal); }
.menu-post-title { font-weight: 600; color: var(--brown); }
.menu-post-meta  { font-size: .8rem; color: #aaa; }

.btn-sm { padding: .3rem .75rem; font-size: .82rem; }

@media (max-width: 700px) {
    .collection-grid     { grid-template-columns: 1fr; }
    .collection-show-header { flex-direction: column; }
    .export-menu         { flex-direction: row; flex-wrap: wrap; }
    .col-post-exports    { flex-direction: row; }
}

/* ===== Atmosphere Widget (fixed) ===================================== */
#cc-atm-bar {
    position: fixed;
    bottom: 1.5rem;
    right: 1.5rem;
    z-index: 1000;
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: .5rem;
}
.atm-btn {
    width: 44px; height: 44px; border-radius: 50%;
    background: var(--brown); color: #fff; border: none;
    cursor: pointer; font-size: 1.2rem;
    display: flex; align-items: center; justify-content: center;
    box-shadow: 0 2px 12px rgba(75,46,43,.4);
    transition: background .2s, transform .2s;
}
.atm-btn:hover { background: var(--teal); transform: scale(1.08); }
.atm-panel {
    display: none;
    flex-direction: column; gap: .75rem;
    background: var(--warm-white); border-radius: 14px;
    padding: 1rem 1.25rem; border: 1px solid rgba(75,46,43,.15);
    box-shadow: 0 8px 32px rgba(0,0,0,.15); min-width: 240px;
    margin-bottom: .25rem;
}
.atm-panel.open { display: flex; }
.atm-row { display: flex; flex-direction: column; gap: .4rem; }
.atm-label { font-size: .72rem; text-transform: uppercase; letter-spacing: .08em; color: #aaa; font-weight: 600; }
.atm-scenes { display: flex; flex-wrap: wrap; gap: .35rem; }
.atm-scene-btn {
    padding: .2rem .65rem; border-radius: 20px;
    border: 1.5px solid rgba(75,46,43,.15); background: #fff;
    font-size: .78rem; cursor: pointer; transition: all .15s;
}
.atm-scene-btn:hover { border-color: var(--teal); color: var(--teal); }
.atm-scene-btn.active { background: var(--brown); color: #fff; border-color: var(--brown); }
.atm-slider { width: 100%; accent-color: var(--teal); cursor: pointer; }
.atm-row-minimal { border-top: 1px solid rgba(75,46,43,.08); padding-top: .5rem; }
.atm-btn-ghost {
    background: none; border: 1.5px solid rgba(75,46,43,.2); border-radius: 8px;
    padding: .35rem .85rem; font-size: .82rem; cursor: pointer;
    color: var(--brown); transition: all .15s; width: 100%; text-align: center;
}
.atm-btn-ghost:hover { background: var(--cream); }
body.minimal-mode .site-nav,
body.minimal-mode .site-footer,
body.minimal-mode .sidebar { display: none !important; }
body.minimal-mode .page-body { max-width: 680px; margin: 2rem auto; padding: 0 1.5rem; }
body.minimal-mode .write-textarea { min-height: 60vh; }
:root { --room-accent: var(--teal); }

/* ===== AI Barista widget ============================================= */
.barista-wrap {
    background: var(--warm-white); border-radius: 12px;
    border: 1px solid rgba(75,46,43,.1); overflow: hidden; margin-top: 1.5rem;
}
.barista-header {
    display: flex; align-items: center; gap: .5rem;
    padding: .9rem 1.25rem; background: var(--brown); color: #fff; font-size: .9rem;
}
.barista-icon { font-size: 1.1rem; }
.barista-tabs { display: flex; border-bottom: 1px solid rgba(75,46,43,.1); }
.barista-tab {
    flex: 1; padding: .6rem; border: none; background: none; cursor: pointer;
    font-size: .82rem; color: #888; border-bottom: 2px solid transparent; transition: all .15s;
}
.barista-tab.active { color: var(--brown); border-bottom-color: var(--teal); font-weight: 600; }
.barista-body { padding: 1rem 1.25rem; }
.barista-hint, .barista-loading { font-size: .85rem; color: #aaa; font-style: italic; }
.barista-prompts { list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; gap: .6rem; }
.barista-prompt {
    font-size: .875rem; padding: .6rem .9rem; border-radius: 8px;
    background: var(--cream); color: var(--charcoal); line-height: 1.5;
    border-left: 3px solid var(--teal);
}
.barista-fetch-btn, .barista-more {
    margin-top: .75rem; display: block; width: 100%; padding: .5rem;
    border: 1.5px solid rgba(75,46,43,.15); border-radius: 8px; background: none;
    cursor: pointer; font-size: .82rem; color: var(--brown); transition: background .15s;
}
.barista-fetch-btn:hover, .barista-more:hover { background: var(--cream); }
.barista-tone-row { display: flex; flex-wrap: wrap; gap: .35rem; margin-bottom: .75rem; }
.barista-tone-btn {
    padding: .25rem .75rem; border-radius: 20px; border: 1.5px solid rgba(75,46,43,.15);
    background: #fff; font-size: .8rem; cursor: pointer; transition: all .15s;
}
.barista-tone-btn:hover, .barista-tone-btn.active { background: var(--teal); color: #fff; border-color: var(--teal); }

/* ===== Post show two-column ========================================== */
.post-show-layout { display: grid; grid-template-columns: 1fr 280px; gap: 2rem; align-items: start; }
.post-show-main { min-width: 0; }
.post-export-row {
    display: flex; align-items: center; gap: .5rem;
    margin-top: 2rem; padding-top: 1rem; border-top: 1px solid rgba(75,46,43,.08);
}

/* ===== Admin ========================================================= */
.admin-wrap { max-width: 960px; margin: 0 auto; padding: 2rem 1rem; }
.admin-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 2rem; }
.admin-header h1 { margin: 0; }
.admin-table { width: 100%; border-collapse: collapse; background: var(--warm-white); border-radius: 12px; overflow: hidden; }
.admin-table th { background: var(--brown); color: #fff; padding: .75rem 1rem; text-align: left; font-size: .85rem; }
.admin-table td { padding: .75rem 1rem; border-bottom: 1px solid rgba(75,46,43,.07); font-size: .9rem; vertical-align: middle; }
.admin-table tr:last-child td { border-bottom: none; }
.admin-actions { display: flex; gap: .5rem; }
.admin-form { background: var(--warm-white); border-radius: 12px; padding: 2rem; border: 1px solid rgba(75,46,43,.1); }
.admin-brew-grid { display: grid; grid-template-columns: repeat(3,1fr); gap: .5rem; }
.admin-brew-item { display: flex; align-items: center; gap: .5rem; font-size: .875rem; }
.badge-active { background: rgba(27,163,156,.12); color: var(--teal); padding: .15rem .6rem; border-radius: 20px; font-size: .78rem; font-weight: 600; }
.badge-inactive { background: rgba(75,46,43,.08); color: #aaa; padding: .15rem .6rem; border-radius: 20px; font-size: .78rem; }
.btn-danger { background: #DC2626; color: #fff; border-color: #DC2626; }
.btn-danger:hover { background: #B91C1C; border-color: #B91C1C; }
.alert-success { background: #f0fdf4; border: 1px solid #bbf7d0; border-radius: 8px; padding: 1rem; color: #166534; font-size: .9rem; margin-bottom: 1rem; }

/* ===== Nav: logged-in user menu (fixed) ============================== */
.nav__auth { display: flex; align-items: center; gap: .6rem; flex-shrink: 0; }
.nav__user-menu { position: relative; }
.nav__user-btn {
    display: flex; align-items: center; gap: .45rem;
    background: none; border: 1.5px solid rgba(75,46,43,.25); border-radius: 24px;
    padding: .25rem .65rem .25rem .3rem; cursor: pointer;
    font-size: .83rem; color: var(--brown);
    transition: border-color .15s, background .15s;
    white-space: nowrap; font-family: inherit;
}
.nav__user-btn:hover { border-color: var(--teal); background: rgba(27,163,156,.05); }
.nav__user-avatar {
    width: 26px; height: 26px; border-radius: 50%;
    background: var(--brown); color: #fff;
    display: flex; align-items: center; justify-content: center;
    font-size: .75rem; font-weight: 700; flex-shrink: 0;
}
.nav__user-name {
    max-width: 90px; overflow: hidden; text-overflow: ellipsis;
    white-space: nowrap; font-weight: 600;
}
.nav__user-dropdown {
    display: none; position: absolute; right: 0; top: calc(100% + .4rem);
    background: #fff; border-radius: 10px; border: 1px solid rgba(75,46,43,.12);
    box-shadow: 0 8px 32px rgba(0,0,0,.1); min-width: 170px; z-index: 600; overflow: hidden;
}
.nav__user-menu.open .nav__user-dropdown { display: block; }
.nav__user-dropdown a, .nav__logout-btn {
    display: block; padding: .6rem 1rem; font-size: .875rem;
    color: var(--charcoal); text-decoration: none; width: 100%;
    text-align: left; background: none; border: none; cursor: pointer;
    transition: background .1s; font-family: inherit; line-height: 1.4;
}
.nav__user-dropdown a:hover, .nav__logout-btn:hover { background: var(--cream); color: var(--brown); }
.nav__dropdown-divider { height: 1px; background: rgba(75,46,43,.08); margin: .25rem 0; }

/* ===== Auth forms ==================================================== */
.auth-wrap { min-height: 70vh; display: flex; align-items: center; justify-content: center; padding: 2rem 1rem; }
.auth-card {
    width: 100%; max-width: 420px; background: var(--warm-white); border-radius: 16px;
    padding: 2.5rem; border: 1px solid rgba(75,46,43,.1); box-shadow: 0 8px 40px rgba(75,46,43,.08);
}
.auth-header { text-align: center; margin-bottom: 2rem; }
.auth-icon { font-size: 2.5rem; display: block; margin-bottom: .75rem; }
.auth-header h1 { margin: 0 0 .4rem; font-size: 1.6rem; }
.auth-header p { color: #888; margin: 0; font-size: .9rem; }
.auth-form { display: flex; flex-direction: column; gap: 1rem; }
.auth-remember { display: flex; align-items: center; }
.btn-full { width: 100%; justify-content: center; }
.auth-footer { text-align: center; margin-top: 1.5rem; font-size: .875rem; color: #888; }
.auth-footer a { color: var(--teal); text-decoration: none; font-weight: 600; }
.auth-terms-note { font-size: .78rem; color: #aaa; text-align: center; margin: .5rem 0 0; }
.auth-terms-note a { color: var(--mocha); }
.input-prefix-wrap { display: flex; align-items: stretch; }
.input-prefix {
    background: rgba(75,46,43,.08); border: 1.5px solid rgba(75,46,43,.2);
    border-right: none; border-radius: 8px 0 0 8px;
    padding: 0 .75rem; display: flex; align-items: center; font-size: .9rem; color: #888;
}
.input-with-prefix { border-radius: 0 8px 8px 0; }

/* ===== Static prose pages ============================================ */
.page-wrap { max-width: 760px; margin: 0 auto; padding: 3rem 1.5rem; }
.page-hero { text-align: center; margin-bottom: 3rem; }
.page-hero-icon { font-size: 3rem; display: block; margin-bottom: 1rem; }
.page-hero h1 { margin: 0 0 .75rem; font-size: 2.2rem; }
.page-hero-sub { font-size: 1.05rem; color: #888; margin: 0; }
.prose-section { margin-bottom: 2.5rem; }
.prose-section h2 { font-size: 1.2rem; color: var(--brown); margin-bottom: .75rem; border-bottom: 2px solid var(--cream); padding-bottom: .4rem; }
.prose-section p { line-height: 1.85; color: #444; margin-bottom: 1rem; }
.prose-section p:last-child { margin-bottom: 0; }

@media (max-width: 860px) {
    .post-show-layout { grid-template-columns: 1fr; }
    .admin-brew-grid { grid-template-columns: repeat(2,1fr); }
    #cc-atm-bar { bottom: 1rem; right: 1rem; }
}


/* ══ Nav user menu — corrected for dark brown nav background ══════════════ */
.nav__auth {
    display: flex;
    align-items: center;
    gap: .6rem;
    flex-shrink: 0;
}
.nav__user-menu { position: relative; }

.nav__user-btn {
    display: inline-flex;
    align-items: center;
    gap: .45rem;
    background: rgba(255,255,255,.10);
    border: 1.5px solid rgba(245,233,211,.30);
    border-radius: 24px;
    padding: .28rem .75rem .28rem .35rem;
    cursor: pointer;
    font-size: .83rem;
    color: rgba(245,233,211,.92);
    font-family: inherit;
    font-weight: 500;
    white-space: nowrap;
    transition: background .15s, border-color .15s;
    line-height: 1;
}
.nav__user-btn:hover {
    background: rgba(255,255,255,.18);
    border-color: var(--mint);
    color: #fff;
}
.nav__user-avatar {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background: var(--teal);
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: .78rem;
    font-weight: 700;
    flex-shrink: 0;
    border: 2px solid rgba(255,255,255,.25);
}
.nav__user-name {
    max-width: 110px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    font-weight: 600;
}
.nav__user-chevron { font-size: .7rem; opacity: .7; }

/* Dropdown panel */
.nav__user-dropdown {
    display: none;
    position: absolute;
    right: 0;
    top: calc(100% + .45rem);
    background: #fff;
    border-radius: 12px;
    border: 1px solid rgba(75,46,43,.12);
    box-shadow: 0 8px 32px rgba(0,0,0,.14);
    min-width: 180px;
    z-index: 600;
    overflow: hidden;
    animation: dropIn .12s ease;
}
@keyframes dropIn {
    from { opacity: 0; transform: translateY(-6px); }
    to   { opacity: 1; transform: translateY(0); }
}
.nav__user-menu.open .nav__user-dropdown { display: block; }

.nav__user-dropdown a,
.nav__logout-btn {
    display: flex;
    align-items: center;
    gap: .5rem;
    padding: .65rem 1rem;
    font-size: .875rem;
    color: var(--charcoal);
    text-decoration: none;
    width: 100%;
    text-align: left;
    background: none;
    border: none;
    cursor: pointer;
    transition: background .1s;
    font-family: inherit;
    line-height: 1.4;
}
.nav__user-dropdown a:hover,
.nav__logout-btn:hover {
    background: var(--cream);
    color: var(--brown);
}
.nav__dropdown-divider {
    height: 1px;
    background: rgba(75,46,43,.08);
    margin: .2rem 0;
}

/* ══ Atmosphere widget — polished ════════════════════════════════════════ */
#cc-atm-bar {
    position: fixed;
    bottom: 1.5rem;
    right: 1.5rem;
    z-index: 900;
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: .5rem;
}
.atm-toggle-btn {
    width: 46px;
    height: 46px;
    border-radius: 50%;
    background: var(--brown);
    color: #fff;
    border: none;
    cursor: pointer;
    font-size: 1.25rem;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 3px 14px rgba(75,46,43,.45);
    transition: background .2s, transform .2s, box-shadow .2s;
}
.atm-toggle-btn:hover {
    background: var(--teal);
    transform: scale(1.08);
    box-shadow: 0 4px 18px rgba(27,163,156,.45);
}
.atm-panel {
    display: none;
    flex-direction: column;
    gap: .75rem;
    background: #fff;
    border-radius: 16px;
    padding: 1.1rem 1.3rem 1rem;
    border: 1px solid rgba(75,46,43,.12);
    box-shadow: 0 12px 40px rgba(0,0,0,.18);
    min-width: 250px;
    margin-bottom: .35rem;
}
.atm-panel.open { display: flex; }

.atm-panel-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: .25rem;
}
.atm-panel-title {
    font-size: .78rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: .09em;
    color: var(--brown);
}
.atm-close-btn {
    background: none; border: none; cursor: pointer;
    color: #bbb; font-size: 1rem; line-height: 1; padding: 0;
}
.atm-close-btn:hover { color: var(--brown); }

.atm-row { display: flex; flex-direction: column; gap: .35rem; }
.atm-label {
    font-size: .7rem;
    text-transform: uppercase;
    letter-spacing: .08em;
    color: #aaa;
    font-weight: 700;
}
.atm-scenes { display: flex; flex-wrap: wrap; gap: .3rem; }
.atm-scene-btn {
    padding: .22rem .65rem;
    border-radius: 20px;
    border: 1.5px solid rgba(75,46,43,.15);
    background: #fafafa;
    font-size: .78rem;
    cursor: pointer;
    transition: all .15s;
    font-family: inherit;
}
.atm-scene-btn:hover { border-color: var(--teal); color: var(--teal); background: rgba(27,163,156,.05); }
.atm-scene-btn.active { background: var(--brown); color: #fff; border-color: var(--brown); }
.atm-slider { width: 100%; accent-color: var(--teal); cursor: pointer; }
.atm-divider { height: 1px; background: rgba(75,46,43,.08); margin: .15rem 0; }
.atm-btn-ghost {
    background: none;
    border: 1.5px solid rgba(75,46,43,.18);
    border-radius: 8px;
    padding: .32rem .85rem;
    font-size: .8rem;
    cursor: pointer;
    color: var(--brown);
    transition: all .15s;
    width: 100%;
    text-align: center;
    font-family: inherit;
}
.atm-btn-ghost:hover { background: var(--cream); }

/* ══ Footer ensure styled ════════════════════════════════════════════════ */
.footer {
    background: var(--brown-dark);
    color: rgba(245,233,211,.7);
    padding: 2rem 0;
    margin-top: auto;
    font-size: .875rem;
    position: relative;
    z-index: 1;
}
.footer__inner {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 1rem;
}
.footer__brand {
    font-family: var(--font-head);
    color: var(--cream);
    font-size: 1.05rem;
    font-weight: 700;
}
.footer__links { display: flex; gap: 1.25rem; flex-wrap: wrap; }
.footer__links a { color: rgba(245,233,211,.6); font-size: .83rem; transition: color .15s; }
.footer__links a:hover { color: var(--cream); }

@media (max-width: 768px) {
    #cc-atm-bar { bottom: 1rem; right: 1rem; }
    .footer__inner { flex-direction: column; text-align: center; }
}


/* ══ Admin shell layout ══════════════════════════════════════════════════ */
.admin-shell {
    display: flex;
    min-height: calc(100vh - 62px);
    align-items: stretch;
}

.admin-sidebar {
    width: 210px;
    flex-shrink: 0;
    background: var(--brown-dark);
    padding: 1.5rem 0 2rem;
    display: flex;
    flex-direction: column;
}
.admin-sidebar-title {
    font-family: var(--font-head);
    color: var(--cream);
    font-size: .95rem;
    font-weight: 700;
    padding: 0 1.25rem 1rem;
    border-bottom: 1px solid rgba(245,233,211,.1);
    margin-bottom: .5rem;
}
.admin-sidebar-nav {
    display: flex;
    flex-direction: column;
    gap: .1rem;
    padding: .5rem 0;
}
.admin-sidebar-nav a {
    display: block;
    padding: .55rem 1.25rem;
    color: rgba(245,233,211,.7);
    font-size: .875rem;
    font-weight: 500;
    text-decoration: none;
    border-left: 3px solid transparent;
    transition: all .12s;
}
.admin-sidebar-nav a:hover {
    background: rgba(255,255,255,.06);
    color: var(--cream);
}
.admin-sidebar-nav a.active {
    background: rgba(27,163,156,.15);
    color: var(--mint);
    border-left-color: var(--teal);
    font-weight: 600;
}
.admin-sidebar-divider {
    height: 1px;
    background: rgba(245,233,211,.1);
    margin: .75rem 1.25rem;
}

.admin-content {
    flex: 1;
    padding: 2rem 2.5rem;
    min-width: 0;
    background: #f7f4f0;
}

/* Page header */
.admin-page-header {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 1.75rem;
    padding-bottom: 1rem;
    border-bottom: 2px solid var(--divider);
}
.admin-page-header h1 { margin: 0; font-size: 1.5rem; }
.admin-page-sub { color: #aaa; font-size: .875rem; }

/* Flash messages */
.admin-flash-success {
    background: #f0fdf4;
    border: 1px solid #bbf7d0;
    border-radius: 8px;
    padding: .75rem 1rem;
    color: #166534;
    font-size: .9rem;
    margin-bottom: 1.5rem;
}
.admin-flash-error {
    background: #fef2f2;
    border: 1px solid #fecaca;
    border-radius: 8px;
    padding: .75rem 1rem;
    color: #991b1b;
    font-size: .9rem;
    margin-bottom: 1.5rem;
}

/* Stats grid */
.admin-stats-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1rem;
    margin-bottom: 2rem;
}
.admin-menu-stats {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(120px,1fr));
    gap: 1rem;
    margin-bottom: 2rem;
}
.admin-stat-card {
    background: #fff;
    border-radius: 12px;
    padding: 1.25rem;
    text-align: center;
    border: 1px solid rgba(75,46,43,.08);
}
.admin-stat-icon { font-size: 1.6rem; margin-bottom: .4rem; }
.admin-stat-num  { font-size: 2rem; font-weight: 700; color: var(--brown); line-height: 1.1; }
.admin-stat-label { font-size: .78rem; color: #aaa; text-transform: uppercase; letter-spacing: .05em; margin-top: .2rem; }

/* Two-column */
.admin-two-col {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
}
.admin-section-title {
    font-size: 1rem;
    color: var(--brown);
    margin-bottom: 1rem;
    padding-bottom: .4rem;
    border-bottom: 1px solid var(--divider);
}
.admin-more-link {
    display: inline-block;
    margin-top: .75rem;
    font-size: .83rem;
    color: var(--teal);
    font-weight: 600;
}

/* Table tweaks for admin background */
.admin-content .admin-table {
    background: #fff;
}
.admin-content .admin-table td,
.admin-content .admin-table th { white-space: normal; }

/* Member actions */
.admin-member-actions {
    display: flex;
    flex-wrap: wrap;
    gap: .5rem;
    align-items: center;
}
.admin-bean-form {
    display: flex;
    gap: .3rem;
    align-items: center;
    flex-wrap: wrap;
}
.admin-bean-input {
    width: 80px;
    padding: .3rem .5rem;
    border: 1.5px solid rgba(75,46,43,.2);
    border-radius: 6px;
    font-size: .82rem;
}
.admin-bean-reason {
    width: 110px;
    padding: .3rem .5rem;
    border: 1.5px solid rgba(75,46,43,.2);
    border-radius: 6px;
    font-size: .82rem;
}

/* Reward grid */
.admin-reward-grid {
    display: flex;
    flex-direction: column;
    gap: .75rem;
}
.admin-reward-row {
    display: flex;
    align-items: center;
    gap: 1rem;
    background: #fff;
    padding: .75rem 1rem;
    border-radius: 8px;
    border: 1px solid rgba(75,46,43,.08);
}
.admin-reward-row label {
    flex: 1;
    font-size: .875rem;
    font-weight: 600;
    color: var(--charcoal);
}
.admin-reward-input {
    width: 90px;
    padding: .4rem .6rem;
    border: 1.5px solid rgba(75,46,43,.2);
    border-radius: 6px;
    font-size: .9rem;
    text-align: right;
}
.admin-reward-unit { font-size: .82rem; color: #aaa; white-space: nowrap; }

/* btn-ghost */
.btn-ghost {
    background: none;
    border: 1.5px solid rgba(75,46,43,.2);
    color: var(--brown);
}
.btn-ghost:hover { background: var(--cream); color: var(--brown); }

@media (max-width: 900px) {
    .admin-sidebar { width: 180px; }
    .admin-content { padding: 1.25rem; }
    .admin-stats-grid { grid-template-columns: repeat(2,1fr); }
    .admin-two-col { grid-template-columns: 1fr; }
}
@media (max-width: 640px) {
    .admin-shell { flex-direction: column; }
    .admin-sidebar { width: 100%; padding: .75rem 0; }
    .admin-sidebar-nav { flex-direction: row; flex-wrap: wrap; padding: 0 .5rem; }
    .admin-sidebar-nav a { border-left: none; border-bottom: 2px solid transparent; padding: .4rem .75rem; }
    .admin-sidebar-nav a.active { border-bottom-color: var(--teal); border-left: none; }
}

/* Admin role select */
.admin-role-select {
    padding: .3rem .5rem;
    border: 1.5px solid rgba(75,46,43,.2);
    border-radius: 6px;
    font-size: .82rem;
    background: #fff;
    cursor: pointer;
    font-family: inherit;
}
.admin-role-select:focus { outline: none; border-color: var(--teal); }
.admin-role-select option[value=admin]     { color: var(--brown); font-weight:700; }
.admin-role-select option[value=moderator] { color: var(--teal);  font-weight:600; }

/* Remove top gap between nav and content */
.page-body { padding-top: 0; }


/* ══ Atmosphere widget v2 — music ═══════════════════════════════════════ */
.atm-bottom-row {
    display: flex; gap: .5rem; align-items: center;
}
.atm-play-btn {
    background: var(--teal); color: #fff; border: none;
    border-radius: 8px; padding: .38rem .9rem; font-size: .85rem;
    font-weight: 600; cursor: pointer; font-family: inherit;
    transition: background .15s; white-space: nowrap;
}
.atm-play-btn:hover { background: var(--teal-dark); }

.atm-status {
    font-size: .72rem; font-weight: 700; letter-spacing: .04em;
    color: var(--teal); min-width: 80px; text-align: right;
    flex: 1;
}

.atm-credit {
    font-size: .7rem; color: #ccc; margin: .35rem 0 0;
    text-align: right;
}
.atm-credit a { color: #bbb; }
.atm-credit a:hover { color: #fff; }

/* Wider panel for more genres */
.atm-panel { min-width: 280px; }
.atm-scenes { gap: .3rem; }
.atm-scene-btn { font-size: .76rem; padding: .2rem .6rem; }

/* ══ Contact Form ═══════════════════════════════════════════════════════ */
.contact-wrap {
    max-width: 700px;
    margin: 2.5rem auto;
    padding: 0 1rem;
}
.contact-card {
    background: #fff;
    border-radius: 12px;
    border: 1px solid rgba(75,46,43,.1);
    padding: 2rem 2.25rem;
}
.contact-title {
    font-size: 1.5rem;
    font-weight: 800;
    margin: 0 0 .35rem;
    color: var(--brown);
}
.contact-sub {
    color: #888;
    margin: 0 0 1.75rem;
    font-size: .9rem;
}
.contact-form .form-group {
    margin-bottom: 1.25rem;
}
.contact-form label {
    display: block;
    font-size: .85rem;
    font-weight: 700;
    color: var(--charcoal);
    margin-bottom: .35rem;
}
.contact-actions {
    display: flex;
    gap: .75rem;
    justify-content: flex-end;
    margin-top: 1.5rem;
}
.contact-header-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 1.5rem;
}
.contact-msg-row {
    padding: 1rem 0;
    border-bottom: 1px solid rgba(75,46,43,.08);
}
.contact-msg-row:last-child { border-bottom: none; }
.contact-msg-meta {
    display: flex;
    align-items: center;
    gap: .75rem;
    margin-bottom: .3rem;
}
.contact-msg-subject {
    font-weight: 700;
    color: var(--charcoal);
}
.contact-msg-preview {
    font-size: .85rem;
    color: #666;
    line-height: 1.4;
}
.contact-reply-preview {
    font-size: .82rem;
    color: var(--teal);
    margin-top: .35rem;
}
.contact-reply-label {
    font-weight: 700;
    margin-right: .3rem;
}
.contact-msg-date {
    font-size: .76rem;
    color: #aaa;
    margin-top: .35rem;
}

/* Status pills */
.contact-status-pill {
    font-size: .72rem;
    font-weight: 700;
    letter-spacing: .04em;
    padding: .15rem .55rem;
    border-radius: 20px;
    text-transform: uppercase;
    display: inline-block;
}
.pill-pending  { background: #fff3cd; color: #856404; }
.pill-read     { background: #d1ecf1; color: #0c5460; }
.pill-resolved { background: #d4edda; color: #155724; }

/* Admin contact index */
.contact-admin-counts {
    display: flex;
    gap: .75rem;
    margin-bottom: 1.5rem;
}
.cac-pill {
    font-size: .8rem;
    font-weight: 700;
    padding: .3rem .85rem;
    border-radius: 20px;
}
.cac-pill.pending  { background: #fff3cd; color: #856404; }
.cac-pill.read     { background: #d1ecf1; color: #0c5460; }
.cac-pill.resolved { background: #d4edda; color: #155724; }

.contact-row-pending td { font-weight: 600; }

/* Admin contact detail */
.contact-admin-detail {
    display: flex;
    flex-direction: column;
    gap: 1.25rem;
}
.cad-card {
    background: #fff;
    border: 1px solid rgba(75,46,43,.1);
    border-radius: 10px;
    padding: 1.5rem;
}
.cad-meta {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: .75rem;
}
.cad-subject {
    font-size: 1.2rem;
    font-weight: 800;
    margin: 0 0 1rem;
    color: var(--brown);
}
.cad-body {
    font-size: .93rem;
    line-height: 1.6;
    color: #444;
    white-space: pre-wrap;
}
.cad-reply-card { border-color: var(--teal); }
.cad-reply-label {
    font-size: .8rem;
    font-weight: 700;
    color: var(--teal);
    text-transform: uppercase;
    letter-spacing: .04em;
    margin-bottom: .5rem;
}

/* Admin sidebar badge */
.admin-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: #e74c3c;
    color: #fff;
    border-radius: 50%;
    font-size: .65rem;
    font-weight: 800;
    min-width: 18px;
    height: 18px;
    padding: 0 4px;
    margin-left: .4rem;
    vertical-align: middle;
}

/* flash-success (member side) */
.flash-success {
    background: #d4edda;
    color: #155724;
    border: 1px solid #c3e6cb;
    border-radius: 8px;
    padding: .75rem 1rem;
    font-size: .9rem;
}

/* ══ Dashboard messages section ════════════════════════════════════ */
.dash-section-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: .15rem;
}
.dash-section-header h2 { margin: 0; }
.dash-section-link {
    font-size: .78rem;
    font-weight: 700;
    color: var(--teal);
    text-decoration: none;
    white-space: nowrap;
}
.dash-section-link:hover { text-decoration: underline; }
.dash-msg-row {
    padding: .7rem 0;
    border-bottom: 1px solid rgba(75,46,43,.07);
}
.dash-msg-row:last-of-type { border-bottom: none; }
.dash-msg-top {
    display: flex;
    align-items: center;
    gap: .5rem;
    margin-bottom: .2rem;
}
.dash-msg-subject {
    font-size: .88rem;
    font-weight: 700;
    color: var(--charcoal);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 160px;
}
.dash-msg-preview {
    font-size: .78rem;
    color: #888;
    line-height: 1.35;
}
.dash-msg-reply {
    font-size: .78rem;
    color: var(--teal);
    line-height: 1.35;
}
.dash-msg-date {
    font-size: .72rem;
    color: #bbb;
    margin-top: .15rem;
}
.dash-more-link {
    display: inline-block;
    margin-top: .6rem;
    font-size: .8rem;
    color: var(--teal);
    font-weight: 600;
    text-decoration: none;
}
.dash-more-link:hover { text-decoration: underline; }

/* ══ form-control alias (contact form, etc.) ════════════════════════════ */
.form-control {
    display: block;
    width: 100%;
    padding: .55rem .85rem;
    border: 1.5px solid rgba(75,46,43,.2);
    border-radius: var(--radius);
    font-family: var(--font-body);
    font-size: .9rem;
    background: #fff;
    color: var(--charcoal);
    transition: border-color .15s;
    box-sizing: border-box;
}
.form-control:focus {
    outline: none;
    border-color: var(--teal);
    box-shadow: 0 0 0 3px rgba(94,131,126,.12);
}
textarea.form-control { resize: vertical; }
.form-control.is-invalid,
.form-input.is-invalid,
.form-textarea.is-invalid { border-color: #e74c3c; }

/* ══ IP Data admin page ═════════════════════════════════════════════════ */
.ip-count-row {
    display: flex;
    gap: 1rem;
    margin-bottom: 1.5rem;
    flex-wrap: wrap;
}
.ip-count-pill {
    background: #fff;
    border: 1px solid rgba(75,46,43,.1);
    border-radius: 10px;
    padding: .75rem 1.25rem;
    min-width: 110px;
    text-align: center;
}
.ip-count-num {
    display: block;
    font-size: 1.5rem;
    font-weight: 800;
    color: var(--brown);
    line-height: 1;
}
.ip-count-label {
    display: block;
    font-size: .75rem;
    color: #888;
    margin-top: .2rem;
    text-transform: capitalize;
}
.ip-filter-bar {
    display: flex;
    gap: .6rem;
    align-items: center;
    flex-wrap: wrap;
    margin-bottom: 1.25rem;
    background: #fff;
    padding: .75rem 1rem;
    border-radius: 8px;
    border: 1px solid rgba(75,46,43,.08);
}
.ip-filter-input {
    padding: .35rem .65rem;
    border: 1.5px solid rgba(75,46,43,.2);
    border-radius: 6px;
    font-size: .85rem;
    font-family: inherit;
    background: #fff;
}
.ip-filter-input:focus { outline: none; border-color: var(--teal); }
.ip-sort-link {
    color: var(--charcoal);
    text-decoration: none;
    font-weight: 600;
    font-size: .82rem;
    white-space: nowrap;
}
.ip-sort-link:hover { color: var(--teal); }
.ip-cat-pill {
    font-size: .72rem;
    font-weight: 700;
    padding: .15rem .55rem;
    border-radius: 20px;
    text-transform: capitalize;
    display: inline-block;
}
.cat-login         { background: #d1ecf1; color: #0c5460; }
.cat-register      { background: #d4edda; color: #155724; }
.cat-post_write    { background: #fff3cd; color: #856404; }
.cat-contact_write { background: #f8d7da; color: #721c24; }

/* ══ room page - btn-primary visibility fix ════════════════════════════ */
.section-header .btn-primary { color: #fff !important; }

/* ══ SVG Logo sizing ════════════════════════════════════════════════════ */
.nav__logo-img {
    height: 38px;
    width: auto;
    display: block;
    /* keep vertical rhythm in the nav */
}
.nav__brand {
    display: flex;
    align-items: center;
    padding: 0;
    line-height: 1;
}
.nav__brand:hover { opacity: .85; }

.footer__logo-img {
    height: 30px;
    width: auto;
    display: block;
    opacity: .92;
    transition: opacity .15s;
}
.footer__logo-img:hover { opacity: 1; }
.footer__brand a { display: inline-flex; align-items: center; }

/* Admin sidebar logo */
.admin-sidebar-logo {
    padding: 1.1rem 1.25rem .85rem;
    border-bottom: 1px solid rgba(245,233,211,.1);
    margin-bottom: .5rem;
    display: flex;
    align-items: center;
    gap: .6rem;
}
.admin-logo-img {
    height: 28px;
    width: auto;
    display: block;
}
.admin-sidebar-badge {
    font-size: .62rem;
    font-weight: 800;
    letter-spacing: .08em;
    text-transform: uppercase;
    background: rgba(217,119,6,.25);
    color: #D97706;
    padding: .15rem .45rem;
    border-radius: 4px;
    white-space: nowrap;
    align-self: center;
}
/* hide old title (replaced by logo block) */
.admin-sidebar-title { display: none; }

/* logo height bump after font-size increase */
.nav__logo-img    { height: 44px; }
.footer__logo-img { height: 34px; }
.admin-logo-img   { height: 32px; }

/* logo font-size bump (68px pass) */
.nav__logo-img    { height: 50px; }
.footer__logo-img { height: 38px; }
.admin-logo-img   { height: 34px; }

/* admin standalone body — no nav gap */
.admin-body { background: #F7F3EE; min-height: 100vh; margin: 0; padding: 0; }
.admin-body .admin-shell { min-height: 100vh; }

/* logo size restore 52px */
.nav__logo-img { height: 44px; }
.footer__logo-img { height: 34px; }
.admin-logo-img { height: 32px; }
