/* ============================================================
   Desde el otro lado — CSS maestro
   ============================================================ */

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

html {
    background: #ffffff;
    -webkit-text-size-adjust: 100%;
    scrollbar-gutter: stable;
}

body {
    background: #ffffff;
    color: #000000;
    font-family: 'Source Serif 4', Georgia, 'Times New Roman', serif;
    font-size: 18px;
    line-height: 1.7;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

body.menu-open {
    overflow: hidden;
}

img, svg, video {
    max-width: 100%;
    display: block;
}

a {
    color: inherit;
    text-decoration: none;
    transition: opacity 0.2s ease;
    cursor: pointer;
}

a:hover { opacity: 0.65; }

:root {
    --color-text: #000000;
    --color-text-emphatic: #111111;
    --color-text-muted: #7a7a7a;
    --color-text-soft: #2a2a2a;
    --color-border: #ececec;
    --color-bg: #ffffff;
    --color-bg-soft: #fafafa;

    --font-serif: 'Source Serif 4', Georgia, 'Times New Roman', serif;
    --font-sans: 'Source Sans 3', -apple-system, BlinkMacSystemFont, sans-serif;

    --width-wide: 1100px;
    --width-stream: 808px;
    --width-narrow: 808px;
    --width-subscribe: 540px;

    --pad-side-desktop: 40px;
    --pad-side-mobile: 22px;
}

@import url('https://fonts.googleapis.com/css2?family=Source+Serif+4:ital,opsz,wght@0,8..60,400;0,8..60,500;0,8..60,600;1,8..60,400&family=Source+Sans+3:wght@400;500;600;700&display=swap');

/* Containers */
.container {
    max-width: var(--width-wide);
    margin: 0 auto;
    padding: 0 var(--pad-side-desktop);
    width: 100%;
}
.container-stream {
    max-width: var(--width-stream);
    margin: 0 auto;
    padding: 0 var(--pad-side-desktop);
    width: 100%;
}
.container-narrow {
    max-width: var(--width-narrow);
    margin: 0 auto;
    padding: 0 var(--pad-side-desktop);
    width: 100%;
}
.container-subscribe {
    max-width: var(--width-subscribe);
    margin: 0 auto;
    padding: 0 var(--pad-side-desktop);
    width: 100%;
}

/* Header */
.site-header {
    padding: 16px 0;
    border-bottom: 1px solid var(--color-border);
    background: var(--color-bg);
    position: sticky;
    top: 0;
    z-index: 100;
    transition: transform 0.3s ease;
}

.site-header.is-hidden {
    transform: translateY(-100%);
}

.site-header-inner {
    display: flex;
    justify-content: space-between;
    align-items: center;
    max-width: 808px;
    margin: 0 auto;
    padding: 0 40px;
    width: 100%;
}

.site-wordmark {
    display: inline-flex;
    align-items: center;
}

/* Logo solo (sin texto): más grande porque es la única presencia de marca */
.site-logo {
    height: 40px;
    width: auto;
    display: block;
}

/* Navegación */
.site-nav {
    display: flex;
    gap: 24px;
    list-style: none;
    margin: 0;
    padding: 0;
}
.site-nav ul {
    display: flex;
    gap: 24px;
    list-style: none;
    margin: 0;
    padding: 0;
}
.site-nav li {
    list-style: none;
    margin: 0;
    padding: 0;
}
.site-nav li::before,
.site-nav li::marker {
    content: none;
    display: none;
}
.site-nav a {
    font-family: var(--font-sans);
    font-size: 13px;
    color: var(--color-text);
    position: relative;
    padding-bottom: 3px;
    font-weight: 400;
}
.site-nav .nav-current a,
.site-nav a.nav-current {
    position: relative;
}
.site-nav .nav-current a::after,
.site-nav a.nav-current::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 1px;
    background: var(--color-text);
}

/* Botón hamburguesa */
.menu-toggle {
    display: none;
    background: transparent;
    border: none;
    padding: 8px;
    cursor: pointer;
    width: 40px;
    height: 40px;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 5px;
    z-index: 101;
}

.menu-toggle-line {
    display: block;
    width: 22px;
    height: 1.5px;
    background: var(--color-text);
    transition: transform 0.25s ease, opacity 0.2s ease;
}

/* Footer */
.site-footer {
    border-top: 1px solid var(--color-border);
    padding: 32px 0;
    font-family: var(--font-sans);
    font-size: 12px;
    color: var(--color-text-muted);
    margin-top: 64px;
}

.site-footer-inner {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 24px;
    flex-wrap: wrap;
    max-width: 808px;
    margin: 0 auto;
    padding: 0 40px;
    width: 100%;
}

.footer-left {
    display: flex;
    align-items: center;
    gap: 18px;
}
.social-icons {
    display: flex;
    gap: 14px;
    align-items: center;
}
.social-icons a {
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--color-text-muted);
    transition: opacity 0.2s ease;
}
.social-icons a:hover { opacity: 0.55; }
.social-icons svg {
    width: 16px;
    height: 16px;
    fill: var(--color-text-muted);
    display: block;
}
.site-footer a { color: var(--color-text-muted); }

/* Tag */
.tag-label {
    display: inline-block;
    font-family: var(--font-sans);
    font-size: 11px;
    font-weight: 600;
    letter-spacing: 0.18em;
    text-transform: uppercase;
    color: var(--color-text);
    padding-bottom: 3px;
    border-bottom: 1px solid var(--color-text);
    margin-bottom: 14px;
}

/* Home presentación */
.home-presentation {
    text-align: center;
    padding: 72px 0 48px;
    max-width: 720px;
    margin: 0 auto 24px;
    border-bottom: 1px solid var(--color-border);
}

/* Firma editorial: Eduardo Garrido arriba del título
   Estilo tipo firma refinada (no tag): sin borde, regular, tracking generoso */
.home-signature {
    display: inline-block;
    font-family: var(--font-sans);
    font-size: 16px;
    font-weight: 400;
    letter-spacing: 0.32em;
    text-transform: uppercase;
    color: var(--color-text);
    margin-bottom: 12px;
    /* Sobrescribimos los estilos heredados de tag-label */
    padding-bottom: 0;
    border-bottom: none;
}

.home-anchor {
    font-family: var(--font-serif);
    font-size: 52px;
    line-height: 1.08;
    font-weight: 500;
    margin-bottom: 12px;
    letter-spacing: -0.02em;
}
.home-territory {
    font-family: var(--font-serif);
    font-size: 18px;
    color: var(--color-text-soft);
    line-height: 1.55;
    margin-bottom: 24px;
    max-width: 540px;
    margin-left: auto;
    margin-right: auto;
}
.home-sub-link {
    font-family: var(--font-sans);
    font-size: 13px;
}
.home-sub-link a {
    border-bottom: 1px solid var(--color-text);
    padding-bottom: 2px;
}

/* Stream destacado */
.stream-item {
    padding: 40px 0 48px;
    border-bottom: 1px solid var(--color-border);
    cursor: pointer;
}
.stream-item:last-child { border-bottom: none; }
.stream-image {
    aspect-ratio: 2 / 1;
    background: var(--color-bg);
    margin-bottom: 24px;
    overflow: hidden;
    transition: opacity 0.2s ease;
}
.stream-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}
.stream-item:hover .stream-image { opacity: 0.85; }
.stream-content h2 {
    font-family: var(--font-serif);
    font-size: 36px;
    font-weight: 500;
    margin-bottom: 16px;
    line-height: 1.12;
    letter-spacing: -0.018em;
}
.stream-excerpt {
    font-family: var(--font-serif);
    font-size: 20px;
    color: var(--color-text-emphatic);
    line-height: 1.45;
    margin-bottom: 22px;
}
.stream-byline {
    font-family: var(--font-sans);
    font-size: 13px;
    color: var(--color-text);
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    gap: 16px;
}
.stream-byline .author {
    font-weight: 700;
    cursor: pointer;
    transition: opacity 0.2s ease;
    color: var(--color-text);
    white-space: nowrap;
}
.stream-byline .author:hover { opacity: 0.6; }
.stream-byline .meta {
    color: var(--color-text-muted);
    font-weight: 400;
    text-align: right;
    white-space: nowrap;
}
.stream-byline .meta .sep {
    margin: 0 6px;
    opacity: 0.6;
}

/* Stream medium */
.stream-item--medium {
    padding: 32px 0 36px;
    display: grid;
    grid-template-columns: 220px 1fr;
    gap: 28px;
    align-items: start;
}
.stream-item--medium .stream-image {
    aspect-ratio: 2 / 1;
    margin-bottom: 0;
}
.stream-item--medium .tag-label {
    margin-bottom: 10px;
    font-size: 10px;
}
.stream-item--medium .stream-content h2 {
    font-size: 22px;
    margin-bottom: 10px;
    line-height: 1.18;
}
.stream-item--medium .stream-excerpt {
    font-size: 15px;
    margin-bottom: 12px;
    line-height: 1.45;
}
.stream-item--medium .stream-byline { font-size: 12px; }

.stream-section-label {
    font-family: var(--font-sans);
    font-size: 11px;
    color: var(--color-text-muted);
    margin: 56px 0 8px;
    letter-spacing: 0.16em;
    text-transform: uppercase;
    font-weight: 500;
    padding-bottom: 14px;
    border-bottom: 1px solid var(--color-border);
}

.archivo-cta {
    text-align: center;
    margin-top: 48px;
    font-family: var(--font-sans);
    font-size: 13px;
}
.archivo-cta a {
    border-bottom: 1px solid var(--color-text);
    padding-bottom: 2px;
}

/* Post */
.post-wrap { padding-top: 40px; }
.post-illustration {
    width: 100%;
    aspect-ratio: 2 / 1;
    margin: 0 auto 44px;
    max-width: 900px;
}
.post-illustration img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}
.post-tag-wrap { text-align: center; margin-bottom: 14px; }
.post-title {
    font-family: var(--font-serif);
    font-size: 42px;
    font-weight: 500;
    line-height: 1.12;
    letter-spacing: -0.02em;
    margin-bottom: 20px;
    text-align: center;
}
.post-meta {
    font-family: var(--font-sans);
    font-size: 14px;
    color: var(--color-text);
    text-align: center;
    margin-bottom: 48px;
    line-height: 1.4;
}
.post-meta .author {
    font-weight: 700;
    cursor: pointer;
    transition: opacity 0.2s ease;
    color: var(--color-text);
}
.post-meta .author:hover { opacity: 0.6; }
.post-meta .sep {
    color: var(--color-text-muted);
    margin: 0 8px;
}
.post-meta .date,
.post-meta .reading-time { color: var(--color-text-muted); }

.post-body { font-size: 18px; line-height: 1.75; }
.post-body p { margin-bottom: 26px; }
.post-body p:first-of-type::first-letter {
    font-family: var(--font-serif);
    float: left;
    font-size: 60px;
    line-height: 0.85;
    font-weight: 500;
    margin: 6px 10px 0 0;
}
.post-body em { font-style: italic; }
.post-body strong { font-weight: 600; }
.post-body h2,
.post-body h3 {
    font-family: var(--font-serif);
    font-weight: 500;
    line-height: 1.2;
    margin-top: 48px;
    margin-bottom: 16px;
    letter-spacing: -0.01em;
}
.post-body h2 { font-size: 28px; }
.post-body h3 { font-size: 22px; }
.post-body blockquote {
    margin: 36px 0;
    padding-left: 24px;
    border-left: 2px solid var(--color-text);
    font-style: italic;
    color: var(--color-text-soft);
    font-size: 19px;
}
.post-body a {
    border-bottom: 1px solid var(--color-text);
    padding-bottom: 1px;
}
.post-body figure { margin: 36px 0; }
.post-body figure img {
    width: 100%;
    height: auto;
    display: block;
}
.post-body figcaption {
    font-family: var(--font-sans);
    font-size: 13px;
    color: var(--color-text-muted);
    text-align: center;
    margin-top: 12px;
    font-style: italic;
}
.post-body ul,
.post-body ol { margin: 0 0 26px 28px; }
.post-body li { margin-bottom: 8px; }
.post-body code {
    font-family: ui-monospace, Menlo, Monaco, monospace;
    font-size: 0.92em;
    background: var(--color-bg-soft);
    padding: 2px 6px;
    border: 1px solid var(--color-border);
}
.post-body pre {
    background: var(--color-bg-soft);
    border: 1px solid var(--color-border);
    padding: 18px;
    margin: 26px 0;
    overflow-x: auto;
    font-size: 14px;
    line-height: 1.5;
}
.post-body pre code {
    background: none;
    border: none;
    padding: 0;
}

/* Subscribe */
.subscribe-block {
    border-top: 1px solid var(--color-border);
    margin-top: 64px;
    padding-top: 44px;
    text-align: center;
}
.subscribe-block-text {
    font-family: var(--font-serif);
    font-size: 17px;
    margin-bottom: 22px;
    color: var(--color-text-soft);
    font-style: italic;
}
.subscribe-form {
    display: flex;
    gap: 0;
    max-width: 460px;
    margin: 0 auto;
    border: 1px solid var(--color-text);
}
.subscribe-form input[type="email"] {
    flex: 1;
    padding: 12px 16px;
    border: none;
    background: transparent;
    font-family: var(--font-sans);
    font-size: 14px;
    color: var(--color-text);
    outline: none;
}
.subscribe-form input[type="email"]::placeholder { color: var(--color-text-muted); }
.subscribe-form input[type="email"]:focus { background: var(--color-bg-soft); }
.subscribe-form button {
    padding: 12px 24px;
    border: none;
    border-left: 1px solid var(--color-text);
    background: var(--color-text);
    color: var(--color-bg);
    font-family: var(--font-sans);
    font-size: 13px;
    font-weight: 500;
    cursor: pointer;
    letter-spacing: 0.02em;
    transition: opacity 0.2s;
}
.subscribe-form button:hover { opacity: 0.82; }
.subscribe-note {
    font-family: var(--font-sans);
    font-size: 12px;
    color: var(--color-text-muted);
    font-style: italic;
    margin-top: 16px;
}

/* Related */
.related {
    margin-top: 80px;
    padding-top: 48px;
    border-top: 1px solid var(--color-border);
}
.related-label {
    font-family: var(--font-sans);
    font-size: 11px;
    color: var(--color-text-muted);
    margin-bottom: 36px;
    text-align: center;
    letter-spacing: 0.16em;
    text-transform: uppercase;
    font-weight: 500;
}
.related-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 32px;
    max-width: 720px;
    margin: 0 auto;
}
.related-item { cursor: pointer; }
.related-image {
    aspect-ratio: 2 / 1;
    width: 100%;
    margin-bottom: 14px;
    transition: opacity 0.2s ease;
    overflow: hidden;
}
.related-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}
.related-item:hover .related-image { opacity: 0.85; }
.related-item .tag-label {
    font-size: 10px;
    margin-bottom: 8px;
    letter-spacing: 0.16em;
}
.related-item h4 {
    font-family: var(--font-serif);
    font-size: 19px;
    font-weight: 500;
    line-height: 1.22;
    margin-bottom: 6px;
}
.related-item .related-date {
    font-family: var(--font-sans);
    font-size: 12px;
    color: var(--color-text-muted);
}

/* Quién */
.quien-wrap { padding-top: 48px; }
.quien-portrait {
    width: 100%;
    aspect-ratio: 2 / 1;
    margin: 0 auto 48px;
    max-width: 720px;
    overflow: hidden;
}
.quien-portrait img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}
.quien-body { font-size: 18px; line-height: 1.75; }
.quien-body p { margin-bottom: 22px; }
.quien-links {
    margin-top: 48px;
    padding-top: 32px;
    border-top: 1px solid var(--color-border);
    font-family: var(--font-sans);
    font-size: 14px;
}
.quien-links a {
    display: block;
    margin-bottom: 12px;
}
.quien-links a::before {
    content: '— ';
    color: var(--color-text-muted);
}

/* Suscribirse */
.subscribe-page {
    padding-top: 64px;
    text-align: center;
}
.subscribe-page h1 {
    font-family: var(--font-serif);
    font-size: 44px;
    font-weight: 500;
    margin-bottom: 28px;
    letter-spacing: -0.02em;
    line-height: 1.1;
}
.subscribe-page .lead {
    font-size: 17px;
    margin-bottom: 40px;
    line-height: 1.6;
    color: var(--color-text-soft);
}

/* Archivo */
.archivo-wrap { padding-top: 56px; }
.archivo-title {
    font-family: var(--font-serif);
    font-size: 40px;
    font-weight: 500;
    letter-spacing: -0.02em;
    margin-bottom: 40px;
    line-height: 1.1;
}

/* Mobile */
@media (max-width: 780px) {
    body { font-size: 16px; }
    .container,
    .container-stream,
    .container-narrow,
    .container-subscribe {
        padding: 0 var(--pad-side-mobile);
    }

    .site-header { padding: 14px 0; }
    .site-header-inner {
        padding: 0 22px;
    }

    /* Logo un poco más chico en mobile */
    .site-logo { height: 32px; }

    /* Botón hamburguesa: visible en mobile */
    .menu-toggle {
        display: flex;
    }

    .menu-toggle.is-open .menu-toggle-line:nth-child(1) {
        transform: translateY(6.5px) rotate(45deg);
    }
    .menu-toggle.is-open .menu-toggle-line:nth-child(2) {
        opacity: 0;
    }
    .menu-toggle.is-open .menu-toggle-line:nth-child(3) {
        transform: translateY(-6.5px) rotate(-45deg);
    }

    /* Menú desplegable full-width en mobile */
    .site-nav {
        position: fixed;
        top: 0;
        left: 0;
        right: 0;
        bottom: 0;
        background: var(--color-bg);
        flex-direction: column;
        justify-content: center;
        align-items: center;
        gap: 32px;
        padding: 22px;
        transform: translateY(-100%);
        transition: transform 0.3s ease;
        z-index: 99;
    }

    .site-nav.is-open {
        transform: translateY(0);
    }

    .site-nav ul {
        flex-direction: column;
        gap: 32px;
        align-items: center;
    }

    .site-nav a {
        font-size: 20px;
        font-weight: 500;
    }

    .home-presentation {
        padding: 44px 0 32px;
        margin: 0 auto 12px;
    }

    .home-anchor {
        font-size: 38px;
        letter-spacing: -0.015em;
    }
    .home-territory {
        font-size: 16px;
        margin-bottom: 22px;
    }
    .home-signature {
        font-size: 15px;
        margin-bottom: 22px;
    }

    .stream-item { padding: 28px 0 32px; }
    .stream-image { margin-bottom: 18px; }
    .tag-label {
        font-size: 10px;
        margin-bottom: 12px;
    }
    .stream-content h2 {
        font-size: 26px;
        margin-bottom: 12px;
    }
    .stream-excerpt {
        font-size: 17px;
        margin-bottom: 16px;
    }
    .stream-byline { font-size: 12px; }

    .stream-item--medium {
        grid-template-columns: 1fr;
        gap: 14px;
        padding: 22px 0 26px;
    }
    .stream-item--medium .stream-content h2 {
        font-size: 20px;
        margin-bottom: 8px;
    }
    .stream-item--medium .stream-excerpt {
        font-size: 14px;
        margin-bottom: 10px;
    }
    .stream-item--medium .stream-byline { font-size: 11px; }

    .post-wrap { padding-top: 28px; }
    .post-title { font-size: 28px; }
    .post-illustration { margin-bottom: 32px; }
    .post-meta { font-size: 13px; }
    .post-body { font-size: 16px; }
    .post-body p:first-of-type::first-letter { font-size: 48px; }
    .post-body h2 { font-size: 24px; }
    .post-body h3 { font-size: 19px; }

    .subscribe-form { flex-direction: column; }
    .subscribe-form button {
        border-left: none;
        border-top: 1px solid var(--color-text);
    }

    .related {
        margin-top: 56px;
        padding-top: 36px;
    }
    .related-grid {
        grid-template-columns: 1fr;
        gap: 28px;
    }
    .related-item h4 { font-size: 17px; }

    .quien-wrap { padding-top: 28px; }
    .quien-portrait { margin-bottom: 36px; }

    .subscribe-page { padding-top: 32px; }
    .subscribe-page h1 { font-size: 32px; }

    .archivo-wrap { padding-top: 32px; }
    .archivo-title {
        font-size: 28px;
        margin-bottom: 28px;
    }

    .site-footer {
        padding: 24px 0;
        margin-top: 40px;
    }
    .site-footer-inner {
        padding: 0 22px;
        flex-direction: column;
        text-align: center;
        gap: 14px;
    }
    .footer-left {
        flex-direction: column;
        gap: 12px;
    }
}
