:root {
    --bg: #f7f8fb;
    --surface: #ffffff;
    --text: #17202a;
    --muted: #566573;
    --border: #dfe5ec;
    --primary: #1557b0;
    --primary-dark: #0f438b;
    --soft-blue: #eef5ff;
    --soft-green: #eef9f1;
    --focus: #ffbf47;
    --radius: 16px;
    --shadow: 0 5px 18px rgba(20, 40, 70, 0.08);
}

* {
    box-sizing: border-box;
}

html {
    font-size: 18px;
    scroll-behavior: smooth;
}

body {
    margin: 0;
    background: var(--bg);
    color: var(--text);
    font-family:
        system-ui,
        -apple-system,
        BlinkMacSystemFont,
        "Segoe UI",
        Arial,
        sans-serif;
    line-height: 1.65;
}

a {
    color: var(--primary);
}

a:hover {
    color: var(--primary-dark);
}

a:focus-visible,
button:focus-visible,
input:focus-visible,
textarea:focus-visible,
select:focus-visible {
    outline: 4px solid var(--focus);
    outline-offset: 3px;
}

.container {
    width: min(1180px, calc(100% - 32px));
    margin-inline: auto;
}

.skip-link {
    position: absolute;
    left: -9999px;
    top: 10px;
    padding: 12px 18px;
    background: #000;
    color: #fff;
    z-index: 9999;
}

.skip-link:focus {
    left: 10px;
}

.community-header {
    background: #fff;
    border-bottom: 1px solid var(--border);
}

.header-inner {
    min-height: 82px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 24px;
}

.brand {
    display: flex;
    align-items: center;
    gap: 12px;
    color: var(--text);
    text-decoration: none;
}

.brand strong,
.brand small {
    display: block;
}

.brand strong {
    font-size: 1.1rem;
}

.brand small {
    color: var(--muted);
}

.brand-logo-placeholder {
    width: 52px;
    height: 52px;
    border-radius: 14px;
    display: grid;
    place-items: center;
    background: var(--primary);
    color: #fff;
    font-weight: 800;
    font-size: 1.2rem;
}

.top-nav {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 8px;
}

.top-nav a {
    padding: 10px 12px;
    text-decoration: none;
    font-weight: 650;
}

.top-nav .nav-button {
    background: var(--primary);
    color: #fff;
    border-radius: 10px;
    padding: 11px 16px;
}

.hero {
    background:
        linear-gradient(
            135deg,
            #eef5ff 0%,
            #f9fbff 55%,
            #eef9f1 100%
        );
    border-bottom: 1px solid var(--border);
}

.hero-inner {
    padding: 64px 0;
    display: grid;
    grid-template-columns: minmax(0, 1.65fr) minmax(280px, .75fr);
    gap: 45px;
    align-items: center;
}

.eyebrow {
    margin: 0 0 8px;
    color: var(--primary);
    font-size: .9rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: .04em;
}

h1,
h2,
h3 {
    line-height: 1.22;
}

h1 {
    margin: 0;
    max-width: 780px;
    font-size: clamp(2rem, 5vw, 3.35rem);
    letter-spacing: -0.035em;
}

h2 {
    margin: 0;
    font-size: clamp(1.55rem, 3vw, 2.2rem);
}

.hero-text {
    max-width: 720px;
    margin: 22px 0;
    font-size: 1.25rem;
    color: #34495e;
}

.welcome {
    font-size: 1.15rem;
}

.hero-actions {
    margin-top: 28px;
    display: flex;
    gap: 14px;
    flex-wrap: wrap;
}

.button {
    min-height: 52px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 12px 22px;
    border-radius: 11px;
    font-size: 1rem;
    font-weight: 750;
    text-decoration: none;
    border: 2px solid transparent;
}

.button-primary {
    background: var(--primary);
    color: #fff;
}

.button-primary:hover {
    background: var(--primary-dark);
    color: #fff;
}

.button-secondary {
    background: #fff;
    color: var(--primary);
    border-color: var(--primary);
}

.safety-card {
    background: #fff;
    padding: 26px;
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    border: 1px solid var(--border);
}

.safety-card strong {
    display: block;
    font-size: 1.1rem;
}

.safety-card p {
    color: var(--muted);
}

.section {
    padding-top: 58px;
    padding-bottom: 58px;
}

.section-heading {
    margin-bottom: 28px;
    display: flex;
    align-items: end;
    justify-content: space-between;
    gap: 20px;
}

.category-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 18px;
}

.category-card {
    min-height: 170px;
    display: flex;
    gap: 18px;
    padding: 24px;
    background: var(--surface);
    color: var(--text);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    text-decoration: none;
    transition:
        transform .15s ease,
        border-color .15s ease;
}

.category-card:hover {
    transform: translateY(-2px);
    border-color: #9dbce4;
    color: var(--text);
}

.category-icon {
    flex: 0 0 auto;
    font-size: 2.1rem;
}

.category-content h3 {
    margin: 0 0 8px;
    font-size: 1.22rem;
}

.category-content p {
    margin: 0 0 14px;
    color: var(--muted);
}

.category-count {
    color: var(--primary);
    font-size: .92rem;
    font-weight: 750;
}

.recent-section {
    background: #fff;
    border-top: 1px solid var(--border);
    border-bottom: 1px solid var(--border);
}

.empty-state {
    padding: 44px 25px;
    text-align: center;
    background: var(--bg);
    border: 1px dashed #b6c2cf;
    border-radius: var(--radius);
}

.empty-icon {
    font-size: 2.8rem;
}

.empty-state h3 {
    margin: 10px 0;
    font-size: 1.35rem;
}

.empty-state p {
    max-width: 650px;
    margin: auto;
    color: var(--muted);
}

.topic-list {
    border: 1px solid var(--border);
    border-radius: var(--radius);
    overflow: hidden;
}

.topic-row {
    padding: 21px 24px;
    display: flex;
    justify-content: space-between;
    gap: 24px;
    background: #fff;
    border-bottom: 1px solid var(--border);
}

.topic-row:last-child {
    border-bottom: 0;
}

.topic-category {
    color: var(--primary);
    font-size: .88rem;
    font-weight: 750;
}

.topic-main h3 {
    margin: 5px 0;
    font-size: 1.15rem;
}

.topic-main p {
    margin: 0;
    color: var(--muted);
    font-size: .9rem;
}

.topic-stats {
    display: flex;
    align-items: center;
    gap: 20px;
    color: var(--muted);
    white-space: nowrap;
}

.topic-stats span {
    display: grid;
    text-align: center;
}

.topic-stats strong {
    color: var(--text);
    font-size: 1.1rem;
}

.stats {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 18px;
}

.stats > div {
    padding: 28px;
    text-align: center;
    background: #fff;
    border: 1px solid var(--border);
    border-radius: var(--radius);
}

.stats strong,
.stats span {
    display: block;
}

.stats strong {
    font-size: 2rem;
    color: var(--primary);
}

.stats span {
    color: var(--muted);
}

.help-card {
    display: flex;
    gap: 25px;
    padding: 34px;
    background: var(--soft-green);
    border: 1px solid #cbe6d2;
    border-radius: var(--radius);
}

.large-icon {
    font-size: 2.4rem;
}

.help-card h2 {
    margin-bottom: 12px;
}

.help-card p {
    max-width: 750px;
}

.community-footer {
    padding: 42px 0;
    background: #18212b;
    color: #fff;
}

.community-footer a {
    color: #fff;
}

.footer-inner {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 30px;
}

.footer-inner p {
    margin: 5px 0 0;
    color: #d7dee5;
}

.footer-inner nav {
    display: flex;
    flex-wrap: wrap;
    gap: 18px;
}

@media (max-width: 850px) {

    html {
        font-size: 17px;
    }

    .header-inner {
        padding: 14px 0;
        align-items: flex-start;
        flex-direction: column;
    }

    .top-nav {
        width: 100%;
    }

    .hero-inner {
        grid-template-columns: 1fr;
        padding: 44px 0;
    }

    .category-grid {
        grid-template-columns: 1fr;
    }

    .section-heading {
        align-items: flex-start;
        flex-direction: column;
    }

    .topic-row {
        flex-direction: column;
    }

    .topic-stats {
        justify-content: flex-start;
    }

    .footer-inner {
        align-items: flex-start;
        flex-direction: column;
    }
}

@media (max-width: 560px) {

    .container {
        width: min(100% - 22px, 1180px);
    }

    .top-nav {
        display: grid;
        grid-template-columns: 1fr 1fr;
    }

    .top-nav a {
        text-align: center;
        border: 1px solid var(--border);
        border-radius: 9px;
    }

    .hero-actions {
        display: grid;
    }

    .button {
        width: 100%;
    }

    .category-card {
        padding: 19px;
    }

    .stats {
        grid-template-columns: 1fr;
    }

    .help-card {
        flex-direction: column;
    }
}

@media (prefers-reduced-motion: reduce) {

    *,
    *::before,
    *::after {
        scroll-behavior: auto !important;
        transition: none !important;
    }
}

/* Logo oficial de la comunidad */
.brand-logo {
    width: 58px;
    height: 58px;
    object-fit: contain;
    display: block;
    border-radius: 12px;
    background: #fff;
}

/* ==================================================
   AJUSTES DE LEGIBILIDAD - IA PARA JUBILADOS
   ================================================== */

/* Logo más visible */
.brand-logo {
    width: 72px;
    height: 72px;
    object-fit: contain;
    display: block;
    border-radius: 12px;
    background: #fff;
}

/* Nombre de la web */
.brand strong {
    font-size: 1.18rem;
}

.brand small {
    font-size: 0.92rem;
}

/* Menú superior más fácil de leer y pulsar */
.top-nav a {
    font-size: 1.02rem;
    min-height: 48px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 11px 15px;
}

/* Categorías: títulos algo mayores */
.category-content h3 {
    font-size: 1.28rem;
    margin-bottom: 9px;
}

/* Descripciones más cómodas para personas mayores */
.category-content p {
    font-size: 1.02rem;
    line-height: 1.65;
}

/* Número de conversaciones más visible */
.category-count {
    font-size: 0.98rem;
}

/* Tarjetas algo más espaciosas */
.category-card {
    padding: 27px;
    min-height: 180px;
}

/* Iconos un poco mayores */
.category-icon {
    font-size: 2.35rem;
}

/* Botones principales más cómodos */
.button {
    min-height: 56px;
    padding: 13px 24px;
    font-size: 1.03rem;
}

/* Aviso de seguridad */
.safety-card {
    font-size: 1rem;
}

.safety-card strong {
    font-size: 1.15rem;
}

/* Móvil */
@media (max-width: 560px) {

    .brand-logo {
        width: 64px;
        height: 64px;
    }

    .category-card {
        padding: 22px;
    }

    .category-content h3 {
        font-size: 1.22rem;
    }

    .category-content p {
        font-size: 1rem;
    }
}


/* ==================================================
   REGISTRO, LOGIN Y CUENTAS
   ================================================== */

.auth-page {
    min-height: calc(100vh - 85px);
    padding: 55px 16px;
    background:
        linear-gradient(
            135deg,
            #eef5ff 0%,
            #f8fbff 55%,
            #eef9f1 100%
        );
}

.auth-container {
    width: min(100%, 680px);
    margin-inline: auto;
}

.auth-card {
    background: #fff;
    border: 1px solid var(--border);
    border-radius: 20px;
    padding: 38px;
    box-shadow: var(--shadow);
}

.auth-card h1 {
    font-size: clamp(1.8rem, 4vw, 2.5rem);
    margin-bottom: 12px;
}

.auth-intro {
    margin-bottom: 30px;
    color: var(--muted);
    font-size: 1.08rem;
}

.auth-form {
    margin-top: 28px;
}

.form-group {
    margin-bottom: 25px;
}

.form-group label {
    display: block;
    margin-bottom: 7px;
    font-size: 1.08rem;
    font-weight: 750;
}

.field-help {
    margin: 0 0 9px;
    color: var(--muted);
    font-size: .94rem;
}

.form-group input,
.form-group textarea,
.form-group select {
    width: 100%;
    min-height: 56px;
    padding: 12px 14px;
    border: 2px solid #aab6c3;
    border-radius: 10px;
    background: #fff;
    color: var(--text);
    font: inherit;
}

.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus {
    border-color: var(--primary);
}

.checkbox-row {
    display: flex;
    align-items: flex-start;
    gap: 13px;
    margin: 22px 0;
    cursor: pointer;
}

.checkbox-row input {
    flex: 0 0 auto;
    width: 23px;
    height: 23px;
    margin-top: 3px;
}

.checkbox-row span {
    line-height: 1.55;
}

.turnstile-wrapper {
    margin: 28px 0;
    overflow-x: auto;
}

.auth-submit {
    width: 100%;
    min-height: 60px;
    font-size: 1.08rem;
    cursor: pointer;
}

.notice {
    margin: 22px 0;
    padding: 17px 19px;
    border-radius: 11px;
    border: 1px solid;
}

.notice ul {
    margin-bottom: 0;
}

.notice-error {
    background: #fff1f0;
    border-color: #dfaaa6;
    color: #701e19;
}

.notice-success {
    background: #edf9f0;
    border-color: #9fd0aa;
    color: #185c28;
}

.notice-info {
    background: #eef5ff;
    border-color: #abc9ed;
    color: #174b83;
}

.auth-bottom {
    margin: 30px 0 0;
    padding-top: 24px;
    border-top: 1px solid var(--border);
    text-align: center;
}

.auth-links {
    margin-top: 24px;
    display: grid;
    gap: 10px;
    text-align: center;
}

.success-card {
    text-align: center;
}

.auth-symbol {
    font-size: 3.5rem;
    margin-bottom: 12px;
}

.success-card .button {
    margin: 8px 4px;
}

@media (max-width: 560px) {

    .auth-page {
        padding: 28px 10px;
    }

    .auth-card {
        padding: 25px 20px;
    }

    .form-group input,
    .form-group textarea,
    .form-group select {
        font-size: 16px;
    }
}


/* ==================================================
   PÁGINAS INTERNAS DEL FORO
   ================================================== */

.community-main {
    min-height: 70vh;
}

.page-section {
    padding-top: 45px;
    padding-bottom: 65px;
}

.content-card,
.form-card,
.reply-card {
    background: #fff;
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 32px;
    box-shadow: var(--shadow);
}

.form-card {
    max-width: 820px;
    margin-inline: auto;
}

.lead {
    font-size: 1.12rem;
    color: var(--muted);
}

.breadcrumbs {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 28px;
    font-size: .95rem;
}

.category-big-icon {
    margin: 0;
    font-size: 2.8rem;
}

.topic-title {
    font-size: 1.25rem;
}

.topic-badge {
    display: inline-block;
    margin-right: 7px;
    padding: 4px 9px;
    border-radius: 20px;
    background: var(--soft-blue);
    color: var(--primary);
    font-size: .8rem;
    font-weight: 750;
}

.pagination {
    margin-top: 28px;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 18px;
    flex-wrap: wrap;
}

.form-group textarea {
    resize: vertical;
    min-height: 130px;
}

.form-actions {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
}

.topic-header {
    margin-bottom: 30px;
}

.posts-list {
    display: grid;
    gap: 18px;
}

.post-card {
    background: #fff;
    border: 1px solid var(--border);
    border-radius: var(--radius);
    overflow: hidden;
    box-shadow: var(--shadow);
}

.post-card.first-post {
    border-color: #afc9e8;
}

.post-author {
    padding: 18px 22px;
    display: flex;
    gap: 13px;
    align-items: center;
    background: #f8fafc;
    border-bottom: 1px solid var(--border);
}

.post-author small {
    display: block;
    color: var(--muted);
}

.avatar-placeholder {
    width: 46px;
    height: 46px;
    display: grid;
    place-items: center;
    background: var(--soft-blue);
    border-radius: 50%;
    font-size: 1.45rem;
}

.admin-badge {
    display: inline-block;
    margin-left: 8px;
    padding: 3px 8px;
    border-radius: 20px;
    background: #e9f2ff;
    color: #174c89;
    font-size: .76rem;
    font-weight: 800;
}

.post-body {
    padding: 26px 24px;
    font-size: 1.05rem;
    line-height: 1.75;
    overflow-wrap: anywhere;
}

.post-helpful {
    padding: 0 24px 18px;
    color: var(--muted);
    font-size: .9rem;
}

.edited {
    display: block;
    padding: 0 24px 18px;
    color: var(--muted);
}

.reply-card {
    max-width: 900px;
    margin: 35px auto 0;
}

.search-form {
    margin-top: 24px;
    display: grid;
    grid-template-columns: 1fr auto;
    gap: 12px;
}

.search-form input {
    min-height: 56px;
    padding: 12px 16px;
    border: 2px solid #aab6c3;
    border-radius: 10px;
    font: inherit;
}

.search-results {
    margin-top: 30px;
}

.search-result-card {
    margin-bottom: 15px;
    padding: 22px;
    background: #fff;
    border: 1px solid var(--border);
    border-radius: var(--radius);
}

.search-result-card h3 {
    margin: 5px 0;
}

.search-result-card p {
    margin: 0;
    color: var(--muted);
}

.profile-card {
    display: flex;
    gap: 25px;
    align-items: flex-start;
    padding: 32px;
    background: #fff;
    border: 1px solid var(--border);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
}

.profile-avatar {
    width: 100px;
    height: 100px;
    display: grid;
    place-items: center;
    flex: 0 0 auto;
    background: var(--soft-blue);
    border-radius: 50%;
    font-size: 3rem;
}

.profile-info h1 {
    margin-top: 0;
}

.profile-bio {
    max-width: 700px;
    margin: 20px 0;
    padding: 18px;
    background: var(--bg);
    border-radius: 10px;
}

.profile-stats {
    margin-top: 24px;
}

.notifications-list {
    display: grid;
    gap: 12px;
}

.notification-card {
    display: flex;
    justify-content: space-between;
    gap: 18px;
    align-items: center;
    padding: 20px;
    background: #fff;
    border: 1px solid var(--border);
    border-radius: 12px;
}

.notification-card.unread {
    border-left: 5px solid var(--primary);
    background: #f7fbff;
}

.notification-card p {
    margin: 5px 0 0;
    color: var(--muted);
}

.rules-list {
    display: grid;
    gap: 12px;
    margin: 30px 0;
}

.rules-list article {
    padding: 18px;
    background: var(--bg);
    border-radius: 10px;
}

.rules-list article p {
    margin: 7px 0 0;
}

.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0,0,0,0);
    white-space: nowrap;
    border: 0;
}

@media (max-width: 650px) {

    .content-card,
    .form-card,
    .reply-card {
        padding: 22px 18px;
    }

    .search-form {
        grid-template-columns: 1fr;
    }

    .search-form .button {
        width: 100%;
    }

    .profile-card {
        flex-direction: column;
    }

    .profile-avatar {
        width: 80px;
        height: 80px;
    }

    .notification-card {
        align-items: flex-start;
        flex-direction: column;
    }

    .notification-card .button {
        width: 100%;
    }
}


/* ==================================================
   PANEL DE ADMINISTRACIÓN
   ================================================== */

.admin-stats {
    margin: 30px 0;
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 16px;
}

.admin-stats > div {
    padding: 25px;
    text-align: center;
    background: #fff;
    border: 1px solid var(--border);
    border-radius: var(--radius);
}

.admin-stats strong,
.admin-stats span {
    display: block;
}

.admin-stats strong {
    font-size: 2rem;
    color: var(--primary);
}

.admin-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 18px;
}

.admin-card {
    padding: 27px;
    background: #fff;
    color: var(--text);
    text-decoration: none;
    border: 1px solid var(--border);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
}

.admin-card:hover {
    border-color: #9dbce4;
    color: var(--text);
}

.admin-card > span {
    font-size: 2.3rem;
}

.admin-card h2 {
    margin: 8px 0;
}

.admin-card p {
    color: var(--muted);
}

.admin-table-wrap {
    margin-top: 25px;
    width: 100%;
    overflow-x: auto;
}

.admin-table {
    width: 100%;
    min-width: 900px;
    border-collapse: collapse;
    background: #fff;
}

.admin-table th,
.admin-table td {
    padding: 15px;
    text-align: left;
    vertical-align: top;
    border: 1px solid var(--border);
}

.admin-table th {
    background: #eef5ff;
}

.inline-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 7px;
}

.small-button {
    padding: 7px 10px;
    border: 1px solid #9faeba;
    border-radius: 7px;
    background: #fff;
    cursor: pointer;
    font: inherit;
    font-size: .82rem;
}

.small-button:hover {
    background: #f0f4f8;
}

.small-button.danger {
    border-color: #c99191;
    color: #8b1f1f;
}

.admin-category-list {
    display: grid;
    gap: 18px;
}

.admin-category-card {
    padding: 25px;
    background: #fff;
    border: 1px solid var(--border);
    border-radius: var(--radius);
}

.admin-category-small {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 15px;
}

.admin-new-category {
    margin-top: 40px;
}

.admin-report-list {
    display: grid;
    gap: 15px;
}

.admin-report-card {
    display: flex;
    justify-content: space-between;
    gap: 25px;
    padding: 22px;
    background: #fff;
    border: 1px solid var(--border);
    border-radius: var(--radius);
}

@media (max-width: 800px) {

    .admin-stats {
        grid-template-columns: 1fr 1fr;
    }

    .admin-grid {
        grid-template-columns: 1fr;
    }

    .admin-report-card {
        flex-direction: column;
    }
}

@media (max-width: 520px) {

    .admin-stats {
        grid-template-columns: 1fr;
    }

    .admin-category-small {
        grid-template-columns: 1fr;
    }
}


/* ==================================================
   FOTOGRAFÍAS DE PERFIL
   ================================================== */

.profile-avatar.photo {
    overflow: hidden;
    padding: 0;
    background: #fff;
}

.profile-photo {
    width: 100px;
    height: 100px;
    display: block;
    object-fit: cover;
    border-radius: 50%;
    border: 3px solid #d9e5f1;
}

.avatar-edit-preview {
    margin: 15px 0 20px;
}

.photo-upload-label {
    display: inline-block;
    margin-bottom: 10px;
    font-weight: 700;
}

.post-avatar {
    width: 48px;
    height: 48px;
    flex: 0 0 48px;
    object-fit: cover;
    border-radius: 50%;
    border: 2px solid #d9e5f1;
    background: #fff;
}

@media (max-width: 560px) {

    .profile-photo {
        width: 85px;
        height: 85px;
    }

    .post-avatar {
        width: 46px;
        height: 46px;
        flex-basis: 46px;
    }
}


/* ==================================================
   ACCIONES EN CONVERSACIONES
   ================================================== */

.topic-actions {
    margin: 22px 0 8px;
    display: flex;
    align-items: center;
    gap: 15px;
    flex-wrap: wrap;
}

.topic-action-help {
    color: var(--muted);
    font-size: .92rem;
}

.post-actions {
    padding: 0 24px 20px;
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
}

.post-actions form {
    margin: 0;
}

.post-action-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 42px;
    padding: 8px 13px;
    border: 1px solid #aebbc7;
    border-radius: 9px;
    background: #fff;
    color: #314252;
    text-decoration: none;
    font: inherit;
    font-size: .9rem;
    font-weight: 700;
    cursor: pointer;
}

.post-action-button:hover {
    background: #f2f6fa;
    color: #17202a;
}

.post-action-button.active {
    background: #eef8f1;
    border-color: #91c79e;
    color: #1b652e;
}

.post-action-button.report {
    color: #805019;
}

.helpful-count {
    color: var(--muted);
    font-size: .88rem;
}

.reported-preview {
    margin: 25px 0;
    padding: 20px;
    background: #f7f8fa;
    border: 1px solid var(--border);
    border-radius: 12px;
}

.reported-preview p {
    margin-bottom: 0;
}

@media (max-width: 560px) {

    .topic-actions {
        align-items: stretch;
        flex-direction: column;
    }

    .topic-actions form,
    .topic-actions .button {
        width: 100%;
    }

    .post-actions {
        align-items: stretch;
        flex-direction: column;
    }

    .post-actions form,
    .post-action-button {
        width: 100%;
    }
}


/* ==================================================
   MODERACIÓN DE MENSAJES
   ================================================== */

.admin-post-actions {
    margin: 0 24px 20px;
    padding: 13px 15px;
    display: flex;
    align-items: center;
    gap: 12px;
    flex-wrap: wrap;
    background: #fff5f5;
    border: 1px solid #e2b3b3;
    border-radius: 9px;
}

.admin-post-actions form {
    margin: 0;
}

.admin-delete-button {
    min-height: 40px;
    padding: 8px 13px;
    border: 1px solid #b64d4d;
    border-radius: 8px;
    background: #fff;
    color: #8c2020;
    font: inherit;
    font-weight: 700;
    cursor: pointer;
}

.admin-delete-button:hover {
    background: #8c2020;
    color: #fff;
}

@media (max-width: 560px) {

    .admin-post-actions {
        align-items: stretch;
        flex-direction: column;
    }

    .admin-post-actions form,
    .admin-delete-button {
        width: 100%;
    }
}


/* ==================================================
   EDICIÓN Y PAPELERA DEL ADMINISTRADOR
   ================================================== */

.admin-edit-button {
    min-height: 40px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 8px 13px;
    border: 1px solid #7e9dbb;
    border-radius: 8px;
    background: #fff;
    color: #174f82;
    text-decoration: none;
    font-weight: 700;
}

.admin-edit-button:hover {
    background: #eef5ff;
}

.trash-list {
    display: grid;
    gap: 18px;
    margin-top: 30px;
}

.trash-card {
    padding: 24px;
    background: #fff;
    border: 1px solid var(--border);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
}

.trash-card h2 {
    margin: 12px 0 5px;
    font-size: 1.2rem;
}

.trash-preview {
    margin-top: 15px;
    padding: 17px;
    background: #f7f8fa;
    border-radius: 9px;
    line-height: 1.7;
}

.trash-actions {
    margin-top: 20px;
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

.trash-actions form {
    margin: 0;
}

@media (max-width: 560px) {

    .admin-edit-button,
    .admin-post-actions form,
    .admin-delete-button {
        width: 100%;
    }

    .trash-actions {
        display: grid;
    }

    .trash-actions form,
    .trash-actions .button {
        width: 100%;
    }
}
