html {
    font-size: 14px;
}

@media (min-width: 768px) {
    html {
        font-size: 16px;
    }
}

body {
    background-color: #f5f2ee;
    color: #2c2c2c;
    font-family: Georgia, 'Times New Roman', serif;
    margin-bottom: 0;
}

/* Nav */
.gallery-nav {
    background-color: #fff;
    border-bottom: 1px solid #ddd;
    padding: 0.75rem 0;
}

.gallery-brand {
    font-size: 1.5rem;
    font-style: italic;
    color: #3a3a3a !important;
    letter-spacing: 0.02em;
}

.gallery-nav .nav-link {
    color: #555 !important;
    font-size: 0.95rem;
    padding: 0.4rem 1rem;
    transition: color 0.2s;
}

.gallery-nav .nav-link:hover {
    color: #222 !important;
}

/* Footer */
.gallery-footer {
    background-color: #fff;
    border-top: 1px solid #ddd;
    padding: 1.25rem 0;
    font-size: 0.875rem;
    color: #888;
    margin-top: 3rem;
}

/* Home page hero */
.gallery-hero {
    text-align: center;
    padding: 4rem 1rem 3rem;
}

.gallery-hero h1 {
    font-size: 3rem;
    font-style: italic;
    color: #3a3a3a;
    margin-bottom: 0.5rem;
}

.gallery-hero p {
    color: #777;
    font-size: 1.1rem;
    margin-bottom: 2.5rem;
}

/* Album cards on home page */
.album-card {
    background: #fff;
    border: 1px solid #e0dbd4;
    border-radius: 4px;
    overflow: hidden;
    transition: box-shadow 0.2s, transform 0.2s;
    text-decoration: none;
    color: inherit;
    display: block;
}

.album-card:hover {
    box-shadow: 0 6px 24px rgba(0,0,0,0.10);
    transform: translateY(-3px);
    color: inherit;
    text-decoration: none;
}

.album-card-thumb {
    width: 100%;
    height: 220px;
    object-fit: cover;
    display: block;
}

.album-card-body {
    padding: 1rem 1.25rem;
}

.album-card-title {
    font-size: 1.15rem;
    font-style: italic;
    color: #3a3a3a;
    margin-bottom: 0.25rem;
}

.album-card-count {
    font-size: 0.85rem;
    color: #999;
    font-family: Arial, sans-serif;
}

/* Album page */
.album-header {
    padding: 2.5rem 0 1.5rem;
    text-align: center;
}

.album-header h1 {
    font-style: italic;
    color: #3a3a3a;
    font-size: 2.25rem;
}

.album-header p {
    color: #999;
    font-size: 0.9rem;
    font-family: Arial, sans-serif;
}

/* Thumbnail grid */
.gallery-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
    gap: 10px;
    padding: 0 0 2rem;
}

.gallery-thumb-wrap {
    overflow: hidden;
    border-radius: 3px;
    background: #e8e4df;
    cursor: pointer;
    aspect-ratio: 1;
}

.gallery-thumb-wrap img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform 0.3s, opacity 0.3s;
}

.gallery-thumb-wrap:hover img {
    transform: scale(1.04);
    opacity: 0.9;
}

/* Lightbox */
.lightbox-overlay {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.92);
    z-index: 1050;
    align-items: center;
    justify-content: center;
}

.lightbox-overlay.active {
    display: flex;
}

.lightbox-img {
    max-width: 90vw;
    max-height: 90vh;
    object-fit: contain;
    border-radius: 2px;
    box-shadow: 0 8px 40px rgba(0,0,0,0.5);
}

.lightbox-close {
    position: fixed;
    top: 1.25rem;
    right: 1.5rem;
    color: #fff;
    font-size: 2rem;
    cursor: pointer;
    line-height: 1;
    opacity: 0.8;
    background: none;
    border: none;
    padding: 0;
}

.lightbox-close:hover {
    opacity: 1;
}

.lightbox-prev,
.lightbox-next {
    position: fixed;
    top: 50%;
    transform: translateY(-50%);
    color: #fff;
    font-size: 2.5rem;
    cursor: pointer;
    opacity: 0.6;
    background: none;
    border: none;
    padding: 0 1rem;
    line-height: 1;
}

.lightbox-prev:hover,
.lightbox-next:hover {
    opacity: 1;
}

.lightbox-prev { left: 0.5rem; }
.lightbox-next { right: 0.5rem; }

.lightbox-counter {
    position: fixed;
    bottom: 1.25rem;
    left: 50%;
    transform: translateX(-50%);
    color: rgba(255,255,255,0.6);
    font-size: 0.85rem;
    font-family: Arial, sans-serif;
}
