@import url('https://fonts.googleapis.com/css2?family=Lato:wght@400;700;900&display=swap');

:root {
    font-family: Lato, Arial, sans-serif;
    color: #405167;
    background: #e9edf1;
    font-size: 18px;
    --pink: #e73059;
    --teal: #159fb6;
    --line: #dde1e7
}

* {
    box-sizing: border-box
}

body {
    margin: 0
}

button,
input,
select,
textarea {
    font: inherit
}

button,
a,
select {
    -webkit-tap-highlight-color: transparent
}

button {
    cursor: pointer;
    color: inherit;
    border: 0;
    background: none
}

button:focus-visible,
a:focus-visible,
input:focus-visible,
select:focus-visible {
    outline: 3px solid #006e87;
    outline-offset: 3px
}

a {
    color: inherit
}

.icon {
    width: 27px;
    height: 27px;
    fill: none;
    stroke: currentColor;
    stroke-width: 1.8;
    stroke-linecap: round;
    stroke-linejoin: round;
    flex-shrink: 0
}

.app {
    height: 100dvh;
    max-width: 540px;
    margin: auto;
    background: #f5f6f8;
    display: flex;
    flex-direction: column;
    position: relative;
    overflow: hidden
}

header {
    background: var(--pink);
    color: white;
    flex-shrink: 0;
    padding: 14px 16px 8px;
    padding-top: max(14px, env(safe-area-inset-top))
}

.brand {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
    height: 64px
}

.logo {
    width: 46%;
    max-width: 235px;
    height: 57px;
    object-fit: contain
}

.weather {
    display: flex;
    align-items: center;
    gap: 7px;
    white-space: nowrap;
    font-size: 19px
}

.weather .icon {
    width: 25px
}

.menu {
    border: 1px solid #ffffff70;
    border-radius: 16px;
    display: grid;
    place-items: center;
    width: 55px;
    height: 55px;
    color: white
}

.menu .icon {
    width: 31px;
    height: 31px
}

.header-tools {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    margin-top: 10px;
    min-height: 45px
}

.header-tools button {
    display: flex;
    align-items: center;
    gap: 9px;
    color: white;
    padding: 8px 0;
    font-weight: 700
}

.region {
    display: flex;
    align-items: center;
    gap: 8px;
    min-width: 0
}

.region select {
    color: white;
    background: transparent;
    border: 0;
    font-size: 17px;
    font-weight: 700;
    max-width: 205px;
    min-height: 44px
}

.region option {
    color: #405167;
    background: white
}

.toolbar {
    flex-shrink: 0;
    background: #f5f6f8;
    padding: 14px 16px 8px;
    z-index: 2
}

.date-tools {
    display: flex;
    gap: 8px;
    align-items: stretch
}

.date-tools button {
    border: 1px solid #d6d8dd;
    background: white;
    border-radius: 14px;
    min-height: 57px;
    font-weight: 700;
    padding: 9px 13px;
    font-size: 19px
}

.date-tools .today {
    min-width: 84px;
    margin-right: auto
}

.date-tools .active {
    background: var(--teal);
    color: white;
    border-color: var(--teal)
}

.upcoming {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px
}

.upcoming .icon,
.search-button {
    color: var(--teal)
}

.search-button {
    min-width: 56px;
    display: grid;
    place-items: center
}

.search-button .icon {
    width: 30px;
    height: 30px
}

#search-box {
    display: flex;
    margin-top: 10px;
    border: 1px solid var(--line);
    border-radius: 12px;
    background: white;
    overflow: hidden
}

#search-box[hidden] {
    display: none
}

#query {
    width: 100%;
    min-width: 0;
    padding: 13px;
    border: 0;
    color: inherit;
    background: transparent
}

#search-box button {
    width: 44px;
    font-size: 27px
}

main {
    flex: 1;
    min-height: 0;
    overflow-y: auto;
    overscroll-behavior: contain;
    padding: 0 16px 18px;
    scrollbar-width: thin
}

.day-title {
    display: flex;
    gap: 12px;
    align-items: center;
    justify-content: space-between;
    margin: 8px 0 16px
}

.day-title h1 {
    font-size: 24px;
    line-height: 1.2;
    margin: 0;
    font-weight: 900
}

.day-title span {
    white-space: nowrap;
    font-size: 17px
}

.card {
    border: 1px solid var(--line);
    border-radius: 15px;
    background: white;
    overflow: hidden;
    margin: 0 0 16px;
    box-shadow: 0 3px 9px #40516703
}

.photo {
    position: relative;
    aspect-ratio: 1.88
}

.photo>button:first-child {
    display: block;
    padding: 0;
    width: 100%;
    height: 100%
}

.photo img.cover {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block
}

.category-badge {
    position: absolute;
    left: 14px;
    top: 13px;
    background: #f9f8f8eF;
    border: 1px solid var(--line);
    width: 63px;
    height: 63px;
    display: grid;
    place-items: center;
    border-radius: 50%;
    pointer-events: none
}

.category-icon {
    width: 40px;
    height: 40px;
    object-fit: contain
}

.save {
    position: absolute;
    right: 20px;
    bottom: -28px;
    width: 56px;
    height: 56px;
    border-radius: 50%;
    background: #e1e4e4;
    display: grid;
    place-items: center;
    z-index: 1;
        border: 3px solid #fff;
}

.save[aria-pressed=true] {
    background: #fde3e9;
    color: var(--pink)
}

.save[aria-pressed=true] .icon {
    fill: #f7b4c4
}

.card-body {
    padding: 19px 19px 20px
}

.when {
    color: #db164b;
    font-weight: 900;
    display: flex;
    align-items: center;
    gap: 8px;
    padding-right: 40px;
    font-size: 19px;
    min-height: 30px
}

.when .icon {
    width: 25px;
    height: 25px
}

.title-button {
    text-align: left;
    display: block;
    padding: 0;
    margin: 10px 0 14px;
    font-size: 25px;
    line-height: 1.18;
    font-weight: 900
}

.location {
    display: flex;
    gap: 9px;
    align-items: flex-start;
    font-size: 20px;
    line-height: 1.1;
    text-transform: uppercase;
}

.location .icon {
    width: 24px;
    margin-top: 1px
}

.location small {
    display: block;
    font-size: 14px;
    color: #627186;
    margin-top: 3px;
    text-transform: uppercase;
    font-weight: 700;
}

.social {
    /* border-top: 1px solid var(--line); */
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    padding: 13px 7px
}

.social button {
    display: flex;
    align-items: center;
    /* flex-direction: column; */
    gap: 10px;
    font-size: 18px;
    padding: 5px 0;
    min-height: 45px;
    justify-content: center;
}

.social button[aria-pressed=true] {
    color: var(--pink)
}

.social button[aria-pressed=true] .icon {
    fill: #fde3e9
}

.bottom {
    flex-shrink: 0;
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    border-top: 1px solid var(--line);
    background: white;
    padding: 11px 8px max(12px, env(safe-area-inset-bottom));
    z-index: 5
}

.bottom button,
.bottom a {
    text-decoration: none;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 9px;
    padding: 4px 0;
    min-height: 62px;
    font-size: 17px
}

.bottom .active {
    color: #dc164b;
    font-weight: 700
}

.bottom .icon {
    width: 30px;
    height: 30px
}

.panel {
    background: white;
    border: 1px solid var(--line);
    border-radius: 16px;
    padding: 16px;
    margin: 8px 0 16px
}

.panel-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    margin-bottom: 14px
}

.panel-head h2 {
    margin: 0;
    font-size: 21px
}

.panel-head button {
    min-width: 44px;
    min-height: 44px;
    font-size: 25px
}

.categories {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 7px
}

.category {
    border: 1px solid var(--line);
    border-radius: 12px;
    padding: 9px 3px;
    font-size: 15px;
    line-height: 1.15;
    min-height: 85px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 6px;
    justify-content: center
}

.category .category-icon {
    width: 30px;
    height: 30px
}

.category[aria-pressed=true] {
    background: #fce5ec;
    border: 2px solid var(--pink);
    color: #c71746;
    padding: 8px 2px
}

.panel-footer {
    display: flex;
    justify-content: space-between;
    gap: 10px;
    margin-top: 15px;
    align-items: center
}

.primary {
    background: var(--teal);
    color: white;
    border-radius: 10px;
    padding: 12px 16px;
    font-weight: 700
}

.calendar-grid {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 3px;
    text-align: center
}

.weekday {
    font-size: 15px;
    padding: 6px 0
}

.calendar-grid button {
    min-height: 43px;
    border-radius: 10px;
    position: relative;
    padding: 5px 0 10px;
    font-size: 18px
}

.calendar-grid .has-events {
    background: #e5f6f8;
    color: #08788e;
    font-weight: 900
}

.has-events:after {
    content: '';
    position: absolute;
    width: 5px;
    height: 5px;
    border-radius: 50%;
    background: var(--teal);
    bottom: 5px;
    left: calc(50% - 2.5px)
}

.calendar-grid .selected {
    background: var(--teal);
    color: white
}

.calendar-grid .selected:after {
    background: white
}

.legend {
    font-size: 15px;
    color: #617184;
    margin: 14px 0 0
}

.menu-links {
    display: flex;
    flex-direction: column
}

.menu-links a {
    display: flex;
    align-items: center;
    gap: 12px;
    text-decoration: none;
    min-height: 49px;
    padding: 8px
}

.menu-links a:nth-last-child(-n+2) {
    font-size: 16px
}

.empty {
    padding: 35px 12px;
    text-align: center;
    line-height: 1.5
}

.detail h1 {
    font-size: 28px;
    line-height: 1.18
}

.detail .hero {
    width: 100%;
    border-radius: 17px
}

.detail p {
    line-height: 1.55
}

.detail .back {
    min-height: 48px;
    padding: 8px 0;
    display: flex;
    align-items: center;
    gap: 8px
}

.detail .info {
    display: flex;
    align-items: center;
    gap: 10px;
    margin: 16px 0
}

.detail .links {
    display: flex;
    gap: 10px;
    flex-wrap: wrap
}

.detail .links a {
    padding: 12px;
    border: 1px solid var(--line);
    border-radius: 10px;
    text-decoration: none;
    background: white
}

.share a {
    display: block;
    padding: 12px 0
}

.share input {
    width: 100%;
    font-size: 15px;
    padding: 10px
}

#toast {
    position: absolute;
    bottom: 100px;
    left: 20px;
    right: 20px;
    background: #34465a;
    color: white;
    border-radius: 12px;
    padding: 12px;
    text-align: center;
    pointer-events: none;
    opacity: 0;
    transition: opacity .2s;
    z-index: 10
}

#toast.visible {
    opacity: 1
}

@media(min-width:500px) {
    .date-tools .today {
        min-width: 110px
    }

    .date-tools button {
        min-height: 63px;
        font-size: 21px
    }

    .brand {
        height: 70px
    }

    .header-tools {
        margin-top: 13px
    }

    .region select {
        font-size: 19px
    }

    .card-body {
        padding: 20px
    }

    .title-button {
        font-size: 29px
    }

    .photo {
        aspect-ratio: 1.88
    }

    .day-title h1 {
        font-size: 27px
    }

    .when {
        font-size: 21px
    }

    .location {
        font-size: 23px
    }

    .social button {
        font-size: 20px
    }
}

@media(max-width:370px) {
    header {
        padding-left: 12px;
        padding-right: 12px
    }

    .brand {
        gap: 8px
    }

    .logo {
        width: 46%
    }

    .weather {
        font-size: 16px;
        gap: 4px
    }

    .weather .icon {
        width: 21px
    }

    .menu {
        width: 47px;
        height: 49px
    }

    .region {
        gap: 3px
    }

    .region select {
        font-size: 15px;
        max-width: 170px
    }

    .header-tools button {
        font-size: 16px
    }

    .toolbar {
        padding: 10px 10px 6px
    }

    .date-tools {
        gap: 6px
    }

    .date-tools button {
        font-size: 16px;
        padding: 9px;
        min-height: 52px
    }

    .date-tools .today {
        min-width: 65px
    }

    .upcoming {
        gap: 7px
    }

    .search-button {
        min-width: 46px
    }

    .bottom button,
    .bottom a {
        font-size: 14px
    }

    main {
        padding-left: 10px;
        padding-right: 10px
    }

    .day-title h1 {
        font-size: 21px
    }

    .day-title span {
        font-size: 15px
    }

    .title-button {
        font-size: 23px
    }

    .category {
        font-size: 14px
    }

    .social button {
        font-size: 16px
    }

    .when {
        font-size: 17px
    }

    .card-body {
        padding-left: 15px;
        padding-right: 15px
    }
}

@media(max-height:500px) {
    header {
        padding-top: 5px
    }

    .brand {
        height: 45px
    }

    .logo {
        height: 40px
    }

    .menu {
        height: 40px
    }

    .header-tools {
        margin-top: 0;
        min-height: 35px
    }

    .toolbar {
        padding-top: 6px
    }

    .date-tools button {
        min-height: 44px
    }

    .bottom {
        padding: 4px
    }

    .bottom button,
    .bottom a {
        min-height: 40px;
        flex-direction: row;
        gap: 5px;
        font-size: 13px
    }

    .bottom .icon {
        width: 21px;
        height: 21px
    }
}

/* Compact persistent navigation */
header {
    padding-top: max(7px, env(safe-area-inset-top));
    padding-bottom: 3px
}

.brand {
    height: 59px;
    overflow: hidden;
    opacity: 1;
    transition: height .18s ease, opacity .14s ease, visibility .18s
}

.header-tools {
    margin-top: 2px;
    min-height: 44px
}

.toolbar {
    padding-top: 7px;
    padding-bottom: 5px
}

.date-tools button {
    min-height: 50px;
    padding-top: 7px;
    padding-bottom: 7px
}

.date-tools button.active .icon {
    color: white
}

.bottom {
    padding-top: 5px;
    padding-bottom: max(5px, env(safe-area-inset-bottom))
}

.bottom button,
.bottom a {
    min-height: 54px;
    gap: 4px;
    padding: 2px 0
}

.bottom .icon {
    width: 26px;
    height: 26px
}

.save[aria-pressed=true],
.social button[data-action=save][aria-pressed=true] {
    background: var(--pink);
    color: white
}

.save[aria-pressed=true] .icon,
.social button[data-action=save][aria-pressed=true] .icon {
    fill: none;
    stroke: white
}

.social button[data-action=save] {
    border-radius: 12px
}

header.compact .brand {
    height: 0;
    opacity: 0;
    visibility: hidden;
    pointer-events: none
}

header.compact .header-tools {
    margin-top: 0
}

main {
    overflow-anchor: none
}

@media(min-width:500px) {
    .brand {
        height: 62px
    }

    .date-tools button {
        min-height: 53px
    }
}

@media(max-width:370px) {
    .toolbar {
        padding-top: 6px;
        padding-bottom: 4px
    }

    .date-tools button {
        min-height: 48px
    }
}

@media(max-height:500px) {
    .brand {
        height: 43px
    }

    .date-tools button {
        min-height: 44px
    }

    .bottom button,
    .bottom a {
        min-height: 40px
    }

    .bottom .icon {
        width: 21px;
        height: 21px
    }
}

@media(prefers-reduced-motion:reduce) {
    .brand {
        transition: none
    }
}

/* Nine-category filters and compact event actions */
.category .category-icon {
    width: 38px;
    height: 38px
}

.social {
    background: #e9ecef;
    padding: 7px 7px
}

.social .icon {
    width: 24px;
    height: 24px
}


/* Publicidad, actividades en curso y fechas consecutivas */
.advertisement {
    margin: 24px 0 26px;
    text-align: center
}

.advertisement>span {
    display: block;
    font-size: 11px;
    letter-spacing: 1.5px;
    color: #6b7481;
    margin-bottom: 7px
}

.advertisement>img {
    display: block;
    width: 100%;
    height: auto;
    border-radius: 12px
}

.also-section {
    margin: 0 0 28px
}

.also-heading {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    margin-bottom: 12px
}

.also-heading h2 {
    font-size: 25px;
    margin: 0;
    font-weight: 900
}

.carousel-controls {
    display: flex;
    gap: 4px
}

.carousel-controls button {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: white;
    border: 1px solid var(--line);
    font-size: 27px;
    line-height: 1
}

.also-track {
    display: flex;
    gap: 12px;
    overflow-x: auto;
    overscroll-behavior-x: contain;
    scroll-snap-type: x mandatory;
    padding: 0 0 9px;
    scrollbar-width: thin;
    scrollbar-color: #c1c8ce transparent
}

.also-card {
    flex: 0 0 61%;
    max-width: 238px;
    height: 310px;
    position: relative;
    overflow: hidden;
    border-radius: 14px;
    scroll-snap-align: start;
    isolation: isolate;
    text-decoration: none;
    display: block;
    text-align: center;
    background: #13181e;
    color: white;
    padding: 0
}

.also-image {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    z-index: -2
}

.also-card:after {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg, rgba(0, 0, 0, .03) 10%, rgba(0, 0, 0, .24) 35%, rgba(0, 0, 0, .87) 72%, #000 100%);
    z-index: -1
}

.also-badge {
    position: absolute;
    top: 14px;
    left: 50%;
    transform: translateX(-50%);
    width: 60px;
    height: 60px;
    border-radius: 50%;
    background: #faf8f9;
    display: grid;
    place-items: center
}

.also-badge img {
    width: 39px;
    height: 39px
}

.also-copy {
    position: absolute;
    bottom: 20px;
    left: 13px;
    right: 13px;
    display: flex;
    flex-direction: column;
    gap: 9px
}

.also-copy strong {
    font-size: 23px;
    line-height: 1.08;
    font-weight: 900;
    text-wrap: balance
}

.also-copy>span {
    font-size: 18px;
    line-height: 1.18;
    color: #ff749b
}

.also-copy small {
    font-size: 15px;
    line-height: 1.2;
    color: #e7e9ed
}

.upcoming-day {
    margin-top: 28px
}

.day-title h2 {
    font-size: 24px;
    font-weight: 900;
    line-height: 1.2;
    margin: 0
}

.day-title {
    align-items: flex-start
}

.day-title>span {
    padding-top: 3px
}

@media(max-width:370px) {
    .also-card {
        flex-basis: 68%;
        height: 290px
    }

    .also-copy strong {
        font-size: 21px
    }

    .day-title h2 {
        font-size: 21px
    }

    .also-heading h2 {
        font-size: 23px
    }
}

@media(min-width:500px) {
    .day-title h2 {
        font-size: 27px
    }

    .also-card {
        flex-basis: 45%
    }
}

/* Dos tarjetas completas y avance de la siguiente, como en la referencia. */
.also-track {
    gap: 12px
}

.also-track .also-card {
    flex: 0 0 42%;
    max-width: none;
    height: auto;
    aspect-ratio: 2304/4128;
    border-radius: 9px
}

.also-badge {
    width: clamp(44px, 12vw, 64px);
    height: clamp(44px, 12vw, 64px);
    top: 14px
}

.also-badge img {
    width: 68%;
    height: 68%
}

.also-copy {
    left: 10px;
    right: 10px;
    bottom: 18px;
    gap: 9px
}

.also-copy strong {
    font-size: clamp(17px, 4.6vw, 24px);
    line-height: 1.07
}

.also-copy>span {
    font-size: clamp(15px, 3.9vw, 20px);
    line-height: 1.12;
    color: #ff477d
}

.also-copy small {
    display: none
}

.also-card:after {
    background: linear-gradient(180deg, transparent 15%, rgba(0, 0, 0, .12) 35%, rgba(0, 0, 0, .82) 73%, #000 100%)
}

@media(max-width:350px) {
    .also-track {
        gap: 9px
    }

    .also-copy {
        left: 7px;
        right: 7px;
        bottom: 12px;
        gap: 6px
    }

    .also-copy strong {
        font-size: 16px
    }

    .also-badge {
        top: 10px
    }
}

/* Publicidad de borde a borde, sin esquinas redondeadas. */
.advertisement {
    margin-left: -16px;
    margin-right: -16px
}

.advertisement>img {
    border-radius: 0
}

@media(max-width:370px) {
    .advertisement {
        margin-left: -10px;
        margin-right: -10px
    }
}

/* Acciones directas para cerrar búsqueda y limpiar categorías. */
#search-box {
    background: white
}

#search-box button {
    background: var(--teal);
    color: white;
    flex: 0 0 48px;
    font-size: 29px;
    font-weight: 700
}

#query {
    background: white
}

#query::-webkit-search-cancel-button {
    -webkit-appearance: none
}

.filter-controls {
    display: flex;
    align-items: center;
    gap: 3px;
    flex-shrink: 0
}

#filter-count {
    color: #ffe14a;
    font-weight: 900;
    white-space: nowrap
}

.header-tools .clear-filters {
    display: grid;
    place-items: center;
    width: 32px;
    min-height: 44px;
    padding: 0
}

.header-tools .clear-filters[hidden] {
    display: none
}

.clear-filters span {
    display: grid;
    place-items: center;
    width: 22px;
    height: 22px;
    line-height: 1;
    border-radius: 5px;
    background: #ffe14a;
    color: var(--pink);
    font-size: 23px;
    font-weight: 700
}

.header-tools {
    gap: 7px
}

.header-tools .region {
    flex: 1;
    justify-content: flex-end;
    min-width: 0
}

.region select {
    width: 100%;
    min-width: 0;
    text-overflow: ellipsis;
    max-width: 205px
}

@media(max-width:370px) {
    .header-tools [data-action=filters] {
        gap: 5px
    }

    .header-tools .region .icon {
        width: 21px
    }

    .header-tools .clear-filters {
        width: 28px
    }
}

.menu-links .icon {
    color: var(--pink)
}

.menu-links>button {
    display: flex;
    align-items: center;
    gap: 12px;
    text-align: left;
    min-height: 49px;
    padding: 8px;
    font-size: 18px
}

/* Selector dimensionado por su etiqueta inicial, sin huecos interiores. */
.header-tools .region {
    flex: 0 1 auto;
    justify-content: flex-start;
    gap: 5px;
    margin-left: auto
}

.region-field {
    position: relative;
    display: block;
    flex: 0 1 auto;
    min-width: 0;
    height: 44px;
    font-size: 17px;
    font-weight: 700
}

.region-measure {
    display: block;
    visibility: hidden;
    white-space: nowrap;
    padding-right: 17px;
    line-height: 44px
}

.region-value {
    position: absolute;
    left: 0;
    right: 17px;
    top: 0;
    line-height: 44px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis
}

.region-field:after {
    content: '';
    position: absolute;
    right: 2px;
    top: 18px;
    width: 6px;
    height: 6px;
    border-right: 2px solid white;
    border-bottom: 2px solid white;
    transform: rotate(45deg);
    pointer-events: none
}

.region .region-field select {
    position: absolute;
    inset: 0;
    opacity: 0;
    width: 100%;
    height: 44px;
    max-width: none;
    cursor: pointer
}

.region-field:focus-within {
    outline: 2px solid white;
    outline-offset: 2px;
    border-radius: 3px
}

.clear-filters span {
    width: 17px;
    height: 17px;
    border-radius: 4px;
    font-size: 18px
}

.header-tools .clear-filters {
    width: 27px
}

.reset-categories {
    display: flex;
    align-items: center;
    gap: 7px;
    min-height: 44px;
    padding: 8px 4px
}

.reset-categories.has-selection {
    color: var(--pink);
    font-weight: 700
}

.reset-categories span {
    font-size: 22px;
    line-height: 1
}

@media(min-width:500px) {
    .region-field {
        font-size: 19px
    }
}

@media(max-width:370px) {
    .region-field {
        font-size: 15px
    }

    .header-tools .clear-filters {
        width: 25px
    }
}

.brand a.logo {
    display: flex;
    align-items: center;
    padding: 0;
    text-decoration: none
}

.brand a.logo img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    display: block
}

.about-brand a {
    display: block
}

.cinema-banner {
    width: 100%;
    max-width: none;
    height: 155px;
    flex: none;
    margin: 18px 0 22px;
    text-align: left;
    border-radius: 12px
}

.cinema-banner .also-image {
    object-fit: cover;
    object-position: center 48%
}

.cinema-banner:after {
    background: linear-gradient(90deg, #0009, #0004), linear-gradient(0deg, #000c, transparent)
}

.cinema-banner .also-badge {
    top: 18px;
    left: 18px;
    transform: none;
    width: 49px;
    height: 49px
}

.cinema-banner .also-badge img {
    width: 32px;
    height: 32px
}

.cinema-banner .also-copy {
    left: 82px;
    right: 16px;
    bottom: 24px;
    gap: 7px
}

.cinema-banner .also-copy strong {
    font-size: 30px;
    text-wrap: initial
}

.cinema-banner .also-copy>span {
    font-size: 19px;
    line-height: 1.2
}

/* Ajuste a la referencia del banner y proporción de iconos */
.cinema-banner {
    height: auto;
    aspect-ratio: 2.45;
    text-align: center
}

.cinema-banner .also-badge {
    left: 50%;
    top: 10%;
    transform: translateX(-50%)
}

.cinema-banner .also-copy {
    left: 12px;
    right: 12px;
    bottom: 11%;
    gap: 5px
}

.cinema-banner .also-copy strong {
    font-size: clamp(28px, 7.5vw, 38px)
}

.cinema-banner .also-copy>span {
    font-size: clamp(18px, 4.6vw, 23px)
}

.category-badge .category-icon,
.also-badge img,
.cinema-banner .also-badge img {
    width: 82%;
    height: 82%
}

.when {
    align-items: flex-start;
    line-height: 1.25
}

.when>.icon {
    margin-top: 0;
    flex-shrink: 0
}

.cinema-banner {
    min-height: 160px
}

span.icon {
    display: inline-block;
    background-color: currentColor;
    -webkit-mask: var(--icon-url) center/contain no-repeat;
    mask: var(--icon-url) center/contain no-repeat;
    vertical-align: middle
}

.search-all-events {
    display: block;
    text-align: center;
    text-decoration: none;
    margin: 22px 0 12px;
    padding: 15px 16px;
    font-size: 18px
}

/* Filtros de agenda aprobados: diez categorías en dos columnas */
.agenda-categories {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 8px
}

.agenda-categories .category {
    flex-direction: row;
    justify-content: flex-start;
    text-align: left;
    gap: 9px;
    min-height: 57px;
    padding: 8px;
    border-radius: 11px;
    font-size: 16px;
    line-height: 1.12
}

.agenda-categories .category .category-icon {
    width: 32px;
    height: 32px;
    flex-shrink: 0
}

.agenda-categories .category[aria-pressed=true] {
    padding: 7px
}

.agenda-filter-footer {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 8px;
    margin-top: 8px
}

.agenda-filter-footer>button {
    min-height: 49px;
    border-radius: 11px;
    padding: 9px 8px;
    font-size: 17px;
    font-weight: 700
}

.agenda-filter-footer .reset-categories {
    background: #f1f3f5;
    justify-content: center
}

@media(max-width:350px) {
    .agenda-categories .category {
        font-size: 15px;
        gap: 7px
    }

    .agenda-categories .category .category-icon {
        width: 30px;
        height: 30px
    }
}

.app>header {
    z-index: 3
}

#food-controls {
    z-index: 2
}

/* Paneles superpuestos (menú, filtros, calendario y compartir): flotan bajo la cabecera sin desplazar el contenido */
#panel {
    position: absolute;
    left: 0;
    right: 0;
    top: var(--panel-top, 0);
    bottom: var(--panel-bottom, 0);
    z-index: 4;
    padding: 0 16px;
    background: rgba(32, 45, 62, .38);
    overflow: hidden
}

#panel:empty {
    display: none
}

#panel .panel {
    max-height: calc(100% - 16px);
    overflow-y: auto;
    overscroll-behavior: contain;
    margin: 8px 0 0;
    box-shadow: 0 14px 34px rgba(32, 45, 62, .28)
}

@media(max-width:370px) {
    #panel {
        padding: 0 10px
    }
}

.pull-back-hint {
    position: absolute;
    left: 50%;
    transform: translateX(-50%);
    z-index: 2;
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 7px 15px;
    border-radius: 99px;
    background: white;
    color: #405167;
    font-size: 14px;
    box-shadow: 0 4px 14px rgba(32, 45, 62, .16);
    pointer-events: none;
    white-space: nowrap;
    transition: background .15s, color .15s
}

.pull-back-hint span {
    font-size: 17px;
    line-height: 1
}

.pull-back-hint.ready {
    background: var(--pink);
    color: white
}

#food-panel {
    position: absolute;
    left: 0;
    right: 0;
    z-index: 4;
    padding: 0 16px;
    background: rgba(32, 45, 62, .38);
    overflow: hidden
}

#food-panel:empty {
    display: none
}

#food-panel .panel {
    max-height: calc(100% - 16px);
    overflow-y: auto;
    overscroll-behavior: contain;
    margin: 8px 0 0;
    box-shadow: 0 14px 34px rgba(32, 45, 62, .28)
}

@media(max-width:360px) {
    #food-panel {
        padding: 0 10px
    }
}

#food-controls {
    position: relative
}

#food-controls .food-search-field {
    position: absolute;
    left: 0;
    right: 0;
    top: 100%;
    margin: 0;
    padding: 8px 16px 10px;
    background: #f5f6f8;
    border-bottom: 1px solid #e0e4ea;
    box-shadow: 0 10px 18px rgba(32, 45, 62, .12)
}

@media(max-width:360px) {
    #food-controls .food-search-field {
        padding: 8px 10px 10px
    }
}

/* Listado de Comer: al recogerse la cabecera no hay fila de herramientas debajo, así que se oculta del todo (salvo la zona segura del iPhone) */
.app.inner-page header {
    transition: padding .18s ease
}

.app.inner-page header.compact {
    padding-top: env(safe-area-inset-top);
    padding-bottom: 0
}

@media(prefers-reduced-motion:reduce) {
    .app.inner-page header {
        transition: none
    }
}