html,
body.magazine-body {
    margin: 0;
    padding: 0;
    height: 100%;
    overflow: hidden;
    background: var(--magazine-bg, #1a1a1a);
}

.magazine-app {
    position: relative;
    width: 100%;
    height: 100dvh;
    height: 100vh;
    overflow: hidden;
    background: var(--magazine-bg, #1a1a1a);
}

.magazine-feed {
    width: 100%;
    height: 100%;
    overflow-y: auto;
    overflow-x: hidden;
    scroll-snap-type: y mandatory;
    -webkit-overflow-scrolling: touch;
}

.magazine-slide {
    width: 100%;
    height: 100%;
    min-height: 100dvh;
    min-height: 100vh;
    scroll-snap-align: start;
    scroll-snap-stop: always;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    box-sizing: border-box;
    flex-shrink: 0;
}

.magazine-page-inner {
    position: relative;
    width: 100%;
    height: 100%;
    max-height: 100dvh;
    max-height: 100vh;
    max-width: min(100vw, calc(100dvh * 9 / 19.5));
    margin: 0 auto;
    overflow: hidden;
}

@media (min-width: 992px) {
    .magazine-page-inner {
        max-width: min(100vw, calc(100vh * 9 / 19.5));
        max-height: 100vh;
    }
}

.magazine-page-inner picture,
.magazine-page-bg {
    width: 100%;
    height: 100%;
    display: block;
}

.magazine-page-bg {
    object-fit: cover;
}

.magazine-video {
    position: absolute;
    z-index: 5;
    pointer-events: auto;
}

.magazine-video-iframe {
    width: 100%;
    height: 100%;
    border: 0;
    display: block;
    background: transparent;
}

.magazine-page-inner--video-fullscreen {
    background: #000;
}

.magazine-page-inner--video-fullscreen .magazine-page-bg,
.magazine-page-inner--video-fullscreen picture {
    display: none;
}

.magazine-video--fullscreen {
    inset: 0;
}

.magazine-video--overlay.magazine-video--custom {
    left: var(--video-ol-left, 6%);
    top: var(--video-ol-top, 35%);
    width: var(--video-ol-width, 88%);
    max-width: 100%;
    height: auto;
    aspect-ratio: 16 / 9;
    transform: none;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.45);
}

.magazine-cover-overlay {
    position: absolute;
    inset: 0;
    z-index: 10;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    padding: clamp(1rem, 8vw, 3rem) clamp(0.75rem, 5vw, 2rem);
    color: #fff;
    text-shadow: 0 2px 12px rgba(0, 0, 0, 0.55);
    pointer-events: none;
}

.magazine-cover-logo {
    text-align: center;
    font-family: Georgia, 'Times New Roman', serif;
    font-size: clamp(1.25rem, 5vw, 2.5rem);
    letter-spacing: 0.15em;
    font-weight: 400;
}

.magazine-cover-announce {
    max-width: 42%;
    font-size: clamp(0.7rem, 2.2vw, 1rem);
    line-height: 1.35;
}

.magazine-cover-announce--right {
    align-self: flex-end;
    text-align: right;
}

.magazine-cover-announce-title {
    font-family: Georgia, 'Times New Roman', serif;
    font-size: clamp(1rem, 3.5vw, 1.75rem);
    font-weight: 700;
    margin-bottom: 0.35em;
}

.magazine-sections-btn {
    position: fixed;
    top: max(12px, env(safe-area-inset-top));
    right: max(12px, env(safe-area-inset-right));
    z-index: 20;
    width: 44px;
    height: 44px;
    border: none;
    border-radius: 50%;
    background: rgba(0, 0, 0, 0.45);
    color: #fff;
    font-size: 1.35rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
}

.magazine-sections-menu {
    position: fixed;
    top: calc(max(12px, env(safe-area-inset-top)) + 52px);
    right: max(12px, env(safe-area-inset-right));
    z-index: 20;
    min-width: 160px;
    background: rgba(0, 0, 0, 0.85);
    border-radius: 8px;
    padding: 0.35rem 0;
    backdrop-filter: blur(8px);
}

.magazine-sections-menu-item {
    display: block;
    width: 100%;
    text-align: left;
    border: none;
    background: transparent;
    color: #fff;
    padding: 0.6rem 1rem;
    font-size: 0.9rem;
    cursor: pointer;
}

.magazine-sections-menu-item:hover {
    background: rgba(255, 255, 255, 0.1);
}

.is-hidden {
    display: none !important;
}

.magazine-nav {
    position: fixed;
    top: 0;
    width: 28%;
    height: 100%;
    border: none;
    background: transparent;
    cursor: pointer;
    z-index: 10;
    padding: 0;
}

.magazine-nav--prev {
    left: 0;
}

.magazine-nav--next {
    right: 0;
}

.magazine-share {
    position: fixed;
    left: max(12px, env(safe-area-inset-left));
    bottom: max(16px, env(safe-area-inset-bottom));
    z-index: 25;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 8px;
}

.magazine-share-toggle {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    border: none;
    border-radius: 999px;
    padding: 8px 14px;
    font-size: 0.85rem;
    font-weight: 600;
    letter-spacing: 0.02em;
    background: rgba(255, 255, 255, 0.92);
    color: #111;
    cursor: pointer;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.35);
}

.magazine-share-toggle[aria-expanded="true"] {
    background: #fff;
}

.magazine-share-panel {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 6px 10px;
    border-radius: 999px;
    background: rgba(0, 0, 0, 0.78);
    backdrop-filter: blur(10px);
}

.magazine-share-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    border: none;
    color: #fff;
    font-size: 1.25rem;
    text-decoration: none;
    cursor: pointer;
    transition: transform 0.15s ease, opacity 0.15s ease;
}

.magazine-share-btn:hover {
    transform: scale(1.08);
    color: #fff;
}

.magazine-share-btn--facebook {
    background: #1877f2;
}

.magazine-share-btn--whatsapp {
    background: #25d366;
}

.magazine-share-btn--telegram {
    background: #229ed9;
}

.magazine-share-btn--copy,
.magazine-share-btn--native {
    background: rgba(255, 255, 255, 0.2);
}

.magazine-share-toast {
    font-size: 0.75rem;
    color: #fff;
    background: rgba(0, 0, 0, 0.75);
    padding: 4px 10px;
    border-radius: 6px;
}
