*,
*::before,
*::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

:root {
    --gold: #c9a84c;
    --red: #c0152a;
    --green: #1a8a30;
    --purple: #8020b0;
    --cream: #f5e8d8;
}

html,
body {
    width: 100%;
    min-height: 100vh;
    color: var(--cream);
    font-family: 'Cormorant Garamond', serif;
    overflow-x: hidden;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

.bg-photo {
    position: fixed;
    inset: 0;
    background: url('../pic/22.jpg') center center / cover no-repeat;
    z-index: 0;
}

.bg-overlay {
    position: fixed;
    inset: 0;
    background: rgba(6, 2, 5, 0.45);
    z-index: 1;
}

nav {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 100;
    padding: 1rem 2.2rem;
    background: rgba(6, 2, 5, 0.35);
    backdrop-filter: blur(10px);
    border-bottom: 0.5px solid rgba(201, 168, 76, 0.12);
}

.back-btn {
    font-family: 'Cormorant Garamond', serif;
    font-style: italic;
    font-size: 0.95rem;
    letter-spacing: 0.25em;
    color: var(--gold);
    text-decoration: none;
    opacity: 0.85;
    transition: opacity 0.3s;
}

.back-btn:hover {
    opacity: 1;
}

main {
    position: relative;
    z-index: 10;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 1.6rem;
    padding: 5rem 2rem 3rem;
    text-align: center;
}

.eyebrow {
    font-style: italic;
    font-size: clamp(0.8rem, 1.8vw, 1rem);
    letter-spacing: 0.35em;
    color: var(--gold);
    opacity: 0.8;
    animation: fadeUp 1.2s ease both;
}

.subtitle {
    font-style: italic;
    font-size: 0.85rem;
    letter-spacing: 0.3em;
    color: rgba(245, 232, 216, 0.45);
    animation: fadeUp 1.2s 0.4s ease both;
}

@keyframes fadeUp {
    from {
        opacity: 0;
        transform: translateY(16px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.present-wrap {
    position: relative;
    width: 220px;
    height: 220px;
    animation: fadeUp 1.2s 0.2s ease both;
}

.present-box {
    position: absolute;
    inset: 0;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: transform 0.15s ease;
}

.present-box:hover {
    transform: scale(1.04);
}

.present-box:active {
    transform: scale(0.97);
}

.present-box::before {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 180px;
    height: 130px;
    background: linear-gradient(145deg, var(--red), #8a0010);
    border-radius: 4px;
    box-shadow: 0 8px 40px rgba(192, 21, 42, 0.45), 0 2px 8px rgba(0, 0, 0, 0.4);
}

.present-box::after {
    content: '';
    position: absolute;
    bottom: 126px;
    left: 50%;
    transform: translateX(-50%);
    width: 196px;
    height: 30px;
    background: linear-gradient(145deg, #e02040, var(--red));
    border-radius: 4px 4px 0 0;
    box-shadow: 0 -2px 12px rgba(192, 21, 42, 0.3);
}

.ribbon-h {
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 180px;
    height: 130px;
    pointer-events: none;
}

.ribbon-h::before {
    content: '';
    position: absolute;
    top: 0;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 22px;
    background: var(--gold);
    opacity: 0.9;
}

.ribbon-v {
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 196px;
    height: 160px;
    pointer-events: none;
}

.ribbon-v::before {
    content: '';
    position: absolute;
    left: 0;
    right: 0;
    bottom: 128px;
    height: 32px;
    background: var(--gold);
    opacity: 0.9;
    display: flex;
    align-items: center;
}

.bow {
    position: absolute;
    bottom: 152px;
    left: 50%;
    transform: translateX(-50%);
    width: 100px;
    height: 60px;
    pointer-events: none;
}

.bow-left,
.bow-right {
    position: absolute;
    bottom: 8px;
    width: 44px;
    height: 44px;
    border-radius: 50% 50% 50% 0;
    background: var(--gold);
    opacity: 0.95;
}

.bow-left {
    left: 0;
    transform: rotate(135deg);
}

.bow-right {
    right: 0;
    transform: rotate(-45deg);
}

.bow-center {
    position: absolute;
    bottom: 18px;
    left: 50%;
    transform: translateX(-50%);
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background: #e8c060;
    z-index: 2;
}

.tap-hint {
    position: absolute;
    bottom: -28px;
    left: 50%;
    transform: translateX(-50%);
    font-style: italic;
    font-size: 0.75rem;
    letter-spacing: 0.3em;
    color: rgba(245, 232, 216, 0.4);
    white-space: nowrap;
    pointer-events: none;
    animation: pulse 2.5s ease-in-out infinite;
}

@keyframes pulse {

    0%,
    100% {
        opacity: 0.4;
    }

    50% {
        opacity: 0.9;
    }
}

.player-wrap {
    position: absolute;
    inset: 0;
    display: none;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 1rem;
    animation: openGift 0.6s cubic-bezier(0.22, 0.68, 0, 1.2) both;
}

.player-wrap.visible {
    display: flex;
}

@keyframes openGift {
    from {
        opacity: 0;
        transform: scale(0.5) rotate(-8deg);
    }

    to {
        opacity: 1;
        transform: scale(1) rotate(0deg);
    }
}

.player-icon {
    font-size: 3.5rem;
    color: var(--gold);
    line-height: 1;
    animation: floatNote 3s ease-in-out infinite;
}

@keyframes floatNote {

    0%,
    100% {
        transform: translateY(0);
    }

    50% {
        transform: translateY(-8px);
    }
}

.player-label {
    font-style: italic;
    font-size: 0.8rem;
    letter-spacing: 0.3em;
    color: rgba(245, 232, 216, 0.6);
}

.player-controls {
    display: flex;
    align-items: center;
    gap: 12px;
    width: 200px;
}

.play-btn {
    background: none;
    border: 0.5px solid rgba(201, 168, 76, 0.5);
    color: var(--gold);
    font-size: 1rem;
    width: 38px;
    height: 38px;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    transition: background 0.2s, border-color 0.2s;
    padding-left: 3px;
}

.play-btn:hover {
    background: rgba(201, 168, 76, 0.12);
    border-color: var(--gold);
}

.progress-bar {
    flex: 1;
    height: 3px;
    background: rgba(245, 232, 216, 0.15);
    border-radius: 2px;
    cursor: pointer;
    position: relative;
}

.progress-fill {
    height: 100%;
    width: 0%;
    background: var(--gold);
    border-radius: 2px;
    transition: width 0.1s linear;
}

.time {
    font-size: 0.7rem;
    color: rgba(245, 232, 216, 0.4);
    letter-spacing: 0.05em;
    min-width: 28px;
    text-align: right;
}

.speed-btn {
    background: none;
    border: 0.5px solid rgba(201, 168, 76, 0.4);
    color: rgba(245, 232, 216, 0.55);
    font-family: 'Cormorant Garamond', serif;
    font-style: italic;
    font-size: 0.8rem;
    letter-spacing: 0.05em;
    padding: 0.25rem 0.5rem;
    border-radius: 3px;
    cursor: pointer;
    flex-shrink: 0;
    transition: color 0.2s, border-color 0.2s, background 0.2s;
}

.speed-btn:hover {
    background: rgba(201, 168, 76, 0.1);
    border-color: var(--gold);
    color: var(--gold);
}

.speed-btn.active {
    background: rgba(201, 168, 76, 0.15);
    border-color: var(--gold);
    color: var(--gold);
}

body::after {
    content: '';
    position: fixed;
    inset: 0;
    background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noise'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noise)' opacity='0.045'/%3E%3C/svg%3E");
    pointer-events: none;
    opacity: 0.3;
    z-index: 999;
}