/* ===== Home: secciones principales ===== */
.portal-intro__actions {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
    flex-shrink: 0;
}

.hub-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 16px;
    margin: 24px 0 34px;
}

.hub-card {
    position: relative;
    display: flex;
    flex-direction: column;
    gap: 10px;
    min-height: 220px;
    padding: 20px;
    overflow: hidden;
    border: 1px solid rgba(255, 255, 255, .12);
    border-radius: 20px;
    background: linear-gradient(140deg, var(--h1, #2a2d3a), var(--h2, #17191f));
    color: #fff;
    isolation: isolate;
    transition: transform .2s, filter .2s;
}

.hub-card::before {
    content: "";
    position: absolute;
    inset: 0;
    z-index: -1;
    background:
        radial-gradient(120% 100% at 100% 0, rgba(255, 255, 255, .22), transparent 55%),
        linear-gradient(180deg, transparent 35%, rgba(0, 0, 0, .32));
}

.hub-card:hover {
    transform: translateY(-3px);
    filter: brightness(1.05);
}

.hub-card__top {
    display: flex;
    align-items: center;
    justify-content: space-between;
    position: relative;
    z-index: 1;
}

.hub-card__num {
    font-family: var(--display);
    font-size: 12px;
    font-weight: 700;
    letter-spacing: .14em;
    color: rgba(255, 255, 255, .65);
}

.hub-card__icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 38px;
    height: 38px;
    border: 1px solid rgba(255, 255, 255, .2);
    border-radius: 12px;
    background: rgba(0, 0, 0, .22);
}

.hub-card__icon svg {
    width: 19px;
    height: 19px;
}

.hub-card h2 {
    margin: 2px 0 0;
    font-family: var(--display);
    font-size: clamp(22px, 2.7vw, 30px);
    line-height: 1.05;
    letter-spacing: -.02em;
}

.hub-card h2 a {
    color: #fff;
    text-decoration: none;
}

.hub-card p {
    max-width: 46ch;
    margin: 0;
    color: rgba(255, 255, 255, .82);
    font-size: 13px;
    line-height: 1.45;
}

.hub-card__chips {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    position: relative;
    z-index: 1;
    margin-top: 4px;
}

.hub-chip {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 5px 9px;
    border: 1px solid rgba(255, 255, 255, .2);
    border-radius: 999px;
    background: rgba(0, 0, 0, .28);
    color: #fff;
    font-size: 10.5px;
    font-weight: 600;
    line-height: 1.2;
    text-decoration: none;
    transition: background .15s;
}

.hub-chip:hover {
    background: rgba(0, 0, 0, .45);
}

.hub-chip em {
    font-style: normal;
    font-weight: 700;
    color: rgba(255, 255, 255, .6);
    font-size: 9.5px;
}

.hub-chip--all {
    border-color: rgba(255, 255, 255, .3);
    background: rgba(255, 255, 255, .16);
}

.hub-card__bottom {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    margin-top: auto;
    padding-top: 8px;
}

.hub-card__count {
    color: rgba(255, 255, 255, .62);
    font-size: 10.5px;
    font-weight: 600;
}

.hub-card__link {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    color: #fff;
    font-size: 11px;
    font-weight: 700;
    text-decoration: none;
}

.hub-card__link svg {
    width: 14px;
    height: 14px;
}

.home-section-head {
    display: flex;
    align-items: center;
    gap: 14px;
    margin: 38px 0 16px;
    scroll-margin-top: 86px;
}

.home-section-num {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    width: 38px;
    height: 38px;
    border: 1px solid rgba(124, 92, 255, .32);
    border-radius: 12px;
    background: rgba(124, 92, 255, .14);
    color: #a78bfa;
    font-family: var(--display);
    font-size: 12px;
    font-weight: 700;
}

.home-section-copy {
    flex: 1;
    min-width: 0;
}

.home-section-copy h2 {
    margin: 0;
    font-family: var(--display);
    font-size: clamp(20px, 2.4vw, 28px);
    letter-spacing: -.02em;
}

.home-section-copy p {
    margin: 2px 0 0;
    color: var(--muted);
    font-size: 12px;
    line-height: 1.4;
}

.home-section-link {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    flex-shrink: 0;
    color: var(--text);
    font-size: 11px;
    font-weight: 700;
    text-decoration: none;
}

.home-section-link svg {
    width: 14px;
    height: 14px;
}

.home-section-link:hover {
    color: #c7ff5b;
}

/* ===== Tarjetas con identidad propia ===== */
.hub-card {
    min-height: 250px;
}

.hub-card__body {
    position: relative;
    z-index: 2;
    display: flex;
    flex-direction: column;
    gap: 10px;
    height: 100%;
    max-width: 60%;
}

.hub-card__art {
    position: absolute;
    top: 0;
    right: 0;
    bottom: 0;
    z-index: 1;
    width: 46%;
    overflow: hidden;
    pointer-events: none;
}

.hub-art-icon {
    position: absolute;
    top: 50%;
    right: 18%;
    color: rgba(255, 255, 255, .45);
    transform: translateY(-50%);
}

.hub-art-icon svg {
    width: 74px;
    height: 74px;
}

/* --- 01 Juegos: arcade neón con portadas --- */
.hub-card--games {
    border-color: rgba(167, 139, 250, .42);
    border-radius: 18px;
    box-shadow: 0 24px 60px -34px rgba(124, 92, 255, .9);
}

.hub-card--games .hub-card__art {
    background:
        radial-gradient(circle at 78% 22%, rgba(167, 139, 250, .38), transparent 55%),
        repeating-linear-gradient(90deg, rgba(255, 255, 255, .045) 0 1px, transparent 1px 26px),
        repeating-linear-gradient(0deg, rgba(255, 255, 255, .045) 0 1px, transparent 1px 26px);
}

.hub-cover {
    position: absolute;
    display: block;
    width: 68%;
    aspect-ratio: 16 / 10;
    overflow: hidden;
    border: 2px solid rgba(255, 255, 255, .4);
    border-radius: 10px;
    background: #1e1b4b;
    box-shadow: 0 14px 30px rgba(0, 0, 0, .45);
    transition: transform .25s;
}

.hub-cover img {
    position: absolute;
    inset: 0;
    z-index: 1;
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.hub-cover__fallback {
    position: absolute;
    inset: 0;
    z-index: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(145deg, #312e81, #0f0a2e);
    color: rgba(255, 255, 255, .35);
}

.hub-cover__fallback svg {
    width: 36px;
    height: 36px;
}

.hub-cover__name {
    position: absolute;
    right: 0;
    bottom: 0;
    left: 0;
    z-index: 2;
    overflow: hidden;
    padding: 14px 7px 5px;
    background: linear-gradient(180deg, transparent, rgba(0, 0, 0, .7));
    color: #fff;
    font-size: 8.5px;
    font-weight: 700;
    line-height: 1.1;
    text-overflow: ellipsis;
    text-shadow: 0 1px 4px rgba(0, 0, 0, .7);
    white-space: nowrap;
}

.hub-cover--1 {
    top: 12%;
    right: 20%;
    z-index: 3;
    transform: rotate(-12deg);
}

.hub-cover--2 {
    top: 35%;
    right: 2%;
    z-index: 2;
    transform: rotate(8deg);
}

.hub-cover--3 {
    top: 57%;
    right: 24%;
    z-index: 1;
    opacity: .82;
    transform: rotate(-4deg);
}

.hub-card--games:hover .hub-cover--1 {
    transform: rotate(-16deg) translate(-4px, -4px);
}

.hub-card--games:hover .hub-cover--2 {
    transform: rotate(12deg) translate(4px, 2px);
}

/* --- 02 Novelas: papel y libro --- */
.hub-card--novels {
    overflow: hidden;
    border-color: rgba(58, 29, 42, .14);
    border-radius: 6px 28px 6px 28px;
    background: linear-gradient(145deg, #fdf2e7 0%, #f0cfc9 58%, #e8b9c8 100%);
    color: #3a1d2a;
    box-shadow: 0 24px 55px -36px rgba(58, 29, 42, .5);
}

.hub-card--novels::before {
    background:
        radial-gradient(120% 100% at 100% 0, rgba(255, 255, 255, .7), transparent 55%),
        repeating-linear-gradient(0deg, rgba(58, 29, 42, .035) 0 1px, transparent 1px 5px);
}

.hub-card--novels h2 a,
.hub-card--novels .hub-card__link {
    color: #3a1d2a;
}

.hub-card--novels p {
    color: rgba(58, 29, 42, .78);
}

.hub-card--novels .hub-card__num,
.hub-card--novels .hub-card__count {
    color: rgba(58, 29, 42, .55);
}

.hub-card--novels .hub-card__icon {
    border-color: rgba(58, 29, 42, .16);
    background: rgba(58, 29, 42, .07);
}

.hub-card--novels .hub-chip {
    border-color: rgba(58, 29, 42, .2);
    background: rgba(58, 29, 42, .07);
    color: #3a1d2a;
}

.hub-card--novels .hub-chip em {
    color: rgba(58, 29, 42, .55);
}

.hub-card--novels .hub-chip--all {
    background: rgba(58, 29, 42, .14);
}

.hub-card__art--novels {
    width: 42%;
}

.hub-book {
    position: absolute;
    top: 50%;
    right: 16%;
    width: 138px;
    aspect-ratio: 2 / 3;
    overflow: hidden;
    border: 1px solid rgba(58, 29, 42, .16);
    border-radius: 3px 9px 9px 3px;
    background: #fff;
    box-shadow: 16px 20px 42px rgba(58, 29, 42, .34), -5px 0 0 #d9b8a6 inset;
    transform: translateY(-50%) rotate(-7deg);
    transition: transform .25s;
}

.hub-book img {
    position: absolute;
    inset: 0;
    z-index: 2;
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.hub-book__design {
    position: absolute;
    inset: 0;
    z-index: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: space-between;
    padding: 16px 12px;
    background: linear-gradient(160deg, #5b1b36, #2a0d1c 70%);
    color: #f8e2d8;
    text-align: center;
}

.hub-book__design small {
    color: rgba(248, 226, 216, .6);
    font-size: 7px;
    font-weight: 800;
    letter-spacing: .16em;
}

.hub-book__design strong {
    font-family: var(--display);
    font-size: 13px;
    line-height: 1.15;
}

.hub-book__design svg {
    width: 28px;
    height: 28px;
    opacity: .7;
}

.hub-book::before {
    content: "";
    position: absolute;
    top: 0;
    bottom: 0;
    left: 0;
    z-index: 3;
    width: 11px;
    background: linear-gradient(90deg, rgba(0, 0, 0, .35), transparent);
}

.hub-book::after {
    content: "";
    position: absolute;
    top: 0;
    right: 0;
    bottom: 0;
    z-index: 3;
    width: 5px;
    background: repeating-linear-gradient(0deg, #f3e9df 0 2px, #e6d6c8 2px 3px);
}

.hub-book__fallback {
    display: flex;
    align-items: center;
    justify-content: center;
    height: 100%;
    background: linear-gradient(160deg, #f8e2d8, #e7b7c8);
    color: #9d4f6e;
}

.hub-book__fallback svg {
    width: 38px;
    height: 38px;
}

.hub-card--novels:hover .hub-book {
    transform: translateY(-50%) rotate(-3deg) scale(1.03);
}

/* --- 03 Obras: biblioteca con hojas --- */
.hub-card--works {
    border-color: rgba(94, 234, 212, .34);
    border-radius: 22px 22px 8px 22px;
    box-shadow: 0 24px 55px -36px rgba(13, 148, 136, .75);
}

.hub-card--works .hub-card__art {
    background: radial-gradient(circle at 82% 24%, rgba(94, 234, 212, .22), transparent 58%);
}

.hub-sheet {
    position: absolute;
    display: block;
    width: 56%;
    aspect-ratio: 3 / 4;
    overflow: hidden;
    border: 2px solid rgba(255, 255, 255, .38);
    border-radius: 8px;
    background: #0f3f3a;
    box-shadow: 0 16px 34px rgba(0, 0, 0, .38);
    transition: transform .25s;
}

.hub-sheet img {
    position: absolute;
    inset: 0;
    z-index: 2;
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.hub-sheet__fallback {
    position: absolute;
    inset: 0;
    z-index: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 10px;
    background: linear-gradient(160deg, #0f766e, #082f2b);
    color: #ccfbf1;
    text-align: center;
    font-size: 9px;
    font-weight: 700;
    line-height: 1.2;
}

.hub-sheet__fallback svg {
    width: 22px;
    height: 22px;
}

.hub-sheet__type {
    position: absolute;
    top: 6px;
    left: 6px;
    z-index: 3;
    padding: 3px 6px;
    border-radius: 4px;
    background: rgba(0, 0, 0, .55);
    color: #fff;
    font-size: 7.5px;
    font-weight: 800;
    letter-spacing: .08em;
    text-transform: uppercase;
}

.hub-sheet--1 {
    top: 13%;
    right: 22%;
    z-index: 3;
    transform: rotate(-9deg);
}

.hub-sheet--2 {
    top: 30%;
    right: 3%;
    z-index: 2;
    transform: rotate(7deg);
}

.hub-stamp {
    position: absolute;
    right: 12%;
    bottom: 12%;
    z-index: 4;
    padding: 5px 9px;
    border: 2px solid rgba(209, 250, 229, .55);
    border-radius: 6px;
    background: rgba(6, 78, 59, .62);
    color: #d1fae5;
    font-size: 9px;
    font-weight: 800;
    letter-spacing: .12em;
    transform: rotate(-4deg);
}

.hub-card--works:hover .hub-sheet--1 {
    transform: rotate(-12deg) translate(-4px, -3px);
}

.hub-card--works:hover .hub-sheet--2 {
    transform: rotate(10deg) translate(4px, 2px);
}

/* --- 04 Desarrolladores: credencial --- */
.hub-card--devs {
    border: 2px dashed rgba(42, 20, 6, .28);
    border-radius: 20px;
    background: linear-gradient(145deg, #ffc46b 0%, #ef7a3a 72%, #d95f28 100%);
    color: #2a1406;
    box-shadow: 0 24px 55px -36px rgba(217, 95, 40, .6);
}

.hub-card--devs::before {
    background:
        radial-gradient(120% 100% at 100% 0, rgba(255, 255, 255, .42), transparent 55%),
        radial-gradient(80% 60% at 8% 100%, rgba(42, 20, 6, .12), transparent);
}

.hub-card--devs h2 a,
.hub-card--devs .hub-card__link {
    color: #2a1406;
}

.hub-card--devs p {
    color: rgba(42, 20, 6, .78);
}

.hub-card--devs .hub-card__num,
.hub-card--devs .hub-card__count {
    color: rgba(42, 20, 6, .58);
}

.hub-card--devs .hub-card__icon {
    border-color: rgba(42, 20, 6, .18);
    background: rgba(42, 20, 6, .08);
}

.hub-card--devs .hub-chip {
    border-color: rgba(42, 20, 6, .2);
    background: rgba(42, 20, 6, .08);
    color: #2a1406;
}

.hub-card--devs .hub-chip--all {
    background: rgba(42, 20, 6, .15);
}

.hub-card__art--devs {
    width: 43%;
}

.hub-badge {
    position: absolute;
    top: 50%;
    right: 12%;
    width: 152px;
    padding: 16px 12px 12px;
    border: 1px solid rgba(42, 20, 6, .14);
    border-radius: 13px;
    background: #fffaf2;
    box-shadow: 0 18px 38px rgba(42, 20, 6, .32);
    text-align: center;
    transform: translateY(-50%) rotate(5deg);
    transition: transform .25s;
}

.hub-badge__clip {
    position: absolute;
    top: 8px;
    left: 50%;
    width: 36px;
    height: 7px;
    border-radius: 999px;
    background: #e7d7c2;
    box-shadow: inset 0 1px 2px rgba(0, 0, 0, .22);
    transform: translateX(-50%);
}

.hub-badge__avatars {
    display: flex;
    justify-content: center;
    margin-top: 10px;
}

.hub-badge__avatars > span {
    position: relative;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    margin-left: -9px;
    overflow: hidden;
    border: 2px solid #fffaf2;
    border-radius: 50%;
    background: #f1c9a5;
    color: #6b3b12;
    font-size: 11px;
    font-weight: 800;
}

.hub-badge__avatars > span:first-child {
    margin-left: 0;
}

.hub-badge__avatars img {
    position: absolute;
    inset: 0;
    z-index: 1;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.hub-badge__avatars svg {
    width: 16px;
    height: 16px;
}

.hub-badge__label {
    display: block;
    margin-top: 8px;
    color: #8a5a2b;
    font-size: 9px;
    font-weight: 800;
    letter-spacing: .12em;
    line-height: 1.25;
}

.hub-card--devs:hover .hub-badge {
    transform: translateY(-50%) rotate(9deg) scale(1.03);
}

@media (max-width: 820px) {
    .hub-grid {
        grid-template-columns: 1fr;
        gap: 12px;
    }

    .hub-card {
        min-height: 225px;
        padding: 16px;
    }

    .portal-intro__actions {
        width: 100%;
    }

    .home-section-head {
        margin-top: 30px;
    }

    .home-section-link {
        font-size: 10px;
    }

    .hub-card__body {
        max-width: 100%;
    }

    .hub-card__art {
        right: -10%;
        width: 56%;
        opacity: .3;
    }

    .hub-card--novels .hub-card__art,
    .hub-card--devs .hub-card__art {
        opacity: .4;
    }

    .hub-book {
        right: 10%;
        width: 112px;
    }

    .hub-badge {
        right: 8%;
        width: 126px;
    }
}

@media (max-width: 560px) {
    .hub-card__art {
        display: none;
    }
}

