
* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    min-height: 100vh;
    background: #c9aaa0;
    font-family: Arial, sans-serif;
    color: #38282b;
}

.loading-screen {
    position: fixed;
    inset: 0;
    z-index: 200;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 18px;
    background: #f7eee8;
    color: #70454d;
    transition: opacity .55s ease, visibility .55s ease;
}

.loading-screen.done {
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
}

.loading-label {
    font-size: 10px;
    letter-spacing: 4px;
    margin-left: 4px;
}

.loading-dots {
    display: inline-block;
    width: 20px;
    overflow: hidden;
    vertical-align: bottom;
    animation: loading-dots 1.2s steps(4, end) infinite;
}

.loading-road {
    position: relative;
    width: 150px;
    height: 2px;
    margin-top: 7px;
    overflow: visible;
    background: repeating-linear-gradient(90deg, #d7bbb1 0 15px, transparent 15px 25px);
}

.loading-rider {
    position: absolute;
    top: -17px;
    left: -17px;
    font-size: 25px;
    animation: loading-ride 1.8s ease-in-out infinite;
}

@keyframes loading-ride {
    0% { transform: translateX(0) rotate(-2deg) scaleX(-1); }
    50% { transform: translateX(70px) rotate(2deg) scaleX(-1); }
    100% { transform: translateX(150px) rotate(-2deg) scaleX(-1); }
}

@keyframes loading-dots {
    0% { width: 0; }
    100% { width: 20px; }
}

.app {
    width: 100%;
    max-width: 430px;
    height: 100vh;
    margin: auto;
    background: #f7eee8;
    position: relative;
    overflow: hidden;
}

.app::before {
    content: "";
    position: absolute;
    width: 230px;
    height: 230px;
    border-radius: 50%;
    background: #ead0ce;
    top: -100px;
    right: -80px;
}

.app::after {
    content: "";
    position: absolute;
    width: 180px;
    height: 180px;
    border-radius: 50%;
    background: #e4d3b7;
    bottom: -100px;
    left: -80px;
}

.top {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    padding: 25px 24px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 9px;
    letter-spacing: 3px;
    color: #70454d;
    z-index: 20;
    opacity: 1;
    transition: opacity .25s ease;
}

.music-player {
    position: absolute;
    right: 20px;
    bottom: 21px;
    z-index: 31;
    display: flex;
    align-items: center;
    gap: 6px;
    width: 116px;
    min-height: 29px;
    padding: 2px 6px 2px 2px;
    border: 1px solid rgba(112, 69, 77, .18);
    border-radius: 20px;
    background: rgba(255, 248, 243, .55);
    box-shadow: 0 4px 12px rgba(112, 69, 77, .06);
}

.music-toggle {
    width: 25px;
    height: 25px;
    flex: 0 0 25px;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 0;
    border-radius: 50%;
    background: #70454d;
    color: #fff8f3;
    cursor: pointer;
    transition: transform .15s ease, background .2s ease;
}

.music-toggle:active {
    transform: scale(.9);
}

.music-toggle.playing {
    background: #b88951;
}

.music-icon {
    font-size: 14px;
    line-height: 1;
}

.music-title {
    height: 25px;
    display: flex;
    align-items: center;
    overflow: hidden;
    color: #70454d;
    font-size: 10px;
    letter-spacing: .5px;
    line-height: normal;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.top.hidden {
    opacity: 0;
    pointer-events: none;
}

.heart {
    font-size: 23px;
    cursor: pointer;
    user-select: none;
    transition: transform .15s ease;
}

.heart:active {
    transform: scale(.8);
}

@media (max-width: 360px) {
    .top {
        padding-left: 17px;
        padding-right: 17px;
    }

    .music-title {
        display: none;
    }
}

main {
    height: 100%;
    position: relative;
    z-index: 2;
}

.screen {
    position: absolute;
    inset: 0;
    padding: 90px 30px 110px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    opacity: 0;
    transform: translateX(35px);
    pointer-events: none;
    visibility: hidden;
    transition: .45s ease;
}

.screen.active {
    opacity: 1;
    transform: translateX(0);
    pointer-events: auto;
    visibility: visible;
}

.content {
    width: 100%;
}

.intro {
    margin-top: -30px;
}

.flower {
    width: 58px;
    height: 58px;
    border-radius: 50%;
    background: #70454d;
    color: #f7eee8;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
    margin-bottom: 30px;
}

.tag {
    display: block;
    color: #a05e67;
    font-size: 9px;
    letter-spacing: 3px;
    margin-bottom: 22px;
}

.number {
    display: block;
    font-family: Georgia, serif;
    font-size: 13px;
    color: #b18b82;
    margin-bottom: 12px;
}

h1,
h2 {
    font-family: Georgia, serif;
    font-weight: normal;
}

h1 {
    font-size: 68px;
    line-height: .82;
    color: #432d31;
    margin-bottom: 32px;
}

h1 em {
    color: #b26c75;
    font-size: 48px;
}

h2 {
    font-size: 43px;
    line-height: .98;
    margin-bottom: 23px;
    color: #432d31;
}

p {
    font-family: Georgia, serif;
    font-size: 18px;
    line-height: 1.5;
    color: #725f60;
    max-width: 340px;
}

.main-btn {
    position: absolute;
    bottom: 68px;
    left: 30px;
    width: calc(100% - 60px);
    padding: 17px;
    border: none;
    border-radius: 13px;
    background: #70454d;
    color: #fff8f3;
    font-size: 11px;
    letter-spacing: 2px;
    cursor: pointer;
    z-index: 5;
    transition: transform .15s ease, opacity .15s ease;
}

.main-btn:active {
    transform: scale(.98);
    opacity: .9;
}

.bike {
    font-size: 65px;
    margin: 0 0 20px;
    width: fit-content;
}

.sun {
    font-size: 70px;
    color: #b88951;
    margin-bottom: 20px;
}

.rings {
    font-size: 50px;
    letter-spacing: -15px;
    color: #b88951;
    margin: 0 0 28px 15px;
}

.tiny-heart {
    color: #b26c75;
    font-size: 30px;
    margin-top: 30px;
}

.secret-star {
    display: inline-block;
    color: #d0a56a;
    font-size: 10px;
    margin-top: 28px;
    user-select: none;
}

.baby {
    width: 65px;
    height: 65px;
    border-radius: 50%;
    background: #d6b5a9;
    color: #70454d;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 25px;
    margin-bottom: 25px;
}

.final-heart {
    color: #b26c75;
    font-size: 60px;
    margin-bottom: 25px;
}

.countdown-block {
    padding: 18px 0;
    border-top: 1px solid #e2cbc3;
}

.countdown-block:first-of-type {
    border-top: none;
    padding-top: 0;
}

.anniversary-mark {
    color: #b88951;
    font-family: Georgia, serif;
    font-size: 16px;
    letter-spacing: 4px;
    margin: 4px 0 22px;
}

.anniversary-mark span {
    color: #d2aea1;
    margin: 0 3px;
}

.countdown-label {
    display: block;
    color: #a05e67;
    font-size: 9px;
    letter-spacing: 2px;
    margin-bottom: 8px;
}

.marriage-counter,
.marriage-counter {
    display: block;
    color: #432d31;
    font-family: Georgia, serif;
    font-size: 28px;
    font-weight: normal;
    letter-spacing: 1px;
}

.countdown-date {
    display: block;
    color: #725f60;
    font-family: Georgia, serif;
    font-size: 14px;
    margin-top: 5px;
}

.countdown-note {
    margin-top: 24px;
    color: #a05e67;
    font-size: 16px;
    line-height: 1.35;
}

.map-screen h2 {
    margin-bottom: 10px;
}

.map-intro {
    font-size: 15px;
    line-height: 1.3;
    margin-bottom: 14px;
}

.travel-map {
    width: 100%;
    height: 260px;
    overflow: hidden;
    border: 5px solid #fffaf5;
    border-radius: 12px;
    box-shadow: 0 5px 14px rgba(112, 69, 77, .16);
    background: #e4d3b7;
}

.leaflet-container {
    font-family: Arial, sans-serif;
}

.travel-pin-wrap {
    background: transparent;
    border: 0;
}

.travel-pin {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 28px;
    height: 28px;
    border: 2px solid #fff8f3;
    border-radius: 50% 50% 50% 0;
    background: #70454d;
    box-shadow: 0 3px 7px rgba(56, 40, 43, .3);
    color: #e4d3b7;
    font-size: 14px;
    transform: rotate(-45deg);
}

.travel-pin-heart {
    display: block;
    transform: rotate(45deg);
}

.map-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-top: 10px;
    color: #a05e67;
    font-family: Georgia, serif;
    font-size: 13px;
}

.clear-map {
    padding: 7px 11px;
    border: 1px solid #d2aea1;
    border-radius: 8px;
    background: transparent;
    color: #70454d;
    font-size: 10px;
    cursor: pointer;
}

.quiz-screen h2 {
    margin-bottom: 20px;
}

.quiz-card {
    padding: 18px 16px 16px;
    border: 1px solid #e4c2bb;
    border-radius: 14px;
    background: rgba(255, 250, 245, .65);
}

.quiz-count {
    display: block;
    color: #b18b82;
    font-size: 10px;
    letter-spacing: 2px;
    margin-bottom: 13px;
}

.quiz-question {
    min-height: 54px;
    color: #432d31;
    font-size: 19px;
    line-height: 1.3;
}

.quiz-answers {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 9px;
    margin-top: 18px;
}

.quiz-answer,
.quiz-next {
    border: 1px solid #b88951;
    border-radius: 9px;
    padding: 12px 8px;
    background: #fff8f3;
    color: #70454d;
    font-size: 12px;
    cursor: pointer;
}

.quiz-answer.selected,
.quiz-answer:active {
    background: #70454d;
    color: #fff8f3;
}

.quiz-answer:disabled {
    cursor: default;
    opacity: .7;
}

.quiz-result {
    min-height: 21px;
    margin-top: 10px;
    color: #a05e67;
    font-size: 14px;
}

.quiz-score {
    display: flex;
    justify-content: center;
    gap: 24px;
    margin-top: 17px;
    color: #725f60;
    font-family: Georgia, serif;
    font-size: 14px;
}

.quiz-score strong {
    margin-left: 4px;
    color: #b88951;
    font-size: 17px;
    font-weight: normal;
}

.quiz-next {
    display: block;
    width: 100%;
    margin-top: 14px;
    background: transparent;
    border-color: #d2aea1;
}

.quiz-next:disabled {
    cursor: default;
    opacity: .4;
}

.gallery-screen h2 {
    margin-bottom: 10px;
}

.polaroid-wall {
    position: relative;
    width: 100%;
    height: 365px;
    margin: 0 auto;
}

.polaroid {
    position: absolute;
    width: 145px;
    padding: 9px 9px 25px;
    border: 0;
    background: #fffaf5;
    box-shadow: 0 5px 12px rgba(112, 69, 77, .16);
    color: #70454d;
    cursor: pointer;
    transition: transform .2s ease, box-shadow .2s ease;
}

.polaroid:active {
    z-index: 5;
    transform: scale(1.06) rotate(0deg);
    box-shadow: 0 9px 20px rgba(112, 69, 77, .22);
}

.polaroid-one { top: 16px; left: 25px; transform: rotate(-7deg); }
.polaroid-two { top: 4px; left: 132px; transform: rotate(6deg); }
.polaroid-three { top: 82px; left: 82px; transform: rotate(2deg); }
.polaroid-four { top: 166px; left: 18px; transform: rotate(-8deg); }
.polaroid-five { top: 188px; left: 126px; transform: rotate(5deg); }
.polaroid-six { top: 40px; right: -2px; transform: rotate(10deg); }
.polaroid-seven { top: 212px; right: -4px; transform: rotate(-11deg); }

.photo-frame {
    display: block;
    width: 127px;
    height: 127px;
    overflow: hidden;
    background: linear-gradient(135deg, #d6b5a9, #e4d3b7 55%, #b88951);
}

.photo-frame img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.photo-frame.missing {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 12px;
    background: #ead5cc;
}

.photo-frame.missing::before {
    content: "ide kerül a fotó";
    color: #a05e67;
    font-family: Georgia, serif;
    font-size: 12px;
    line-height: 1.2;
    text-align: center;
}

.photo-frame.missing img {
    display: none;
}

.photo-lightbox {
    position: absolute;
    inset: 0;
    z-index: 100;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 52px 18px 30px;
    background: rgba(56, 40, 43, .88);
}

.photo-lightbox[hidden] {
    display: none;
}

.photo-lightbox img {
    display: block;
    width: auto;
    height: auto;
    max-width: 88%;
    max-height: 68%;
    object-fit: contain;
    border: 6px solid #fffaf5;
    box-shadow: 0 10px 30px rgba(0, 0, 0, .25);
}

.lightbox-close {
    position: absolute;
    top: 18px;
    right: 18px;
    width: 34px;
    height: 34px;
    border: 1px solid rgba(255, 248, 243, .6);
    border-radius: 50%;
    background: transparent;
    color: #fff8f3;
    font-size: 25px;
    line-height: 1;
    cursor: pointer;
}

.notebook-screen .content {
    padding: 18px 16px 22px;
    background: #f4e5dc;
    border-left: 1px solid #e4c2bb;
    border-right: 1px solid #e4c2bb;
}

.note-input {
    display: block;
    width: 100%;
    height: min(52vh, 390px);
    min-height: 250px;
    resize: none;
    padding: 8px 10px 8px 12px;
    border: 0;
    outline: none;
    background-color: #fffaf5;
    background-image: repeating-linear-gradient(
        to bottom,
        transparent 0,
        transparent 31px,
        #ead5cc 32px
    );
    background-size: 100% 32px;
    color: #432d31;
    font-family: Georgia, serif;
    font-size: 16px;
    line-height: 32px;
    box-shadow: 0 2px 8px rgba(112, 69, 77, .08);
}

.note-input::placeholder {
    color: #b18b82;
    opacity: 1;
}

.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

.progress {
    position: absolute;
    bottom: 31px;
    left: 24px;
    display: flex;
    gap: 6px;
    z-index: 30;
    opacity: 1;
    transition: opacity .25s ease;
}

.music-player {
    transition: opacity .25s ease, transform .2s ease;
}

.top.hidden + main + .progress + .music-player {
    opacity: 0;
    pointer-events: none;
}

.progress.hidden {
    opacity: 0;
    pointer-events: none;
}

.dot {
    width: 5px;
    height: 5px;
    border-radius: 50%;
    background: #d1bbb1;
    transition: .3s;
}

.dot.active {
    width: 20px;
    border-radius: 5px;
    background: #70454d;
}

.secret-page {
    position: absolute;
    inset: 0;
    padding: 80px 30px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    background: #4b3036;
    opacity: 0;
    transform: scale(.96);
    visibility: hidden;
    pointer-events: none;
    transition: opacity .35s ease, transform .4s ease;
    z-index: 100;
}

.secret-page.show {
    opacity: 1;
    transform: scale(1);
    visibility: visible;
    pointer-events: auto;
}

.secret-content {
    width: 100%;
}

.secret-number {
    display: block;
    font-size: 9px;
    letter-spacing: 3px;
    color: #f5ddd5;
    opacity: .55;
    margin-bottom: 45px;
}

.secret-symbol {
    font-size: 70px;
    color: #e2a6a9;
    margin-bottom: 30px;
}

.secret-page h2 {
    color: #fff4ef;
    font-size: 52px;
    margin-bottom: 25px;
}

.secret-page p {
    color: #f5ddd5;
    opacity: .75;
}

.secret-back {
    position: absolute;
    bottom: 35px;
    left: 30px;
    width: calc(100% - 60px);
    padding: 15px;
    border: 1px solid rgba(255,255,255,.35);
    border-radius: 12px;
    background: transparent;
    color: #fff4ef;
    font-size: 10px;
    letter-spacing: 2px;
    cursor: pointer;
    transition: background .2s ease;
}

.secret-back:active {
    background: rgba(255,255,255,.08);
}

@media (max-width: 430px) {
    .app {
        min-height: 100vh;
    }
}
