/* === Reset & Base === */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
[hidden] { display: none !important; }

:root {
  --bg: #0f0f0f;
  --bg2: #1a1a1a;
  --bg3: #242424;
  --text: #e8e8e8;
  --text2: #888;
  --accent: #1a6fb5;
  --accent-light: #4a9fd4;
  --border: #2a2a2a;
  --font-body: 'Source Sans 3', system-ui, -apple-system, sans-serif;
  --font-head: 'Merriweather', Georgia, serif;
  --max-w: 1200px;
  --logo-offset: 280px;
}

/* Contingut amb offset esquerre 1/4 blanc + 3/4 text */
.text-offset {
  display: grid;
  grid-template-columns: 1fr 3fr;
}
.text-offset > * { grid-column: 2; }
.text-offset .page-content,
.text-offset .projecte-text,
.text-offset .musics-intro,
.text-offset .section-intro,
.text-offset .historia-content,
.text-offset p { max-width: none; width: 100%; }

html { font-size: 16px; scroll-behavior: smooth; }
body { background: var(--bg); color: var(--text); font-family: var(--font-body); line-height: 1.6; }
a { color: var(--accent-light); text-decoration: none; }
a:hover { color: var(--accent-light); }
img { max-width: 100%; display: block; }

.container { max-width: var(--max-w); margin: 0 auto; padding: 0 1.5rem; }

/* === Password Gate === */
#pwd-gate {
  position: fixed; inset: 0; z-index: 9999;
  background: var(--bg);
  display: flex; align-items: center; justify-content: center;
}
.pwd-box { text-align: center; max-width: 360px; padding: 2rem; }
.pwd-title { font-family: var(--font-head); font-size: 1.5rem; margin-bottom: .5rem; }
.pwd-sub { color: var(--text2); font-size: .9rem; margin-bottom: 2rem; }
#pwd-form { display: flex; flex-direction: column; gap: .75rem; }
#pwd-input {
  background: var(--bg2); border: 1px solid var(--border); color: var(--text);
  padding: .75rem 1rem; font-size: 1rem; border-radius: 4px;
  text-align: center; letter-spacing: .1em;
}
#pwd-input:focus { outline: none; border-color: var(--accent); }
#pwd-form button {
  background: var(--accent); color: #fff; border: none;
  padding: .75rem 1rem; font-size: 1rem; font-weight: 600;
  border-radius: 4px; cursor: pointer;
}
#pwd-form button:hover { background: var(--accent-light); }
#pwd-error { color: #e05; font-size: .85rem; }

/* === Header === */
.site-header {
  border-bottom: 1px solid var(--border);
  position: sticky; top: 0;
  background: rgba(11,22,38,.97);
  backdrop-filter: blur(8px);
  z-index: 100;
}
.site-header .container { display: flex; padding: 0 1.5rem; }
.header-right { display: flex; flex-direction: column; flex: 1; min-width: 0; }

/* Fila 1: logo + títol + cerca */
.header-top {
  display: flex; align-items: center; justify-content: space-between; gap: 1rem;
  padding: .4rem 0;
}
.site-brand { display: flex; align-items: center; gap: .85rem; color: var(--text); }
.site-brand:hover { color: var(--accent-light); }
.site-logo { width: 80px; height: 80px; border-radius: 50%; flex-shrink: 0; }
.site-brand-text { font-family: var(--font-head); font-size: 1rem; line-height: 1.3; }
.header-top-right { display: flex; align-items: center; gap: 1rem; }
.header-social { color: var(--text2); display: flex; align-items: center; transition: color .15s; }
.header-social:hover { color: var(--accent-light); }

/* Fila 2: nav */
.header-nav {
  display: flex; gap: 2rem; flex-wrap: wrap;
  justify-content: flex-end;
  padding: .2rem 0 .35rem;
}
.header-nav a {
  color: var(--text2); font-size: 1.3rem;
  position: relative; padding-bottom: 3px;
  transition: color .2s;
}
.header-nav a::after {
  content: ''; position: absolute; bottom: 0; left: 0;
  width: 0; height: 2px;
  background: var(--accent-light);
  transition: width .25s ease;
}
.header-nav a:hover { color: var(--accent-light); }
.header-nav a:hover::after { width: 100%; }

/* === Header search === */
.header-cerca {
  display: flex; align-items: center;
  background: var(--bg2); border: 1px solid var(--border);
  border-radius: 4px; overflow: hidden;
  flex-shrink: 0;
}
.header-cerca-input {
  background: transparent; border: none; outline: none;
  color: var(--text); font-size: .85rem;
  padding: .35rem .6rem; width: 140px;
}
.header-cerca-input::placeholder { color: var(--text2); }
.header-cerca-btn {
  background: transparent; border: none; cursor: pointer;
  color: var(--text2); padding: .35rem .5rem;
  display: flex; align-items: center;
  transition: color .15s;
}
.header-cerca-btn:hover { color: var(--accent-light); }

/* === Search page === */
.cerca-section { padding: 3rem 0; }
.cerca-title {
  font-family: var(--font-head); font-size: 2rem;
  margin-bottom: 1.5rem; padding-bottom: 1rem;
  border-bottom: 1px solid var(--border);
}
.cerca-form { margin-bottom: 1rem; }
.cerca-input {
  width: 100%; max-width: 600px;
  background: var(--bg2); border: 1px solid var(--border);
  color: var(--text); font-size: 1.1rem;
  padding: .75rem 1rem; border-radius: 4px; outline: none;
  font-family: var(--font-body);
}
.cerca-input:focus { border-color: var(--accent); }
.cerca-info { color: var(--text2); font-size: .85rem; margin-bottom: 1.5rem; min-height: 1.2em; }
.cerca-buit { color: var(--text2); }

.cerca-resultats {
  display: flex; flex-direction: column; gap: 1px;
  background: var(--border); border: 1px solid var(--border);
  max-width: 720px;
}
.cerca-card {
  background: var(--bg); padding: 1.25rem 1.5rem;
  display: flex; flex-direction: column; gap: .3rem;
  transition: background .15s;
}
.cerca-card:hover { background: var(--bg2); }
.cerca-label {
  font-size: .7rem; text-transform: uppercase;
  letter-spacing: .08em; color: var(--accent);
}
.cerca-nom {
  font-family: var(--font-head); font-weight: 700;
  font-size: 1.1rem; color: var(--text);
}
.cerca-meta { font-size: .85rem; color: var(--accent-light); }
.cerca-resum { font-size: .85rem; color: var(--text2); line-height: 1.5; margin-top: .15rem; }

/* === Footer === */
.site-footer {
  background: rgb(11,22,38);
  padding: 2rem 0;
  margin-top: 4rem;
  color: var(--text2);
  font-size: .85rem;
}
.footer-cols {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 2rem;
}
.footer-left { align-self: center; }
.footer-mid { align-self: center; }

/* Nav secundari footer — mateix efecte que header-nav */
.footer-nav-sec { display: flex; flex-direction: column; gap: .4rem; }
.footer-nav-sec a {
  color: var(--text2); font-size: 1.3rem;
  position: relative; padding-bottom: 3px;
  transition: color .2s; display: inline-flex; align-items: center; gap: .5rem;
}
.footer-nav-sec a::after {
  content: ''; position: absolute; bottom: 0; left: 0;
  width: 0; height: 2px;
  background: var(--accent-light);
  transition: width .25s ease;
}
.footer-nav-sec a:hover { color: var(--accent-light); }
.footer-nav-sec a:hover::after { width: 100%; }

.footer-editorial-logo { display: block; margin-bottom: .75rem; }
.footer-editorial-logo img { width: 72px; height: 72px; object-fit: contain; display: block; }
.footer-powered { color: var(--text2); font-size: .85rem; }
.footer-powered strong { color: var(--accent-light); }
.footer-powered:hover { color: var(--accent-light); }
.footer-powered-sub { font-size: .72rem; color: var(--text2); letter-spacing: .04em; }
.footer-right { text-align: right; display: flex; flex-direction: column; align-items: flex-end; gap: .2rem; }
.footer-copy { color: var(--text2); margin-bottom: .4rem; font-size: .85rem; }
.footer-copy a { color: var(--text2); }
.footer-copy a:hover { color: var(--accent-light); }
.footer-copyright { font-size: .72rem; color: var(--text2); opacity: .7; line-height: 1.5; margin-top: .3rem; max-width: 340px; }
.footer-copyright a { color: var(--text2); text-decoration: underline; }
.footer-copyright a:hover { color: var(--accent-light); }
.footer-legal { display: flex; gap: 1rem; justify-content: flex-start; }
.footer-legal a { color: var(--text2); font-size: .8rem; }
.footer-legal a:hover { color: var(--accent-light); }

/* === Buttons === */
.btn {
  display: inline-block; padding: .7rem 1.75rem;
  background: var(--accent); color: #fff; font-weight: 600;
  border-radius: 4px; margin: .25rem; font-size: .9rem;
  transition: background .15s;
}
.btn:hover { background: var(--accent-light); color: #fff; }
.btn-outline {
  background: transparent; color: var(--accent-light);
  border: 1px solid var(--accent);
}
.btn-outline:hover { background: var(--accent); color: #fff; }
.btn-disabled { opacity: .5; cursor: default; pointer-events: none; }

/* === Homepage Hero === */
.home-hero { padding: 5rem 0 4rem; }
.hero-grid {
  display: grid;
  grid-template-columns: 280px 1fr;
  gap: 4rem;
  align-items: center;
}
.hero-logo img {
  width: 100%;
  max-width: 280px;
  filter: drop-shadow(0 0 40px rgba(26,111,181,.3));
}
.hero-text h1 {
  font-family: var(--font-head);
  font-size: clamp(1.8rem, 3.5vw, 3rem);
  margin-bottom: 1.25rem;
  line-height: 1.2;
}
.hero-text p { color: var(--text2); font-size: 1.05rem; line-height: 1.8; margin-bottom: .75rem; }
.hero-text em { color: var(--accent-light); font-style: italic; }
.hero-actions { margin-top: 2rem; }

/* === Random Cards === */
.home-random { padding: 0 0 4rem; }
.random-grid {
  display: grid;
  grid-template-columns: 2fr 3fr;
  gap: 1px;
  background: var(--border);
  border: 1px solid var(--border);
}
.random-card {
  background: var(--bg2);
  padding: 2rem;
  transition: background .15s;
}
.random-card:hover { background: var(--bg3); }
.random-label {
  display: block;
  font-size: .75rem;
  text-transform: uppercase;
  letter-spacing: .08em;
  color: var(--accent);
  margin-bottom: .5rem;
}
.random-name { font-family: var(--font-head); font-size: 1.5rem; margin-bottom: .5rem; }
.random-name a { color: var(--text); }
.random-name a:hover { color: var(--accent-light); }
.random-meta { color: var(--accent-light); font-size: .9rem; }
.random-city { color: var(--text2); font-size: .85rem; margin-top: .25rem; }
.random-foto {
  width: 100%; max-width: 350px;
  aspect-ratio: 1;
  overflow: hidden;
  margin-bottom: 1.25rem;
}
.random-foto img {
  width: 100%; height: 100%;
  object-fit: cover; object-position: top;
  filter: grayscale(100%);
  display: block;
  transition: filter .3s;
}
.random-card--music:hover .random-foto img { filter: grayscale(0%); }
.random-llibres-stack { display: flex; flex-direction: column; gap: 0; margin-top: .75rem; }
.random-llibres-stack .llibre-home-card { padding: 1.5rem 0; }
.random-llibres-stack .llibre-home-card + .llibre-home-card { border-top: 1px solid var(--border); }
.random-llibres-stack .llibre-home-card img { width: 300px; max-width: 100%; flex-shrink: 0; }

/* === Books Home === */
.home-llibres { padding: 0 0 5rem; }
.home-autors { padding: 4rem 0; border-top: 1px solid var(--border); }
.home-numeros { padding: 4rem 0; border-top: 1px solid var(--border); }
.home-gracies { padding: 4rem 0; border-top: 1px solid var(--border); }
.section-title {
  font-family: var(--font-head);
  font-size: 1.5rem;
  margin-bottom: 2rem;
  padding-bottom: .75rem;
  border-bottom: 1px solid var(--border);
  color: var(--text2);
  text-transform: uppercase;
  letter-spacing: .05em;
  font-size: 1rem;
}
.llibres-home-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 3rem;
}
.llibre-home-card {
  display: grid;
  grid-template-columns: 130px 1fr;
  gap: 1.5rem;
  align-items: flex-start;
}
.llibre-home-card img {
  border: 1px solid var(--border);
  width: 130px;
}
.llibre-home-info h3 {
  font-family: var(--font-head);
  font-size: 1.2rem;
  margin-bottom: .3rem;
}
.llibre-home-info h3 a { color: var(--text); }
.llibre-home-info h3 a:hover { color: var(--accent-light); }
.llibre-sub { color: var(--accent); font-size: .8rem; margin-bottom: .6rem; }
.llibre-home-info p { color: var(--text2); font-size: .9rem; line-height: 1.7; margin-bottom: .75rem; }

/* === Músics Listing === */
.musics-section { padding: 3rem 0; }
.musics-section h1 { font-family: var(--font-head); font-size: 2rem; margin-bottom: 2rem; }

.filtres {
  display: flex; flex-wrap: wrap; gap: 1rem; align-items: center;
  margin-bottom: 1.5rem; padding: 1rem; background: var(--bg2); border-radius: 6px;
}
.filtres label { display: flex; flex-direction: column; gap: .25rem; font-size: .85rem; color: var(--text2); }
.filtres select, #filtre-cerca {
  background: var(--bg3); border: 1px solid var(--border); color: var(--text);
  padding: .4rem .75rem; border-radius: 4px; font-size: .9rem;
}
#filtre-cerca { min-width: 200px; }

.musics-count { color: var(--text2); font-size: .85rem; margin-bottom: 1.5rem; }

.musics-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 1px;
  background: var(--border);
  border: 1px solid var(--border);
}
.musico-card {
  background: var(--bg);
  display: block;
  transition: background .15s;
  overflow: hidden;
}
.musico-card:hover { background: var(--bg2); }
.card-foto { aspect-ratio: 1 / 1; overflow: hidden; background: var(--bg3); }
.card-foto img {
  width: 100%; height: 100%; object-fit: cover; object-position: top;
  display: block; filter: grayscale(100%); transition: filter .3s;
}
.musico-card:hover .card-foto img { filter: grayscale(0%); }
.card-foto-placeholder { width: 100%; height: 100%; background: var(--bg3); }
.card-nom { font-family: var(--font-head); font-size: 1rem; font-weight: 700; color: var(--text); margin: .75rem .75rem .15rem; }
.card-nom-complet { font-size: .75rem; color: var(--text2); margin: 0 .75rem .2rem; }
.card-meta { font-size: .75rem; color: var(--text2); margin: 0 .75rem; }
.card-instruments { font-size: .75rem; color: var(--accent-light); margin: .25rem .75rem .75rem; }

/* === Typography rules === */
.musico-nom,
.card-nom,
.random-name,
h1, h2, h3 { font-weight: 700; }

.musico-nom-complet,
.musico-dades,
.card-nom-complet,
.card-meta,
.random-city { font-family: 'Merriweather', Georgia, serif; font-weight: 400; }

.musico-bio,
.page-content,
.section-intro,
.musics-intro,
.autor-bio,
.projecte-text { font-family: 'Source Sans 3', system-ui, sans-serif; }

/* Breadcrumb */
.breadcrumb {
  font-size: .78rem; color: var(--text2);
  margin-bottom: 1.75rem; display: flex; align-items: center; flex-wrap: wrap; gap: .25rem;
}
.breadcrumb a { color: var(--text2); border-bottom: 1px dotted var(--border); }
.breadcrumb a:hover { color: var(--accent-light); border-bottom-color: var(--accent-light); }
.breadcrumb-actual { color: var(--text2); }

/* === Musician Single Page === */
.musico-page { padding: 3rem 0; }
.musico-layout {
  display: grid;
  grid-template-columns: 280px 1fr;
  gap: 3rem;
  align-items: flex-start;
  margin-bottom: 3rem; padding-bottom: 2rem; border-bottom: 1px solid var(--border);
}
.musico-layout--sense-foto { grid-template-columns: 1fr; }
.musico-foto-col { flex-shrink: 0; }
.musico-polaroid {
  display: inline-block;
  background: #fff;
  padding: 8px 8px 20px;
  box-shadow: 0 2px 12px rgba(0,0,0,.18), 0 0 0 1px rgba(0,0,0,.06);
}
.musico-polaroid--sense-data { padding-bottom: 8px; }
.musico-polaroid { position: relative; }
.musico-polaroid::after {
  content: '© Joan Linux';
  position: absolute;
  bottom: 10px; left: 50%;
  transform: translateX(-50%);
  font-family: var(--font-body);
  font-size: .65rem;
  letter-spacing: .06em;
  color: rgba(255,255,255,.45);
  pointer-events: none;
  white-space: nowrap;
  text-shadow: 0 1px 3px rgba(0,0,0,.7);
  z-index: 2;
}
.musico-foto-btn {
  background: none; border: none; padding: 0; cursor: zoom-in;
  position: relative; display: block;
}
.musico-foto-zoom {
  position: absolute; bottom: .5rem; right: .5rem;
  background: rgba(0,0,0,.55); color: #fff;
  font-size: .85rem; padding: .2rem .4rem; border-radius: 3px;
  opacity: 0; transition: opacity .2s; pointer-events: none;
}
.musico-foto-btn:hover .musico-foto-zoom { opacity: 1; }
.musico-foto {
  width: 280px; height: 280px;
  object-fit: cover; object-position: top;
  -webkit-user-drag: none;
  -webkit-touch-callout: none;
  user-select: none;
  filter: grayscale(100%);
  display: block;
  transition: filter .3s;
}
.musico-foto:hover { filter: grayscale(0%); }
.musico-foto-caption {
  display: flex; flex-direction: column; align-items: center;
  font-family: 'Caveat', cursive;
  color: #555;
  text-align: center;
  padding-top: 10px;
  line-height: 1.4;
}
.caption-text { font-size: .85rem; }
.caption-date { font-size: 1.05rem; font-weight: 600; }
.musico-info-col { min-width: 0; }
.musico-nom { font-family: var(--font-head); font-size: clamp(2rem, 4vw, 3rem); margin-bottom: .5rem; }
.musico-nom-complet { color: var(--text2); font-size: 1rem; margin-bottom: .75rem; }
.musico-dades { color: var(--text2); font-size: .95rem; margin-bottom: .5rem; }
.musico-dades a { color: var(--text2); border-bottom: 1px dotted var(--border); }
.musico-dades a:hover { color: var(--accent-light); border-bottom-color: var(--accent-light); }
.musico-instruments { color: var(--accent-light); font-size: .95rem; margin-bottom: .25rem; }
.musico-bandes { color: var(--text2); font-size: .9rem; }
.musico-rip { color: var(--text2); font-style: normal; }
.musico-bio { line-height: 1.8; font-size: 1.05rem; max-width: 72ch; margin-top: 2rem; padding-top: 1.5rem; border-top: 1px solid var(--border); }
.musico-bio p + p { margin-top: 1rem; }
.musico-bio em { color: var(--accent-light); font-style: italic; }

/* Acordió músic */
.musico-acordio { margin-top: 1.25rem; border-top: 1px solid var(--border); }
.acordio-item { border-bottom: 1px solid var(--border); }
.acordio-cap {
  width: 100%; display: flex; justify-content: space-between; align-items: center;
  background: none; border: none; cursor: pointer;
  padding: .75rem 0; color: var(--text);
  font-family: var(--font-head); font-size: 1rem;
  text-align: left; transition: color .2s;
}
.acordio-cap:hover { color: var(--accent-light); }
.acordio-cap[aria-expanded="true"] { color: var(--accent-light); }
.acordio-icon {
  font-size: 1.25rem; line-height: 1; color: var(--accent-light);
  transition: transform .3s ease; display: inline-block;
}
.acordio-cap[aria-expanded="true"] .acordio-icon { transform: rotate(45deg); }
.acordio-cos {
  display: grid;
  grid-template-rows: 0fr;
  transition: grid-template-rows .35s ease;
}
.acordio-cos.obert { grid-template-rows: 1fr; }
.acordio-cos-inner { overflow: hidden; }
.acordio-cos.obert .acordio-cos-inner { padding-bottom: 1rem; }

/* Lightbox */
.lightbox {
  display: none; position: fixed; inset: 0; z-index: 1000;
  background: rgba(0,0,0,.88); align-items: center; justify-content: center;
}
.lightbox.actiu { display: flex; }
.lightbox-contingut {
  max-width: 90vw; max-height: 90vh;
  display: flex; align-items: center; justify-content: center;
  position: relative;
}
.lightbox-contingut::after {
  content: '© Joan Linux';
  position: absolute;
  bottom: 10px; left: 50%;
  transform: translateX(-50%);
  font-family: var(--font-body);
  font-size: .7rem;
  letter-spacing: .06em;
  color: rgba(255,255,255,.4);
  pointer-events: none;
  white-space: nowrap;
  text-shadow: 0 1px 4px rgba(0,0,0,.9);
  z-index: 2;
}
.lightbox-contingut img {
  max-width: 90vw; max-height: 85vh;
  object-fit: contain;
  filter: grayscale(100%);
  -webkit-user-drag: none;
  -webkit-touch-callout: none;
  user-select: none;
  transition: filter .3s;
  -webkit-user-drag: none; user-select: none;
  pointer-events: none;
}
.lightbox-tanca {
  position: absolute; top: 1.25rem; right: 1.5rem;
  background: none; border: none; color: #fff; font-size: 1.75rem;
  cursor: pointer; line-height: 1; opacity: .7; transition: opacity .2s;
}
.lightbox-tanca:hover { opacity: 1; }

.musico-nav {
  display: flex; justify-content: space-between; margin-top: 3rem;
  padding-top: 2rem; border-top: 1px solid var(--border);
  font-size: .9rem;
}
.musico-nav a { color: var(--text2); }
.musico-nav a:hover { color: var(--accent-light); }

/* === Sales / Temples del Blues === */
.sala-page { padding: 3rem 0; }
.sala-layout {
  display: flex; gap: 2.5rem; align-items: flex-start;
}
.sala-layout--sense-logo { display: block; }
.sala-logo-col { flex-shrink: 0; }
.sala-logo {
  width: 180px;
  object-fit: contain;
  display: block;
}
.sala-info-col { min-width: 0; }
.sala-nom { font-family: var(--font-head); font-size: clamp(1.8rem, 3.5vw, 2.5rem); margin-bottom: .5rem; }
.sala-dades { color: var(--text2); font-size: .95rem; margin-bottom: 1rem; }
.sala-bio { line-height: 1.75; }
.sala-bio p { margin-bottom: 1rem; }
@media (max-width: 600px) {
  .sala-layout { flex-direction: column; }
  .sala-logo { width: 120px; }
}

/* === Entitats / Qui Dona Suport === */
.entitat-page { padding: 3rem 0; }
.entitat-layout { display: flex; gap: 2.5rem; align-items: flex-start; }
.entitat-layout--sense-logo { display: block; }
.entitat-logo-col { flex-shrink: 0; display: flex; flex-direction: column; gap: 1rem; align-items: flex-start; }
.entitat-foto { width: 280px; height: 280px; object-fit: cover; object-position: top; display: block; }
.entitat-logo { width: 180px; object-fit: contain; display: block; }
.entitat-info-col { min-width: 0; }
.entitat-nom { font-family: var(--font-head); font-size: clamp(1.8rem, 3.5vw, 2.5rem); margin-bottom: .5rem; }
.entitat-dades { color: var(--text2); font-size: .95rem; margin-bottom: 1rem; }
.entitat-bio { line-height: 1.75; }
.entitat-bio p { margin-bottom: 1rem; }
@media (max-width: 600px) {
  .entitat-layout { flex-direction: column; }
  .entitat-logo { width: 120px; }
}

/* === Generic Content Page === */
.content-page { padding: 3rem 0; }
.content-page h1 {
  font-family: var(--font-head);
  font-size: clamp(1.8rem, 3vw, 2.5rem);
  margin-bottom: 2rem;
  padding-bottom: 1rem;
  border-bottom: 1px solid var(--border);
}
.page-content { max-width: 720px; font-size: 1.05rem; line-height: 1.8; }
.page-content p + p { margin-top: 1rem; }
.page-content h2 { font-family: var(--font-head); font-size: 1.4rem; margin: 2rem 0 .75rem; color: var(--text2); }
.page-content h3 { font-family: var(--font-head); font-size: 1.15rem; margin: 1.5rem 0 .5rem; }
.page-content em { color: var(--accent-light); font-style: italic; }
.page-content strong { color: var(--text); }
.page-content blockquote { border-left: 2px solid var(--accent); padding-left: 1.25rem; color: var(--text2); margin: 1.5rem 0; }

/* === Història === */
.historia-content { width: 100%; }
.historia-foto {
  float: right;
  margin: .25rem 0 1.5rem 2rem;
  border: 1px solid var(--border);
  width: 260px;
  flex-shrink: 0;
}
.historia-foto img {
  width: 100%;
  display: block;
  filter: grayscale(100%);
}
.historia-content::after { content: ''; display: table; clear: both; }

/* === Entitat single === */
.entitat-layout {
  display: grid;
  grid-template-columns: 1fr 3fr;
  gap: 2.5rem;
  align-items: start;
}
.entitat-logo img {
  width: 100%;
  max-width: 180px;
  display: block;
}
.entitat-info h1 {
  font-family: var(--font-head);
  font-size: clamp(1.8rem, 3vw, 2.5rem);
  margin-bottom: 1.5rem;
}
.entitat-web { margin-bottom: 1.25rem; font-size: .9rem; color: var(--text2); }

/* === Section List Page === */
.section-page { padding: 3rem 0; }
.section-page h1 {
  font-family: var(--font-head);
  font-size: clamp(1.8rem, 3vw, 2.5rem);
  margin-bottom: 2rem;
  padding-bottom: 1rem;
  border-bottom: 1px solid var(--border);
}
.section-intro {
  max-width: 720px; font-size: 1.05rem; line-height: 1.8;
  color: var(--text2); margin-bottom: 3rem;
  border-left: 2px solid var(--accent); padding-left: 1.25rem;
}
.section-intro p + p { margin-top: .75rem; }

/* Acordions músics */
.musics-acordions { margin: 1.5rem 0 2rem; max-width: 720px; }
.acordio { border-bottom: 1px solid var(--border); }
.acordio:first-child { border-top: 1px solid var(--border); }
.acordio-cap {
  list-style: none; cursor: pointer;
  padding: .85rem 0;
  font-family: var(--font-head); font-size: 1.1rem; font-weight: 700;
  color: var(--accent-light);
  display: flex; align-items: center; justify-content: space-between;
  user-select: none;
  transition: color .2s;
}
.acordio-cap::-webkit-details-marker { display: none; }
.acordio-cap::after {
  content: '+'; font-size: 1.4rem; font-weight: 300;
  color: var(--text2); transition: transform .2s, color .2s;
  flex-shrink: 0;
}
.acordio[open] > .acordio-cap { color: var(--text); }
.acordio[open] > .acordio-cap::after { content: '−'; color: var(--accent-light); }
.acordio-cos {
  padding: 0 0 1.25rem;
  color: var(--text2); font-size: 1rem; line-height: 1.8;
  animation: acordio-open .2s ease;
}
@keyframes acordio-open {
  from { opacity: 0; transform: translateY(-4px); }
  to   { opacity: 1; transform: translateY(0); }
}
.section-intro p:last-child em:only-child {
  display: block; margin-top: 1rem;
  font-size: .8rem; font-style: normal; letter-spacing: .04em;
  color: var(--accent-light); opacity: .7;
  border-top: 1px solid var(--border); padding-top: .6rem;
}
.section-items {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 1px;
  background: var(--border);
  border: 1px solid var(--border);
}
.section-item {
  background: var(--bg);
  padding: 1.5rem;
  transition: background .15s;
}
.section-item:hover { background: var(--bg2); }
.section-item h2 { font-family: var(--font-head); font-size: 1.15rem; margin-bottom: .4rem; }
.section-item h2 a { color: var(--text); }
.section-item h2 a:hover { color: var(--accent-light); }
.item-meta { color: var(--text2); font-size: .85rem; }
.item-summary { color: var(--text2); font-size: .9rem; margin-top: .5rem; line-height: 1.6; }

/* Músics intro text */
.musics-intro {
  max-width: 720px; font-size: 1rem; line-height: 1.8;
  color: var(--text2); margin-bottom: 3rem;
  border-left: 2px solid var(--accent); padding-left: 1.25rem;
}
.musics-intro p + p { margin-top: .75rem; }
.musics-intro strong { color: var(--accent-light); }

/* === Pàgina Projecte === */
.projecte-page { padding: 3rem 0; }
.projecte-layout {
  display: grid;
  grid-template-columns: 1fr 3fr;
  gap: 3rem;
  align-items: start;
}
.projecte-sidebar {
  position: sticky;
  top: 5rem;
}
.projecte-index {
  display: flex;
  flex-direction: column;
  gap: .75rem;
  border-left: 2px solid var(--border);
  padding-left: 1.25rem;
}
.projecte-index a {
  font-size: .85rem;
  color: var(--text2);
  text-decoration: none;
  line-height: 1.4;
  transition: color .2s;
}
.projecte-index a:hover { color: var(--accent-light); }
.projecte-contingut h1 {
  font-family: var(--font-head);
  font-size: clamp(1.8rem, 3vw, 2.5rem);
  margin-bottom: 2rem;
  padding-bottom: 1rem;
  border-bottom: 1px solid var(--border);
}
.projecte-page h2,
.historia-page h2 { font-family: var(--font-head); font-size: 1.5rem; margin-bottom: 1.5rem; color: var(--accent-light); }

/* Stats */
.stats-section { margin-top: 3rem; margin-bottom: 4rem; padding-top: 2rem; border-top: 1px solid var(--border); }
.stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
  gap: 1px; background: var(--border);
  border: 1px solid var(--border);
}
.stat {
  background: var(--bg2); padding: 1.5rem 1rem; text-align: center;
  display: flex; flex-direction: column; gap: .4rem;
}
.stat-num { font-family: var(--font-head); font-size: 2.5rem; color: var(--accent-light); line-height: 1; }
.stat-label { font-size: .8rem; color: var(--text2); text-transform: uppercase; letter-spacing: .05em; }

/* Llibres (projecte page) */
.llibres-section { margin-bottom: 4rem; }
.llibres-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 2rem; }
.llibre-card { display: flex; gap: 1.5rem; align-items: flex-start; }
.llibre-card img { width: 100px; flex-shrink: 0; border: 1px solid var(--border); }
.llibre-info h3 { font-family: var(--font-head); margin-bottom: .25rem; }
.llibre-info p { font-size: .85rem; color: var(--text2); margin-top: .3rem; }
.llibre-desc { color: var(--text) !important; }
.llibre-isbn { font-size: .75rem !important; color: var(--border) !important; }

/* Autors */
.autors-section { margin-bottom: 4rem; }
.autors-principal { display: flex; justify-content: center; margin-bottom: 2.5rem; }
.autors-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 2.5rem; }
.autor-card { text-align: center; }
.autor-foto {
  width: 120px; height: 120px;
  border-radius: 50%; object-fit: cover; object-position: top;
  margin: 0 auto 1rem;
  border: 2px solid var(--accent);
  filter: grayscale(100%);
  transition: filter .3s;
  display: block;
}
.autor-foto:hover { filter: grayscale(0%); }
.autor-foto--placeholder { background: var(--bg3); }
.autor-card--petit { opacity: .85; }
.autor-foto--petit { width: 120px; height: 120px; border-width: 2px; }
.autor-card--petit h3 { font-size: 1rem; }
.autor-card--petit h3 a { color: var(--text); }
.autor-card--petit h3 a:hover { color: var(--accent-light); }
.autor-card h3 { font-family: var(--font-head); font-size: 1.2rem; margin-bottom: .25rem; }
.autor-rol { color: var(--accent-light); font-size: .85rem; margin-bottom: .75rem; }
.autor-bio { font-size: .9rem; color: var(--text2); line-height: 1.6; }
.autor-card { text-decoration: none; transition: opacity .2s; }
.autor-card:hover { opacity: .8; }

/* Fitxa autor individual */
.autor-page { padding: 3rem 0; }
.autor-layout {
  display: grid; grid-template-columns: 260px 1fr; gap: 3rem; align-items: flex-start;
}
.autor-layout--sense-foto { grid-template-columns: 1fr; }
.autor-foto-gran {
  width: 260px; height: 260px; object-fit: cover; object-position: top;
  border-radius: 50%; border: 2px solid var(--border);
  filter: grayscale(100%); transition: filter .3s; display: block;
}
.autor-foto-gran:hover { filter: grayscale(0%); }
.autor-info-col { min-width: 0; }
.autor-rol-page { color: var(--accent-light); font-size: .9rem; text-transform: uppercase; letter-spacing: .08em; margin-bottom: .5rem; }
.autor-nom { font-family: var(--font-head); font-size: clamp(2rem, 4vw, 3rem); margin-bottom: 1rem; }
.autor-web { font-size: .9rem; margin-bottom: 1.5rem; }
.autor-web a { color: var(--accent-light); }
.autor-bio-text { line-height: 1.8; font-size: 1.05rem; max-width: 72ch; }
.autor-bio-text p + p { margin-top: 1rem; }
@media (max-width: 700px) {
  .autor-layout { grid-template-columns: 1fr; gap: 1.5rem; }
  .autor-foto-gran { width: 160px; height: 160px; }
}

/* Bibliografia */
.biblio-section { margin-bottom: 4rem; }
.biblio-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
  gap: 2rem;
}
.biblio-card {
  display: flex;
  flex-direction: column;
  gap: .75rem;
}
.biblio-portada {
  aspect-ratio: 2 / 3;
  overflow: hidden;
  background: var(--bg3);
  border: 1px solid var(--border);
}
.biblio-portada img {
  width: 100%; height: 100%;
  object-fit: cover;
  display: block;
  filter: grayscale(100%);
  transition: filter .3s;
}
.biblio-card:hover .biblio-portada img { filter: grayscale(0%); }
.biblio-portada-placeholder {
  width: 100%; height: 100%;
  display: flex; align-items: center; justify-content: center;
  padding: 1rem;
}
.biblio-portada-placeholder span {
  font-family: var(--font-head);
  font-size: .8rem;
  color: var(--text2);
  text-align: center;
  line-height: 1.4;
}
.biblio-titol {
  font-family: var(--font-head);
  font-weight: 700;
  font-size: .95rem;
  color: var(--text);
  line-height: 1.3;
}
.biblio-autor { font-size: .8rem; color: var(--accent-light); }
.biblio-btn { font-size: .75rem; padding: .4rem .9rem; margin: 0; }

/* Logo editorial + col·laboradors */
.editorial-peu {
  display: flex;
  align-items: center;
  gap: 3rem;
  padding: 3rem 0;
  border-top: 1px solid var(--border);
}
.editorial-peu > img { max-width: 160px; width: 100%; }
.editorial-logo { text-align: center; flex-shrink: 0; }
.editorial-logo img { max-width: 160px; margin: 0 auto .75rem; }
.editorial-logo p { color: var(--text2); font-size: .9rem; }
.editorial-gracies { color: var(--text2); font-size: .9rem; line-height: 1.6; }
.editorial-gracies-label { font-size: .75rem; text-transform: uppercase; letter-spacing: .06em; color: var(--text2); margin-bottom: .75rem; }
.gracies-section { margin-top: 3rem; padding: 2rem; background: rgba(255,255,255,.04); border-radius: 10px; }
.gracies-logos { display: flex; align-items: center; gap: 3rem; flex-wrap: wrap; margin-top: 1.25rem; }
.gracies-logos a { display: block; transition: opacity .2s; }
.gracies-logos img { height: 48px; width: auto; max-width: 160px; object-fit: contain; opacity: .75; transition: opacity .2s; }
.gracies-logos a:hover img { opacity: 1; }

.editorial-cita-wrap { display: flex; align-items: center; }
.projecte-cita {
  padding: 0;
  margin: 0;
  border: none;
}
.cita-en {
  font-family: 'Caveat', cursive;
  font-size: 1.9rem;
  font-weight: 600;
  font-style: normal;
  color: var(--text);
  line-height: 1.35;
  margin-bottom: .4rem;
}
.cita-ca {
  font-family: 'Caveat', cursive;
  font-size: 1.5rem;
  font-style: normal;
  color: var(--accent-light);
  line-height: 1.35;
  margin-bottom: .75rem;
}
.cita-autor {
  font-size: .85rem;
  font-style: italic;
  color: var(--text2);
  display: block;
}

/* === Taxonomy (instrument / banda) === */
.taxonomy-section { padding: 3rem 0; }
.taxonomy-title {
  font-family: var(--font-head);
  font-size: clamp(1.6rem, 3vw, 2.5rem);
  margin-bottom: .5rem;
  padding-bottom: 1rem;
  border-bottom: 1px solid var(--border);
}
.taxonomy-count { color: var(--text2); font-size: .85rem; margin-bottom: 2rem; }

.taxonomy-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
  gap: 1.5rem;
}
.taxo-card {
  display: flex;
  flex-direction: column;
  gap: .75rem;
  text-decoration: none;
  transition: opacity .15s;
}
.taxo-card:hover { opacity: .8; }
.taxo-foto {
  aspect-ratio: 1 / 1;
  overflow: hidden;
  background: var(--bg3);
  border: 1px solid var(--border);
}
.taxo-foto img {
  width: 100%; height: 100%;
  object-fit: cover;
  display: block;
  filter: grayscale(100%);
  transition: filter .3s;
}
.taxo-card:hover .taxo-foto img { filter: grayscale(0%); }
.taxo-foto-placeholder {
  width: 100%; height: 100%;
  background: var(--bg3);
}
.taxo-nom {
  font-family: var(--font-head);
  font-weight: 700;
  font-size: .95rem;
  color: var(--text);
  line-height: 1.3;
  text-align: center;
}
.taxo-instruments {
  font-size: .75rem;
  color: var(--accent-light);
  text-align: center;
  margin-top: .2rem;
}

/* === Bandes grid === */
.bandes-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 1px;
  background: var(--border);
  border: 1px solid var(--border);
}
.banda-card {
  background: var(--bg);
  padding: 1.5rem;
  transition: background .15s;
}
.banda-card:hover { background: var(--bg2); }
.banda-nom {
  font-family: var(--font-head);
  font-weight: 700;
  font-size: 1.05rem;
  margin-bottom: .75rem;
  padding-bottom: .5rem;
  border-bottom: 1px solid var(--border);
}
.banda-nom a { color: var(--text); }
.banda-nom a:hover { color: var(--accent-light); }
.banda-membres {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: .3rem;
}
.banda-membres li { font-size: .85rem; }
.banda-membres a { color: var(--text2); }
.banda-membres a:hover { color: var(--accent-light); }

.bandes-grid--single { grid-template-columns: 1fr; }
.banda-card--full { background: transparent; padding: 0; }
.banda-card--full:hover { background: transparent; }
.banda-membres--grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
  gap: 1.5rem;
  list-style: none;
}
.banda-membre-link {
  display: flex; flex-direction: column; gap: .75rem;
  text-decoration: none; transition: opacity .15s;
}
.banda-membre-link:hover { opacity: .8; }

/* === Sales (Els Temples) === */
.sales-section { padding: 3rem 0; }
.sales-section h1 {
  font-family: var(--font-head);
  font-size: clamp(1.8rem, 3vw, 2.5rem);
  margin-bottom: 2rem;
  padding-bottom: 1rem;
  border-bottom: 1px solid var(--border);
}
.sales-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 1.5rem;
}
.sala-card {
  display: flex;
  flex-direction: column;
  background: var(--bg2);
  border: 1px solid var(--border);
  overflow: hidden;
  transition: border-color .15s;
  text-decoration: none;
}
.sala-card:hover { border-color: var(--accent); }
.sala-imatge {
  aspect-ratio: 1 / 1;
  overflow: hidden;
  background: var(--bg3);
  display: flex;
  align-items: center;
  justify-content: center;
}
.sala-imatge img {
  max-width: 100%; max-height: 100%;
  width: auto; height: auto;
  object-fit: contain;
  display: block;
  filter: grayscale(100%);
  transition: filter .3s;
}
.sala-card:hover .sala-imatge img { filter: grayscale(0%); }
.sala-imatge-placeholder {
  width: 100%; height: 100%;
  display: flex; align-items: center; justify-content: center;
  background: var(--bg3);
  padding: 1rem;
}
.sala-imatge-placeholder span {
  font-family: var(--font-head);
  font-size: .9rem;
  color: var(--text2);
  text-align: center;
}
.sala-info { padding: 1rem 1.25rem 1.25rem; }
.sala-nom {
  font-family: var(--font-head);
  font-weight: 700;
  font-size: 1rem;
  color: var(--text);
  margin-bottom: .25rem;
}
.sala-meta { font-size: .8rem; color: var(--text2); }

/* === Forms (contacte / butlletí) === */
.form-page-header { margin-bottom: 2.5rem; }
.form-page-header h1 { font-family: var(--font-head); font-size: 2rem; margin-bottom: .5rem; }
.form-page-sub { color: var(--text2); font-size: 1rem; }

.form-wrap { max-width: 560px; }

.blues-form { display: flex; flex-direction: column; gap: 1.25rem; }
.blues-form--compact { gap: 1rem; }

.form-group { display: flex; flex-direction: column; gap: .35rem; }
.form-group label {
  font-size: .85rem;
  font-weight: 600;
  color: var(--text2);
  text-transform: uppercase;
  letter-spacing: .04em;
}
.form-group input,
.form-group select,
.form-group textarea {
  background: var(--bg2);
  border: 1px solid var(--border);
  border-radius: 4px;
  color: var(--text);
  font-family: var(--font-body);
  font-size: 1rem;
  padding: .6rem .85rem;
  transition: border-color .2s;
  width: 100%;
}
.form-group input::placeholder,
.form-group textarea::placeholder { color: var(--text2); opacity: .6; }
.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
  outline: none;
  border-color: var(--accent-light);
}
.form-group select { appearance: none; cursor: pointer; }
.form-group textarea { resize: vertical; min-height: 120px; }

.btn-blues {
  align-self: flex-start;
  background: var(--accent);
  border: none;
  border-radius: 4px;
  color: #fff;
  cursor: pointer;
  font-family: var(--font-body);
  font-size: .95rem;
  font-weight: 600;
  padding: .65rem 1.75rem;
  transition: background .2s, opacity .2s;
}
.btn-blues:hover { background: var(--accent-light); }
.btn-blues:disabled { opacity: .5; cursor: not-allowed; }

.form-success {
  display: flex; flex-direction: column; align-items: flex-start; gap: 1rem;
  padding: 2rem; background: var(--bg2); border-radius: 6px;
}
.form-success svg { color: #4ade80; }
.form-success h2 { font-family: var(--font-head); font-size: 1.25rem; }
.form-success p { color: var(--text2); }

.contacte-alt { margin-top: 2rem; color: var(--text2); font-size: .9rem; }

/* Butlletí grid */
.butlleti-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 2.5rem; margin-bottom: 2rem; }
.butlleti-card {
  background: var(--bg2); border-radius: 8px; padding: 1.75rem;
  border: 1px solid var(--border);
}
.butlleti-card--musics { border-color: var(--accent); }
.butlleti-card h2 {
  font-family: var(--font-head); font-size: 1.1rem;
  margin-bottom: .5rem; color: var(--accent-light);
}
.butlleti-card > p { color: var(--text2); font-size: .9rem; margin-bottom: 1.25rem; }

.form-privacitat { font-size: .8rem; color: var(--text2); max-width: 720px; }

/* === Cookie banner === */
.cookie-banner {
  position: fixed; bottom: 0; left: 0; right: 0; z-index: 8000;
  background: var(--bg2); border-top: 1px solid var(--border);
  padding: 1rem 1.5rem;
  display: flex; align-items: center; gap: 1.5rem; flex-wrap: wrap;
}
.cookie-text { font-size: .85rem; color: var(--text2); flex: 1; min-width: 200px; }
.cookie-text a { color: var(--accent-light); }
.cookie-btns { display: flex; align-items: center; gap: 1rem; flex-shrink: 0; }
.btn-blues--sm { padding: .4rem 1.1rem; font-size: .85rem; }
.cookie-link { font-size: .8rem; color: var(--text2); }

.form-group--check { margin-top: .25rem; }
.check-label {
  display: flex; gap: .6rem; align-items: flex-start;
  cursor: pointer; font-size: .85rem; color: var(--text2); line-height: 1.5;
}
.check-label input[type=checkbox] {
  width: 16px; height: 16px; min-width: 16px;
  margin-top: .15rem; accent-color: var(--accent-light); cursor: pointer;
}
.check-label a { color: var(--accent-light); }

.gracies-wrap {
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  text-align: center; padding: 5rem 0; gap: 1.25rem;
}
.gracies-wrap svg { color: #4ade80; }
.gracies-wrap h1 { font-family: var(--font-head); font-size: 2rem; }
.gracies-wrap p { color: var(--text2); }
.gracies-wrap .btn-blues { margin-top: .5rem; }

/* === Responsive === */
@media (max-width: 900px) {
  .text-offset { grid-template-columns: 1fr; }
  .text-offset > * { grid-column: 1; }
  .projecte-layout { grid-template-columns: 1fr; }
  .projecte-sidebar { display: none; }
  .hero-grid { grid-template-columns: 1fr; gap: 2rem; }
  .hero-logo { text-align: center; }
  .hero-logo img { margin: 0 auto; max-width: 200px; }
  .random-grid { grid-template-columns: 1fr; }
  .llibres-home-grid { grid-template-columns: 1fr; }
  .musico-layout { grid-template-columns: 1fr; gap: 1.5rem; }
  .musico-foto { width: 200px; height: 200px; }
}
@media (max-width: 900px) {
  .taxonomy-grid { grid-template-columns: repeat(auto-fill, minmax(130px, 1fr)); gap: 1rem; }
}
@media (max-width: 700px) {
  .butlleti-grid { grid-template-columns: 1fr; }
}
@media (max-width: 640px) {
  .site-header .container { padding: 0 1rem; }
  .site-logo { width: 56px; height: 56px; }
  .site-brand-text { font-size: .85rem; }
  .header-top { flex-wrap: wrap; gap: .5rem; }
  .header-nav { gap: 1rem; justify-content: flex-start; margin: 0 -1rem; padding: .4rem 1rem; }
  .header-nav a { font-size: 1rem; }
  .header-cerca-input { width: 100px; }
  .filtres { flex-direction: column; }
  .musics-grid { grid-template-columns: 1fr 1fr; }
  .footer-cols { flex-direction: column; gap: 1rem; }
  .footer-mid { display: none; }
}
@media (max-width: 400px) {
  .musics-grid { grid-template-columns: 1fr; }
}

/* === Scroll progress bar === */
#scroll-progress {
  position: fixed; top: 0; left: 0; z-index: 9500;
  height: 3px; width: 0%;
  background: var(--accent-light);
  transition: width .1s linear;
  pointer-events: none;
}

/* === Homepage gracies layout === */
.home-gracies-top {
  display: grid;
  grid-template-columns: 1fr 2fr;
  gap: 3rem;
  align-items: flex-start;
}
.home-gracies-editorial {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 1rem;
}
.home-gracies-editorial img { max-width: 200px; width: 100%; }
.home-gracies-editorial p { color: var(--text2); font-size: .95rem; line-height: 1.6; }
.home-gracies-dreta { display: flex; flex-direction: column; gap: 2rem; }
.home-gracies-bottom {}
.gracies-intro { color: var(--text2); font-size: .85rem; text-transform: uppercase; letter-spacing: .06em; margin-bottom: .75rem; }

@media (max-width: 768px) {
  .home-gracies-top { grid-template-columns: 1fr; gap: 2rem; }
}

/* === Biblio section spacing === */
.biblio-section { margin-top: 3rem; }

/* === Autor musica link === */
.autor-musica-link { margin-top: 1.5rem; }
.autor-musica-link a { color: var(--accent-light); font-size: .9rem; }
.autor-musica-link a:hover { color: var(--accent); }

/* === Back to top button === */
#back-to-top {
  position: fixed; bottom: 5rem; right: 1.5rem; z-index: 7000;
  width: 40px; height: 40px;
  background: rgba(11,22,38,.85);
  border: 1px solid rgba(74,159,212,.35);
  border-radius: 50%;
  color: var(--accent-light);
  display: flex; align-items: center; justify-content: center;
  cursor: pointer;
  opacity: 0; visibility: hidden;
  transition: opacity .25s, visibility .25s, transform .2s, background .2s;
  transform: translateY(8px);
}
#back-to-top.visible {
  opacity: 1; visibility: visible; transform: translateY(0);
}
#back-to-top:hover {
  background: rgba(26,111,181,.75);
  transform: translateY(-2px);
}

/* === Pàgina Estadístiques === */
.stats-page .container { max-width: 900px; }
.stats-header { margin-bottom: 2rem; }
.stats-sub { color: var(--text2); font-size: .85rem; margin-top: .3rem; }
.stats-sub a { color: var(--text2); }
.stats-period-btns { display: flex; gap: .5rem; margin-top: 1rem; }
.stats-period-btn {
  background: var(--bg3); border: 1px solid var(--border); color: var(--text2);
  border-radius: 4px; padding: .3rem .8rem; font-size: .82rem; cursor: pointer;
  font-family: var(--font-body); transition: background .2s, color .2s;
}
.stats-period-btn.active,
.stats-period-btn:hover { background: var(--accent); border-color: var(--accent); color: #fff; }
.stats-kpis { display: flex; gap: 1.5rem; margin-bottom: 2rem; flex-wrap: wrap; }
.stats-kpis--sub { margin-bottom: 1rem; }
.stats-kpi {
  background: var(--bg2); border: 1px solid var(--border); border-radius: 8px;
  padding: 1.2rem 1.5rem; flex: 1; min-width: 140px; text-align: center;
}
.stats-kpi--highlight { border-color: rgba(232,160,32,.5); background: rgba(232,160,32,.06); }
.stats-kpi-num { display: block; font-family: var(--font-head); font-size: 2rem; color: var(--accent-light); }
.stats-kpi--highlight .stats-kpi-num { color: #e8a020; }
.stats-kpi-label { font-size: .78rem; color: var(--text2); text-transform: uppercase; letter-spacing: .05em; }
.stats-section { margin-bottom: 3rem; }
.stats-section h2 { font-size: 1.1rem; margin-bottom: 1rem; color: var(--text); }
.stats-section--qr { border-left: 3px solid #e8a020; padding-left: 1.25rem; }
.stats-section-desc { color: var(--text2); font-size: .85rem; margin-bottom: 1rem; }
.stats-chart-wrap { background: var(--bg2); border: 1px solid var(--border); border-radius: 8px; padding: 1rem; }
.stats-loading { color: var(--text2); font-size: .85rem; padding: 1rem 0; }
.stats-error { color: #e05555; font-size: .85rem; }
.stats-pages-ol { list-style: none; display: flex; flex-direction: column; gap: .4rem; }
.stats-page-item {
  display: flex; align-items: center; gap: .75rem; position: relative;
  background: var(--bg2); border-radius: 4px; padding: .5rem .75rem; overflow: hidden;
}
.stats-page-item--qr { border-left: 3px solid #e8a020; }
.stats-page-bar-wrap { position: absolute; inset: 0; z-index: 0; }
.stats-page-bar { height: 100%; background: rgba(26,111,181,.12); transition: width .4s; }
.stats-page-item--qr .stats-page-bar { background: rgba(232,160,32,.12); }
.stats-page-path { position: relative; flex: 1; font-size: .82rem; color: var(--text2); font-family: monospace; word-break: break-all; }
.stats-page-count { position: relative; font-size: .85rem; color: var(--text); font-weight: 600; white-space: nowrap; }
.stats-footer-note { color: var(--text2); font-size: .78rem; margin-top: 2rem; }
.stats-footer-note a { color: var(--text2); }

/* Pestanyes */
.stats-tabs { display: flex; gap: 0; border-bottom: 1px solid var(--border); margin-bottom: 2rem; }
.stats-tab {
  background: none; border: none; border-bottom: 3px solid transparent;
  color: var(--text2); cursor: pointer; font-family: var(--font-body);
  font-size: .9rem; padding: .65rem 1.2rem; margin-bottom: -1px;
  transition: color .2s, border-color .2s;
}
.stats-tab:hover { color: var(--text); }
.stats-tab.active { color: var(--accent-light); border-bottom-color: var(--accent-light); }
.stats-tab--qr.active { color: #e8a020; border-bottom-color: #e8a020; }
.stats-tab-panel { display: none; }
.stats-tab-panel.active { display: block; }

/* Dos columnes */
.stats-two-col { display: grid; grid-template-columns: 1fr 1fr; gap: 2rem; }
@media (max-width: 700px) { .stats-two-col { grid-template-columns: 1fr; } }

/* QR kpi */
.stats-kpi--qr { border-color: rgba(232,160,32,.5); background: rgba(232,160,32,.06); }
.stats-kpi--qr .stats-kpi-num { color: #e8a020; }

/* Top lists */
.stats-top-ol { list-style: none; display: flex; flex-direction: column; gap: .35rem; }
.stats-top-item {
  display: flex; align-items: center; gap: .6rem;
  background: var(--bg2); border-radius: 4px; padding: .45rem .65rem;
  position: relative; overflow: hidden;
}
.stats-top-rank { color: var(--text2); font-size: .75rem; min-width: 1.2rem; text-align: right; position: relative; }
.stats-top-bar-wrap { position: absolute; left: 0; top: 0; bottom: 0; width: 100%; z-index: 0; }
.stats-top-bar { height: 100%; background: rgba(26,111,181,.1); transition: width .4s; }
.stats-top-bar--ref { background: rgba(74,159,212,.1); }
.stats-top-name { position: relative; flex: 1; font-size: .82rem; color: var(--text2); word-break: break-all; }
.stats-top-count { position: relative; font-size: .85rem; color: var(--text); font-weight: 600; white-space: nowrap; }

/* Refs list */
.stats-refs-list .stats-top-name { font-family: monospace; }

/* Controls */
.stats-controls { display: flex; align-items: center; gap: 1rem; margin-top: .75rem; flex-wrap: wrap; }

/* === Llibre de visites === */
.visites-page .container { max-width: 760px; }
.visites-header { margin-bottom: 2.5rem; }
.visites-header h1 {
  font-family: var(--font-head);
  font-size: 2rem;
  margin-bottom: 1rem;
}
.visites-intro {
  font-size: 1.05rem;
  line-height: 1.8;
  color: var(--text);
  margin-bottom: .75rem;
}
.visites-nota {
  font-size: .82rem;
  color: var(--text2);
  line-height: 1.6;
}
.visites-nota a { color: var(--text2); text-decoration: underline; }
.visites-separador {
  text-align: center;
  margin: 2rem 0 2.5rem;
  color: var(--accent);
  letter-spacing: .5em;
  font-size: .9rem;
  opacity: .5;
}
.visites-giscus {
  background: var(--bg2);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 1.5rem;
  min-height: 200px;
}

/* === Newsletter slide-in + tab === */
.nl-tab {
  position: fixed;
  right: 0;
  top: 50%;
  transform: translateY(-50%) translateX(100%);
  z-index: 8000;
  background: var(--accent);
  color: #fff;
  border: none;
  border-radius: 4px 0 0 4px;
  padding: .6rem .4rem 2.4rem;
  cursor: pointer;
  writing-mode: vertical-rl;
  text-orientation: mixed;
  font-family: var(--font-body);
  font-size: .75rem;
  letter-spacing: .08em;
  text-transform: uppercase;
  opacity: 0;
  transition: transform .35s ease, opacity .35s ease, background .2s;
}
.nl-tab--visible {
  opacity: 1;
  transform: translateY(-50%) translateX(0);
}
.nl-tab--hidden {
  opacity: 0;
  pointer-events: none;
}
.nl-tab:hover { background: var(--accent-light); }

.nl-panel {
  position: fixed;
  right: 0;
  top: 50%;
  transform: translateY(-50%) translateX(calc(100% + 2rem));
  z-index: 7999;
  width: 280px;
  transition: transform .35s ease;
}
.nl-panel--visible {
  transform: translateY(-50%) translateX(0);
}
.nl-panel-inner {
  background: var(--bg2);
  border: 1px solid var(--border);
  border-right: none;
  border-radius: 8px 0 0 8px;
  padding: 1.25rem 1.25rem 1rem;
  position: relative;
}
.nl-tanca {
  position: absolute;
  top: .6rem;
  right: .7rem;
  background: none;
  border: none;
  color: var(--text2);
  cursor: pointer;
  font-size: 1rem;
  line-height: 1;
  padding: .2rem;
}
.nl-tanca:hover { color: var(--text); }
.nl-titol {
  font-family: var(--font-head);
  font-size: 1rem;
  color: var(--text);
  margin-bottom: .4rem;
  padding-right: 1.5rem;
}
.nl-desc {
  font-size: .82rem;
  color: var(--text2);
  margin-bottom: .9rem;
  line-height: 1.5;
}
.nl-form { display: flex; flex-direction: column; gap: .5rem; }
.nl-form input[type=email] {
  background: var(--bg3);
  border: 1px solid var(--border);
  border-radius: 4px;
  color: var(--text);
  font-family: var(--font-body);
  font-size: .85rem;
  padding: .5rem .7rem;
  width: 100%;
}
.nl-form input[type=email]:focus {
  outline: none;
  border-color: var(--accent-light);
}
.nl-form .btn-blues {
  font-size: .85rem;
  padding: .5rem;
}
.nl-ok { color: var(--accent-light); font-size: .85rem; text-align: center; padding: .5rem 0; }
.nl-legal { font-size: .72rem; color: var(--text2); margin-top: .6rem; }
.nl-legal a { color: var(--text2); }

@media (max-width: 600px) {
  .nl-panel { width: 260px; }
}

/* ============================================================
   COMING SOON OVERLAY
   ============================================================ */
.cs-overlay {
  display: none; /* JS el fa visible */
  position: fixed;
  inset: 0;
  z-index: 9999;
  background: rgba(8, 8, 8, .82);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  align-items: center;
  justify-content: center;
  padding: 1rem;
}
.cs-overlay.cs-sortint {
  animation: cs-fade-out .5s ease forwards;
}
@keyframes cs-fade-out {
  to { opacity: 0; }
}

.cs-card {
  background: rgba(22, 22, 22, .96);
  border: 1px solid rgba(255,255,255,.07);
  border-radius: 12px;
  padding: 2.2rem 2rem 1.8rem;
  max-width: 520px;
  width: 100%;
  text-align: center;
  box-shadow: 0 12px 48px rgba(0,0,0,.6);
}

.cs-coberta {
  margin-bottom: 1.4rem;
  display: flex;
  justify-content: center;
}
.cs-coberta img {
  width: auto;
  max-width: 200px;
  max-height: 260px;
  object-fit: contain;
  border-radius: 4px;
  box-shadow: 0 6px 24px rgba(0,0,0,.6);
}

.cs-pre {
  font-family: var(--font-body);
  font-size: .78rem;
  letter-spacing: .18em;
  text-transform: uppercase;
  color: var(--accent-light);
  margin: 0 0 .4rem;
}
.cs-titol {
  font-family: var(--font-title);
  font-size: clamp(1.35rem, 4vw, 1.9rem);
  font-weight: 700;
  color: var(--text);
  line-height: 1.2;
  margin: 0 0 1.4rem;
}

/* Compte enrere */
.cs-countdown {
  display: flex;
  align-items: flex-end;
  justify-content: center;
  gap: .3rem;
  margin-bottom: 1.6rem;
}
.cs-cd-bloc {
  display: flex;
  flex-direction: column;
  align-items: center;
  min-width: 3.2rem;
}
.cs-cd-bloc span:first-child {
  font-family: var(--font-title);
  font-size: 2rem;
  font-weight: 700;
  color: var(--accent-light);
  line-height: 1;
}
.cs-cd-label {
  font-size: .65rem;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--text2);
  margin-top: .1rem;
}
.cs-cd-sep {
  font-size: 1.6rem;
  color: var(--text2);
  padding-bottom: .6rem;
}

/* Esdeveniments */
.cs-events {
  display: flex;
  align-items: flex-start;
  justify-content: center;
  gap: 1rem;
  margin-bottom: 1.5rem;
  flex-wrap: wrap;
}
.cs-event {
  flex: 1;
  min-width: 160px;
  text-align: center;
}
.cs-event-tipus {
  font-size: .7rem;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--accent-light);
  margin: 0 0 .25rem;
}
.cs-event-data {
  font-family: var(--font-title);
  font-size: 1rem;
  font-weight: 700;
  color: var(--text);
  margin: 0 0 .2rem;
}
.cs-event-lloc {
  font-size: .85rem;
  font-weight: 600;
  color: var(--text);
  margin: 0 0 .15rem;
}
.cs-event-adreca {
  font-size: .75rem;
  color: var(--text2);
  line-height: 1.45;
  margin: 0;
}
.cs-event-sep {
  font-size: .8rem;
  color: var(--text2);
  padding-top: 1.2rem;
  flex: 0;
}

/* Newsletter */
.cs-newsletter { margin-bottom: 1.2rem; }
.cs-nl-text {
  font-size: .82rem;
  color: var(--text2);
  margin: 0 0 .6rem;
}
.cs-form {
  display: flex;
  gap: .4rem;
  flex-wrap: wrap;
  justify-content: center;
}
.cs-form input[type=email] {
  flex: 1;
  min-width: 200px;
  background: var(--bg3);
  border: 1px solid var(--border);
  border-radius: 4px;
  color: var(--text);
  font-family: var(--font-body);
  font-size: .85rem;
  padding: .5rem .75rem;
}
.cs-form input[type=email]:focus {
  outline: none;
  border-color: var(--accent-light);
}
.cs-form button {
  background: var(--accent);
  color: #fff;
  border: none;
  border-radius: 4px;
  font-family: var(--font-body);
  font-size: .85rem;
  font-weight: 600;
  padding: .5rem 1rem;
  cursor: pointer;
  transition: background .2s;
}
.cs-form button:hover { background: var(--accent-light); }
.cs-ok { color: var(--accent-light); font-size: .88rem; padding: .4rem 0; }

/* Logos patrocinadors/editors */
.cs-logos {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 1.2rem;
  flex-wrap: wrap;
  margin-top: .4rem;
  padding-top: 1rem;
  border-top: 1px solid rgba(255,255,255,.07);
}
.cs-logos img {
  height: 36px;
  width: auto;
  object-fit: contain;
  opacity: .75;
  filter: grayscale(30%);
  transition: opacity .2s;
}
.cs-logos img:hover { opacity: 1; }

@media (max-width: 480px) {
  .cs-card { padding: 1.8rem 1.2rem 1.4rem; }
  .cs-events { flex-direction: column; align-items: center; }
  .cs-event-sep { display: none; }
}
