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

body {
    background-color: #f4f1ea;
    /* Soft paper texture effect */
    background-image: radial-gradient(#d5d2cc 1px, transparent 1px);
    background-size: 20px 20px;
    color: #4a4a4a;
    font-family: 'Karla', sans-serif;
    overflow-x: hidden;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

h1, h2, h3, .caption {
    font-family: 'Caveat', cursive;
}

/* Audio Control */
.audio-control {
    position: fixed;
    top: 20px;
    right: 20px;
    background: rgba(255, 255, 255, 0.8);
    backdrop-filter: blur(5px);
    padding: 10px 15px;
    border-radius: 30px;
    box-shadow: 0 4px 6px rgba(0,0,0,0.1);
    display: flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
    z-index: 100;
    transition: transform 0.3s ease;
}

.audio-control:hover {
    transform: scale(1.05);
}

.audio-control .icon {
    font-size: 1.2rem;
}

.audio-control .text {
    font-weight: 700;
    font-size: 0.9rem;
    color: #a67c52;
}

/* Header */
header {
    text-align: center;
    padding: 60px 20px 20px;
}

header h1 {
    font-size: 3.5rem;
    color: #8b5a2b;
    margin-bottom: 10px;
    text-shadow: 1px 1px 2px rgba(0,0,0,0.1);
}

header .subtitle {
    font-size: 1.1rem;
    letter-spacing: 1px;
    color: #a67c52;
}

/* Quotes Section */
.quotes-section {
    width: 100%;
    max-width: 600px;
    margin: 30px auto;
    text-align: center;
    min-height: 80px;
    display: flex;
    justify-content: center;
    align-items: center;
}

.quote-text {
    font-family: 'Caveat', cursive;
    font-size: 1.8rem;
    color: #6a4a3a;
    opacity: 0;
    transition: opacity 1.5s ease-in-out;
}

.quote-text.visible {
    opacity: 1;
}

/* Gallery Section */
.gallery-section {
    flex-grow: 1;
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 60px 20px;
}

.polaroid-gallery {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 40px;
    max-width: 1000px;
}

.polaroid {
    position: relative;
    width: 250px;
    background: #fff;
    padding: 15px 15px 40px 15px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.15);
    border: 1px solid #e0e0e0;
    transform: rotate(var(--rotation));
    transition: transform 0.4s ease-out, box-shadow 0.4s ease, z-index 0s;
    transform-origin: center center;
    cursor: pointer;
    z-index: 1;
}

.polaroid-img-wrapper {
    width: 100%;
    height: 200px;
    overflow: hidden;
    background: #000;
}

.polaroid-img-wrapper img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    filter: sepia(30%) contrast(1.1);
    transition: filter 0.4s ease;
}

.polaroid .caption {
    text-align: center;
    font-size: 1.8rem;
    color: #333;
    margin-top: 15px;
}

/* Hover Effects */
.polaroid:hover {
    transform: rotate(0deg) scale(1.1);
    box-shadow: 0 15px 30px rgba(0,0,0,0.3);
    z-index: 10 !important;
}

.polaroid:hover .polaroid-img-wrapper img {
    filter: sepia(0%) contrast(1);
}

/* Response Section */
.response-section {
    background: #fff;
    max-width: 600px;
    margin: 60px auto;
    padding: 40px;
    border-radius: 8px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.05);
    text-align: center;
    border: 1px dashed #d5d2cc;
}

.response-section h2 {
    font-size: 2.5rem;
    color: #8b5a2b;
    margin-bottom: 20px;
}

.response-form {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.input-group input, 
.input-group textarea {
    width: 100%;
    padding: 15px;
    border: 1px solid #e0e0e0;
    border-radius: 4px;
    background: #faf9f6;
    font-family: 'Karla', sans-serif;
    font-size: 1rem;
    color: #4a4a4a;
    transition: border-color 0.3s ease;
}

.input-group input:focus, 
.input-group textarea:focus {
    outline: none;
    border-color: #a67c52;
    background: #fff;
}

.submit-btn {
    background: #8b5a2b;
    color: #fff;
    border: none;
    padding: 15px;
    font-family: 'Karla', sans-serif;
    font-size: 1.1rem;
    font-weight: 700;
    border-radius: 4px;
    cursor: pointer;
    transition: background 0.3s ease, transform 0.2s ease;
}

.submit-btn:hover {
    background: #6a4a3a;
    transform: translateY(-2px);
}

.success-msg {
    margin-top: 20px;
    color: #4caf50;
    font-weight: 700;
}

.hidden {
    display: none;
}

/* Responsive */
@media screen and (max-width: 480px) {
    header h1 {
        font-size: 2.8rem;
    }
    
    .polaroid-gallery {
        gap: 30px;
    }
    
    .polaroid {
        width: 280px;
    }
    
    .polaroid-img-wrapper {
        height: 230px;
    }
    
    .response-section {
        margin: 40px 20px;
        padding: 30px 20px;
    }
}
