/* ============================================================
   COMERÇOS — directori complet amb paginació
   Reutilitza nav, footer, dividers, paper-grain, stamps,
   .sector-grid i .sector-card de styles.css
   ============================================================ */

.cmcs-wrap { max-width: 1600px; margin: 0 auto; padding: 0 24px; width: 100%; }
.cmcs-narrow { max-width: 1180px; }

/* --- capçalera --- */
.cmcs-header { padding: 124px 0 0; }
.cmcs-header .kicker-bracket { margin-bottom: 14px; }
.cmcs-title {
  font-family: 'Young Serif', serif; font-weight: 400;
  font-size: clamp(40px, 5vw, 72px); line-height: 1.02; letter-spacing: -.02em;
  color: #2a241d; margin: 0 0 14px;
}
.cmcs-intro {
  font-family: 'Newsreader', serif; font-style: italic; font-size: 20px;
  line-height: 1.5; color: #6f6555; max-width: 600px; margin: 0;
}
.cmcs-intro strong { font-style: normal; color: #b1432c; font-weight: 600; }

/* --- barra d'eines --- */
.cmcs-toolbar { padding: 34px 0 0; display: flex; flex-direction: column; gap: 22px; }
.cmcs-search {
  display: flex; align-items: center; gap: 14px; max-width: 520px;
  background: #fffdf8; border: 1.5px solid #e1d4bd; border-radius: 999px;
  padding: 9px 9px 9px 22px; box-shadow: 0 18px 44px -22px rgba(98, 74, 40, .4);
}
.cmcs-search input { flex: 1; border: none; outline: none; background: transparent; font-family: 'Atkinson Hyperlegible', sans-serif; font-size: 17px; color: #2a241d; min-width: 0; }
.cmcs-search button { flex: none; background: #b1432c; color: #fff; border: none; border-radius: 999px; padding: 11px 22px; font-family: 'Atkinson Hyperlegible', sans-serif; font-size: 15px; font-weight: 600; cursor: pointer; }
.cmcs-filters { display: flex; flex-wrap: wrap; gap: 10px; }
.cmcs-filters .chip {
  background: #fffdf8; border: 1px solid #e1d4bd; color: #5c5345;
  border-radius: 999px; padding: 9px 17px; font-family: 'Atkinson Hyperlegible', sans-serif;
  font-size: 14px; font-weight: 500; cursor: pointer; transition: all .18s ease; white-space: nowrap;
}
.cmcs-filters .chip:hover { border-color: #b1432c; color: #b1432c; }
.cmcs-filters .chip.active { background: #b1432c; border-color: #b1432c; color: #fffdf8; }

/* --- recompte --- */
.cmcs-count {
  display: flex; align-items: baseline; gap: 8px; flex-wrap: wrap;
  font-size: 14px; color: rgba(241, 231, 214, .7); font-weight: 500; margin-bottom: 28px;
}
.cmcs-count strong { color: #f1e7d6; font-weight: 600; }
.cmcs-count .reset { margin-left: auto; color: #e9c46a; text-decoration: none; font-size: 13.5px; font-weight: 600; cursor: pointer; }
.cmcs-count .reset:hover { text-decoration: underline; }

/* --- estat buit --- */
.cmcs-empty { text-align: center; padding: 60px 20px; color: rgba(241, 231, 214, .7); }
.cmcs-empty .big { font-family: 'Young Serif', serif; font-size: 26px; color: #f1e7d6; margin: 0 0 10px; }

/* --- paginació --- */
.pagination {
  display: flex; align-items: center; justify-content: center; flex-wrap: wrap; gap: 8px;
  margin-top: 52px;
}
.pagination button {
  min-width: 44px; height: 44px; padding: 0 14px;
  background: transparent; border: 1px solid rgba(241, 231, 214, .22);
  color: rgba(241, 231, 214, .85); border-radius: 10px;
  font-family: 'Atkinson Hyperlegible', sans-serif; font-size: 15px; font-weight: 600;
  cursor: pointer; transition: all .18s ease;
}
.pagination button:hover:not(:disabled):not(.active) { border-color: #e9c46a; color: #e9c46a; }
.pagination button.active { background: #b1432c; border-color: #b1432c; color: #fffdf8; cursor: default; }
.pagination button:disabled { opacity: .35; cursor: not-allowed; }
.pagination .ellipsis { color: rgba(241, 231, 214, .5); padding: 0 4px; align-self: center; }
.pagination .nav-btn { display: inline-flex; align-items: center; gap: 7px; }

/* ============================================================
   RESPONSIVE
   ============================================================ */
@media (max-width: 1500px) {
  .sectores-listing .sector-grid { grid-template-columns: repeat(3, 1fr); }
}
@media (max-width: 1100px) {
  .sectores-listing .sector-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 720px) {
  .cmcs-wrap { padding: 0 22px; }
  .cmcs-header { padding-top: 100px; }
  .cmcs-intro { font-size: 18px; }
  .cmcs-search input { font-size: 16px; }
  .sectores-listing .sector-grid { grid-template-columns: 1fr; }
  .pagination button { min-width: 42px; height: 42px; }
}
@media (max-width: 480px) {
  .cmcs-wrap { padding: 0 18px; }
  .pagination .nav-btn span { display: none; }
}
