/* ==========================================================================
   Penna y Asociados — estilos del sitio público
   Réplica del tema Avada original con transiciones modernas.
   ========================================================================== */

:root {
    --primary: #5f021f;
    --primary-hover: #7a0a2d;
    --primary-soft: #f7eef1;
    --text: #747474;
    --heading: #333333;
    --black: #000000;
    --border: #e5e5e5;
    --border-strong: #d2d3d4;
    --bg: #ffffff;
    --bg-soft: #f6f6f6;
    --submenu-bg: #f2efef;
    --submenu-border: #dcdadb;
    --footer-bg: #363839;
    --footer-text: #8c8989;
    --footer-title: #dddddd;
    --footer-link: #bfbfbf;

    --font: "Open Sans", Arial, Helvetica, sans-serif;
    --font-alt: "PT Sans", Arial, Helvetica, sans-serif;

    --container: 1100px;
    --gutter: 30px;

    /* Curvas y duraciones de animación */
    --ease-out: cubic-bezier(0.23, 1, 0.32, 1);
    --ease-in-out: cubic-bezier(0.77, 0, 0.175, 1);
    --dur-press: 140ms;
    --dur-hover: 200ms;
    --dur-menu: 200ms;
    --dur-modal: 250ms;
}

/* ---------- Base ---------- */

*,
*::before,
*::after { box-sizing: border-box; }

html {
    -webkit-text-size-adjust: 100%;
    scroll-behavior: smooth;
    scroll-padding-top: 90px;
}

body {
    margin: 0;
    background: var(--bg);
    color: var(--text);
    font-family: var(--font);
    font-size: 13px;
    line-height: 1.54;
    -webkit-font-smoothing: antialiased;
    overflow-x: hidden;
}

img { max-width: 100%; height: auto; display: block; }
a { color: var(--primary); text-decoration: none; transition: color var(--dur-hover) ease; }
@media (hover: hover) and (pointer: fine) {
    a:hover { color: var(--primary-hover); }
}
h1, h2, h3, h4, h5, h6 { color: var(--heading); font-weight: 400; margin: 0 0 .6em; line-height: 1.4; }
p { margin: 0 0 1.4em; }
button { font: inherit; }
input, textarea, select { font: inherit; color: var(--heading); }
:focus-visible { outline: 2px solid var(--primary); outline-offset: 2px; }
main:focus { outline: none; }

.container { width: 100%; max-width: calc(var(--container) + var(--gutter) * 2); margin: 0 auto; padding: 0 var(--gutter); }
.container-narrow { max-width: 900px; }
.section { padding-top: 55px; padding-bottom: 60px; }

.sr-only, .hp-field {
    position: absolute !important; width: 1px; height: 1px; padding: 0; margin: -1px;
    overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}
.skip-link { position: absolute; left: 12px; top: -60px; z-index: 1000; background: var(--primary); color: #fff; padding: 10px 16px; transition: transform var(--dur-hover) var(--ease-out); }
.skip-link:focus { transform: translateY(72px); color: #fff; }

.icon { flex: none; }

/* ---------- Botones ---------- */

.btn {
    display: inline-flex; align-items: center; justify-content: center; gap: 8px;
    padding: 11px 23px; border: 1px solid transparent; border-radius: 2px;
    font-family: var(--font-alt); font-weight: 700; font-size: 14px; line-height: 1.2;
    text-transform: uppercase; letter-spacing: 0; cursor: pointer;
    transition: background-color var(--dur-hover) ease, color var(--dur-hover) ease, transform var(--dur-press) var(--ease-out), box-shadow var(--dur-hover) ease;
}
.btn:active { transform: scale(0.97); }
.btn-primary { background: var(--primary); color: #fff; box-shadow: 0 2px 0 #3d0014; }
.btn-primary:visited { color: #fff; }
@media (hover: hover) and (pointer: fine) {
    .btn-primary:hover { background: var(--primary-hover); color: #fff; }
}
.btn-xl { font-size: 18px; padding: 17px 40px; border-color: rgba(255, 255, 255, .8); box-shadow: none; }

.link-more { display: inline-flex; align-items: center; gap: 4px; font-size: 12px; color: var(--heading); }
.link-more .icon { transition: transform var(--dur-hover) var(--ease-out); }
@media (hover: hover) and (pointer: fine) {
    .link-more:hover { color: var(--primary); }
    .link-more:hover .icon { transform: translateX(3px); }
}

/* ---------- Header ---------- */

.site-header { position: relative; z-index: 100; background: #fff; }
.header-top { border-bottom: 1px solid var(--border); }
.header-top-inner { display: flex; align-items: center; gap: 28px; padding-top: 30px; padding-bottom: 30px; min-height: 141px; }
.logo { flex: none; display: block; }
.logo img { width: 309px; height: auto; }
.header-tools { display: flex; align-items: center; gap: 18px; margin-left: 10px; flex: 1; }
.btn-video { font-size: 14px; padding: 13px 26px; }
.header-search { display: flex; align-items: center; gap: 12px; flex: 1; max-width: 460px; }
.header-search-label { font-size: 15px; color: var(--heading); white-space: nowrap; }
.search-field, .sidebar-search, .mobile-search { display: flex; flex: 1; min-width: 0; }
.search-field input, .sidebar-search input, .mobile-search input {
    flex: 1; min-width: 0; height: 29px; padding: 0 12px; border: 1px solid #d2d2d2; border-right: 0;
    font-size: 12px; background: #fff; border-radius: 0; -webkit-appearance: none; appearance: none;
    transition: border-color var(--dur-hover) ease;
}
.search-field input:focus, .sidebar-search input:focus, .mobile-search input:focus { outline: none; border-color: var(--primary); }
.search-field button, .sidebar-search button, .mobile-search button {
    flex: none; width: 29px; height: 29px; border: 0; background: #000; color: #fff; cursor: pointer;
    display: grid; place-items: center; transition: background-color var(--dur-hover) ease;
}
@media (hover: hover) and (pointer: fine) {
    .search-field button:hover, .sidebar-search button:hover, .mobile-search button:hover { background: var(--primary); }
}

.menu-toggle { display: none; margin-left: auto; background: none; border: 0; padding: 8px; color: var(--heading); cursor: pointer; }
.menu-toggle-icon { display: grid; }
.menu-toggle-icon .icon { grid-area: 1 / 1; transition: opacity var(--dur-menu) ease, transform var(--dur-menu) var(--ease-out); }
.menu-toggle-icon .icon-close { opacity: 0; transform: rotate(-45deg) scale(.9); }
.menu-toggle[aria-expanded="true"] .icon-menu { opacity: 0; transform: rotate(45deg) scale(.9); }
.menu-toggle[aria-expanded="true"] .icon-close { opacity: 1; transform: none; }

/* Navegación principal: se vuelve fija al hacer scroll */
.main-nav { background: #fff; border-bottom: 1px solid var(--border); height: 82px; }
.main-nav > .container { height: 100%; }
.nav-stuck .main-nav {
    position: fixed; top: 0; left: 0; right: 0; height: 64px; z-index: 200;
    box-shadow: 0 1px 12px rgba(0, 0, 0, .08);
    animation: nav-drop 300ms var(--ease-out);
}
.nav-stuck .site-header { padding-bottom: 82px; }
@keyframes nav-drop { from { transform: translateY(-100%); } to { transform: translateY(0); } }

.menu { list-style: none; margin: 0; padding: 0; display: flex; height: 100%; align-items: stretch; }
.menu-item { position: relative; display: flex; align-items: center; }
.menu-item + .menu-item { margin-left: 22px; }
.menu-item > a {
    position: relative; display: flex; align-items: center; height: 100%;
    font-size: 17px; color: var(--heading); white-space: nowrap;
}
.menu-item > a::before {
    content: ""; position: absolute; left: 0; right: 0; top: 0; height: 3px; background: var(--primary);
    transform: scaleX(0); transform-origin: left; transition: transform 250ms var(--ease-out);
}
.menu-item.is-active > a { color: var(--primary); }
.menu-item.is-active > a::before { transform: scaleX(1); }
@media (hover: hover) and (pointer: fine) {
    .menu-item:hover > a { color: var(--primary); }
    .menu-item:hover > a::before { transform: scaleX(1); }
}
.submenu-toggle { display: none; }

.submenu {
    list-style: none; margin: 0; padding: 0; position: absolute; top: 100%; left: 0; min-width: 220px; width: max-content; max-width: 340px;
    background: var(--submenu-bg); border-top: 3px solid var(--primary);
    box-shadow: 0 8px 22px rgba(0, 0, 0, .08);
    opacity: 0; visibility: hidden; transform: translateY(6px) scale(.98); transform-origin: top left;
    transition: opacity var(--dur-menu) var(--ease-out), transform var(--dur-menu) var(--ease-out), visibility 0s linear var(--dur-menu);
}
.menu-item.has-children:hover > .submenu,
.menu-item.has-children:focus-within > .submenu,
.menu-item.is-open > .submenu {
    opacity: 1; visibility: visible; transform: none;
    transition: opacity var(--dur-menu) var(--ease-out), transform var(--dur-menu) var(--ease-out), visibility 0s;
}
.submenu a {
    display: block; padding: 9px 20px; font-size: 15px; color: var(--heading); border-bottom: 1px solid var(--submenu-border);
    transition: background-color var(--dur-hover) ease, color var(--dur-hover) ease;
}
.submenu li:last-child a { border-bottom: 0; }
.submenu a[aria-current="page"] { color: var(--primary); }
@media (hover: hover) and (pointer: fine) {
    .submenu a:hover { background: #f8f8f8; color: var(--primary); }
}
.mobile-search { display: none; }

/* ---------- Barra de título ---------- */

.title-bar { background: var(--bg-soft); border-top: 1px solid var(--border-strong); border-bottom: 1px solid var(--border-strong); }
.title-bar-inner { display: flex; align-items: center; justify-content: space-between; gap: 20px; min-height: 87px; padding-top: 16px; padding-bottom: 16px; }
.title-bar-heading { font-size: 18px; color: #222; margin: 0; }
.breadcrumbs { font-size: 10px; color: var(--heading); display: flex; flex-wrap: wrap; gap: 5px; justify-content: flex-end; text-align: right; }
.breadcrumbs a { color: var(--heading); }
@media (hover: hover) and (pointer: fine) { .breadcrumbs a:hover { color: var(--primary); } }

/* ---------- Hero / slider ---------- */

.hero { position: relative; overflow: hidden; background: #fff; }
.hero-track { display: grid; }
.hero-slide {
    grid-area: 1 / 1; min-height: 500px; display: flex; align-items: center;
    background-size: cover; background-position: center; background-color: #fff;
    opacity: 0; visibility: hidden;
    transition: opacity 900ms ease, visibility 0s linear 900ms;
}
.hero-slide.is-active { opacity: 1; visibility: visible; transition: opacity 900ms ease, visibility 0s; z-index: 1; }
.hero-bg-gray { background-color: #9a9a9a; }
.hero-content { text-align: center; padding-top: 50px; padding-bottom: 60px; }
.hero-title { font-weight: 400; margin: 0 auto 18px; max-width: 1000px; color: var(--black); }
.hero-text { margin: 0 auto 32px; max-width: 900px; color: var(--black); }
.hero-size-large .hero-title { font-size: clamp(38px, 6vw, 74px); line-height: 1.12; }
.hero-size-large .hero-text { font-size: clamp(18px, 2.3vw, 30px); line-height: 1.35; }
.hero-size-small .hero-title { font-size: clamp(20px, 2.4vw, 32px); line-height: 1.4; color: var(--heading); }
.hero-size-small .hero-text { font-size: clamp(15px, 1.4vw, 18px); line-height: 1.6; color: var(--heading); }
.hero-bg-gray .hero-title, .hero-bg-gray .hero-text { color: #fff; }

/* El contenido de cada slide entra con un leve desplazamiento */
.hero-slide .hero-title,
.hero-slide .hero-text,
.hero-slide .btn { opacity: 0; transform: translateY(18px); }
.hero-slide.is-active .hero-title,
.hero-slide.is-active .hero-text,
.hero-slide.is-active .btn {
    opacity: 1; transform: none;
    transition: opacity 700ms var(--ease-out), transform 900ms var(--ease-out);
}
.hero-slide.is-active .hero-title { transition-delay: 250ms; }
.hero-slide.is-active .hero-text { transition-delay: 370ms; }
.hero-slide.is-active .btn { transition-delay: 490ms, 490ms, 0s, 0s, 0s; transition-property: opacity, transform, background-color, color, box-shadow; }
.hero-slide.is-active .btn:active { transform: scale(0.97); transition-delay: 0s; }

.hero-arrow {
    position: absolute; top: 50%; z-index: 3; width: 44px; height: 44px; margin-top: -22px;
    display: grid; place-items: center; border: 0; border-radius: 50%; cursor: pointer;
    background: rgba(0, 0, 0, .25); color: #fff; opacity: 0;
    transition: opacity var(--dur-hover) ease, background-color var(--dur-hover) ease, transform var(--dur-press) var(--ease-out);
}
.hero-arrow:active { transform: scale(0.94); }
.hero-prev { left: 18px; }
.hero-next { right: 18px; }
.hero:hover .hero-arrow, .hero-arrow:focus-visible { opacity: 1; }
@media (hover: hover) and (pointer: fine) { .hero-arrow:hover { background: var(--primary); } }
@media (hover: none) { .hero-arrow { opacity: .8; } }

.hero-dots { position: absolute; left: 0; right: 0; bottom: 22px; z-index: 3; display: flex; justify-content: center; gap: 8px; }
.hero-dots button {
    width: 10px; height: 10px; padding: 0; border-radius: 50%; border: 0; cursor: pointer;
    background: rgba(255, 255, 255, .55); box-shadow: 0 0 0 1px rgba(0, 0, 0, .15);
    transition: background-color var(--dur-hover) ease, transform var(--dur-hover) var(--ease-out);
}
.hero-dots button[aria-selected="true"] { background: #fff; transform: scale(1.25); }

/* ---------- Home ---------- */

.home-intro { padding: 60px 0 70px; text-align: center; }
.home-intro-title { font-size: clamp(22px, 2.4vw, 30px); line-height: 1.45; color: var(--heading); margin-bottom: 22px; }
.home-intro-title span { color: var(--primary); }
.home-intro-text { font-size: 13px; line-height: 1.8; max-width: 1100px; margin: 0 auto 26px; }
.home-intro-text strong { color: var(--heading); }

.video-embed { position: relative; aspect-ratio: 16 / 9; background: #000; margin: 0 auto; overflow: hidden; }
.video-embed iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.video-facade { position: absolute; inset: 0; width: 100%; padding: 0; border: 0; cursor: pointer; background: #000; color: #fff; }
.video-facade img { width: 100%; height: 100%; object-fit: cover; opacity: .85; transition: opacity 300ms ease, transform 600ms var(--ease-out); }
.video-facade-title {
    position: absolute; top: 0; left: 0; right: 0; padding: 14px 20px; text-align: left;
    background: linear-gradient(rgba(0, 0, 0, .75), transparent); font-family: Arial, sans-serif; font-size: 16px; font-weight: 700;
}
.video-play {
    position: absolute; left: 50%; top: 50%; width: 76px; height: 52px; margin: -26px 0 0 -38px;
    display: grid; place-items: center; border-radius: 12px; background: var(--primary);
    transition: transform var(--dur-hover) var(--ease-out), background-color var(--dur-hover) ease;
}
@media (hover: hover) and (pointer: fine) {
    .video-facade:hover img { opacity: 1; transform: scale(1.02); }
    .video-facade:hover .video-play { transform: scale(1.08); background: #c4302b; }
}
.video-facade:active .video-play { transform: scale(0.96); }

.home-founder { background: var(--bg-soft); border-top: 1px solid var(--border); padding: 60px 0; }
.founder { display: grid; grid-template-columns: 220px 1fr; gap: 40px; align-items: center; max-width: 900px; }
.founder-photo img { width: 220px; height: auto; box-shadow: 0 10px 30px rgba(0, 0, 0, .12); }
.founder-name { font-size: 22px; margin-bottom: 2px; }
.founder-role { font-size: 13px; color: var(--primary); text-transform: uppercase; letter-spacing: .06em; margin-bottom: 16px; }
.founder-bio { font-size: 14px; line-height: 1.8; }

/* ---------- Contenido editorial ---------- */

.entry-content { color: var(--text); font-size: 13px; line-height: 1.7; }
.entry-content::after { content: ""; display: table; clear: both; }
.entry-content h1 { font-size: 34px; color: var(--heading); margin: 1.1em 0 .5em; }
.entry-content h2 { font-size: 22px; margin: 1em 0 .6em; }
.entry-content h3 { font-size: 16px; line-height: 1.55; color: var(--text); margin: 0 0 1.1em; }
.entry-content h4 { font-size: 13px; line-height: 1.7; color: var(--text); margin: 0 0 1.1em; }
.entry-content > :first-child { margin-top: 0; }
.entry-content strong { color: var(--heading); }
.entry-content img { margin: 10px auto 20px; }
.entry-content p img:only-child { margin-top: 0; }
.entry-content ul, .entry-content ol { padding-left: 1.4em; margin: 0 0 1.4em; }
.entry-content li { margin-bottom: .4em; }
.entry-content li > h3, .entry-content li > h4 { margin-bottom: .4em; }
.entry-content blockquote { margin: 0 0 1.4em; padding: 4px 0 4px 20px; border-left: 3px solid var(--primary); }
.entry-content iframe { display: block; width: 100%; aspect-ratio: 16 / 9; height: auto; border: 0; margin: 10px 0 24px; }
.entry-content table { width: 100%; border-collapse: collapse; margin: 0 0 30px; font-size: 13px; display: block; overflow-x: auto; }
.entry-content th, .entry-content td { border: 1px solid var(--border); padding: 10px 12px; text-align: left; vertical-align: top; }
.entry-content tr:first-child td { background: #fafafa; }
.entry-content td p { margin: 0 0 .3em; }
.entry-content th img { margin: 0 auto; }
.entry-content a { text-decoration: underline; text-decoration-color: rgba(95, 2, 31, .3); text-underline-offset: 2px; transition: color var(--dur-hover) ease, text-decoration-color var(--dur-hover) ease; }
@media (hover: hover) and (pointer: fine) { .entry-content a:hover { text-decoration-color: currentColor; } }

.entry-page { max-width: 100%; }
.section-title { font-size: 18px; color: var(--heading); margin: 0 0 30px; display: flex; align-items: center; gap: 16px; }
.section-title::after { content: ""; flex: 1; height: 6px; border-top: 1px solid var(--border); border-bottom: 1px solid var(--border); }

.team { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 40px; margin-bottom: 50px; }
.team-member img { width: 150px; height: 150px; object-fit: cover; margin: 0 0 16px; }
.team-member h4 { font-size: 14px; color: var(--heading); font-weight: 600; margin-bottom: 10px; }
.team-member p { text-align: justify; }
.reading-box { background: var(--bg-soft); border-top: 3px solid var(--primary) !important; border-left: 0 !important; padding: 26px 30px !important; }
.reading-box p { font-size: 15px; line-height: 1.7; color: var(--heading); margin: 0; }

.archive-description { margin-bottom: 40px; }
.archive-description img { max-width: 886px; width: 100%; }

/* Listados de documentos */
.topic-list { list-style: none; padding: 0; margin: 0 0 50px; display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 10px; }
.topic-list a {
    display: flex; justify-content: space-between; align-items: center; padding: 14px 18px;
    border: 1px solid var(--border); color: var(--heading); font-size: 14px;
    transition: border-color var(--dur-hover) ease, color var(--dur-hover) ease, background-color var(--dur-hover) ease;
}
@media (hover: hover) and (pointer: fine) { .topic-list a:hover { border-color: var(--primary); color: var(--primary); background: var(--primary-soft); } }
.doc-list { display: grid; gap: 0; }
.doc-item { padding: 22px 0; border-bottom: 1px solid var(--border); }
.doc-item time { font-size: 11px; text-transform: uppercase; letter-spacing: .06em; color: #999; }
.doc-item h3 { font-size: 17px; margin: 4px 0 8px; }
.doc-item h3 a { color: var(--heading); }
@media (hover: hover) and (pointer: fine) { .doc-item h3 a:hover { color: var(--primary); } }
.doc-item p { margin: 0; }

/* ---------- Grilla de posts (masonry) ---------- */

.post-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 30px; align-items: start; }
.post-grid.is-masonry { display: flex; gap: 30px; align-items: flex-start; }
.masonry-col { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 30px; }
.post-card {
    background: #fff; border: 1px solid #ebeaea; border-bottom-width: 3px;
    transition: box-shadow 300ms ease, transform 300ms var(--ease-out);
}
@media (hover: hover) and (pointer: fine) {
    .post-card:hover { box-shadow: 0 12px 30px rgba(0, 0, 0, .08); transform: translateY(-3px); }
    .post-card:hover .post-card-media img { transform: scale(1.04); }
}
.post-card-media { display: block; overflow: hidden; aspect-ratio: 16 / 10; background: var(--bg-soft); }
.post-card-media img { width: 100%; height: 100%; object-fit: cover; transition: transform 600ms var(--ease-out); }
.post-card-body { padding: 26px 24px 22px; }
.post-card-title { font-size: 18px; line-height: 1.45; margin: 0 0 16px; padding-bottom: 16px; border-bottom: 1px solid #e7e6e6; }
.post-card-title a { color: var(--heading); }
@media (hover: hover) and (pointer: fine) { .post-card-title a:hover { color: var(--primary); } }
.post-card-excerpt { font-size: 12.5px; line-height: 1.65; margin: 0 0 18px; overflow-wrap: anywhere; }

.pagination { display: flex; justify-content: center; flex-wrap: wrap; gap: 6px; margin-top: 50px; font-size: 12px; }
.pagination a, .pagination span {
    display: inline-flex; align-items: center; gap: 4px; min-width: 32px; height: 32px; padding: 0 10px; justify-content: center;
    border: 1px solid var(--border); color: var(--heading);
    transition: border-color var(--dur-hover) ease, color var(--dur-hover) ease, background-color var(--dur-hover) ease;
}
.pagination .current { background: var(--primary); border-color: var(--primary); color: #fff; }
@media (hover: hover) and (pointer: fine) { .pagination a:hover { border-color: var(--primary); color: var(--primary); } }

/* ---------- Post individual y sidebar ---------- */

.layout-sidebar { display: grid; grid-template-columns: minmax(0, 1fr) 240px; gap: 60px; padding-top: 55px; padding-bottom: 70px; }
.post-hero { margin: 0 0 28px; overflow: hidden; }
.post-hero img { width: 100%; }
.post-title { font-size: 18px; color: var(--heading); margin-bottom: 8px; }
.post-meta { font-size: 12px; color: #999; margin-bottom: 26px; display: flex; flex-wrap: wrap; gap: 8px; }

.related { margin-top: 50px; }
.line-title { display: flex; align-items: center; gap: 14px; font-size: 14px; color: var(--heading); margin-bottom: 20px; }
.line-title::after { content: ""; flex: 1; height: 6px; border-top: 1px solid var(--border); border-bottom: 1px solid var(--border); }
.related-track { display: grid; grid-auto-flow: column; grid-auto-columns: calc((100% - 60px) / 4); gap: 20px; overflow-x: auto; scroll-snap-type: x mandatory; padding-bottom: 10px; scrollbar-width: thin; }
.related-item { scroll-snap-align: start; color: var(--heading); font-size: 12px; line-height: 1.45; }
.related-thumb { display: block; aspect-ratio: 4 / 3; overflow: hidden; background: var(--bg-soft); margin-bottom: 8px; }
.related-thumb img { width: 100%; height: 100%; object-fit: cover; transition: transform 500ms var(--ease-out); }
.related-placeholder { display: grid; place-items: center; height: 100%; color: #c9c9c9; font-size: 20px; letter-spacing: .1em; }
@media (hover: hover) and (pointer: fine) {
    .related-item:hover { color: var(--primary); }
    .related-item:hover img { transform: scale(1.05); }
}

.sidebar { font-size: 13px; }
.widget { margin-bottom: 40px; }
.widget-title { font-size: 13px; color: var(--heading); margin-bottom: 14px; }
.widget-title-box { font-size: 13px; color: var(--primary); border-left: 3px solid var(--primary); padding: 10px 14px; background: #fff; border-top: 1px solid var(--border); border-bottom: 1px solid var(--border); border-right: 1px solid var(--border); }
.widget-text p { margin: 0; line-height: 1.8; }
.widget-list { list-style: none; margin: 0; padding: 0; }
.widget-list li { border-bottom: 1px solid var(--border); }
.widget-list a { display: block; padding: 9px 0 9px 14px; position: relative; color: var(--text); line-height: 1.5; transition: color var(--dur-hover) ease, transform var(--dur-hover) var(--ease-out); }
.widget-list a::before { content: "›"; position: absolute; left: 0; top: 8px; color: #aaa; }
@media (hover: hover) and (pointer: fine) { .widget-list a:hover { color: var(--primary); transform: translateX(3px); } }

.social { list-style: none; margin: 0; padding: 0; display: flex; gap: 14px; }
.social a { display: grid; place-items: center; color: #bebdbd; transition: color var(--dur-hover) ease, transform var(--dur-hover) var(--ease-out); }
.social-muted a { color: #b4b4b4; }
@media (hover: hover) and (pointer: fine) {
    .social a:hover { color: #fff; transform: translateY(-2px); }
    .social-muted a:hover { color: var(--primary); }
}

/* ---------- Formulario de contacto ---------- */

.contact-form { display: grid; gap: 18px; max-width: 100%; }
.field { display: grid; gap: 8px; font-size: 12px; }
.field em { font-style: normal; color: #999; }
.field input, .field textarea {
    width: 100%; padding: 9px 12px; border: 1px solid #d2d2d2; border-radius: 0; background: #fff; font-size: 13px;
    transition: border-color var(--dur-hover) ease, box-shadow var(--dur-hover) ease;
}
.field input { height: 32px; }
.field textarea { resize: vertical; min-height: 120px; }
.field input:focus, .field textarea:focus { outline: none; border-color: var(--primary); box-shadow: 0 0 0 3px rgba(95, 2, 31, .1); }
.field.has-error input, .field.has-error textarea { border-color: #b3261e; }
.contact-form .btn { justify-self: start; background: #8b0000; box-shadow: none; }
.contact-form .btn[aria-busy="true"] { opacity: .7; pointer-events: none; }

.notice { padding: 14px 18px; margin: 0 0 22px; border-left: 3px solid; font-size: 13px; animation: notice-in 300ms var(--ease-out); }
.notice-success { background: #eef7ef; border-color: #2e7d32; color: #1e4d20; }
.notice-error { background: #fdecea; border-color: #b3261e; color: #7a1a14; }
@keyframes notice-in { from { opacity: 0; transform: translateY(-6px); } }

.search-page-form { display: flex; gap: 10px; max-width: 560px; margin: 0 0 30px; }
.search-page-form input { flex: 1; height: 42px; padding: 0 14px; border: 1px solid #d2d2d2; }
.search-page-form input:focus { outline: none; border-color: var(--primary); }
.search-count { margin-bottom: 30px; }
.empty-state { font-size: 15px; }
.error-page { text-align: center; }
.error-page .search-page-form { margin: 26px auto; }
.error-code { font-size: 120px; font-weight: 300; line-height: 1; color: var(--primary); margin: 0 0 10px; }

/* ---------- Footer ---------- */

.site-footer { background: var(--footer-bg); color: var(--footer-text); border-top: 12px solid #2d2f30; }
.footer-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 30px; padding-top: 43px; padding-bottom: 40px; }
.footer-title { font-size: 17px; color: var(--footer-title); text-transform: uppercase; margin-bottom: 18px; }
.footer-links, .footer-fake-titles { list-style: none; margin: 0; padding: 0; }
.footer-links a { display: inline-block; color: var(--footer-link); font-size: 15px; line-height: 1.6; transition: color var(--dur-hover) ease, transform var(--dur-hover) var(--ease-out); }
.footer-fake-titles li { margin-bottom: 20px; }
.footer-fake-titles a { color: var(--footer-title); font-size: 17px; text-transform: uppercase; transition: color var(--dur-hover) ease; }
@media (hover: hover) and (pointer: fine) {
    .footer-links a:hover { color: #fff; transform: translateX(3px); }
    .footer-fake-titles a:hover { color: #fff; }
}
.footer-logo { margin: 36px 0 26px; width: 238px; }
.footer-subtitle { font-size: 11px; text-transform: uppercase; color: #6d6b6b; margin-bottom: 12px; font-weight: 400; }
.footer-contact { font-style: normal; font-size: 13px; line-height: 1.7; }
.footer-contact p { margin: 0 0 10px; }
.footer-contact a { color: var(--footer-link); }
.footer-bottom { border-top: 1px solid #4b4c4d; background: #282a2b; padding: 18px 0; font-size: 12px; color: #8c8989; }

.to-top {
    position: fixed; right: 20px; bottom: 20px; z-index: 150; width: 42px; height: 42px; display: grid; place-items: center;
    background: #333; color: #fff; border-radius: 4px 4px 0 0;
    opacity: 0; visibility: hidden; transform: translateY(12px);
    transition: opacity 250ms var(--ease-out), transform 250ms var(--ease-out), visibility 0s linear 250ms, background-color var(--dur-hover) ease;
}
.to-top.is-visible { opacity: 1; visibility: visible; transform: none; transition: opacity 250ms var(--ease-out), transform 250ms var(--ease-out), visibility 0s, background-color var(--dur-hover) ease; }
.to-top:visited { color: #fff; }
@media (hover: hover) and (pointer: fine) { .to-top:hover { background: var(--primary); color: #fff; } }

/* ---------- Modal de video ---------- */

.video-modal { position: fixed; inset: 0; z-index: 500; display: grid; place-items: center; padding: 20px; }
.video-modal[hidden] { display: none; }
.video-modal-backdrop { position: absolute; inset: 0; background: rgba(10, 0, 4, .82); opacity: 0; transition: opacity var(--dur-modal) var(--ease-out); }
.video-modal-dialog {
    position: relative; width: min(1000px, 100%); opacity: 0; transform: scale(.96);
    transition: opacity var(--dur-modal) var(--ease-out), transform var(--dur-modal) var(--ease-out);
}
.video-modal.is-open .video-modal-backdrop { opacity: 1; }
.video-modal.is-open .video-modal-dialog { opacity: 1; transform: none; }
.video-frame { aspect-ratio: 16 / 9; background: #000; }
.video-frame iframe { width: 100%; height: 100%; border: 0; display: block; }
.video-modal-close { position: absolute; top: -46px; right: 0; background: none; border: 0; color: #fff; cursor: pointer; padding: 8px; transition: transform var(--dur-press) var(--ease-out); }
.video-modal-close:active { transform: scale(.9); }
body.modal-open { overflow: hidden; }

/* ---------- Revelado al hacer scroll ---------- */

.js [data-reveal] { opacity: 0; transform: translateY(24px); }
.js [data-reveal].is-revealed {
    opacity: 1; transform: none;
    transition: opacity 700ms var(--ease-out), transform 900ms var(--ease-out);
    transition-delay: calc(var(--i, 0) * 70ms);
}
.js .post-card[data-reveal].is-revealed { transition: opacity 700ms var(--ease-out) calc(var(--i, 0) * 70ms), transform 900ms var(--ease-out) calc(var(--i, 0) * 70ms), box-shadow 300ms ease; }
@media (hover: hover) and (pointer: fine) {
    .js .post-card[data-reveal].is-revealed:hover { transform: translateY(-3px); transition-delay: 0s; transition-duration: 300ms; }
}

/* ---------- Responsive ---------- */

@media (max-width: 1100px) {
    .header-search-label { display: none; }
    .menu-item + .menu-item { margin-left: 16px; }
    .menu-item > a { font-size: 15px; }
}

@media (max-width: 900px) {
    :root { --gutter: 20px; }
    html { scroll-padding-top: 20px; }
    .header-top-inner { min-height: 0; padding-top: 18px; padding-bottom: 18px; gap: 12px; }
    .logo img { width: 230px; }
    .header-tools { display: none; }
    .menu-toggle { display: block; }

    .main-nav {
        height: auto; border-bottom: 0; overflow: hidden;
        display: grid; grid-template-rows: 0fr; transition: grid-template-rows 300ms var(--ease-out);
    }
    .main-nav > .container { min-height: 0; overflow: hidden; }
    .main-nav.is-open { grid-template-rows: 1fr; border-bottom: 1px solid var(--border); }
    .nav-stuck .main-nav { position: static; height: auto; box-shadow: none; animation: none; }
    .nav-stuck .site-header { padding-bottom: 0; }

    .menu { flex-direction: column; height: auto; padding: 6px 0 10px; }
    .menu-item { flex-wrap: wrap; border-bottom: 1px solid var(--border); }
    .menu-item + .menu-item { margin-left: 0; }
    .menu-item > a { flex: 1; height: auto; padding: 13px 0; font-size: 16px; }
    .menu-item > a::before { display: none; }
    .submenu-toggle {
        display: grid; place-items: center; width: 44px; height: 44px; background: none; border: 0; color: var(--heading); cursor: pointer;
    }
    .submenu-toggle .icon { transition: transform 250ms var(--ease-out); }
    .submenu-toggle[aria-expanded="true"] .icon { transform: rotate(180deg); }
    .submenu {
        position: static; flex-basis: 100%; min-width: 0; box-shadow: none; border-top: 0;
        opacity: 1; visibility: visible; transform: none; display: none; margin-bottom: 10px;
    }
    .menu-item.has-children:not(.is-open):hover > .submenu,
    .menu-item.has-children:not(.is-open):focus-within > .submenu { display: none; }
    .menu-item.is-open > .submenu { display: block; animation: submenu-in 250ms var(--ease-out); }
    @keyframes submenu-in { from { opacity: 0; transform: translateY(-4px); } }
    .submenu { width: auto; max-width: none; }
    .submenu a { font-size: 14px; }
    .mobile-search { display: flex; margin: 6px 0 20px; }
    .mobile-search input, .mobile-search button { height: 40px; }
    .mobile-search button { width: 44px; }

    .title-bar-inner { flex-direction: column; align-items: flex-start; min-height: 0; gap: 6px; }
    .breadcrumbs { justify-content: flex-start; text-align: left; }

    .hero-slide { min-height: 440px; }
    .hero-arrow { display: none; }

    .layout-sidebar { grid-template-columns: 1fr; gap: 40px; padding-top: 36px; }
    .post-grid { grid-template-columns: repeat(2, 1fr); }
    .related-track { grid-auto-columns: calc((100% - 20px) / 2.3); }
    .footer-grid { grid-template-columns: repeat(2, 1fr); }
    .section { padding-top: 36px; padding-bottom: 44px; }
}

@media (max-width: 600px) {
    .logo img { width: 200px; }
    .hero-slide { min-height: 420px; }
    .hero-size-small .hero-title { font-size: 19px; }
    .btn-xl { font-size: 15px; padding: 14px 28px; }
    .home-intro { padding: 44px 0 50px; }
    .founder { grid-template-columns: 1fr; text-align: center; gap: 24px; }
    .founder-photo img { margin: 0 auto; width: 180px; }
    .post-grid, .post-grid.is-masonry { grid-template-columns: 1fr; }
    .footer-grid { grid-template-columns: 1fr; }
    .entry-content h1 { font-size: 26px; }
    .search-page-form { flex-direction: column; }
    .error-code { font-size: 90px; }
}

/* ---------- Movimiento reducido: sin desplazamientos, sólo fundidos breves ---------- */

@media (prefers-reduced-motion: reduce) {
    html { scroll-behavior: auto; }
    .js [data-reveal] { transform: none; }
    .js [data-reveal].is-revealed { transition: opacity 300ms ease; transition-delay: 0s; }
    .hero-slide .hero-title, .hero-slide .hero-text, .hero-slide .btn { transform: none; }
    .hero-slide, .hero-slide.is-active { transition-duration: 300ms; }
    .hero-slide.is-active .hero-title, .hero-slide.is-active .hero-text, .hero-slide.is-active .btn { transition: opacity 300ms ease; transition-delay: 0s; }
    .nav-stuck .main-nav { animation: none; }
    .submenu, .video-modal-dialog, .to-top { transform: none !important; }
    .post-card, .post-card-media img, .related-thumb img, .video-facade img, .widget-list a, .footer-links a, .social a { transition-property: color, background-color, box-shadow, opacity; }
    .post-card:hover, .js .post-card[data-reveal].is-revealed:hover { transform: none; }
    .main-nav { transition: none; }
}
