/* Full width section */
.photo-album {
    padding: 8rem 0 12rem;
    background-color: #f4f4f4;
    text-align: center;
    position: relative;
    max-width: 100%;
    overflow: hidden;
}

/* Container for content that should be centered */
.photo-album .container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 1rem;
    position: relative;
}

/* Section titles */
.photo-album .section-title,
.photo-album .section-subtitle {
    max-width: 800px;
    margin-left: auto;
    margin-right: auto;
    padding: 0 2rem;
}

/* Full width outer container */
.album-outer {
    width: 100%;
    margin: 4rem 0;
    position: relative;
    margin-right: 6rem;
    margin-top: 12rem;
    margin-bottom: 12rem;
}

/* Album container */
.album-container {
    position: relative;
    min-height: 60vh;
    perspective: 2000px;
    width: 100%;
    max-width: 100%;
    padding: 0;
    margin: 0;
    box-sizing: border-box;
}

.album-page {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    min-height: 60vh;
    max-width: 100%;
    box-sizing: border-box;
    display: none;
    justify-content: center;
    align-items: center;
    gap: 4rem;
    padding: 4rem 2rem;
    margin: 0 auto;
    background: #fff;
    opacity: 0;
    transition: transform 0.5s ease, opacity 0.5s ease;
    backface-visibility: hidden;
}

.album-page.active {
    display: flex;
    opacity: 1;
    transform: translateX(0);
    position: relative;
    margin-right: 4rem;
}

/* Slide in/out animations */
.slide-in-right {
    display: flex !important;
    opacity: 0;
    transform: translateX(100%);
    animation: slideInRight 0.5s forwards;
}

.slide-in-left {
    display: flex !important;
    opacity: 0;
    transform: translateX(-100%);
    animation: slideInLeft 0.5s forwards;
}

.slide-out-left {
    display: flex !important;
    opacity: 1;
    animation: slideOutLeft 0.5s forwards;
}

.slide-out-right {
    display: flex !important;
    opacity: 1;
    animation: slideOutRight 0.5s forwards;
}

.polaroid {
    background: white;
    padding: 1.5rem 1.5rem 3rem;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    transform: rotate(-2deg);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    max-width: 400px;
    width: calc(50% - 4rem);
    margin: 0 2rem;
    box-sizing: border-box;
}

.polaroid:nth-child(even) {
    transform: rotate(2deg);
}

.polaroid:hover {
    transform: rotate(0) scale(1.05);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
    z-index: 10;
}

.polaroid img {
    width: 100%;
    height: 300px;
    object-fit: cover;
    display: block;
    margin-bottom: 1.5rem;
    border: 1px solid #eee;
}

.polaroid p {
    font-family: 'Dancing Script', cursive, sans-serif;
    font-size: 1.8rem;
    color: #333;
    margin: 0;
    text-align: center;
}

.album-controls {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 2rem;
    margin-top: 3rem;
    
}

.album-nav {
    background: var(--primary-color);
    color: white;
    border: none;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 2rem;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
}

.album-nav:hover {
    background: var(--accent-color);
    transform: translateY(-2px);
    box-shadow: 0 6px 15px rgba(0, 0, 0, 0.15);
}

.album-nav:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    transform: none;
}

.page-indicator {
    font-size: 1.6rem;
    color: var(--text-color);
    min-width: 120px;
    text-align: center;
}

/* Responsive Adjustments */
/* Responsive styles */
@media (max-width: 1200px) {
    .polaroid {
        max-width: 350px;
    }
}

@media (max-width: 992px) {
    .polaroid {
        width: calc(50% - 2rem);
        margin: 0 1rem;
    }
}

@media (max-width: 768px) {
    .album-page {
        flex-direction: column;
        gap: 3rem;
        padding: 2rem 1rem;
    }
    
    .polaroid {
        width: 100%;
        max-width: 400px;
        margin: 0 auto;
    }
    
    .album-controls {
        margin-top: 2rem;
        padding: 0 1rem;
    }
    
    .album-nav {
        width: 40px;
        height: 40px;
        font-size: 1.6rem;
    }
    
    .page-indicator {
        font-size: 1.4rem;
    }
}

@media (max-width: 480px) {
    .photo-album {
        padding: 4rem 0;
    }
    
    .album-page {
        padding: 1rem 0.5rem;
    }
    
    .polaroid {
        padding: 1rem 1rem 2rem;
    }
    
    .polaroid img {
        height: 250px;
    }
}

/* Slide animations */
@keyframes slideInRight {
    from {
        transform: translateX(100%);
        opacity: 0;
    }
    to {
        transform: translateX(0);
        opacity: 1;
    }
}

@keyframes slideInLeft {
    from {
        transform: translateX(-100%);
        opacity: 0;
    }
    to {
        transform: translateX(0);
        opacity: 1;
    }
}

@keyframes slideOutLeft {
    from {
        transform: translateX(0);
        opacity: 1;
    }
    to {
        transform: translateX(-100%);
        opacity: 0;
    }
}

@keyframes slideOutRight {
    from {
        transform: translateX(0);
        opacity: 1;
    }
    to {
        transform: translateX(100%);
        opacity: 0;
    }
}

/* Add a subtle paper texture to the album pages */
.album-page::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('data:image/svg+xml;utf8,<svg width="100" height="100" viewBox="0 0 100 100" xmlns="http://www.w3.org/2000/svg"><path d="M0 0h100v100H0z" fill="none"/><path d="M20 20h60v60H20z" stroke="%23eee" stroke-width="0.5" fill="none"/></svg>');
    opacity: 0.3;
    pointer-events: none;
    z-index: -1;
    border-radius: 8px;
}
