/* Renovación visual 314MC — mantiene intactos los fondos, fotografías y contenido. */
:root {
  --motion-fast: 160ms;
  --motion-ui: 240ms;
  --ease-ui: cubic-bezier(.22, 1, .36, 1);
}

/* Sitio público: jerarquía más serena, navegación flotante y controles consistentes. */
.site-header {
  background: rgba(3, 5, 10, .88);
  border-bottom-color: rgba(20, 70, 160, .28);
  -webkit-backdrop-filter: blur(16px);
  backdrop-filter: blur(16px);
  transition: background var(--motion-ui) ease, border-color var(--motion-ui) ease;
}
.header-inner { min-height: 66px; padding: .55rem 0; }
.logo-title { gap: 12px; padding: 6px 10px 6px 6px; border-radius: 999px; }
.logo-title:hover { transform: translateY(-1px); }
.logo-title img { width: 36px; height: 36px; animation: none; }
.logo-text { font-size: .92rem; letter-spacing: .1em; animation: none; text-shadow: none; }
.user-login-btn { width: 42px; height: 42px; border: 1px solid rgba(255,255,255,.13); border-radius: 50%; color: var(--text-main); transition: color var(--motion-fast), background var(--motion-fast), border-color var(--motion-fast); }
.user-login-btn svg { width: 19px; height: 19px; fill: currentColor; }
.user-login-btn:hover { color: #fff; background: rgba(215,38,61,.16); border-color: rgba(215,38,61,.48); }

.apple-dock {
  bottom: max(18px, env(safe-area-inset-bottom));
  gap: 6px;
  padding: 7px 9px;
  background: rgba(11, 12, 16, .88);
  border-color: rgba(255,255,255,.16);
  box-shadow: 0 12px 34px rgba(0,0,0,.42);
  -webkit-backdrop-filter: blur(18px);
  backdrop-filter: blur(18px);
}
.apple-dock.dock-scrolled { transform: translateX(-50%) scale(.96); opacity: 1; }
.apple-dock a { width: 46px; height: 46px; color: rgba(245,245,245,.68); }
.apple-dock a svg { width: 21px; height: 21px; stroke-width: 1.7; }
.apple-dock a.active { color: #101010; }
.dock-indicator { width: 46px; height: 46px; top: 7px; }

/* Mantener la identidad y el contenido; ordenar mejor la lectura en cada sección. */
main > section:not(#inicio) { scroll-margin-top: 82px; }
.section-header { max-width: 720px; margin-bottom: clamp(2.25rem, 5vw, 4rem); }
.section-header h2,
.santiago-info h2,
.aventuras-cover-content h2,
.contact-form h3 {
  letter-spacing: .045em;
  line-height: 1.08;
  text-wrap: balance;
}
.section-header h2 { font-size: clamp(2rem, 4.3vw, 3.4rem); border-bottom-width: 2px; }
.section-subtitle { max-width: 58ch; margin-inline: auto; line-height: 1.65; font-style: normal; }
.hero-container { min-height: min(680px, calc(100svh - 66px)); padding-top: clamp(3rem, 8vh, 6rem); padding-bottom: clamp(3rem, 8vh, 6rem); }
.hero-content { max-width: 700px; }
.hero-content h1 { max-width: 12ch; font-size: clamp(2.65rem, 6.3vw, 5rem); letter-spacing: .045em; line-height: 1.02; text-wrap: balance; }
.hero-content h2 { letter-spacing: .16em !important; line-height: 1.5; }
.hero-phrase { max-width: 34ch; font-style: normal; letter-spacing: .015em; line-height: 1.5; }
.hero-actions { gap: .8rem; }
.hero-actions .btn { min-height: 48px; padding: .82rem 1.45rem; font-size: .9rem; letter-spacing: .06em; }
.hero-actions .btn-primary,
.aventuras-cover-content .btn-primary { box-shadow: none; }
.section-inicio-cards { padding: clamp(3.5rem, 7vw, 6rem) 0; }
.cards-container { max-width: 1120px; grid-template-columns: repeat(2, minmax(0,1fr)); gap: clamp(1rem, 2.5vw, 2rem); }
.modern-card { min-height: 290px; padding: clamp(1.5rem, 3vw, 2.5rem); border-radius: 1rem; backdrop-filter: none; -webkit-backdrop-filter: none; box-shadow: 0 8px 24px rgba(0,0,0,.35); }
.modern-card h3 { font-size: clamp(1.55rem, 2.5vw, 2rem); letter-spacing: .035em; border-bottom-width: 2px; }
.modern-card p { max-width: 44ch; font-size: 1rem; line-height: 1.65; }
.btn-card { border-width: 1px; border-radius: 999px; font-size: .86rem; letter-spacing: .055em; }
.modern-card:hover { transform: translateY(-4px); box-shadow: 0 14px 32px rgba(0,0,0,.42); }
.section-santiago, .section-aventuras { padding-top: clamp(4rem, 8vw, 7rem); padding-bottom: clamp(4rem, 8vw, 7rem); }
.santiago-container { gap: clamp(2rem, 6vw, 5rem); }
.santiago-info h2 { font-size: clamp(2rem, 4vw, 3.25rem); border-bottom-width: 2px; }
.santiago-text p { max-width: 62ch; font-size: 1.05rem; line-height: 1.75; }
.santiago-subtitle { font-size: 1.25rem; letter-spacing: .035em; }
.santiago-contact-data, .santiago-form-box { border-radius: 1rem; }
.santiago-form-box { padding: clamp(1.4rem, 3.5vw, 2.75rem); box-shadow: 0 10px 28px rgba(0,0,0,.32); }
.contact-form h3 { font-size: clamp(1.5rem, 3vw, 2rem); border-bottom-width: 2px; }
.contact-form input, .contact-form textarea { min-height: 48px; border-radius: .65rem; }
.contact-form button { min-height: 48px; border-radius: 999px; box-shadow: none; }
.social-links { gap: .65rem; }
.social-btn { min-height: 46px; padding: .65rem 1rem; border-radius: 999px; box-shadow: none; }
.aventuras-cover { min-height: clamp(420px, 58vw, 620px); }
.aventuras-cover-content h2 { font-size: clamp(2.5rem, 5vw, 4rem); }
.aventuras-cover-content p { max-width: 38ch; margin-inline: auto; font-style: normal; line-height: 1.55; }
.aventuras-cover-content .btn-primary { min-height: 48px; padding: .85rem 1.7rem; border-radius: 999px; font-size: .9rem; }
.gallery-grid, .gallery-container, .merch-grid { gap: clamp(1rem, 2vw, 1.5rem); }
.gallery-item, .blog-card, .merch-card, .memorial-card { border-radius: 1rem; }
.blog-card, .merch-card { box-shadow: 0 8px 24px rgba(0,0,0,.28); }
.blog-card:hover, .merch-card:hover { transform: translateY(-4px); box-shadow: 0 14px 32px rgba(0,0,0,.4); }
.merch-card-content { padding: 0 1.5rem 1.75rem; }
.merch-card-content h3 { line-height: 1.35; text-wrap: balance; }
.merch-btn { min-height: 46px; border-radius: 999px; backdrop-filter: none; }
.memorial-card { overflow: hidden; }
.site-footer { padding: 1.35rem 0; border-top-color: rgba(20,70,160,.3); font-size: .9rem; }

/* El banner conserva sus fondos; las redes se dibujan como piezas nítidas de HTML y SVG. */
.section-banner:not(.banner-social-active) .banner-glitch-text {
  width: min(100%, 46ch);
  font-size: clamp(1.25rem, 4.2vw, 2.5rem);
  letter-spacing: clamp(.02em, .08vw, 2px);
  line-height: 1.18;
  text-wrap: balance;
}
.section-banner.banner-social-active .banner-glitch-text { width: 100%; padding-inline: .5rem; font-family: system-ui, sans-serif; text-shadow: none; }
.section-banner.banner-social-active .banner-glitch-text::after { display: none; }
.section-banner.banner-social-active .banner-glitch-text.fade-out { animation: socialFadeOut 260ms ease both; }
.section-banner.banner-social-active .banner-glitch-text.fade-in { animation: socialFadeIn 380ms cubic-bezier(.22,1,.36,1) both; }
.banner-social-ad {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: clamp(1rem, 2.5vw, 2rem);
  width: min(100%, 760px);
  min-height: 104px;
  margin-inline: auto;
  padding: .75rem 1.25rem;
  color: var(--text-main);
  text-align: left;
  text-decoration: none;
  text-transform: none;
  letter-spacing: normal;
  background: rgba(0,0,0,.2);
  border: 1px solid rgba(255,255,255,.12);
  border-left: 3px solid var(--accent-red);
  border-radius: .9rem;
  transition: border-color var(--motion-ui), background-color var(--motion-ui), transform var(--motion-ui) var(--ease-ui);
}
.banner-social-ad:hover { background: rgba(0,0,0,.38); border-color: rgba(215,38,61,.58); transform: translateY(-2px); }
.banner-social-icon { display: grid; place-items: center; flex: 0 0 clamp(48px, 6vw, 66px); width: clamp(48px, 6vw, 66px); height: clamp(48px, 6vw, 66px); color: #fff; }
.banner-social-icon svg { display: block; width: 100%; height: 100%; fill: currentColor; overflow: visible; }
.banner-social-instagram .banner-social-icon svg { fill: none; }
.banner-social-instagram .banner-social-icon circle:last-child { fill: currentColor; stroke: none; }
.banner-social-copy { display: flex; flex: 1; flex-direction: column; align-items: flex-start; min-width: 0; gap: .08rem; }
.banner-social-eyebrow { color: #d4d5d9; font-size: clamp(.72rem, 1.2vw, .9rem); font-weight: 650; letter-spacing: .16em; line-height: 1.35; }
.banner-social-copy strong { color: #fff; font-size: clamp(1.6rem, 3vw, 2.5rem); font-weight: 850; letter-spacing: .035em; line-height: 1.03; }
.banner-social-handle { max-width: 100%; color: var(--text-muted); font-size: clamp(.75rem, 1.25vw, .92rem); line-height: 1.4; overflow-wrap: anywhere; white-space: normal; }
.banner-social-arrow { display: grid; place-items: center; flex: 0 0 36px; width: 36px; height: 36px; border: 1px solid rgba(215,38,61,.55); border-radius: 50%; color: #fff; font-size: 1.2rem; transition: transform var(--motion-ui) var(--ease-ui), background-color var(--motion-ui); }
.banner-social-ad:hover .banner-social-arrow { transform: translate(2px,-2px); background: rgba(215,38,61,.2); }
.banner-social-facebook .banner-social-icon { animation: socialFacebook 520ms cubic-bezier(.22,1,.36,1) both; }
.banner-social-instagram .banner-social-icon { animation: socialInstagram 620ms cubic-bezier(.22,1,.36,1) both; }
.banner-social-youtube .banner-social-icon { animation: socialYoutube 520ms cubic-bezier(.22,1,.36,1) both; }
.banner-social-tiktok .banner-social-icon { animation: socialTiktok 600ms cubic-bezier(.22,1,.36,1) both; }
.banner-social-copy { animation: socialCopy 540ms 70ms cubic-bezier(.22,1,.36,1) both; }
@keyframes socialFadeOut { to { opacity: 0; transform: translateY(-5px); } }
@keyframes socialFadeIn { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: translateY(0); } }
@keyframes socialCopy { from { opacity: 0; transform: translateX(-10px); } to { opacity: 1; transform: translateX(0); } }
@keyframes socialFacebook { from { opacity: 0; transform: translateX(-12px) scale(.9); } to { opacity: 1; transform: translateX(0) scale(1); } }
@keyframes socialInstagram { from { opacity: 0; transform: rotate(-16deg) scale(.86); } to { opacity: 1; transform: rotate(0) scale(1); } }
@keyframes socialYoutube { from { opacity: 0; transform: scale(.82); } 72% { opacity: 1; transform: scale(1.08); } to { opacity: 1; transform: scale(1); } }
@keyframes socialTiktok { from { opacity: 0; transform: translateY(8px) rotate(-8deg); } to { opacity: 1; transform: translateY(0) rotate(0); } }

/* Estados de interacción visibles, respetando la paleta del club. */
:where(a, button, input, textarea, select):focus-visible { outline: 2px solid var(--accent-red); outline-offset: 3px; }
:where(button, .btn, .social-btn, .merch-btn) { transition-duration: var(--motion-ui); }

/* Intranet: el shell y los controles conservan el negro, rojo y azul existentes. */
.admin-layout { min-height: 100svh; height: 100svh; }
body:has(.admin-layout) { padding-bottom: 0 !important; }
.admin-sidebar { width: 264px; background: #080808; border-right-color: rgba(255,255,255,.1); }
.sidebar-header { min-height: 78px; padding: 1rem 1.2rem; }
.sidebar-header img { width: 38px; height: 38px; object-fit: contain; }
.sidebar-header h2 { font-size: 1.02rem; letter-spacing: .035em; }
.sidebar-nav { padding: .75rem .65rem 1rem; scrollbar-width: thin; }
.nav-item, .accordion-header { min-height: 42px; margin: 2px 0; padding: .62rem .8rem; gap: .72rem; border-radius: .65rem; border-right: 0; font-size: .9rem; line-height: 1.3; transition: color var(--motion-fast), background var(--motion-fast), transform var(--motion-fast); }
.nav-item:hover, .nav-item.active { color: #fff; background: rgba(255,255,255,.075); border-right: 0; }
.nav-item.active { box-shadow: inset 2px 0 0 var(--accent-red); }
.nav-item svg, .accordion-header svg.header-icon { flex: 0 0 18px; width: 18px; height: 18px; margin: 0; fill: currentColor; color: #a8a8a8; }
.nav-item.active svg, .nav-item:hover svg, .accordion-header.active svg, .accordion-header:hover svg { color: #fff; }
.nav-item.inner-item { min-height: 38px; padding-left: 1.05rem; color: #aeb3be; font-size: .84rem; }
.nav-item.inner-item svg { width: 16px; height: 16px; flex-basis: 16px; }
.accordion-header { cursor: pointer; font-weight: 550; }
.accordion-header.active { color: #fff; background: rgba(255,255,255,.04); }
.accordion-icon { color: #818793; font-size: 1rem; }
.accordion-content { padding: .25rem 0 .35rem .5rem; background: transparent; }
#admin-menu-section > div:first-child { margin: .85rem .35rem .45rem !important; padding: 1rem .45rem .45rem !important; border-top-color: rgba(255,255,255,.1) !important; letter-spacing: .09em !important; }
.sidebar-footer { padding: .9rem 1rem 1rem; border-top-color: rgba(255,255,255,.1); }
.user-info { gap: .18rem; margin-bottom: .75rem; }
.user-name { font-size: .92rem; }
.user-role { font-size: .72rem; letter-spacing: .09em; }
.logout-btn { min-height: 42px; border-radius: .65rem; }
.top-navbar { height: 64px; flex: 0 0 64px; padding: 0 clamp(1rem, 2vw, 1.75rem); background: #050505; border-bottom-color: rgba(255,255,255,.1); }
.mobile-menu-btn { width: 42px; height: 42px; border: 1px solid rgba(255,255,255,.14); border-radius: .65rem; font-size: 1.15rem; }
.breadcrumbs { font-size: .9rem; }
.top-actions { gap: .85rem !important; }
.btn-web-publica { min-height: 40px; padding: .5rem .85rem !important; border-radius: 999px !important; }
.content-area { padding: clamp(1.15rem, 2.6vw, 2.25rem); }
.view-container { max-width: 1440px; margin: 0 auto; }
.view-container > h2, .view-container > div > h2 { font-size: clamp(1.45rem, 2.4vw, 1.9rem); line-height: 1.2; letter-spacing: -.02em; text-wrap: balance; }
.view-container > p { max-width: 74ch; line-height: 1.6; }
.dashboard-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1rem; }
.widget { background: #111; border-color: rgba(255,255,255,.09); border-radius: .9rem; padding: clamp(1rem, 2vw, 1.4rem); box-shadow: none; }
.widget-header { margin-bottom: .85rem; padding-bottom: .75rem; }
.widget-header h3 { font-size: 1rem; line-height: 1.4; }
.badge { background: rgba(215,38,61,.15); color: #ff7b89; padding: .18rem .55rem; border-radius: 999px; }
.content-area :is(input:not([type=checkbox]), textarea, select) { min-height: 42px; border-radius: .6rem; }
.content-area :is(button, .btn, [role=button]) { transition: transform var(--motion-fast) var(--ease-ui), background-color var(--motion-fast), border-color var(--motion-fast), color var(--motion-fast); }
.content-area :is(button, .btn, [role=button]):active { transform: translateY(1px); }
.content-area :is(table th, .table th) { color: #c4c7ce; font-size: .78rem; letter-spacing: .035em; }
.content-area :is(table td, .table td) { line-height: 1.5; }
.content-area :is(.gallery-item, .blog-card, .merch-card, .memorial-card, .member-card, .miembro-card) { border-radius: .85rem; }
.content-area :is(.gallery-grid, .gallery-container, .merch-grid) { gap: 1rem; }
.content-area :is(.profile-card, .perfil-card, .garage-card, .moto-card, .widget) { border-color: rgba(255,255,255,.1); }
.content-area :is(.profile-card, .perfil-card, .garage-card, .moto-card) { background-color: #111; }
#perfil-root .profile-card-header { border-radius: 1rem; border-top-width: 2px; margin-bottom: 2rem; }
#perfil-root .garaje-layout { gap: 1rem !important; }
#perfil-root [style*="rgba(20,20,20"] { border-radius: .85rem !important; }
#perfil-root svg[stroke]:not([stroke="white"]) { stroke: #b3b7c5 !important; }
#perfil-root :is(button, .btn-primary, .btn-cancel) { min-height: 42px; border-radius: .65rem !important; }
#perfil-root h2, #perfil-root h3, #perfil-root h4 { text-wrap: balance; }

/* Campana: el estado del permiso push siempre queda escrito junto al control. */
.btn-bell { width: 42px; height: 42px; color: #c2c5cc; border: 1px solid transparent; border-radius: 50%; }
.btn-bell:hover, .btn-bell[aria-expanded="true"] { color: #fff; background: rgba(255,255,255,.07); border-color: rgba(255,255,255,.12); }
.btn-bell.has-unread { color: #fff; }
.btn-bell.has-unread::after { content: ""; position: absolute; inset: 4px; border: 1px solid rgba(215,38,61,.55); border-radius: inherit; pointer-events: none; }
.notifications-dropdown { margin-top: .6rem; border-radius: .85rem; border-color: rgba(255,255,255,.13); background: #101010; box-shadow: 0 18px 42px rgba(0,0,0,.48); }
.notifications-header { gap: .75rem; align-items: center; flex-wrap: wrap; border-radius: .85rem .85rem 0 0; }
.notifications-header h4 { font-size: .95rem; }
.notification-actions { gap: .5rem; }
.push-toggle { width: auto; min-width: 44px; min-height: 40px; padding: .35rem .65rem; gap: .5rem; border: 1px solid rgba(255,255,255,.16); border-radius: 999px; color: #c5c8ce; background: rgba(255,255,255,.035); }
.push-toggle svg { width: 18px; height: 18px; flex: 0 0 auto; }
.push-toggle-label { font-size: .76rem; font-weight: 650; white-space: nowrap; }
.push-toggle:hover { color: #fff; background: rgba(255,255,255,.08); }
.push-toggle.is-active { color: #fff; background: rgba(215,38,61,.17); border-color: rgba(215,38,61,.5); }
.push-toggle.is-active svg { animation: bell-ring 420ms ease; }
.push-feedback { display: block; position: static; width: auto; height: auto; padding: .65rem 1rem; margin: 0; overflow: visible; clip-path: none; color: #bdc1ca; font-size: .78rem; line-height: 1.45; border-bottom: 1px solid rgba(255,255,255,.08); }
.push-feedback.is-active { color: #fff; background: rgba(215,38,61,.1); }
.push-feedback.is-notice { color: #e0c3c7; border-bottom-color: rgba(215,38,61,.2); }
.push-toggle:disabled { opacity: .68; }

@keyframes bell-ring { 0%, 100% { transform: rotate(0); } 18% { transform: rotate(14deg); } 38% { transform: rotate(-12deg); } 58% { transform: rotate(8deg); } 78% { transform: rotate(-4deg); } }

@media (max-width: 768px) {
  .header-inner { min-height: 58px; }
  .logo-title img { width: 32px; height: 32px; }
  .apple-dock { width: min(460px, calc(100% - 28px)); bottom: max(12px, env(safe-area-inset-bottom)); }
  .apple-dock a { width: 44px; height: 44px; }
  .dock-indicator { width: 44px; height: 44px; }
  .hero-container { min-height: min(690px, calc(100svh - 58px)); }
  .hero-actions { flex-direction: row; }
  .hero-actions .btn { width: auto; }
  .cards-container { display: grid; grid-template-columns: 1fr; margin-inline: 0; padding: 0; overflow: visible; }
  .modern-card { width: 100%; min-width: 0; min-height: 245px; scroll-snap-align: unset; }
  .dashboard-grid { grid-template-columns: 1fr; }
  .admin-sidebar { width: min(300px, 88vw); background: #080808; }
  .content-area { padding: 1.1rem; }
  .top-navbar { height: 58px; flex-basis: 58px; padding-inline: .85rem; }
  .notifications-dropdown { position: fixed; top: 64px; right: .75rem; width: min(360px, calc(100vw - 1.5rem)); }
  .banner-social-ad { width: min(100%, 620px); min-height: 96px; gap: .9rem; padding: .65rem .8rem; }
  .banner-social-icon { flex-basis: 48px; width: 48px; height: 48px; }
  .banner-social-arrow { flex-basis: 32px; width: 32px; height: 32px; }
  .banner-social-copy strong { font-size: clamp(1.45rem, 7vw, 2rem); }
  .banner-social-handle { font-size: .75rem; }
}
@media (max-width: 480px) {
  .hero-content h1 { font-size: clamp(2.35rem, 11vw, 3.15rem); }
  .hero-actions { align-items: stretch; flex-direction: column; max-width: 320px; }
  .hero-actions .btn { width: 100%; }
  .section-header { padding-inline: .25rem; }
  .social-btn { min-height: 44px; padding: .6rem .8rem; font-size: .9rem; }
  .notifications-dropdown { top: 60px; right: .5rem; width: calc(100vw - 1rem); }
  .section-banner.banner-social-active .banner-container { padding-inline: .5rem; }
  .banner-social-ad { gap: .7rem; padding-inline: .65rem; }
  .banner-social-icon { flex-basis: 42px; width: 42px; height: 42px; }
  .banner-social-arrow { flex-basis: 30px; width: 30px; height: 30px; }
  .banner-social-eyebrow { letter-spacing: .12em; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; }
}
