/* style.css */
:root {
    --text-light: #FDFBF7;
    --text-accent: #FFDDE1;
    --font-storybook: 'Alice', serif;
}

/* Enables smooth animation of the radial dissolve mask */
@property --mask-inner {
    syntax: '<percentage>';
    inherits: false;
    initial-value: 95%;
}

@property --mask-outer {
    syntax: '<percentage>';
    inherits: false;
    initial-value: 150%;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    -webkit-tap-highlight-color: transparent;
}

body, html {
    width: 100%;
    height: 100vh;
    height: 100dvh;
    background-color: #050505;
    font-family: var(--font-storybook);
    overflow: hidden;
    display: flex;
    justify-content: center;
    align-items: center;
    user-select: none;
    -webkit-user-select: none;
    touch-action: manipulation;
    perspective: 1500px;
}

#demo-label {
    position: fixed;
    top: max(16px, env(safe-area-inset-top));
    left: max(16px, env(safe-area-inset-left));
    z-index: 1000000;
    padding: 8px 12px;
    border-radius: 999px;
    background: #2b1521;
    color: var(--text-light);
    font-size: 0.75rem;
    pointer-events: none;
}

#gift-content {
    width: 100%;
    height: 100vh;
    height: 100dvh;
    position: relative;
    display: flex;
    justify-content: center;
    align-items: center;
}

.visually-hidden {
    position: absolute;
    width: 1px;
    height: 1px;
    clip-path: inset(50%);
    overflow: hidden;
    white-space: nowrap;
}

/* --- Backgrounds & Overlays --- */
#bg-layer {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-size: cover;
    background-position: center;
    opacity: 0;
    filter: blur(20px);
    transform: scale(1.1);
    transition: opacity 3s ease, filter 4s ease-out, transform 5s ease-out;
    z-index: 1;
}

#bg-layer.active {
    opacity: 0.6;
    filter: blur(0px);
    transform: scale(1);
}

#dim-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: radial-gradient(circle, rgba(0,0,0,0.3) 0%, rgba(0,0,0,0.8) 100%);
    opacity: 0;
    transition: opacity 2s ease;
    z-index: 2;
}

#dim-overlay.active {
    opacity: 1;
}

.start-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: #050505;
    border: 0;
    z-index: 99999;
    display: flex;
    justify-content: center;
    align-items: center;
    color: var(--text-light);
    font-family: inherit;
    font-size: 1.4rem;
    letter-spacing: 2px;
    cursor: pointer;
    transition: opacity 0.5s ease;
}

.start-overlay:focus-visible {
    outline: 2px solid var(--text-accent);
    outline-offset: -6px;
}

.start-overlay:disabled {
    cursor: wait;
}

.start-overlay.hidden {
    opacity: 0;
    pointer-events: none;
}

.pin-gate {
    align-items: safe center;
    justify-content: safe center;
    padding: clamp(12px, 4vw, 32px);
    overflow: auto;
    text-align: center;
    cursor: default;
    letter-spacing: normal;
    color: #fff0e3;
    background: radial-gradient(ellipse at center, #370e0b, #1c0505);
}

.pin-card {
    --pin-muted: #dfa698;
    --pin-edge: #f2b4a049;
    flex: 0 1 28rem;
    min-width: 0;
    padding: clamp(24px, 5vw, 42px);
    border: 1px solid var(--pin-edge);
    border-radius: 28px;
    background: linear-gradient(145deg, #511811f5, #320b08f7 64%, #290807);
    box-shadow: inset 0 1px 2px #e3886638, 0 22px 70px #140302b5;
}

.pin-brand {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    color: var(--pin-muted);
    font-size: 0.7rem;
    letter-spacing: 0.28em;
    text-transform: uppercase;
}

.pin-brand::before,
.pin-brand::after {
    content: '';
    width: 24px;
    height: 1px;
    background: var(--pin-edge);
}

#access-heading {
    margin-top: 18px;
    font-size: clamp(2rem, 7.5vw, 3rem);
    font-weight: normal;
    line-height: 1.06;
}

#access-message {
    margin-top: 10px;
    color: var(--pin-muted);
    font-size: 1rem;
    line-height: 1.35;
}

.pin-field {
    margin-top: 26px;
    text-align: left;
}

.pin-field label {
    display: block;
    margin-bottom: 8px;
    font-size: 0.95rem;
}

#gift-pin {
    display: block;
    width: 100%;
    min-height: 56px;
    padding: 10px 12px;
    border: 1px solid #d99581a3;
    border-radius: 11px;
    background: #220705;
    color: #fff0e3;
    font: 1.4rem / 1.25 system-ui, sans-serif;
    letter-spacing: 0.7em;
    text-indent: 0.7em;
    text-align: center;
    caret-color: #ffd3bd;
}

#gift-pin::placeholder {
    color: #c58a7d;
    opacity: 0.65;
}

#gift-pin[aria-invalid="true"] {
    border-color: #ffab9c;
}

#gift-pin:focus-visible,
.pin-unlock:focus-visible {
    outline: 2px solid #ffcfb8;
    outline-offset: 3px;
}

#pin-error {
    min-height: 1.35em;
    margin: 8px 0 10px;
    color: #ffc0b4;
    font-size: 0.875rem;
    line-height: 1.35;
}

.pin-unlock {
    width: 100%;
    min-height: 48px;
    padding: 10px 16px;
    border: 1px solid #fbd4bf;
    border-radius: 11px;
    background: linear-gradient(180deg, #ffe0cb, #e6ad98);
    color: #390d09;
    font-family: inherit;
    font-size: 1.1rem;
    line-height: 1.25;
    cursor: pointer;
}

.pin-unlock:hover {
    background: #ffe3d1;
}

#retry-btn {
    margin-top: 24px;
}

@media (max-height: 460px) {
    .pin-card { padding-block: 20px; }
    #access-heading { font-size: 2rem; }
    .pin-field { margin-top: 12px; }
    #gift-pin { min-height: 44px; }
}

/* --- Typography & Text Positioning --- */
#story-container {
    position: relative;
    z-index: 10;
    width: 90%;
    max-width: 400px;
    height: 100%;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
}

.story-text {
    position: absolute;
    max-width: 100%;
    overflow-wrap: anywhere;
    color: var(--text-light);
    visibility: hidden;
    opacity: 0;
    filter: blur(10px);
    transform: translateY(15px);
    transition-property: opacity, filter, transform, visibility;
    transition-duration: 1.5s, 1.5s, 1.5s, 0s;
    transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);
    pointer-events: none;
    text-shadow: 0px 4px 15px rgba(0,0,0,0.5);
}

.story-text.show {
    visibility: visible;
    opacity: 1;
    filter: blur(0px);
    transform: translateY(0);
}

.story-text.exit {
    visibility: hidden;
    opacity: 0;
    filter: blur(10px);
    transform: translateY(-15px);
    transition-delay: 0s, 0s, 0s, 1.5s;
    animation: none !important;
}

.story-group {
    position: absolute;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 20px;
    pointer-events: none;
}

.story-group .story-text {
    position: relative;
}

.cinematic { font-size: 3rem; }
.personal { font-size: 3rem; }
.hint-text { font-size: 1.1rem; letter-spacing: 2px; color: #EBEBEB; opacity: 0.8; }
.soothing { font-size: 1.4rem; letter-spacing: 3px; opacity: 0.8; }
.buildup { font-size: 2.2rem; line-height: 1.5; }

/* --- Animations & Interactions --- */
.rotate-icon {
    width: 28px;
    height: 48px;
    border: 2px solid #EBEBEB;
    border-radius: 6px;
    margin-top: 15px;
    transform-origin: center;
}

#tilt-screen.show:not(.exit) .rotate-icon {
    animation: rotatePhone 2.5s infinite ease-in-out 1.5s;
}

@keyframes rotatePhone {
    0%, 15% { transform: rotate(0deg); opacity: 1; }
    45%, 55% { transform: rotate(-90deg); opacity: 1; }
    85%, 100% { transform: rotate(0deg); opacity: 1; }
}

.landscape-group {
    width: 90vw;
    max-width: 800px;
    text-align: center;
}

.interactive-group.active {
    pointer-events: auto;
    cursor: pointer;
}

.pulsing-cta {
    position: relative;
    background: none;
    border: 0;
    font-family: inherit;
    font-size: 1.6rem;
    color: var(--text-accent);
    margin-top: 15px;
    letter-spacing: 2px;
}

.interactive-group.active .pulsing-cta {
    pointer-events: auto;
    cursor: pointer;
}

.pulsing-cta > span {
    display: inline-block;
}

.pulsing-cta.show:not(.exit) > span {
    animation: gentlePulse 2s infinite alternate ease-in-out 1.5s;
}

@keyframes gentlePulse {
    0% { opacity: 1; transform: scale(1); text-shadow: 0px 4px 15px rgba(0,0,0,0.5); }
    100% { opacity: 0.6; transform: scale(0.95); text-shadow: 0px 0px 15px rgba(255,221,225,0.6); }
}

/* =========================================
   MUSIC CARD INTEGRATION
   ========================================= */
#bg-layer.music-stage {
    background-color: #310705;
    background-blend-mode: screen;
    background-size: cover;
}

#bg-layer.music-stage.active {
    opacity: 0.92;
}

#bg-layer.music-stage + #dim-overlay {
    background: radial-gradient(ellipse at center, #21020144, #30040129 72%, #1b0201ae);
}

.landscape-card {
    --mask-inner: 95%;
    --mask-outer: 150%;
    --card-ink: #fff0e3;
    --card-muted: #d89b8a;
    position: absolute;
    z-index: 20;
    width: min(90vw, 1450px);
    height: min(90dvh, 57.8vw, 930px);
    container-type: size;
    transform: scale(0.96);
    opacity: 0;
    pointer-events: none;
    transition: transform 1.5s cubic-bezier(0.2, 0.8, 0.2, 1),
                opacity 1.5s ease-in-out;
    color: var(--card-ink);
    background-color: #340b08;
    background-position: center;
    background-size: cover;
    border: 1px solid #a64a406b;
    border-radius: clamp(20px, 3.35vw, 54px);
    box-shadow: inset 0 1px 3px #e4705661, inset 0 -1px 3px #e4705644,
                0 20px 54px #140301a6;
    display: grid;
    grid-template-columns: 53.75% minmax(0, 1fr);
    overflow: hidden;
    -webkit-mask-image: radial-gradient(ellipse at center, black var(--mask-inner), transparent var(--mask-outer));
    mask-image: radial-gradient(ellipse at center, black var(--mask-inner), transparent var(--mask-outer));
}

.landscape-card.active {
    opacity: 1;
    pointer-events: auto;
    transform: scale(1);
}

.landscape-card.dissolve-radial {
    --mask-inner: -35%;
    --mask-outer: 0%;
    opacity: 0;
    filter: blur(14px);
    transform: scale(0.96);
    pointer-events: none;
    transition: --mask-inner 2.6s cubic-bezier(0.4, 0, 0.2, 1),
                --mask-outer 2.6s cubic-bezier(0.4, 0, 0.2, 1),
                opacity 2.4s ease-in-out 0.2s,
                filter 2.6s ease-in-out,
                transform 2.6s cubic-bezier(0.4, 0, 0.2, 1);
}

.canvas-section {
    position: relative;
    background-color: #2003002b;
    border-right: 1px solid #d179673f;
}

.lyric-mask {
    --lyric-fade: 14%;
    position: absolute;
    inset: 0;
    overflow: hidden;
    -webkit-mask-image: linear-gradient(to bottom, transparent, black var(--lyric-fade) calc(100% - var(--lyric-fade)), transparent);
    mask-image: linear-gradient(to bottom, transparent, black var(--lyric-fade) calc(100% - var(--lyric-fade)), transparent);
}

.lyric-wrapper {
    position: absolute;
    top: 0;
    width: 100%;
    padding: 0 11%;
    transition: transform 1s cubic-bezier(0.25, 0.8, 0.25, 1);
}

.lyric-line {
    font-size: clamp(1.15rem, min(3.35cqw, 5.6cqh), 3.125rem);
    line-height: 1.42;
    text-align: center;
    overflow-wrap: anywhere;
    margin-bottom: 1em;
    text-shadow: 0 2px 14px #200300;
    opacity: 0;
    transform: translateY(12px);
    transition: opacity 0.65s ease, transform 0.8s ease;
}

.lyric-line.active {
    opacity: 1;
    transform: translateY(0);
}

.lyric-line.passed {
    transform: translateY(-12px);
}

.control-section {
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    min-width: 0;
    min-height: 0;
    padding: 8.5cqh 4.5cqw 13cqh;
    background: linear-gradient(150deg, #76271e31, #5e120c38 70%, #3d09082e);
    text-align: center;
}

.device-info {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.95em;
    text-transform: uppercase;
    white-space: nowrap;
    letter-spacing: 0.26em;
    font-size: clamp(0.54rem, min(1.58cqw, 2.5cqh), 1.35rem);
}

.device-info::before,
.device-info::after {
    content: '';
    flex: 1;
    height: 1px;
    max-width: 2.8em;
    background-color: currentColor;
    opacity: 0.76;
}

.song-info {
    margin-top: 4.6cqh;
}

.song-title {
    display: -webkit-box;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
    overflow: hidden;
    overflow-wrap: anywhere;
    font-size: clamp(1.35rem, min(4.7cqw, 7.4cqh), 4rem);
    line-height: 1.05;
    font-weight: normal;
    text-shadow: 0 2px 16px #2a0504;
}

.artist-name {
    margin-top: 0.45em;
    color: var(--card-muted);
    font-size: clamp(0.8rem, min(2.55cqw, 3.8cqh), 2.25rem);
    line-height: 1.1;
}

.player-art {
    display: grid;
    justify-items: center;
    gap: 2cqh;
}

.sealed-letter {
    display: block;
    width: min(58%, 23cqh, 215px);
    aspect-ratio: 1;
    object-fit: contain;
    filter: drop-shadow(0 10px 20px #1601009c);
}

.player-waveform {
    width: min(55%, 300px);
    height: clamp(14px, 6.8cqh, 65px);
    background: repeating-linear-gradient(
        90deg, var(--card-ink) 0 21%, transparent 22% 100%
    ) 0 50% / calc(100% / 34) 100%;
    clip-path: polygon(
        0 48%, 8% 48%, 16% 44%, 20% 35%, 24% 43%, 29% 36%,
        35% 30%, 40% 24%, 44% 12%, 48% 0, 51% 12%, 55% 22%,
        60% 29%, 63% 23%, 67% 37%, 74% 42%, 79% 36%, 84% 47%,
        100% 48%, 100% 52%, 84% 53%, 79% 64%, 74% 58%, 67% 63%,
        63% 77%, 60% 71%, 55% 78%, 51% 88%, 48% 100%, 44% 88%,
        40% 76%, 35% 70%, 29% 64%, 24% 57%, 20% 65%, 16% 56%,
        8% 52%, 0 52%
    );
}

.progress-container {
    padding-inline: 4px;
}

.time-labels {
    display: flex;
    justify-content: space-between;
    font-size: clamp(0.75rem, min(1.7cqw, 2.6cqh), 1.5rem);
    font-variant-numeric: tabular-nums;
    margin-bottom: 1.5cqh;
}

.progress-bar-bg {
    width: 100%;
    height: clamp(4px, 1.2cqh, 12px);
    background-color: #e6a39334;
    border-radius: 100px;
}

.progress-bar-fill {
    height: 100%;
    width: 0%;
    background-color: #edc3b4;
    border-radius: inherit;
    position: relative;
    transition: width 0.1s linear;
}

.progress-bar-fill::after {
    content: '';
    position: absolute;
    top: 50%;
    right: 0;
    width: clamp(10px, 3cqh, 27px);
    aspect-ratio: 1;
    transform: translate(50%, -50%);
    background-color: #fff5ef;
    border-radius: 50%;
    box-shadow: 0 0 14px #f8ae9a9c;
}

.playback-engine {
    position: relative;
}

.controls {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    align-items: center;
    justify-items: center;
    margin-top: 4.3cqh;
}

.controls button {
    background: none;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    color: var(--card-ink);
    display: grid;
    place-items: center;
    transition: transform 0.2s ease, color 0.2s ease;
}

.controls button:focus-visible {
    outline: 2px solid var(--card-ink);
    outline-offset: 3px;
}

.controls button:hover {
    transform: scale(1.08);
    color: white;
}

.controls button:disabled {
    opacity: 0.4;
    transform: none;
    cursor: default;
}

.controls button svg {
    fill: currentColor;
    width: 80%;
}

.btn-play { width: clamp(44px, 12.5cqh, 100px); aspect-ratio: 1; }
.btn-skip { width: clamp(44px, 7.5cqh, 60px); aspect-ratio: 1; }

#playback-status {
    position: absolute;
    inset: 100% 0 auto;
    color: var(--card-muted);
    font-size: clamp(0.65rem, 2.25cqh, 0.9rem);
    margin-top: 0.25em;
}

.typing-cursor::after {
    content: '|';
    animation: blink 0.8s step-end infinite;
}

@keyframes blink {
    50% { opacity: 0; }
}

/* =========================================
   CINEMATIC ROMANTIC REVEAL
   ========================================= */
.romantic-reveal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    transform: none;
    background-color: rgba(0, 0, 0, 0);
    z-index: 999999;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    font-family: var(--font-storybook);
    text-align: center;
    overflow: hidden;
    opacity: 0;
    pointer-events: none;
    transition: opacity 2.5s ease-in-out, background-color 2.5s ease-in-out;
}

.romantic-reveal-overlay.active {
    opacity: 1;
    pointer-events: auto;
    background-color: rgba(0, 0, 0, 1);
}

.bg-video {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    transform: none;
    object-fit: cover;
    z-index: 1;
    pointer-events: none;
    transition: opacity 4s ease-in-out, filter 4s ease-in-out;
}

.bg-video.faded-out {
    opacity: 0;
    filter: blur(25px);
}

.bg-video.show {
    opacity: 0.5;
    filter: blur(8px);
}

.reveal-container {
    flex: 1;
    min-height: 0;
    display: grid;
    /* Center the heading and reserve room below it on short screens. */
    grid-template-rows: minmax(0, 1fr) auto minmax(min-content, 1fr);
    place-items: center;
    align-items: safe center;
    width: 100%;
    overflow: auto;
    perspective: 1000px;
    z-index: 10;
}

.reveal-container.hidden,
.romantic-reveal-overlay.hidden,
.take-time-msg.hidden {
    display: none;
}

.reveal-line {
    --mask-inner: 95%;
    --mask-outer: 150%;
    grid-area: 2 / 1;
    margin: 0;
    padding: clamp(12px, 3vw, 20px) clamp(10px, 5vw, 44px);
    max-width: calc(100% - 60px);
    overflow-wrap: anywhere;
    text-align: center;
    -webkit-mask-image: radial-gradient(ellipse at center, black var(--mask-inner), transparent var(--mask-outer));
    mask-image: radial-gradient(ellipse at center, black var(--mask-inner), transparent var(--mask-outer));
    transition: transform 2.8s cubic-bezier(0.25, 0.8, 0.25, 1),
                filter 2.8s ease-in-out,
                opacity 2.8s ease-in-out,
                scale 2.8s ease-in-out,
                visibility 2.8s ease-in-out,
                text-shadow 2.8s ease-in-out;
    opacity: 0;
    visibility: hidden;
    filter: blur(10px);
    scale: 0.88;
    transform: translateZ(-60px);
    text-shadow: 0 0 0 rgba(255, 221, 225, 0);
}

.cinematic-text-glow {
    font-size: 1.8rem;
    color: #FFDDE1;
    letter-spacing: 1px;
}

.bold-love-text-glow {
    font-size: clamp(2rem, min(10vw, 16vh), 4.5rem);
    color: #ffffff;
}

.reveal-line.appear {
    opacity: 1;
    visibility: visible;
    filter: blur(0px);
    scale: 1;
    transform: translateZ(0px);
    text-shadow: 0 0 25px rgba(255, 221, 225, 0.7);
}

/* 02 · Velvet Edge-Inward Dissolve for "So..." & "What I'm really trying to say is..." */
.reveal-line.dissolve-radial {
    --mask-inner: -35%;
    --mask-outer: 0%;
    opacity: 0;
    filter: blur(14px);
    scale: 0.96;
    transform: translateZ(0px);
    text-shadow: 0 0 0 rgba(255, 221, 225, 0);
    visibility: hidden;
    transition: --mask-inner 2.2s cubic-bezier(0.4, 0, 0.2, 1),
                --mask-outer 2.2s cubic-bezier(0.4, 0, 0.2, 1),
                opacity 2s ease-in-out 0.2s,
                filter 2.2s ease-in-out,
                scale 2.2s cubic-bezier(0.4, 0, 0.2, 1),
                text-shadow 2s ease-in-out,
                visibility 0s linear 2.2s;
}

.reveal-footer {
    grid-area: 3 / 1;
    align-self: start;
    display: grid;
    width: 100%;
    padding-block: 6px 16px;
}

#rev-line3:not(.appear) + .reveal-footer {
    display: none;
}

.cta-container,
.take-time-msg {
    grid-area: 1 / 1;
    align-self: start;
}

.cta-container.hidden {
    visibility: hidden;
}

.cta-container {
    display: flex;
    flex-direction: column;
    gap: 20px;
    align-items: center;
    width: 100%;
}

.btn-primary {
    background: linear-gradient(135deg, #ff3b30, #c40018);
    color: white;
    padding: 16px 40px;
    border-radius: 50px;
    border: none;
    max-width: calc(100% - 32px);
    font-size: 1.2rem;
    font-family: system-ui, sans-serif;
    font-weight: 600;
    cursor: pointer;
    box-shadow: 0 10px 25px rgba(255, 59, 48, 0.4);
    transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
}

.btn-primary:hover {
    transform: translateY(-3px);
    box-shadow: 0 15px 35px rgba(255, 59, 48, 0.6);
}

.btn-secondary {
    background: transparent;
    color: #FFDDE1;
    padding: 12px 30px;
    border-radius: 50px;
    border: 1px solid rgba(255, 221, 225, 0.3);
    max-width: calc(100% - 32px);
    font-size: 1rem;
    font-family: system-ui, sans-serif;
    cursor: pointer;
    transition: all 0.3s ease;
}

.btn-secondary:hover {
    background: rgba(255, 221, 225, 0.1);
    border-color: #FFDDE1;
}

.responses-ready .cta-container:not(.hidden) {
    animation: simpleFade 1.5s ease-in-out;
}

@keyframes simpleFade {
    from { opacity: 0; }
    to { opacity: 1; }
}

.take-time-msg {
    justify-self: center;
    padding-inline: 16px;
    color: #FFDDE1;
    font-size: 1.3rem;
    font-style: italic;
    opacity: 0;
    transition: opacity 1.5s ease;
}

.take-time-msg.show {
    opacity: 1;
}

.word-reveal {
    display: inline-block;
    max-width: 100%;
    animation: magicalWordFade 2.5s cubic-bezier(0.25, 0.8, 0.25, 1) both;
}

@keyframes magicalWordFade {
    from {
        opacity: 0;
        filter: blur(12px);
        transform: translateY(15px) scale(0.9);
    }
    to {
        opacity: 1;
        filter: blur(0px);
        transform: translateY(0) scale(1);
    }
}

[hidden] {
    display: none !important;
}



/* Keep the sideways scene on narrow screens until the phone is horizontal. */
@media (orientation: portrait) and (max-width: 767px) {
    .landscape-group {
        width: 85vh;
        width: 85dvh;
        transform: rotate(90deg);
    }

    .landscape-card {
        width: min(90dvh, 1450px);
        height: min(90vw, 57.8dvh, 930px);
        border-radius: clamp(20px, 3.35dvh, 54px);
        rotate: 90deg;
    }
}

@media (orientation: landscape) and (max-height: 480px), (orientation: portrait) and (max-width: 480px) {
    .control-section {
        padding-block: 6cqh 8cqh;
    }

    .song-info,
    .controls {
        margin-top: 3cqh;
    }
}

@media (orientation: landscape) and (max-height: 480px) {
    .cta-container {
        gap: 10px;
    }
}

@media (prefers-reduced-motion: reduce) {
    #gift-content *,
    #gift-content *::after {
        transition-duration: 0s !important;
        transition-delay: 0s !important;
        animation-duration: 0s !important;
        animation-delay: 0s !important;
        animation-iteration-count: 1 !important;
    }

    .bg-video {
        display: none;
    }
}
