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

body {
    background-color: #000;
    color: #fff;
    font-family: 'Georgia', 'Times New Roman', serif;
    min-height: 100vh;
}

.letter-container {
    min-height: 100vh;
    max-width: 800px;
    width: 100%;
    display: flex;
    align-items: center;
    padding: 40px 20px;
    margin: 0 auto;
}

.text-wrapper {
    line-height: 1.8;
    font-size: 18px;
    letter-spacing: 0.5px;
    white-space: pre-wrap;
    word-wrap: break-word;
    text-align: left;
    width: 100%;
    display: block;
}

#letter-text {
    white-space: pre-wrap;
    display: inline;
}

.cursor {
    display: inline-block;
    width: 2px;
    height: 1.2em;
    background-color: #fff;
    margin-left: 2px;
    animation: blink 0.7s infinite;
    vertical-align: text-bottom;
}

.cursor.hide {
    display: none;
}

@keyframes blink {
    0%, 50% {
        opacity: 1;
    }
    51%, 100% {
        opacity: 0;
    }
}

/* Responsive font sizes */
@media (max-width: 768px) {
    .text-wrapper {
        font-size: 16px;
    }
}

@media (max-width: 480px) {
    .text-wrapper {
        font-size: 14px;
    }
}

/* =================================
   IMAGE GALLERY STYLES
   ================================= */
#images-container {
    width: 100%;
    margin-top: 100vh; /* Space after letter */
}

.image-section {
    width: 100%;
    height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 40px;
    transition: opacity 0.3s ease-out;
}

.image-section img {
    max-width: 90%;
    max-height: 90vh;
    width: auto;
    height: auto;
    object-fit: contain;
    display: block;
}

/* Mobile adjustments for images */
@media (max-width: 768px) {
    .image-section {
        padding: 20px;
    }

    .image-section img {
        max-width: 95%;
        max-height: 85vh;
    }
}

/* =================================
   AUDIO CONTROLS STYLES
   ================================= */
.audio-controls {
    position: fixed;
    bottom: 30px;
    right: 30px;
    display: flex;
    align-items: center;
    gap: 15px;
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    padding: 15px 20px;
    border-radius: 50px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
    z-index: 1000;
}

.control-btn {
    background: transparent;
    border: none;
    font-size: 24px;
    cursor: pointer;
    padding: 5px;
    transition: transform 0.2s;
}

.control-btn:hover {
    transform: scale(1.1);
}

#volume-slider {
    width: 100px;
    height: 5px;
    -webkit-appearance: none;
    appearance: none;
    background: rgba(255, 255, 255, 0.3);
    outline: none;
    border-radius: 5px;
    cursor: pointer;
}

#volume-slider::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 15px;
    height: 15px;
    background: #fff;
    cursor: pointer;
    border-radius: 50%;
    transition: transform 0.2s;
}

#volume-slider::-webkit-slider-thumb:hover {
    transform: scale(1.2);
}

#volume-slider::-moz-range-thumb {
    width: 15px;
    height: 15px;
    background: #fff;
    cursor: pointer;
    border-radius: 50%;
    border: none;
    transition: transform 0.2s;
}

#volume-slider::-moz-range-thumb:hover {
    transform: scale(1.2);
}

@media (max-width: 768px) {
    .audio-controls {
        bottom: 20px;
        right: 20px;
        padding: 12px 15px;
        gap: 10px;
    }

    #volume-slider {
        width: 80px;
    }

    .control-btn {
        font-size: 20px;
    }
}
