/**
 * Focus on Photography - Gallery Styles
 *
 * Styles for masonry and slideshow gallery displays.
 *
 * @package FocusOnPhotography
 * @since 1.0.0
 */

/* ==========================================================================
   CSS Custom Properties
   ========================================================================== */

:root {
    --fop-gold: #FFD700;
    --fop-grey-light: #f5f5f5;
    --fop-grey-dark: #333;
    --fop-success: #4CAF50;
    --fop-primary: #2196F3;
    --fop-card-radius: 12px;
    --fop-gutter: 16px;
    --fop-font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;

    /* Theme variables (light theme default - no system preference detection) */
    color-scheme: light;
    --fop-bg: #ffffff;
    --fop-text: #1a1a1a;
    --fop-muted: #555555;
    --fop-border: #e0e0e0;
    --fop-surface-1: #ffffff;
    --fop-surface-2: #f8f9fa;
    /* Card variant palettes (light) */
    --fop-quote-bg-start: #e8f4ff;
    --fop-quote-bg-end: #dbeafe;
    --fop-quote-border: #2196F3;
    --fop-week-bg-start: #f0fdf4;
    --fop-week-bg-end: #dcfce7;
    --fop-week-border: #34a853;
}

/* Dark mode variable overrides (html.dark is applied early) */
:root.dark {
    color-scheme: dark;
    --fop-bg: #121212;              /* not pure black */
    --fop-text: #f3f4f6;            /* near-white for readability */
    --fop-muted: #cfcfcf;           /* muted body text */
    --fop-border: #3a3a3a;          /* subtle borders */
    --fop-surface-1: #1e1e1e;       /* base card surface */
    --fop-surface-2: #232323;       /* elevated surface */
    /* Desaturated accents for dark mode */
    --fop-quote-bg-start: #1f2937;  /* slate-800 */
    --fop-quote-bg-end: #111827;    /* slate-900 */
    --fop-quote-border: #4c82b8;    /* desaturated primary */
    --fop-week-bg-start: #0f2f1a;   /* deep green tint */
    --fop-week-bg-end: #0b2415;     /* darker variant */
    --fop-week-border: #2d7a45;     /* desaturated green */
}

/* ==========================================================================
   Gallery Wrapper
   ========================================================================== */

.fop-gallery-wrapper {
    font-family: var(--fop-font-family);
    padding: 20px 0;
}

.fop-gallery-empty {
    text-align: center;
    padding: 60px 20px;
}

.fop-no-photos {
    font-size: 18px;
    color: #888;
    margin: 0;
}

/* ==========================================================================
   Student Sections
   ========================================================================== */

.fop-student-section {
    margin-bottom: 48px;
}

.fop-student-section:last-child {
    margin-bottom: 0;
}

.fop-student-header {
    margin-bottom: 20px;
}

.fop-student-name {
    font-size: 24px;
    font-weight: 700;
    color: var(--fop-grey-dark);
    margin: 0 0 8px 0;
    padding-bottom: 8px;
    border-bottom: 3px solid var(--fop-gold);
    display: inline-block;
}

.fop-student-quote {
    font-size: 14px;
    color: #666;
    font-style: italic;
    margin: 8px 0 0 0;
    line-height: 1.5;
    max-width: 600px;
}

.fop-student-quote .quote-attribution {
    display: inline-block;
    font-style: normal;
    color: #888;
    font-size: 13px;
    margin-left: 4px;
}

/* ==========================================================================
   Masonry Grid - Responsive Columns
   Respects data-columns attribute (2, 3, or 4) set via Settings > Gallery
   ========================================================================== */

.fop-masonry-grid {
    display: flex;
    flex-wrap: wrap;
    margin: 0 calc(var(--fop-gutter) / -2);
}

/* Photo card sizing for responsive columns */
.fop-photo-card {
    box-sizing: border-box;
    padding: calc(var(--fop-gutter) / 2) calc(var(--fop-gutter) / 2) 0 calc(var(--fop-gutter) / 2);
}

/* Desktop: Use column count from data-columns attribute */
@media screen and (min-width: 1200px) {
    /* Default: 3 columns (33.333%) */
    .fop-photo-card {
        width: 33.333%;
    }
    
    /* 2 columns (50%) */
    .fop-masonry-gallery[data-columns="2"] .fop-photo-card {
        width: 50%;
    }
    
    /* 3 columns (33.333%) - explicit for clarity */
    .fop-masonry-gallery[data-columns="3"] .fop-photo-card {
        width: 33.333%;
    }
    
    /* 4 columns (25%) */
    .fop-masonry-gallery[data-columns="4"] .fop-photo-card {
        width: 25%;
    }
}

/* Desktop (smaller): Cap at 3 columns max */
@media screen and (min-width: 768px) and (max-width: 1199px) {
    /* Default: 3 columns */
    .fop-photo-card {
        width: 33.333%;
    }
    
    /* 2 columns stays at 2 */
    .fop-masonry-gallery[data-columns="2"] .fop-photo-card {
        width: 50%;
    }
    
    /* 3 and 4 columns both become 3 at this breakpoint */
    .fop-masonry-gallery[data-columns="3"] .fop-photo-card,
    .fop-masonry-gallery[data-columns="4"] .fop-photo-card {
        width: 33.333%;
    }
}

/* Tablet: 2 columns */
@media screen and (min-width: 480px) and (max-width: 767px) {
    .fop-photo-card {
        width: 50%;
    }
}

/* Mobile: 1 column */
@media screen and (max-width: 479px) {
    .fop-photo-card {
        width: 100%;
    }
    
    .fop-masonry-grid {
        margin: 0;
    }
    
    .fop-photo-card {
        padding: 0;
    }
}

/* Grid loading state */
.fop-masonry-grid:not(.masonry-initialized) {
    opacity: 0.5;
}

.fop-masonry-grid.masonry-initialized {
    opacity: 1;
    transition: opacity 0.3s ease;
}

/* ==========================================================================
   Photo Card Base
   ========================================================================== */

.fop-photo-card-inner {
    background: var(--fop-surface-1);
    border: 1px solid var(--fop-border);
    border-radius: var(--fop-card-radius);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
    overflow: hidden;
    transition: transform 0.2s, box-shadow 0.2s;
    display: flex;
    flex-direction: column;
}

.fop-photo-card-inner:hover {
    transform: none;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

/* Photo Thumbnail */
.fop-photo-thumbnail {
    position: relative;
    overflow: hidden;
    background: var(--fop-surface-2);
}

.fop-photo-thumbnail img {
    display: block;
    width: 100%;
    height: auto;
    transition: transform 0.3s ease;
}

.fop-photo-card-inner:hover .fop-photo-thumbnail img {
    transform: none;
}

/* Photo Info */
.fop-photo-info {
    padding: 12px 14px;
}

.fop-photo-title {
    font-size: 15px;
    font-weight: 600;
    color: var(--fop-grey-dark);
    margin: 0 0 4px 0;
    line-height: 1.3;
}

.fop-photo-caption {
    font-size: 13px;
    color: #666;
    margin: 0;
    line-height: 1.4;
    /* Reserve consistent space to align card bottoms across a row */
    height: calc(1.4em * 2); /* clamp to 2 lines */
    overflow: hidden;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
}

/* View Photo button removed from gallery markup; strip unused styles */

/* Hover effects removed */

/* Read-only Sticker Display (Gallery Cards) */
.fop-sticker-tray-readonly {
    display: flex;
    flex-wrap: wrap;
    justify-content: flex-start !important;
    gap: 2px;
    margin: 8px 0 0 0; /* No bottom margin to eliminate gap */
    padding: 8px;
    background: #f9f9f9;
    border-radius: 8px;
    min-height: auto;
    align-items: center;
    text-align: left;
}

.fop-sticker-readonly {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    margin: 0;
    padding: 4px;
    background: transparent !important;
    border-radius: 20px;
    font-size: 14px;
    flex-shrink: 0;
}

.fop-sticker-readonly .fop-sticker-emoji {
    font-size: 18px;
}

.fop-sticker-readonly .fop-sticker-count {
    font-size: 12px;
    font-weight: 700;
    color: var(--fop-grey-dark);
    background: #fff;
    border-radius: 50%;
    min-width: 20px;
    height: 20px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.fop-sticker-empty-message {
    font-size: 13px;
    color: var(--fop-blue);
    font-style: normal;
    background: #e3f2fd;
    padding: 8px 14px;
    border-radius: 20px;
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

.fop-sticker-empty-message::before {
    content: '✨';
}

/* ==========================================================================
   Student's Choice (Featured) Styling
   ========================================================================== */

.fop-photo-card.is-featured .fop-photo-card-inner {
    border: 4px solid var(--fop-gold);
    border-radius: 12px;
}

.fop-photo-thumbnail {
    position: relative;
}

.fop-badge {
    position: absolute;
    top: 10px;
    right: 10px;
    padding: 5px 12px;
    border-radius: 20px;
    font-size: 13px;
    font-weight: 600;
    z-index: 2;
    pointer-events: none;
}

.fop-badge-featured {
    background: var(--fop-gold);
    color: var(--fop-grey-dark);
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.15);
}

.fop-badge-challenge {
    background: #e74c3c;
    color: #fff;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.15);
}

/* Position challenge badge below featured if both exist */
.fop-photo-card.is-featured .fop-badge-challenge {
    top: 46px;
}

/* Teacher Toggle Featured Button */
.fop-teacher-toggle-featured {
    position: absolute;
    bottom: 10px;
    left: 10px;
    padding: 5px;
    border-radius: 16px;
    font-size: 12px;
    font-weight: 600;
    background: rgba(255, 255, 255, 0.95);
    border: 2px solid var(--fop-gold);
    color: var(--fop-grey-dark);
    cursor: pointer;
    z-index: 3;
    transition: all 0.2s ease;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.15);
}

.fop-teacher-toggle-featured:hover {
    background: rgba(255, 255, 255, 0.95);
    transform: none;
}

.fop-teacher-toggle-featured:active {
    transform: none;
}

.fop-teacher-toggle-featured.is-processing {
    opacity: 0.6;
    pointer-events: none;
}

/* Teacher toggle in slideshow */
.fop-slide-badges .fop-teacher-toggle-featured {
    position: relative;
    bottom: auto;
    left: auto;
    margin-left: 10px;
}

/* View button (pill) - right justified */
.fop-view-btn {
    position: absolute;
    bottom: 10px;
    right: 10px;
    padding: 5px 10px;
    border-radius: 16px;
    font-size: 12px;
    font-weight: 600;
    color: #fff;
    background: #0D47A1; /* dark blue */
    border: 2px solid #0D47A1;
    cursor: pointer;
    z-index: 3;
    transition: background 0.2s ease, color 0.2s ease;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.15);
}

.fop-view-btn:hover,
.fop-view-btn:active {
    background: #0B3D91; /* slightly darker on hover/active */
    color: #fff;
}

/* ==========================================================================
   Tech Specs Tooltip
   ========================================================================== */

.fop-tech-specs {
    position: relative;
    padding: 8px 14px 12px;
    border-top: 1px solid #eee;
}

.fop-tech-specs-toggle {
    background: none;
    border: none;
    padding: 4px 8px;
    cursor: pointer;
    font-size: 18px;
    opacity: 0.6;
    transition: opacity 0.2s;
    min-height: 44px;
    min-width: 44px;
}

.fop-tech-specs-toggle:hover,
.fop-tech-specs-toggle:focus {
    opacity: 1;
}

.fop-tech-specs-tooltip {
    display: none;
    position: absolute;
    bottom: 100%;
    left: 10px;
    background: var(--fop-grey-dark);
    color: #fff;
    padding: 10px 14px;
    border-radius: 8px;
    font-size: 13px;
    min-width: 160px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
    z-index: 10;
}

.fop-tech-specs-tooltip::after {
    content: '';
    position: absolute;
    top: 100%;
    left: 20px;
    border: 8px solid transparent;
    border-top-color: var(--fop-grey-dark);
}

.fop-tech-specs-toggle:hover + .fop-tech-specs-tooltip,
.fop-tech-specs-toggle:focus + .fop-tech-specs-tooltip,
.fop-tech-specs-tooltip:hover,
.fop-tech-specs-tooltip.is-visible {
    display: block;
}

.fop-spec-row {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 3px 0;
}

.fop-spec-label {
    font-weight: 600;
    min-width: 32px;
}

.fop-spec-value {
    color: #ccc;
}

/* ==========================================================================
   Sticker Tray
   ========================================================================== */

.fop-sticker-tray {
    display: flex;
    flex-wrap: wrap;
    justify-content: flex-start;
    gap: 4px;
    padding: 10px 8px;
    border-top: 1px solid #eee;
    background: var(--fop-grey-light);
    border-radius: 0 0 8px 8px;
    margin-top: auto; /* Anchor tray to bottom of card */
}

/* Hide comments section in gallery cards to avoid bottom whitespace */
.fop-photo-card-inner .fop-comments-section {
    display: none;
    height: 0;
    padding: 0;
    border-top: none;
}

.fop-sticker-btn {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 2px;
    background: none;
    border: none;
    padding: 4px 6px;
    cursor: pointer;
    min-height: 40px;
    min-width: 36px;
    border-radius: 8px;
    transition: transform 0.2s, background 0.2s;
}

.fop-sticker-btn:hover,
.fop-sticker-btn:focus {
    background: none;
}

.fop-sticker-btn:active {
    transform: none;
}

.fop-sticker-emoji {
    font-size: 24px;
    filter: none !important;
    transition: filter 0.2s, transform 0.2s;
}

/* Ensure WordPress emoji images are also colorful */
.fop-sticker-emoji img.emoji {
    filter: none !important;
    -webkit-filter: none !important;
}

.fop-sticker-btn:hover .fop-sticker-emoji,
.fop-sticker-btn:focus .fop-sticker-emoji {
    filter: none;
    transform: none;
}

/* Bounce animation removed */

.fop-sticker-count {
    font-size: 11px;
    color: #666;
    font-weight: 600;
    min-height: 14px;
    transition: transform 0.15s ease;
}

/* Pop animation when count updates */
.fop-sticker-count.is-updated {
    transform: scale(1.4);
    color: var(--fop-gold);
}


/* ==========================================================================
   Comments Section
   ========================================================================== */

.fop-comments-section {
    padding: 10px 14px 14px;
    border-top: 1px solid #eee;
}

.fop-comments-list {
    max-height: 120px;
    overflow-y: auto;
    margin-bottom: 10px;
}

.fop-comment {
    font-size: 13px;
    line-height: 1.4;
    padding: 4px 0;
    border-bottom: 1px solid #f0f0f0;
}

.fop-comment:last-child {
    border-bottom: none;
}

.fop-comment-author {
    font-weight: 600;
    color: var(--fop-grey-dark);
    margin-right: 4px;
}

.fop-comment-text {
    color: #555;
}

.fop-comment-form {
    margin: 0;
}

.fop-comment-name-row {
    display: flex;
    gap: 8px;
    margin-bottom: 8px;
}

.fop-comment-name-select {
    flex: 1;
    padding: 8px 12px;
    border: 1px solid #ddd;
    border-radius: 8px;
    font-size: 14px;
    min-height: 44px;
    background: #fff;
    cursor: pointer;
    outline: none;
    transition: border-color 0.2s;
}

.fop-comment-name-select:focus {
    border-color: var(--fop-gold);
}

.fop-comment-name-input {
    flex: 1;
    padding: 8px 12px;
    border: 1px solid #ddd;
    border-radius: 8px;
    font-size: 14px;
    min-height: 44px;
    outline: none;
    transition: border-color 0.2s;
}

.fop-comment-name-input:focus {
    border-color: var(--fop-gold);
}

.fop-comment-identity-lock {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 12px;
    margin-bottom: 10px;
    border: 1px dashed #d9d9d9;
    border-radius: 12px;
    background: #f8f8f8;
    color: var(--fop-grey-dark);
    font-size: 14px;
}

.fop-comment-identity-lock-icon {
    font-size: 18px;
}

.fop-comment-input-row {
    display: flex;
    gap: 8px;
}

.fop-comment-input {
    flex: 1;
    padding: 10px 12px;
    border: 1px solid #ddd;
    border-radius: 20px;
    font-size: 14px;
    min-height: 44px;
    outline: none;
    transition: border-color 0.2s;
}

.fop-comment-input:focus {
    border-color: var(--fop-gold);
}

.fop-comment-submit {
    background: var(--fop-grey-dark);
    color: #fff;
    border: none;
    border-radius: 50%;
    width: 44px;
    height: 44px;
    font-size: 18px;
    cursor: pointer;
    transition: background 0.2s, transform 0.2s;
    display: flex;
    align-items: center;
    justify-content: center;
}

.fop-comment-submit:hover,
.fop-comment-submit:focus {
    background: #555;
    transform: scale(1.05);
}

.fop-comment-submit:active {
    transform: scale(0.95);
}

/* New comment animation */
.fop-comment.is-new {
    background: rgba(255, 215, 0, 0.2);
    animation: fop-comment-fade-in 0.3s ease;
}

@keyframes fop-comment-fade-in {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* ==========================================================================
   Challenge Card (Week's Challenge Display)
   ========================================================================== */

.fop-challenge-card {
    margin-bottom: 32px;
    width: 100%;
}

/* Styled challenge card (yellow box with icon) - used in gallery header */
.fop-challenge-card.fop-challenge-card-styled {
    background: transparent;
    border: none;
    box-shadow: none;
    padding: 0;
}

.fop-challenge-card-inner {
    display: flex;
    align-items: flex-start;
    gap: 16px;
    background: linear-gradient(135deg, #fff9e6 0%, #fff3cc 100%);
    border: 2px solid var(--fop-gold);
    border-radius: 16px;
    padding: 20px 24px;
    box-shadow: 0 4px 12px rgba(255, 215, 0, 0.15);
}

.fop-challenge-icon {
    font-size: 40px;
    line-height: 1;
    flex-shrink: 0;
}

.fop-challenge-content {
    flex: 1;
}

/* "This Week's Challenge" label */
.fop-challenge-label {
    font-size: 12px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: #b8860b;
    margin: 0 0 6px 0;
}

/* Challenge title - bold and prominent */
.fop-challenge-title {
    font-size: 18px;
    font-weight: 700;
    line-height: 1.3;
    color: var(--fop-grey-dark);
    margin: 0 0 8px 0;
}

/* Challenge description */
.fop-challenge-description {
    font-size: 15px;
    line-height: 1.5;
    color: #555;
    margin: 0 0 10px 0;
}

/* Legacy class - kept for compatibility */
.fop-challenge-text {
    font-size: 17px;
    line-height: 1.5;
    color: var(--fop-grey-dark);
    margin: 0;
}

/* Practice and Difficulty metadata row */
.fop-challenge-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    font-size: 13px;
    color: #777;
    margin-top: 4px;
}

.fop-challenge-practice,
.fop-challenge-difficulty {
    display: inline-flex;
    align-items: center;
    background: rgba(0, 0, 0, 0.05);
    padding: 4px 10px;
    border-radius: 12px;
}

@media screen and (max-width: 767px) {
    .fop-challenge-card-inner {
        padding: 16px 18px;
    }
    
    .fop-challenge-icon {
        font-size: 32px;
    }
    
    .fop-challenge-title {
        font-size: 16px;
    }
    
    .fop-challenge-description,
    .fop-challenge-text {
        font-size: 14px;
    }
    
    .fop-challenge-meta {
        flex-direction: column;
        gap: 6px;
    }
}

/* ==========================================================================
   Slideshow Layout - Main Display Area
   ========================================================================== */

/* ==========================================================================
   Info Cards for Quote and Week (match Challenge aesthetics)
   ==========================================================================
*/

.fop-info-card {
    margin-bottom: 24px;
    width: 100%;
}

.fop-info-card-inner {
    display: flex;
    align-items: flex-start;
    gap: 16px;
    border: 2px solid transparent;
    border-radius: 16px;
    padding: 18px 22px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.06);
}

.fop-info-icon {
    font-size: 36px;
    line-height: 1;
    flex-shrink: 0;
}

.fop-info-content {
    flex: 1;
}

/* Quote card (soft blue) */
.fop-quote-card .fop-info-card-inner {
    background: linear-gradient(135deg, var(--fop-quote-bg-start) 0%, var(--fop-quote-bg-end) 100%);
    border-color: var(--fop-quote-border);
    box-shadow: 0 4px 12px rgba(33,150,243,0.12);
}

.fop-quote-card .fop-quote-of-day-text {
    margin: 0;
    text-align: left;
    color: var(--fop-text);
}

/* Week card (soft green) */
.fop-week-card .fop-info-card-inner {
    background: linear-gradient(135deg, var(--fop-week-bg-start) 0%, var(--fop-week-bg-end) 100%);
    border-color: var(--fop-week-border);
    box-shadow: 0 4px 12px rgba(52,168,83,0.12);
}

.fop-week-title {
    font-size: 16px;
    font-weight: 700;
    color: var(--fop-text);
    margin: 0 0 6px 0;
}

.fop-week-description {
    font-size: 15px;
    margin: 0;
    color: var(--fop-muted);
    line-height: 1.5;
}

@media screen and (max-width: 767px) {
    .fop-info-card-inner {
        padding: 16px 18px;
    }
    .fop-info-icon {
        font-size: 30px;
    }
    .fop-week-title {
        font-size: 15px;
    }
    .fop-week-description {
        font-size: 14px;
    }
}

/* ==========================================================================
   Week Timeline
   ========================================================================== */

.fop-week-timeline {
    margin: 20px auto 24px;
    max-width: 800px;
    padding: 0 16px;
}

.fop-week-timeline-track {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    position: relative;
}

.fop-week-timeline-node {
    display: flex;
    flex-direction: column;
    align-items: center;
    flex: 1;
    position: relative;
    cursor: pointer;
    transition: transform 0.2s ease;
}

.fop-week-timeline-node:hover {
    transform: translateY(-2px);
}

.fop-week-timeline-connector {
    position: absolute;
    top: 15px;
    right: 50%;
    width: 100%;
    height: 3px;
    background: #dcdcde;
    z-index: 0;
}

.fop-week-timeline-connector.filled {
    background: #8c8f94;
}

.fop-week-timeline-circle {
    width: 30px;
    height: 30px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
    font-size: 13px;
    position: relative;
    z-index: 1;
    transition: all 0.2s ease;
    border: 3px solid;
}

/* Completed week state */
.fop-week-timeline-node.completed .fop-week-timeline-circle {
    background: #c3c4c7;
    border-color: #8c8f94;
    color: #50575e;
}

.fop-week-check {
    font-size: 14px;
    font-weight: bold;
}

/* Current week state */
.fop-week-timeline-node.current .fop-week-timeline-circle {
    background: #00a32a;
    border-color: #00a32a;
    color: #fff;
    box-shadow: 0 0 0 2px #fff, 0 0 0 4px #00a32a;
}

/* Upcoming week state */
.fop-week-timeline-node.upcoming .fop-week-timeline-circle {
    background: #fff;
    border-color: #c3c4c7;
    color: #50575e;
}

.fop-week-timeline-label {
    margin-top: 8px;
    font-size: 11px;
    text-align: center;
    max-width: 70px;
    line-height: 1.3;
    color: #666;
    word-wrap: break-word;
}

.fop-week-timeline-node.current .fop-week-timeline-label {
    font-weight: 600;
    color: #00a32a;
}

.fop-week-timeline-node.completed .fop-week-timeline-label {
    color: #50575e;
}

/* Week Timeline Collapsible Toggle (hidden on desktop) */
.fop-week-timeline-toggle {
    display: none;
    width: 100%;
    padding: 12px 16px;
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
    border: 2px solid #c3c4c7;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 600;
    color: #50575e;
    cursor: pointer;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    transition: all 0.2s ease;
}

.fop-week-timeline-toggle:hover {
    border-color: #00a32a;
    color: #00a32a;
}

.fop-timeline-toggle-icon {
    font-size: 16px;
}

.fop-timeline-toggle-text {
    flex: 1;
    text-align: left;
}

.fop-timeline-toggle-arrow {
    font-size: 10px;
    transition: transform 0.2s ease;
}

.fop-week-timeline.is-expanded .fop-timeline-toggle-arrow {
    transform: rotate(180deg);
}

/* Week Timeline Responsive - Tablet */
@media (max-width: 900px) {
    .fop-week-timeline {
        position: relative;
    }

    .fop-week-timeline-toggle {
        display: flex;
    }

    .fop-week-timeline-track {
        display: none;
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        z-index: 10;
        background: #fff;
        border: 2px solid #c3c4c7;
        border-top: none;
        border-radius: 0 0 8px 8px;
        padding: 16px;
        box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
        flex-wrap: wrap;
        justify-content: center;
        gap: 8px;
    }

    .fop-week-timeline.is-expanded .fop-week-timeline-track {
        display: flex;
    }

    .fop-week-timeline-node {
        flex: 0 0 auto;
        min-width: 65px;
    }

    .fop-week-timeline-connector {
        display: none;
    }
}

/* Week Timeline Responsive - Mobile */
@media (max-width: 600px) {
    .fop-week-timeline {
        padding: 0 8px;
    }

    .fop-week-timeline-toggle {
        padding: 10px 12px;
        font-size: 13px;
    }

    .fop-week-timeline-track {
        padding: 12px;
        gap: 6px;
    }

    .fop-week-timeline-node {
        min-width: 55px;
    }

    .fop-week-timeline-circle {
        width: 28px;
        height: 28px;
        font-size: 11px;
    }

    .fop-week-timeline-label {
        font-size: 10px;
        max-width: 50px;
    }
}

/* Week Timeline Filter State */
.fop-week-timeline-node.is-filtered .fop-week-timeline-circle {
    box-shadow: 0 0 0 4px rgba(255, 152, 0, 0.4);
    border-color: #ff9800;
}

.fop-week-timeline-node.is-filtered .fop-week-timeline-label {
    color: #ff9800;
    font-weight: 600;
}

/* Show All Weeks Button */
.fop-show-all-weeks-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    margin: 12px auto 0;
    padding: 8px 16px;
    background: #fff;
    border: 2px solid #ff9800;
    border-radius: 20px;
    color: #ff9800;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
}

.fop-show-all-weeks-btn:hover {
    background: #ff9800;
    color: #fff;
}

.fop-show-all-weeks-btn .fop-show-all-icon {
    font-size: 14px;
}

.fop-slideshow-gallery {
    display: flex;
    flex-wrap: wrap;
    gap: 24px;
    max-width: 1200px;
    width: 100%;
    margin: 0 auto 40px auto;
    padding: 0 20px;
    align-items: flex-start;
}

/* Student filter in Photo Details panel */
.fop-photo-details-student-filter {
    border-top: 1px solid #e5e7eb;
    padding-top: 1.25rem;
    margin-top: 1.25rem;
}

.fop-student-filter-wrapper {
    position: relative;
    margin-top: 0.5rem;
}

.fop-student-filter-toggle {
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: space-between;
    border-radius: 8px;
    border: 1px solid #cfd4df;
    padding: 10px 12px;
    font-size: 14px;
    font-weight: 500;
    background: #fff;
    color: var(--fop-grey-dark);
    cursor: pointer;
    transition: border-color 0.2s, box-shadow 0.2s;
}

.fop-student-filter-toggle:hover {
    border-color: #999;
}

.fop-student-filter-toggle:focus {
    outline: none;
    border-color: var(--fop-gold);
    box-shadow: 0 0 0 3px rgba(255, 196, 0, 0.25);
}

.fop-student-filter-toggle[aria-expanded="true"] .fop-filter-arrow {
    transform: rotate(180deg);
}

.fop-filter-arrow {
    transition: transform 0.2s;
    font-size: 12px;
}

.fop-student-filter-dropdown {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    margin-top: 4px;
    background: #fff;
    border: 1px solid #cfd4df;
    border-radius: 8px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    z-index: 100;
    max-height: 300px;
    overflow-y: auto;
}

.fop-student-filter-options {
    padding: 8px 0;
}

.fop-student-filter-option {
    display: flex;
    align-items: center;
    padding: 8px 12px;
    cursor: pointer;
    transition: background-color 0.15s;
    gap: 8px;
}

.fop-student-filter-option:hover:not(.is-disabled) {
    background-color: #f3f4f6;
}

.fop-student-filter-option.is-disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.fop-student-filter-option input[type="checkbox"] {
    cursor: pointer;
    width: 16px;
    height: 16px;
    margin: 0;
}

.fop-student-filter-option.is-disabled input[type="checkbox"] {
    cursor: not-allowed;
}

.fop-student-name {
    flex: 1;
    font-size: 14px;
    color: var(--fop-grey-dark);
}

.fop-no-photos-badge {
    font-size: 12px;
    color: #6b7280;
    font-style: italic;
}

.fop-slideshow-main {
    flex: 1 1 640px;
    min-width: 0;
}

.fop-slideshow-image-area {
    position: relative;
    background: linear-gradient(135deg, #0d1117, #1f2937);
    border-radius: 20px;
    padding: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    height: 600px;
    box-shadow: 0 20px 60px rgba(15, 23, 42, 0.35);
}

.fop-photo-frame {
    width: 100%;
    height: 100%;
    border-radius: 16px;
    background: radial-gradient(circle at center, rgba(255, 255, 255, 0.08), rgba(255, 255, 255, 0));
    border: 1px solid rgba(255, 255, 255, 0.12);
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.05);
}

.fop-slideshow-image {
    width: 100%;
    height: 100%;
    max-width: 100%;
    max-height: 100%;
    display: block;
    object-fit: contain;
}

.fop-slide-badges {
    position: absolute;
    top: 16px;
    right: 16px;
    display: flex;
    flex-direction: column;
    gap: 8px;
    z-index: 5;
}

.fop-slide-badges .fop-badge {
    position: static;
}

.fop-slide-counter {
    position: absolute;
    bottom: 16px;
    left: 16px;
    background: rgba(0, 0, 0, 0.6);
    color: #fff;
    padding: 6px 14px;
    border-radius: 20px;
    font-size: 14px;
    font-weight: 600;
}

/* ==========================================================================
   Global Modal Styles (student filter error)
   ========================================================================== */

.fop-modal {
    position: fixed;
    inset: 0;
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 2000;
}

.fop-modal.is-visible {
    display: flex;
}

.fop-modal-overlay {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.55);
}

.fop-modal-content {
    position: relative;
    background: #fff;
    border-radius: 14px;
    padding: 28px 32px;
    width: min(420px, calc(100% - 40px));
    box-shadow: 0 24px 60px rgba(15, 23, 42, 0.25);
    text-align: center;
    z-index: 1;
}

.fop-modal-content h3 {
    margin: 0 0 12px 0;
    font-size: 20px;
    font-weight: 700;
    color: var(--fop-grey-dark);
}

.fop-modal-message {
    font-size: 15px;
    color: var(--fop-muted);
    margin: 0 0 24px 0;
    line-height: 1.5;
}

.fop-modal-close {
    position: absolute;
    top: 10px;
    right: 10px;
    border: none;
    background: transparent;
    font-size: 20px;
    cursor: pointer;
    color: #888;
}

.fop-modal-close:hover,
.fop-modal-close:focus {
    color: var(--fop-grey-dark);
}

.fop-modal-dismiss {
    border: none;
    background: var(--fop-grey-dark);
    color: #fff;
    padding: 12px 28px;
    border-radius: 999px;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    transition: transform 0.2s, background 0.2s;
}

.fop-modal-dismiss:hover,
.fop-modal-dismiss:focus {
    background: #111;
    transform: translateY(-1px);
}

body.fop-modal-open {
    overflow: hidden;
}

@media screen and (max-width: 767px) {
    .fop-slideshow-image-area {
        height: 400px;
    }
    
    .fop-slideshow-image {
        max-height: 50vh;
    }
}

/* ==========================================================================
   Slideshow Navigation (Prev/Next)
   ========================================================================== */

.fop-slideshow-nav {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    margin-top: 24px;
    flex-wrap: wrap;
}

.fop-nav-btn {
    display: flex;
    align-items: center;
    gap: 10px;
    background: linear-gradient(135deg, rgba(32, 32, 35, 0.92), rgba(12, 12, 15, 0.85));
    color: #fff;
    border: 1px solid rgba(255, 255, 255, 0.15);
    border-radius: 999px;
    padding: 14px 28px;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    min-height: 54px;
    min-width: 120px;
    letter-spacing: 0.02em;
    text-transform: uppercase;
    box-shadow: 0 18px 35px rgba(15, 23, 42, 0.25);
    transition: background 0.2s ease, transform 0.2s ease, box-shadow 0.2s ease;
    backdrop-filter: blur(6px);
}

.fop-nav-btn:hover,
.fop-nav-btn:focus-visible {
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.12), rgba(255, 255, 255, 0.06));
    color: #fff;
    box-shadow: 0 20px 38px rgba(15, 23, 42, 0.35);
}

.fop-nav-btn:active {
    transform: translateY(1px) scale(0.99);
}

.fop-nav-btn:disabled {
    opacity: 0.35;
    cursor: not-allowed;
    box-shadow: none;
}

.fop-nav-icon {
    font-size: 22px;
    line-height: 1;
}

.fop-nav-prev {
    justify-content: center;
}

.fop-nav-next {
    justify-content: center;
}

.fop-slideshow-nav.is-hidden {
    display: none;
}

.fop-slideshow-main:focus-visible {
    outline: 2px solid var(--fop-gold);
    outline-offset: 10px;
    border-radius: 24px;
}

.fop-slideshow-meta {
    margin-top: 32px;
    display: flex;
    flex-direction: column;
    gap: 12px;
    align-items: stretch;
}

.fop-slideshow-inline-title {
    margin: 0;
    text-align: center;
    font-size: clamp(1.6rem, 2vw, 2.3rem);
    font-weight: 700;
    letter-spacing: 0.02em;
    color: var(--fop-text);
    line-height: 1.2;
}

.fop-slideshow-meta-actions {
    width: 100%;
    display: flex;
    justify-content: flex-end;
    margin-top: 12px;
}

@media screen and (max-width: 768px) {
    .fop-slideshow-meta {
        gap: 16px;
    }

    .fop-slideshow-inline-title {
        font-size: 1.5rem;
    }
}

.fop-photo-details-trigger {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    border: 1px solid var(--fop-border);
    background: var(--fop-surface-2);
    color: var(--fop-text);
    padding: 12px 20px;
    border-radius: 999px;
    font-size: 15px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    cursor: pointer;
    transition: background 0.2s ease, transform 0.2s ease;
    box-shadow: 0 4px 12px rgba(15, 23, 42, 0.1);
}

.fop-photo-details-trigger:hover,
.fop-photo-details-trigger:focus-visible {
    background: var(--fop-surface-1);
    transform: translateY(-1px);
}

.fop-photo-details-icon {
    font-size: 18px;
    line-height: 1;
}

@media screen and (max-width: 768px) {
    .fop-slideshow-meta-actions {
        justify-content: center;
    }

    .fop-photo-details-trigger {
        width: 100%;
        justify-content: center;
    }
}

/* ==========================================================================
   Photo Details Modal
   ========================================================================== */

.fop-photo-details-modal {
    position: fixed;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 32px 16px;
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transition: opacity 0.25s ease, visibility 0.25s ease;
    z-index: 999;
}

.fop-photo-details-modal.is-visible {
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
}

.fop-photo-details-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(8, 12, 20, 0.75);
    backdrop-filter: blur(10px);
}

.fop-photo-details-panel {
    position: relative;
    background: #fff;
    border-radius: 22px;
    width: min(760px, 100%);
    max-height: calc(100vh - 120px);
    overflow-y: auto;
    padding: 28px 32px;
    box-shadow: 0 30px 90px rgba(15, 23, 42, 0.45);
    z-index: 1;
}

.fop-photo-details-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    border-bottom: 1px solid rgba(15, 23, 42, 0.08);
    padding-bottom: 16px;
    margin-bottom: 20px;
}

.fop-photo-details-eyebrow {
    text-transform: uppercase;
    font-size: 12px;
    letter-spacing: 0.22em;
    color: var(--fop-muted);
    margin: 0 0 4px 0;
}

.fop-photo-details-header h3 {
    margin: 0;
    font-size: 26px;
    font-weight: 700;
    color: var(--fop-grey-dark);
}

.fop-photo-details-label {
    text-transform: uppercase;
    font-size: 12px;
    letter-spacing: 0.18em;
    color: var(--fop-muted, #6b7280);
    margin: 0 0 6px;
}

.fop-photo-details-title {
    margin: 4px 0 0;
    font-size: 20px;
    font-weight: 600;
    color: var(--fop-grey-dark);
}

.fop-photo-details-close {
    border: none;
    background: rgba(15, 23, 42, 0.05);
    color: var(--fop-grey-dark);
    width: 40px;
    height: 40px;
    border-radius: 50%;
    font-size: 22px;
    line-height: 1;
    cursor: pointer;
    transition: background 0.2s ease, transform 0.2s ease;
}

.fop-photo-details-close:hover,
.fop-photo-details-close:focus-visible {
    background: rgba(15, 23, 42, 0.15);
    transform: rotate(4deg);
}

.fop-photo-details-body {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.fop-photo-details-section {
    padding: 16px 0;
    border-bottom: 1px solid rgba(15, 23, 42, 0.08);
}

.fop-photo-details-section:first-child {
    padding-top: 0;
}

.fop-photo-details-section:last-child {
    border-bottom: none;
    padding-bottom: 0;
}

.fop-photo-details-student {
    margin: 0;
    font-size: 22px;
    font-weight: 700;
    color: var(--fop-grey-dark);
}

.fop-photo-details-reflection-text {
    font-size: 15px;
    line-height: 1.6;
    color: var(--fop-grey-dark);
    margin: 0;
}

.fop-photo-details-reflection-empty {
    font-size: 14px;
    color: #aaa;
    font-style: italic;
    margin: 0;
}

.fop-techspecs-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
    gap: 12px;
    margin-bottom: 24px;
}

.fop-techspec-item {
    display: flex;
    align-items: center;
    gap: 8px;
    background: var(--fop-grey-light);
    padding: 10px 12px;
    border-radius: 8px;
}

.fop-techspec-item:first-child {
    grid-column: 1 / -1;
    justify-content: space-between;
    align-items: flex-start;
    flex-wrap: wrap;
}

.fop-techspec-item:first-child .fop-techspec-label {
    flex-shrink: 0;
    padding-top: 2px;
}

.fop-techspec-item:first-child .fop-techspec-value {
    text-align: right;
    flex: 1;
    min-width: 0;
    overflow-wrap: break-word;
    word-break: break-word;
    hyphens: auto;
}

.fop-techspec-label {
    font-size: 12px;
    font-weight: 700;
    color: #888;
    min-width: 28px;
    flex-shrink: 0;
}

.fop-techspec-value {
    font-size: 14px;
    font-weight: 600;
    color: var(--fop-grey-dark);
    word-break: break-word;
}

.fop-techspecs-empty {
    font-size: 14px;
    color: #aaa;
    font-style: italic;
    margin: 0 0 24px 0;
}

@media screen and (max-width: 640px) {
    .fop-photo-details-panel {
        max-height: calc(100vh - 60px);
        padding: 20px;
    }

    .fop-photo-details-header h3 {
        font-size: 22px;
    }
}

@media screen and (max-width: 480px) {
    .fop-nav-btn {
        padding: 12px 16px;
        min-width: 80px;
    }
    
    .fop-nav-label {
        display: none;
    }
    
    .fop-nav-icon {
        font-size: 24px;
    }
}

/* ==========================================================================
   Slideshow Sidebar
   ========================================================================== */


@media screen and (max-width: 1180px) {
    .fop-slideshow-gallery {
        max-width: 100%;
    }
}

@media screen and (max-width: 1024px) {
    .fop-slideshow-gallery {
        flex-direction: column;
        padding: 0 16px;
    }

    .fop-slideshow-main {
        width: 100%;
    }
}

@media screen and (max-width: 640px) {
    .fop-slideshow-image-area {
        padding: 16px;
        border-radius: 16px;
    }

    .fop-photo-frame {
        border-radius: 12px;
    }

    .fop-slideshow-nav {
        flex-direction: column;
    }

    .fop-nav-btn {
        justify-content: center;
        width: 100%;
    }
}

/* Drawer Toggle (hidden on desktop) */

/* ==========================================================================
   Layout Toggle
   ========================================================================== */

.fop-gallery-container {
    position: relative;
}

/* Full-bleed responsive container that fills the viewport width
   while keeping content comfortably padded on wide screens. */
.fop-gallery-container.fop-full-bleed {
    width: 100vw;
    margin-left: calc(50% - 50vw);
    margin-right: calc(50% - 50vw);
    padding-left: clamp(16px, 4vw, 48px);
    padding-right: clamp(16px, 4vw, 48px);
    box-sizing: border-box;
}

/* When using WordPress block theme alignment, let theme control width */
.fop-gallery-container.fop-full-bleed.alignfull,
.fop-gallery-container.fop-full-bleed.alignwide {
    width: 100%;
    margin-left: 0;
    margin-right: 0;
}

/* Prevent parent theme containers from clipping the breakout.
   Requires modern browsers with :has() support. */
:where(*):has(> .fop-gallery-container.fop-full-bleed) {
    overflow: visible !important;
}

/* Ensure full-bleed respects dark theme without visual glitches */
.fop-gallery-container.fop-full-bleed.fop-theme-dark {
    background-color: #000000; /* entire page area behind cards is black in dark mode */
}

.fop-slideshow-breadcrumbs {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin: 16px 0 24px;
    align-items: center;
}

.fop-breadcrumb-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 16px;
    border-radius: 999px;
    border: 1px solid #d0d7de;
    background: #ffffff;
    color: #1f2328;
    font-weight: 600;
    text-decoration: none;
    box-shadow: 0 1px 2px rgba(15, 23, 42, 0.08);
    transition: background 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease;
}

.fop-breadcrumb-btn:hover,
.fop-breadcrumb-btn:focus-visible {
    background: #f5f5f5;
    border-color: #b3bac5;
    box-shadow: 0 2px 6px rgba(15, 23, 42, 0.12);
}

.fop-breadcrumb-btn:focus-visible {
    outline: 2px solid var(--fop-gold);
    outline-offset: 2px;
}

.fop-breadcrumb-btn.is-secondary {
    background: #f0f4ff;
    border-color: #b3c7ff;
    color: #1b3a8a;
}

.fop-breadcrumb-btn.is-secondary:hover,
.fop-breadcrumb-btn.is-secondary:focus-visible {
    background: #e3ecff;
    border-color: #96b0ff;
}

.fop-breadcrumb-icon {
    font-size: 16px;
}

.fop-layout-toggle {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 8px;
    margin-bottom: 20px;
}

.fop-layout-toggle-label {
    font-size: 14px;
    color: #666;
    margin-right: 4px;
}

.fop-layout-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    background: var(--fop-grey-light);
    border: 2px solid transparent;
    border-radius: 8px;
    cursor: pointer;
    transition: background 0.2s, border-color 0.2s;
}

.fop-layout-btn:hover,
.fop-layout-btn:focus {
    background: #e8e8e8;
}

.fop-layout-btn.is-active {
    background: #fff;
    border-color: var(--fop-gold);
}

.fop-layout-icon {
    font-size: 18px;
    color: var(--fop-grey-dark);
}

/* ==========================================================================
   Responsive Adjustments
   ========================================================================== */

@media screen and (max-width: 767px) {
    .fop-student-name {
        font-size: 20px;
    }
    
    .fop-gallery-wrapper {
        padding: 16px 0;
    }
    
    .fop-student-section {
        margin-bottom: 32px;
    }
}

/* Touch target minimum size */
@media (pointer: coarse) {
    .fop-photo-card-inner {
        min-height: 44px;
    }
}

/* ==========================================================================
   Photo Lightbox Modal
   ========================================================================== */

.fop-lightbox {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 999999;
    padding: 20px;
    box-sizing: border-box;
}

.fop-lightbox.is-open {
    display: flex;
    align-items: center;
    justify-content: center;
}

.fop-lightbox-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.85);
    cursor: pointer;
}

.fop-lightbox-content {
    position: relative;
    display: flex;
    flex-direction: row;
    max-width: 1200px;
    max-height: 90vh;
    width: 100%;
    background: #fff;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.4);
    z-index: 1;
}

.fop-lightbox-close {
    position: absolute;
    top: 16px;
    right: 16px;
    width: 44px;
    height: 44px;
    background: rgba(0, 0, 0, 0.6);
    color: #fff;
    border: none;
    border-radius: 50%;
    font-size: 28px;
    line-height: 1;
    cursor: pointer;
    z-index: 10;
    transition: background 0.2s, transform 0.2s;
    display: flex;
    align-items: center;
    justify-content: center;
}

.fop-lightbox-close:hover,
.fop-lightbox-close:focus {
    background: rgba(0, 0, 0, 0.8);
    transform: scale(1.1);
}

.fop-lightbox-image-container {
    flex: 1 1 60%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #000;
    position: relative;
    min-height: 300px;
    padding-bottom: 110px; /* reserve space for reaction tray */
}

.fop-lightbox-image {
    max-width: 100%;
    max-height: calc(85vh - 120px);
    object-fit: contain;
}

.fop-lightbox-badges {
    position: absolute;
    top: 16px;
    left: 16px;
    display: flex;
    flex-direction: column;
    gap: 8px;
    z-index: 2;
}

/* Override masonry-card absolute positioning for badges inside the lightbox */
.fop-lightbox-badges .fop-badge {
    position: static;
    z-index: auto;
}

.fop-lightbox-info {
    flex: 0 0 320px;
    padding: 24px;
    overflow-y: auto;
    max-height: 85vh;
    background: #fff;
}

.fop-lightbox-header {
    margin-bottom: 20px;
    padding-bottom: 16px;
    border-bottom: 1px solid #eee;
}

.fop-lightbox-title {
    font-size: 22px;
    font-weight: 700;
    margin: 0 0 8px 0;
    color: var(--fop-grey-dark);
    font-family: var(--fop-font-family);
}

.fop-lightbox-photographer {
    font-size: 15px;
    color: #666;
    margin: 0;
}

.fop-lightbox-caption {
    margin-bottom: 12px;
}

.fop-lightbox-caption:empty {
    display: none;
}

.fop-lightbox-notes {
    margin-bottom: 12px;
    padding: 10px 15px;
    background: #fff8e1;
    border-radius: 10px;
    border-left: 4px solid #ffc107;
}

.fop-lightbox-notes:empty {
    display: none;
}

.fop-lightbox-notes-title {
    font-size: 14px;
    font-weight: 600;
    margin-bottom: 6px;
    color: var(--fop-grey-dark);
}

.fop-lightbox-notes-text {
    font-size: 14px;
    line-height: 1.3;
    color: #555;
    margin: 0;
    font-style: italic;
}

.fop-lightbox-exif {
    margin-bottom: 16px;
    padding: 14px 16px;
    background: var(--fop-surface-2);
    border-radius: var(--fop-card-radius);
    border: 1px solid var(--fop-border);
}

.fop-lightbox-exif:empty {
    display: none;
}

.fop-lightbox-exif-title {
    font-size: 14px;
    font-weight: 600;
    margin-bottom: 10px;
    color: var(--fop-grey-dark);
}

.fop-lightbox-exif-list {
    display: grid;
    grid-template-columns: auto 1fr;
    column-gap: 12px;
    row-gap: 8px;
    margin: 0;
}

.fop-lightbox-exif-item {
    display: contents;
}

.fop-lightbox-exif-item dt {
    font-weight: 600;
    font-size: 13px;
    color: var(--fop-grey-dark);
    margin: 0;
}

.fop-lightbox-exif-item dd {
    margin: 0;
    font-size: 13px;
    color: var(--fop-grey-dark);
    word-break: break-word;
    white-space: normal;
}

.fop-lightbox-exif-empty {
    margin: 0;
    font-size: 13px;
    color: var(--fop-grey-dark);
    opacity: 0.8;
}

@media (max-width: 640px) {
    .fop-lightbox-exif-list {
        grid-template-columns: 1fr;
    }

    .fop-lightbox-exif-item dt {
        margin-bottom: 2px;
    }
}

/* ==========================================================================
   Lightbox Reaction Tray (below photo)
   ========================================================================== */

.fop-lightbox-reaction-tray {
    display: flex;
    flex-wrap: nowrap;
    justify-content: center;
    align-items: center;
    gap: 6px;
    padding: 10px 12px;
    background: rgba(0, 0, 0, 0.75);
    backdrop-filter: blur(8px);
    border-top: 1px solid rgba(255, 215, 0, 0.3);
    position: absolute;
    left: 16px;
    right: 16px;
    bottom: 16px;
    border-radius: 12px;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.35);
    overflow-x: auto;
    overflow-y: hidden;
    scrollbar-width: thin;
    scrollbar-color: rgba(255, 215, 0, 0.3) transparent;
}

.fop-lightbox-sticker-btn {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 2px;
    background: #fff !important;
    border: 1px solid #e0e0e0;
    padding: 4px 6px;
    cursor: pointer;
    min-height: 40px;
    min-width: 36px;
    border-radius: 8px;
    transition: transform 0.2s ease, background 0.2s ease, border-color 0.2s ease, opacity 0.2s ease, filter 0.2s ease;
    position: relative;
    flex-shrink: 0;
    filter: grayscale(100%);
    opacity: 0.6;
}

/* Hover - slight opacity increase only, stay grayscale */
.fop-lightbox-sticker-btn:hover:not(.has-voted),
.fop-lightbox-sticker-btn:focus:not(.has-voted) {
    opacity: 0.8;
    filter: grayscale(100%);
    background: #fff !important;
    border-color: var(--fop-gold);
}

.fop-lightbox-sticker-btn:active {
    transform: scale(0.95);
}

/* Emoji sizing */
.fop-lightbox-sticker-btn .fop-sticker-emoji {
    font-size: 20px;
}

/* ONLY user-voted emojis get color via .has-voted */
.fop-lightbox-sticker-btn.has-voted {
    filter: grayscale(0%) !important;
    opacity: 1 !important;
    background: #fff !important;
    border-color: var(--fop-gold);
    box-shadow: 0 0 0 2px rgba(255, 215, 0, 0.35);
}

/* Locked state - already voted in past session */
.fop-lightbox-sticker-btn.is-locked {
    cursor: not-allowed;
    opacity: 0.5;
    filter: grayscale(100%);
    background: #fff !important;
}

.fop-lightbox-sticker-btn.is-locked:hover {
    transform: none;
    background: #fff !important;
    border-color: #e0e0e0;
}

/* Lightbox sticker count */
.fop-lightbox-sticker-btn .fop-sticker-count {
    font-size: 10px;
    font-weight: 600;
    color: #888;
}

/* Removed: .has-votes class no longer used in lightbox (only .has-voted matters) */

/* Lightbox sticker badge - proportionally smaller circle for modal */
/* Always visible since lightbox only shows stickers with votes */
.fop-lightbox-sticker-btn .fop-sticker-badge {
    display: flex;
    font-size: 8px;
    width: 14px;
    height: 14px;
    aspect-ratio: 1 / 1;
    flex-shrink: 0;
}

/* Removed: Legacy grid styles no longer needed for horizontal tray */

/* ==========================================================================
   Lightbox Comments Section
   ========================================================================== */

.fop-lightbox-comments {
    padding: 10px 15px;
    background: var(--fop-grey-light);
    border-radius: 10px;
    margin-top: 0;
}

.fop-lightbox-comments-title {
    font-size: 14px;
    font-weight: 600;
    margin-bottom: 8px;
    color: var(--fop-grey-dark);
}

.fop-lightbox-comment-form {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.fop-lightbox-comment-name-row {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.fop-lightbox-comment-name-select {
    width: 100%;
    padding: 10px 12px;
    border: 1px solid #ddd;
    border-radius: 8px;
    font-size: 14px;
    background: #fff;
    color: var(--fop-grey-dark);
    min-height: 44px;
    cursor: pointer;
}

.fop-lightbox-comment-name-select:focus {
    outline: none;
    border-color: var(--fop-gold);
    box-shadow: 0 0 0 2px rgba(255, 215, 0, 0.2);
}

.fop-lightbox-comment-name-input {
    width: 100%;
    padding: 10px 12px;
    border: 1px solid #ddd;
    border-radius: 8px;
    font-size: 14px;
    min-height: 44px;
}

.fop-lightbox-comment-name-input:focus {
    outline: none;
    border-color: var(--fop-gold);
    box-shadow: 0 0 0 2px rgba(255, 215, 0, 0.2);
}

/* Comment input textarea */
.fop-lightbox-comment-input-row {
    margin-top: 8px;
}

.fop-lightbox-comment-input {
    width: 100%;
    padding: 10px 12px;
    border: 1px solid #ddd;
    border-radius: 8px;
    font-size: 14px;
    font-family: inherit;
    resize: vertical;
    min-height: 60px;
    box-sizing: border-box;
}

.fop-lightbox-comment-input:focus {
    outline: none;
    border-color: var(--fop-gold);
    box-shadow: 0 0 0 2px rgba(255, 215, 0, 0.2);
}

/* Submit button */
.fop-lightbox-comment-submit-row {
    margin-top: 8px;
}

.fop-lightbox-comment-submit {
    width: 100%;
    padding: 12px 16px;
    background: var(--fop-gold);
    color: var(--fop-grey-dark);
    border: none;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    min-height: 44px;
    transition: background 0.2s, transform 0.1s;
}

.fop-lightbox-comment-submit:hover {
    background: #e6c200;
}

.fop-lightbox-comment-submit:active {
    transform: scale(0.98);
}

.fop-lightbox-comment-submit:disabled {
    background: #ccc;
    cursor: not-allowed;
}

/* Existing comments list */
.fop-lightbox-comments-list {
    margin-top: 16px;
    padding-top: 12px;
    border-top: 1px solid #eee;
}

.fop-lightbox-comment-item {
    padding: 8px 0;
    font-size: 13px;
    line-height: 1.4;
    border-bottom: 1px solid #f0f0f0;
}

.fop-lightbox-comment-item:last-child {
    border-bottom: none;
}

.fop-lightbox-comment-author {
    font-weight: 600;
    color: var(--fop-grey-dark);
}

.fop-lightbox-comment-text {
    color: #555;
}

.fop-lightbox-comments-empty {
    font-size: 13px;
    color: #888;
    font-style: italic;
    margin: 0;
}

/* ==========================================================================
   Caption Editing in Lightbox
   ========================================================================== */

.fop-lightbox-caption-title {
    font-size: 14px;
    font-weight: 600;
    margin-bottom: 8px;
    color: var(--fop-grey-dark);
    display: flex;
    align-items: center;
    gap: 8px;
}

.fop-caption-edit-btn {
    background: none;
    border: none;
    padding: 2px 6px;
    font-size: 14px;
    cursor: pointer;
    opacity: 0.6;
    transition: opacity 0.2s;
    border-radius: 4px;
}

.fop-caption-edit-btn:hover {
    opacity: 1;
    background: rgba(0, 0, 0, 0.05);
}

.fop-lightbox-caption-text {
    font-size: 15px;
    line-height: 1.6;
    color: #555;
    margin: 0;
}

.fop-caption-placeholder {
    padding: 10px 15px;
    background: rgba(255, 215, 0, 0.1);
    border: 2px dashed var(--fop-gold);
    border-radius: 8px;
    cursor: pointer;
    transition: background 0.2s, border-color 0.2s;
    line-height: 1.2;
}

.fop-caption-placeholder:hover {
    background: rgba(255, 215, 0, 0.2);
    border-color: #e6c200;
}

.fop-caption-placeholder-text {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 14px;
    color: #888;
    font-style: italic;
}

.fop-caption-edit-form {
    margin-top: 8px;
}

.fop-caption-input {
    width: 100%;
    padding: 10px 12px;
    border: 1px solid #ddd;
    border-radius: 8px;
    font-size: 14px;
    font-family: var(--fop-font-family);
    resize: vertical;
    min-height: 60px;
    outline: none;
    transition: border-color 0.2s;
}

.fop-caption-input:focus {
    border-color: var(--fop-gold);
}

.fop-caption-actions {
    display: flex;
    gap: 8px;
    margin-top: 8px;
}

.fop-caption-save,
.fop-caption-cancel {
    padding: 8px 16px;
    border-radius: 6px;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.2s, transform 0.1s;
}

.fop-caption-save {
    background: var(--fop-gold);
    color: var(--fop-grey-dark);
    border: none;
}

.fop-caption-save:hover {
    background: #e6c200;
}

.fop-caption-save:active {
    transform: scale(0.98);
}

.fop-caption-save.is-saving {
    opacity: 0.7;
    pointer-events: none;
}

.fop-caption-cancel {
    background: #fff;
    color: #666;
    border: 1px solid #ddd;
}

.fop-caption-cancel:hover {
    background: #f5f5f5;
}

/* Body scroll lock when lightbox is open */
body.fop-lightbox-open {
    overflow: hidden;
}

/* Lightbox responsive adjustments */
@media screen and (max-width: 900px) {
    .fop-lightbox-content {
        flex-direction: column;
        max-height: 95vh;
    }

    .fop-lightbox-image-container {
        flex: 0 0 auto;
        max-height: 50vh;
    }

    .fop-lightbox-info {
        flex: 1 1 auto;
        max-height: 45vh;
    }
}

@media screen and (max-width: 480px) {
    .fop-lightbox {
        padding: 10px;
    }

    .fop-lightbox-info {
        padding: 16px;
    }

    .fop-lightbox-title {
        font-size: 18px;
    }

    .fop-lightbox-sticker-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

/* ==========================================================================
   Sticker Vote Tracking Styles
   ========================================================================== */

/* Sticker button when user has already voted */
.fop-sticker-btn.has-voted {
    opacity: 1;
}

/* Voted sticker emoji shows in full color */
.fop-sticker-btn.has-voted .fop-sticker-emoji {
    filter: grayscale(0%) !important;
}

/* Vote badge on sticker (checkmark or count) - positioned below emoji */
.fop-sticker-badge {
    font-size: 10px;
    background: var(--fop-success);
    color: #fff;
    border-radius: 50%;
    width: 16px;
    height: 16px;
    display: none;
    align-items: center;
    justify-content: center;
    line-height: 1;
    font-weight: 600;
    flex-shrink: 0;
    aspect-ratio: 1 / 1;
}

.fop-sticker-btn.has-voted .fop-sticker-badge {
    display: flex;
}

/* Ensure sticker button is positioned for the badge */
.fop-sticker-btn {
    position: relative;
}

/* Shake animation for already voted */
@keyframes fop-shake {
    0%, 100% { transform: translateX(0); }
    25% { transform: translateX(-4px); }
    75% { transform: translateX(4px); }
}

.fop-sticker-btn.already-voted-shake {
    animation: fop-shake 0.3s ease-in-out;
}

/* Make photo thumbnails clickable cursor */
.fop-photo-thumbnail img {
    cursor: zoom-in;
    transition: transform 0.2s, box-shadow 0.2s;
}

.fop-photo-thumbnail img:hover {
    transform: scale(1.02);
}

/* ==========================================================================
   DARK THEME STYLES
   Applied when .fop-theme-dark class is on .fop-gallery-container
   ========================================================================== */

/**
 * Dark Theme - Global Page Background & Title
 * Extend black background to the entire page area and make
 * the WordPress page/post title readable in dark mode.
 */
html.dark body,
html.dark .wp-site-blocks,
html.dark main#wp--skip-link--target {
    background-color: #000 !important;
}

/* ==========================================================================
   WordPress Page Title Styling
   ========================================================================== */

/* Base styles for page title (light mode) */
.wp-block-post-title,
h1.entry-title {
    margin-left: 0 !important;
    margin-right: 0 !important;
    padding-left: 20px !important;
    padding-right: 20px !important;
    text-align: center !important;
    white-space: nowrap !important;
    font-size: clamp(1.5rem, 5vw, 3rem) !important;
    display: block !important;
    width: 100% !important;
    font-family: "Playfair Display", "Lora", "Cinzel", Georgia, serif !important;
    color: #121212 !important;
}

/* Dark mode title styling */
html.dark .wp-block-post-title,
html.dark h1.entry-title {
    color: #FAFAFA !important;
}

.fop-theme-dark .wp-block-post-title,
.fop-theme-dark h1.entry-title {
    color: #FAFAFA !important;
}

@media screen and (max-width: 480px) {
    .wp-block-post-title,
    h1.entry-title {
        font-size: 1.25rem !important;
    }
}

/**
 * Dark Theme - Gallery Container Background
 */
.fop-gallery-container.fop-theme-dark {
    background-color: #000000; /* entire background black */
    color: #e0e0e0; /* headings/outside-of-cards text */
}

/**
 * Dark Theme - Text Colors for Titles, Captions, Labels
 * Gallery cards use light theme colors (dark text on white), other elements use light text
 */
.fop-theme-dark .fop-photo-title {
    color: #333; /* Match light theme - dark text */
}

.fop-theme-dark .fop-photo-caption {
    color: #666; /* Match light theme - dark gray text */
}

.fop-theme-dark .fop-student-name,
.fop-theme-dark .fop-gallery-header,
.fop-theme-dark .fop-layout-toggle-label,
.fop-theme-dark .fop-session-header-name,
.fop-theme-dark .fop-current-week-text,
.fop-theme-dark .fop-week-timeline-header-text,
.fop-theme-dark .fop-lightbox-title,
.fop-theme-dark .fop-lightbox-photographer {
    color: #f5f5f5;
}

/* Dark Theme - Week Timeline */
.fop-theme-dark .fop-week-timeline-toggle {
    background: linear-gradient(135deg, #1f2937 0%, #111827 100%);
    border-color: #374151;
    color: #e5e7eb;
}

.fop-theme-dark .fop-week-timeline-toggle:hover {
    border-color: #34d399;
    color: #34d399;
}

.fop-theme-dark .fop-week-timeline-connector {
    background: #374151;
}

.fop-theme-dark .fop-week-timeline-connector.filled {
    background: #6b7280;
}

.fop-theme-dark .fop-week-timeline-node.completed .fop-week-timeline-circle {
    background: #374151;
    border-color: #6b7280;
    color: #d1d5db;
}

.fop-theme-dark .fop-week-timeline-node.current .fop-week-timeline-circle {
    background: #059669;
    border-color: #059669;
    color: #fff;
    box-shadow: 0 0 0 2px #111827, 0 0 0 4px #059669;
}

.fop-theme-dark .fop-week-timeline-node.upcoming .fop-week-timeline-circle {
    background: #1f2937;
    border-color: #374151;
    color: #9ca3af;
}

.fop-theme-dark .fop-week-timeline-label {
    color: #9ca3af;
}

.fop-theme-dark .fop-week-timeline-node.current .fop-week-timeline-label {
    color: #34d399;
}

.fop-theme-dark .fop-week-timeline-node.completed .fop-week-timeline-label {
    color: #9ca3af;
}

@media (max-width: 900px) {
    .fop-theme-dark .fop-week-timeline-track {
        background: #111827;
        border-color: #374151;
        box-shadow: 0 4px 12px rgba(0, 0, 0, 0.4);
    }
}

.fop-theme-dark .fop-show-all-weeks-btn {
    background: #1f2937;
    border-color: #f59e0b;
    color: #f59e0b;
}

.fop-theme-dark .fop-show-all-weeks-btn:hover {
    background: #f59e0b;
    color: #1f2937;
}

.fop-theme-dark .fop-slideshow-breadcrumbs {
    color: #f5f5f5;
}

.fop-theme-dark .fop-breadcrumb-btn {
    background: #101828;
    border-color: #1f2937;
    color: #f8fafc;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.4);
}

.fop-theme-dark .fop-breadcrumb-btn.is-secondary {
    background: #1d2a50;
    border-color: #304174;
    color: #e0e7ff;
}

.fop-theme-dark .fop-breadcrumb-btn:hover,
.fop-theme-dark .fop-breadcrumb-btn:focus-visible,
.fop-theme-dark .fop-breadcrumb-btn.is-secondary:hover,
.fop-theme-dark .fop-breadcrumb-btn.is-secondary:focus-visible {
    background: #1f2937;
    border-color: #3f4c63;
}

.fop-theme-dark .fop-photo-details-student-filter {
    border-top-color: #374151;
}

.fop-theme-dark .fop-student-filter-toggle {
    background: #111827;
    border-color: #374151;
    color: #e5e7eb;
}

.fop-theme-dark .fop-student-filter-toggle:hover {
    border-color: #6b7280;
}

.fop-theme-dark .fop-student-filter-toggle:focus {
    border-color: var(--fop-gold);
    box-shadow: 0 0 0 3px rgba(255, 196, 0, 0.15);
}

.fop-theme-dark .fop-student-filter-dropdown {
    background: #111827;
    border-color: #374151;
}

.fop-theme-dark .fop-student-filter-option:hover:not(.is-disabled) {
    background-color: #1f2937;
}

.fop-theme-dark .fop-student-name {
    color: #e5e7eb;
}

.fop-theme-dark .fop-no-photos-badge {
    color: #9ca3af;
}

.fop-theme-dark .fop-modal-content {
    background: #111827;
    color: #f8fafc;
}

.fop-theme-dark .fop-modal-message {
    color: #cbd5f5;
}

.fop-theme-dark .fop-modal-dismiss {
    background: #fbbf24;
    color: #111;
}

.fop-theme-dark .fop-modal-dismiss:hover,
.fop-theme-dark .fop-modal-dismiss:focus {
    background: #fcd34d;
}

.fop-theme-dark .fop-modal-close {
    color: #94a3b8;
}

.fop-theme-dark .fop-modal-close:hover,
.fop-theme-dark .fop-modal-close:focus {
    color: #f8fafc;
}

.fop-theme-dark .fop-photo-notes,
.fop-theme-dark .fop-quote-of-day-text,
.fop-theme-dark .fop-quote-of-day-attribution,
.fop-theme-dark .fop-challenge-title,
.fop-theme-dark .fop-challenge-description,
.fop-theme-dark .fop-challenge-label,
.fop-theme-dark .fop-tech-specs-content,
.fop-theme-dark .fop-comment-text,
.fop-theme-dark .fop-lightbox-caption {
    color: #cccccc;
}

/**
 * Dark Theme - Card Backgrounds
 * Cards remain light with dark text to match light theme exactly
 */
.fop-theme-dark .fop-photo-card {
    background-color: transparent;
    border: none;
}

/* Keep cards light in dark mode (match light theme exactly) */
.fop-theme-dark .fop-photo-card-inner {
    background-color: #ffffff;
    border-color: #e0e0e0;
    color: #1a1a1a;
}

.fop-theme-dark .fop-photo-thumbnail {
    background: #f5f5f5;
}

.fop-theme-dark .fop-quote-card .fop-info-card-inner {
    background: linear-gradient(135deg, #e8f4ff 0%, #dbeafe 100%);
    border-color: #2196F3;
}
.fop-theme-dark .fop-quote-card .fop-quote-of-day-text {
    color: #1a1a1a;
}

.fop-theme-dark .fop-week-card .fop-info-card-inner {
    background: linear-gradient(135deg, #f0fdf4 0%, #dcfce7 100%);
    border-color: #34a853;
}
.fop-theme-dark .fop-week-title { color: #1a1a1a; }
.fop-theme-dark .fop-week-description { color: #555555; }

.fop-theme-dark .fop-challenge-card .fop-challenge-card-inner {
    background: linear-gradient(135deg, #fff9e6 0%, #fff3cc 100%);
    border: 2px solid var(--fop-gold);
}
.fop-theme-dark .fop-challenge-title,
.fop-theme-dark .fop-challenge-description,
.fop-theme-dark .fop-challenge-label { color: #1a1a1a; }

.fop-theme-dark .fop-student-tile.is-active {
    background-color: #3a3a3a;
    border-color: #5a5a5a;
}

/**
 * Dark Theme - Sticker Tray and Buttons
 * Sticker tray stays light to match visual reference
 */
.fop-theme-dark .fop-sticker-tray {
    background-color: #f9f9f9 !important;
    border-top: 1px solid #eee !important;
}

.fop-theme-dark .fop-sticker-readonly .fop-sticker-count {
    color: #333 !important;
    background: #fff !important;
}

.fop-theme-dark .fop-sticker-empty-message {
    background: #e3f2fd !important;
    color: #0d47a1 !important;
}

.fop-theme-dark .fop-sticker-btn {
    background-color: #3a3a3a;
    border: 1px solid #4a4a4a;
}

.fop-theme-dark .fop-sticker-btn:hover {
    background-color: #4a4a4a;
    border-color: #5a5a5a;
}

.fop-theme-dark .fop-sticker-btn.has-voted {
    background-color: #4a4a4a;
    border-color: #6a6a6a;
}

.fop-theme-dark .fop-sticker-count {
    color: #e0e0e0;
}

/* Theme toggle button styling */
.fop-theme-toggle-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    padding: 0;
    background-color: transparent;
    border: 1px solid #ddd;
    border-radius: 50%;
    cursor: pointer;
    transition: background-color 0.2s, border-color 0.2s;
}

.fop-theme-toggle-btn:hover {
    background-color: #f0f0f0;
    border-color: #bbb;
}

.fop-theme-toggle-btn .fop-theme-icon {
    font-size: 18px;
    line-height: 1;
}

/* Show sun icon in light mode, moon in dark mode */
.fop-theme-toggle-btn .fop-theme-icon-moon {
    display: none;
}

.fop-theme-dark .fop-theme-toggle-btn .fop-theme-icon-sun {
    display: none;
}

.fop-theme-dark .fop-theme-toggle-btn .fop-theme-icon-moon {
    display: inline;
}

/* Dark theme toggle button styles */
.fop-theme-dark .fop-theme-toggle-btn {
    border-color: #4a4a4a;
}

.fop-theme-dark .fop-theme-toggle-btn:hover {
    background-color: #3a3a3a;
    border-color: #5a5a5a;
}

/* Layout and upload buttons in dark mode */
.fop-theme-dark .fop-layout-btn {
    background-color: #3a3a3a;
    border-color: #4a4a4a;
    color: #e0e0e0;
}

.fop-theme-dark .fop-layout-btn:hover,
.fop-theme-dark .fop-layout-btn.is-active {
    background-color: #4a4a4a;
    border-color: #5a5a5a;
}

.fop-theme-dark .fop-upload-btn {
    background-color: #3a3a3a;
    border-color: #4a4a4a;
    color: #e0e0e0;
}

.fop-theme-dark .fop-upload-btn:hover {
    background-color: #4a4a4a;
    border-color: #5a5a5a;
}

/**
 * Dark Theme - Lightbox Modal
 */
.fop-theme-dark .fop-lightbox-content {
    background-color: #1a1a1a;
    border: 1px solid #3a3a3a;
}

.fop-theme-dark .fop-lightbox-overlay {
    background-color: rgba(0, 0, 0, 0.9);
}

.fop-theme-dark .fop-lightbox-close {
    color: #e0e0e0;
    background-color: #2a2a2a;
    border: 1px solid #4a4a4a;
}

.fop-theme-dark .fop-lightbox-close:hover {
    background-color: #3a3a3a;
    color: #fff;
}

.fop-theme-dark .fop-lightbox-info {
    background-color: #252525;
    border-left: 1px solid #3a3a3a;
}

.fop-theme-dark .fop-lightbox-nav-btn {
    background-color: rgba(42, 42, 42, 0.8);
    color: #e0e0e0;
    border: 1px solid #4a4a4a;
}

.fop-theme-dark .fop-lightbox-nav-btn:hover {
    background-color: rgba(58, 58, 58, 0.9);
}

.fop-theme-dark .fop-lightbox-sticker-tray {
    background-color: #2a2a2a;
    border-top: 1px solid #3a3a3a;
}

.fop-theme-dark .fop-lightbox-comments {
    background-color: #252525;
    border-top: 1px solid #3a3a3a;
}

.fop-theme-dark .fop-lightbox-comment {
    background-color: #2a2a2a;
    border: 1px solid #3a3a3a;
}

.fop-theme-dark .fop-lightbox-comment-author {
    color: #f5f5f5;
}

.fop-theme-dark .fop-lightbox-tech-specs {
    background-color: #2a2a2a;
    border: 1px solid #3a3a3a;
    color: #cccccc;
}

/**
 * Dark Theme - Accessibility & Contrast (WCAG AA Compliant)
 *
 * Contrast Ratios (verified against WCAG AA 4.5:1 for normal text):
 * - #f5f5f5 on #1a1a1a = 15.3:1 (primary text on container) ✓
 * - #f5f5f5 on #2a2a2a = 12.6:1 (primary text on cards) ✓
 * - #cccccc on #1a1a1a = 10.3:1 (secondary text on container) ✓
 * - #cccccc on #2a2a2a = 8.5:1 (secondary text on cards) ✓
 * - #e0e0e0 on #3a3a3a = 7.2:1 (button text) ✓
 */

/* Focus states for keyboard accessibility */
.fop-theme-dark .fop-theme-toggle-btn:focus-visible,
.fop-theme-dark .fop-layout-btn:focus-visible,
.fop-theme-dark .fop-upload-btn:focus-visible,
.fop-theme-dark .fop-sticker-btn:focus-visible {
    outline: 2px solid #6ea8fe;
    outline-offset: 2px;
}

.fop-theme-dark .fop-lightbox-close:focus-visible,
.fop-theme-dark .fop-lightbox-nav-btn:focus-visible {
    outline: 2px solid #6ea8fe;
    outline-offset: 2px;
}

.fop-theme-dark .fop-week-tile:focus-visible,
.fop-theme-dark .fop-student-tile:focus-visible {
    outline: 2px solid #6ea8fe;
    outline-offset: 2px;
}

/* Links in dark mode */
.fop-theme-dark a {
    color: #6ea8fe;
}

.fop-theme-dark a:hover {
    color: #9ec5fe;
}

.fop-theme-dark a:focus-visible {
    outline: 2px solid #6ea8fe;
    outline-offset: 2px;
}

/* Form inputs in dark mode */
.fop-theme-dark input[type="text"],
.fop-theme-dark textarea,
.fop-theme-dark select {
    background-color: #2a2a2a;
    border: 1px solid #4a4a4a;
    color: #e0e0e0;
}

.fop-theme-dark input[type="text"]:focus,
.fop-theme-dark textarea:focus,
.fop-theme-dark select:focus {
    border-color: #6ea8fe;
    outline: none;
    box-shadow: 0 0 0 2px rgba(110, 168, 254, 0.25);
}

.fop-theme-dark input[type="text"]::placeholder,
.fop-theme-dark textarea::placeholder {
    color: #888888;
}

/* ==========================================================================
   LIGHTBOX HEADER CONTROLS & FULLSCREEN BUTTON
   ========================================================================== */

.fop-lightbox-header-controls {
    position: absolute;
    top: 10px;
    right: 10px;
    display: flex;
    gap: 8px;
    z-index: 10;
}

/* ==========================================================================
   AUTO-ADVANCE SLIDESHOW BUTTON
   ========================================================================== */

.fop-lightbox-autoadvance {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    padding: 0;
    background-color: rgba(255, 255, 255, 0.9);
    border: 1px solid #ddd;
    border-radius: 4px;
    cursor: pointer;
    transition: background-color 0.2s, border-color 0.2s;
    font-size: 14px;
    line-height: 1;
}

.fop-lightbox-autoadvance:hover {
    background-color: #fff;
    border-color: #bbb;
}

.fop-lightbox-autoadvance:focus-visible {
    outline: 2px solid #0073aa;
    outline-offset: 2px;
}

/* Show play icon by default, pause icon when auto-advancing */
.fop-lightbox-autoadvance .fop-autoadvance-icon-pause {
    display: none;
}

.fop-lightbox.is-auto-advancing .fop-lightbox-autoadvance .fop-autoadvance-icon-play {
    display: none;
}

.fop-lightbox.is-auto-advancing .fop-lightbox-autoadvance .fop-autoadvance-icon-pause {
    display: inline;
}

/* Visual indicator when auto-advance is active */
.fop-lightbox.is-auto-advancing .fop-lightbox-autoadvance {
    background-color: rgba(0, 123, 255, 0.15);
    border-color: #007bff;
}

.fop-lightbox.is-auto-advancing .fop-lightbox-autoadvance:hover {
    background-color: rgba(0, 123, 255, 0.25);
}

/* Dark theme auto-advance button */
.fop-theme-dark .fop-lightbox-autoadvance {
    background-color: rgba(42, 42, 42, 0.9);
    border-color: #4a4a4a;
    color: #e0e0e0;
}

.fop-theme-dark .fop-lightbox-autoadvance:hover {
    background-color: rgba(58, 58, 58, 0.95);
    border-color: #5a5a5a;
}

.fop-theme-dark .fop-lightbox-autoadvance:focus-visible {
    outline-color: #6ea8fe;
}

.fop-theme-dark .fop-lightbox.is-auto-advancing .fop-lightbox-autoadvance {
    background-color: rgba(110, 168, 254, 0.2);
    border-color: #6ea8fe;
}

/* ==========================================================================
   AUTO-ADVANCE PROGRESS BAR
   ========================================================================== */

.fop-autoadvance-progress {
    position: absolute;
    top: 56px;
    left: 0;
    right: 0;
    height: 4px;
    background-color: rgba(0, 0, 0, 0.1);
    z-index: 5;
    overflow: hidden;
    opacity: 0;
    transition: opacity 0.3s ease;
}

/* Show progress bar when auto-advancing */
.fop-lightbox.is-auto-advancing .fop-autoadvance-progress {
    opacity: 1;
}

.fop-autoadvance-progress-bar {
    height: 100%;
    width: 0%;
    background: linear-gradient(90deg, #007bff 0%, #00c6ff 100%);
    transition: width linear;
    will-change: width;
}

/* Animation for progress bar fill */
.fop-lightbox.is-auto-advancing .fop-autoadvance-progress-bar {
    animation: fop-progress-fill var(--fop-autoadvance-duration, 5s) linear forwards;
}

@keyframes fop-progress-fill {
    from {
        width: 0%;
    }
    to {
        width: 100%;
    }
}

/* Dark theme progress bar */
.fop-theme-dark .fop-autoadvance-progress {
    background-color: rgba(255, 255, 255, 0.1);
}

.fop-theme-dark .fop-autoadvance-progress-bar {
    background: linear-gradient(90deg, #6ea8fe 0%, #00c6ff 100%);
}

/* Fullscreen mode progress bar position */
.fop-lightbox.is-fullscreen .fop-autoadvance-progress,
.fop-lightbox.is-fullscreen-fallback .fop-autoadvance-progress,
.fop-lightbox:fullscreen .fop-autoadvance-progress {
    top: 56px;
}

/* Paused state for progress bar */
.fop-lightbox.is-auto-advance-paused .fop-autoadvance-progress-bar {
    animation-play-state: paused;
}

/* Visual indicator that auto-advance is paused */
.fop-lightbox.is-auto-advance-paused .fop-autoadvance-progress {
    opacity: 0.5;
}

.fop-lightbox.is-auto-advance-paused .fop-lightbox-autoadvance {
    opacity: 0.6;
}

/* ==========================================================================
   FULLSCREEN BUTTON
   ========================================================================== */

.fop-lightbox-fullscreen {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    padding: 0;
    background-color: rgba(255, 255, 255, 0.9);
    border: 1px solid #ddd;
    border-radius: 4px;
    cursor: pointer;
    transition: background-color 0.2s, border-color 0.2s;
    font-size: 18px;
    line-height: 1;
}

.fop-lightbox-fullscreen:hover {
    background-color: #fff;
    border-color: #bbb;
}

.fop-lightbox-fullscreen:focus-visible {
    outline: 2px solid #0073aa;
    outline-offset: 2px;
}

/* Show enter icon by default, exit icon in fullscreen */
.fop-lightbox-fullscreen .fop-fullscreen-icon-exit {
    display: none;
}

.fop-lightbox.is-fullscreen .fop-lightbox-fullscreen .fop-fullscreen-icon-enter,
.fop-lightbox.is-fullscreen-fallback .fop-lightbox-fullscreen .fop-fullscreen-icon-enter {
    display: none;
}

.fop-lightbox.is-fullscreen .fop-lightbox-fullscreen .fop-fullscreen-icon-exit,
.fop-lightbox.is-fullscreen-fallback .fop-lightbox-fullscreen .fop-fullscreen-icon-exit {
    display: inline;
}

/* Visual indicator for fullscreen state */
.fop-fullscreen-indicator {
    display: none;
    position: absolute;
    top: -4px;
    right: -4px;
    width: 10px;
    height: 10px;
    background-color: #28a745;
    border-radius: 50%;
    border: 2px solid #fff;
    animation: fop-fullscreen-pulse 2s infinite;
}

.fop-lightbox.is-fullscreen .fop-fullscreen-indicator,
.fop-lightbox.is-fullscreen-fallback .fop-fullscreen-indicator {
    display: block;
}

@keyframes fop-fullscreen-pulse {
    0%, 100% {
        opacity: 1;
        transform: scale(1);
    }
    50% {
        opacity: 0.7;
        transform: scale(1.1);
    }
}

/* Fullscreen button state change when active */
.fop-lightbox.is-fullscreen .fop-lightbox-fullscreen,
.fop-lightbox.is-fullscreen-fallback .fop-lightbox-fullscreen {
    background-color: rgba(40, 167, 69, 0.15);
    border-color: #28a745;
    position: relative;
}

.fop-lightbox.is-fullscreen .fop-lightbox-fullscreen:hover,
.fop-lightbox.is-fullscreen-fallback .fop-lightbox-fullscreen:hover {
    background-color: rgba(40, 167, 69, 0.25);
}

/* Dark theme fullscreen button */
.fop-theme-dark .fop-lightbox-fullscreen {
    background-color: rgba(42, 42, 42, 0.9);
    border-color: #4a4a4a;
    color: #e0e0e0;
}

.fop-theme-dark .fop-lightbox-fullscreen:hover {
    background-color: rgba(58, 58, 58, 0.95);
    border-color: #5a5a5a;
}

.fop-theme-dark .fop-lightbox-fullscreen:focus-visible {
    outline-color: #6ea8fe;
}

/* ==========================================================================
   FULLSCREEN MODE STYLES & FALLBACK
   For browsers without native Fullscreen API support
   ========================================================================== */

/* Native fullscreen styles (applied when browser enters fullscreen) */
.fop-lightbox:fullscreen,
.fop-lightbox:-webkit-full-screen,
.fop-lightbox:-moz-full-screen,
.fop-lightbox:-ms-fullscreen {
    width: 100%;
    height: 100%;
    background-color: #000;
}

.fop-lightbox:fullscreen .fop-lightbox-content,
.fop-lightbox:-webkit-full-screen .fop-lightbox-content,
.fop-lightbox:-moz-full-screen .fop-lightbox-content,
.fop-lightbox:-ms-fullscreen .fop-lightbox-content {
    width: 100%;
    height: 100%;
    max-width: none;
    max-height: none;
    border-radius: 0;
}

/* CSS Fallback for browsers without Fullscreen API */
.fop-lightbox.is-fullscreen-fallback {
    position: fixed !important;
    top: 0 !important;
    left: 0 !important;
    right: 0 !important;
    bottom: 0 !important;
    width: 100vw !important;
    height: 100vh !important;
    z-index: 999999 !important;
    background-color: #000 !important;
}

.fop-lightbox.is-fullscreen-fallback .fop-lightbox-overlay {
    display: none;
}

.fop-lightbox.is-fullscreen-fallback .fop-lightbox-content {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    width: 100%;
    height: 100%;
    max-width: none;
    max-height: none;
    margin: 0;
    border-radius: 0;
    border: none;
}

.fop-lightbox.is-fullscreen-fallback .fop-lightbox-image-container {
    height: calc(100% - 60px);
}

.fop-lightbox.is-fullscreen-fallback .fop-lightbox-image {
    max-height: 100%;
    object-fit: contain;
}

/* ==========================================================================
   Fullscreen Mode - Sidebar (Info Panel) Visibility
   Hide sidebar in fullscreen, show on hover/focus for accessibility
   ========================================================================== */

/* Base sidebar styles for fullscreen (native API) */
.fop-lightbox:fullscreen .fop-lightbox-info,
.fop-lightbox:-webkit-full-screen .fop-lightbox-info,
.fop-lightbox:-moz-full-screen .fop-lightbox-info,
.fop-lightbox:-ms-fullscreen .fop-lightbox-info,
.fop-lightbox.is-fullscreen-fallback .fop-lightbox-info,
.fop-lightbox.is-fullscreen .fop-lightbox-info {
    position: fixed;
    right: -320px;
    top: 60px;
    bottom: 0;
    width: 300px;
    max-width: 90vw;
    background-color: rgba(255, 255, 255, 0.98);
    box-shadow: -4px 0 20px rgba(0, 0, 0, 0.3);
    overflow-y: auto;
    transition: right 0.3s ease-in-out;
    z-index: 10;
    padding: 20px;
}

/* Show sidebar on hover */
.fop-lightbox:fullscreen .fop-lightbox-info:hover,
.fop-lightbox:-webkit-full-screen .fop-lightbox-info:hover,
.fop-lightbox:-moz-full-screen .fop-lightbox-info:hover,
.fop-lightbox:-ms-fullscreen .fop-lightbox-info:hover,
.fop-lightbox.is-fullscreen-fallback .fop-lightbox-info:hover,
.fop-lightbox.is-fullscreen .fop-lightbox-info:hover,
.fop-lightbox:fullscreen .fop-lightbox-content:hover .fop-lightbox-info,
.fop-lightbox:-webkit-full-screen .fop-lightbox-content:hover .fop-lightbox-info,
.fop-lightbox:-moz-full-screen .fop-lightbox-content:hover .fop-lightbox-info,
.fop-lightbox:-ms-fullscreen .fop-lightbox-content:hover .fop-lightbox-info,
.fop-lightbox.is-fullscreen-fallback .fop-lightbox-content:hover .fop-lightbox-info,
.fop-lightbox.is-fullscreen .fop-lightbox-content:hover .fop-lightbox-info {
    right: 0;
}

/* Show sidebar on focus within (keyboard accessibility) */
.fop-lightbox:fullscreen .fop-lightbox-info:focus-within,
.fop-lightbox:-webkit-full-screen .fop-lightbox-info:focus-within,
.fop-lightbox:-moz-full-screen .fop-lightbox-info:focus-within,
.fop-lightbox:-ms-fullscreen .fop-lightbox-info:focus-within,
.fop-lightbox.is-fullscreen-fallback .fop-lightbox-info:focus-within,
.fop-lightbox.is-fullscreen .fop-lightbox-info:focus-within {
    right: 0;
}

/* Sidebar trigger zone on right edge for easier hover access */
.fop-lightbox.is-fullscreen::after,
.fop-lightbox.is-fullscreen-fallback::after {
    content: '';
    position: fixed;
    right: 0;
    top: 60px;
    bottom: 0;
    width: 30px;
    z-index: 9;
    cursor: pointer;
}

/* When hovering the trigger zone, show the sidebar */
.fop-lightbox.is-fullscreen:hover .fop-lightbox-info,
.fop-lightbox.is-fullscreen-fallback:hover .fop-lightbox-info {
    right: 0;
}

/* Dark theme sidebar in fullscreen */
.fop-gallery-container.fop-theme-dark .fop-lightbox:fullscreen .fop-lightbox-info,
.fop-gallery-container.fop-theme-dark .fop-lightbox:-webkit-full-screen .fop-lightbox-info,
.fop-gallery-container.fop-theme-dark .fop-lightbox:-moz-full-screen .fop-lightbox-info,
.fop-gallery-container.fop-theme-dark .fop-lightbox:-ms-fullscreen .fop-lightbox-info,
.fop-gallery-container.fop-theme-dark .fop-lightbox.is-fullscreen-fallback .fop-lightbox-info,
.fop-gallery-container.fop-theme-dark .fop-lightbox.is-fullscreen .fop-lightbox-info,
.fop-theme-dark .fop-lightbox:fullscreen .fop-lightbox-info,
.fop-theme-dark .fop-lightbox:-webkit-full-screen .fop-lightbox-info,
.fop-theme-dark .fop-lightbox:-moz-full-screen .fop-lightbox-info,
.fop-theme-dark .fop-lightbox:-ms-fullscreen .fop-lightbox-info,
.fop-theme-dark .fop-lightbox.is-fullscreen-fallback .fop-lightbox-info,
.fop-theme-dark .fop-lightbox.is-fullscreen .fop-lightbox-info {
    background-color: rgba(30, 30, 30, 0.98);
    color: #e0e0e0;
}

/* Mobile: smaller sidebar width */
@media (max-width: 480px) {
    .fop-lightbox:fullscreen .fop-lightbox-info,
    .fop-lightbox:-webkit-full-screen .fop-lightbox-info,
    .fop-lightbox:-moz-full-screen .fop-lightbox-info,
    .fop-lightbox:-ms-fullscreen .fop-lightbox-info,
    .fop-lightbox.is-fullscreen-fallback .fop-lightbox-info,
    .fop-lightbox.is-fullscreen .fop-lightbox-info {
        width: 250px;
        right: -260px;
    }
}

/* ==========================================================================
   Dark Theme WordPress Navigation Override
   ========================================================================== */

/* 
 * Force header navigation links to be white when dark theme is active.
 * High specificity needed to override WordPress Twenty Twenty-Five theme's
 * has-contrast-color !important rule.
 */

/* When .dark class is applied to html (via localStorage/theme toggle) */
html.dark .wp-block-template-part .wp-block-navigation a,
html.dark .wp-block-template-part .wp-block-navigation .wp-block-navigation-item__content,
html.dark .wp-block-template-part .wp-block-navigation .wp-block-page-list a,
html.dark .wp-block-template-part .wp-block-navigation.has-contrast-color,
html.dark .wp-block-template-part .wp-block-navigation__responsive-container.has-contrast-color,
html.dark .wp-block-template-part .wp-block-navigation .has-contrast-color {
    color: #ffffff !important;
}

html.dark .wp-block-template-part .wp-block-navigation a:hover,
html.dark .wp-block-template-part .wp-block-navigation .wp-block-navigation-item__content:hover {
    color: #e5e5e5 !important;
}

/* ==========================================================================
    Lightbox Dark Mode Override - FORCE LIGHT MODE IN LIGHTBOX ONLY
    ========================================================================== */

/*
 * STRICT: Dark mode is disabled in the lightbox to ensure optimal photo viewing
 * and consistent UI experience. All dark mode variables are overridden here.
 */

html.dark .fop-lightbox {
    color-scheme: light;
}

html.dark .fop-lightbox-content,
html.dark .fop-lightbox-info,
html.dark .fop-lightbox-header,
html.dark .fop-lightbox-caption,
html.dark .fop-lightbox-notes,
html.dark .fop-lightbox-exif,
html.dark .fop-lightbox-comments {
    background: #ffffff !important;
    color: #1a1a1a !important;
}

html.dark .fop-lightbox-title {
    color: #333 !important;
}

html.dark .fop-lightbox-photographer {
    color: #666 !important;
}

html.dark .fop-lightbox-header {
    border-bottom-color: #eee !important;
}

html.dark .fop-lightbox-notes {
    background: #e8f4ff !important;
    border-left-color: #2196F3 !important;
}

html.dark .fop-lightbox-notes-title {
    color: #1a1a1a !important;
}

html.dark .fop-lightbox-notes-text {
    color: #333 !important;
}

html.dark .fop-lightbox-exif {
    background: #f8f9fa !important;
}

html.dark .fop-exif-row {
    color: #1a1a1a !important;
}

html.dark .fop-exif-label {
    color: #666 !important;
}

html.dark .fop-exif-value {
    color: #1a1a1a !important;
}

html.dark .fop-comments-section {
    background: #ffffff !important;
}

html.dark .fop-comments-title {
    color: #333 !important;
}

html.dark .fop-comment {
    background: #f8f9fa !important;
    border-color: #e0e0e0 !important;
}

html.dark .fop-comment-author {
    color: #2196F3 !important;
}

html.dark .fop-comment-text {
    color: #333 !important;
}

html.dark .fop-comment-date {
    color: #999 !important;
}

html.dark .fop-comment-form textarea,
html.dark .fop-comment-form select,
html.dark .fop-comment-form input[type="text"],
html.dark .fop-lightbox-comment-form textarea,
html.dark .fop-lightbox-comment-form select,
html.dark .fop-lightbox-comment-form input[type="text"] {
    background: #ffffff !important;
    color: #1a1a1a !important;
    border-color: #ddd !important;
}

html.dark .fop-comment-form textarea::placeholder,
html.dark .fop-lightbox-comment-form textarea::placeholder {
    color: #999 !important;
}

html.dark .fop-identity-locked-message {
    background: #fff3cd !important;
    color: #856404 !important;
    border-color: #ffc107 !important;
}

html.dark .fop-comment-btn-submit {
    background: #FFD700 !important;
    color: #000 !important;
}

html.dark .fop-comment-btn-submit:hover {
    background: #e5c200 !important;
}

html.dark .fop-lightbox-comment-submit {
    background: #FFD700 !important;
    color: #000 !important;
}

html.dark .fop-lightbox-comment-submit:hover {
    background: #e5c200 !important;
}

/* ==========================================================================
   Comment Form Notices & Disabled State
   ========================================================================== */

.fop-comment-notice {
    display: none;
    margin-bottom: 12px;
    padding: 10px 12px;
    border-radius: 6px;
    border: 1px solid transparent;
    font-size: 0.95rem;
    line-height: 1.4;
}

.fop-comment-notice.is-visible {
    display: block;
}

.fop-comment-notice.is-warning {
    background-color: #fff8e1;
    border-color: #ffe082;
    color: #7a5b00;
}

.fop-comment-notice.is-error {
    background-color: #fdecea;
    border-color: #f5c6cb;
    color: #8a1c1c;
}

.fop-comment-notice.is-success {
    background-color: #e8f5e9;
    border-color: #c8e6c9;
    color: #1b5e20;
}

html.dark .fop-comment-notice.is-warning {
    color: #7a5b00;
}

html.dark .fop-comment-notice.is-error {
    color: #8a1c1c;
}

html.dark .fop-comment-notice.is-success {
    color: #1b5e20;
}

.fop-comment-form.is-disabled,
.fop-lightbox-comment-form.is-disabled {
    opacity: 0.65;
}

/* ==========================================================================
   Mobile/Tablet Refinements for Sidebar & Stage
   ========================================================================== */

@media screen and (max-width: 1024px) {
    /* When the layout stacks vertically, ensure the photo title is centered */
    .fop-slideshow-inline-title {
        text-align: center;
    }
}

@media screen and (max-width: 768px) {
    /* Match the student filter width to the 100% wide Photo Details button */
    .fop-slideshow-meta .fop-photo-details-student-filter {
        justify-content: center;
        width: 100%;
    }
    
    .fop-slideshow-meta .fop-student-filter-wrapper {
        width: 100%;
    }
    
    /* Ensure the dropdown menu itself spans the full width too */
    .fop-slideshow-meta .fop-student-filter-dropdown {
        width: 100%;
    }
}

@media screen and (max-width: 640px) {
    /* Make the locked stage height fluid on mobile so it doesn't push the buttons off-screen */
    .fop-slideshow-image-area {
        height: clamp(280px, 60vh, 400px);
        padding: 12px;
    }
}

/* ==========================================================================
   FR-2: Week-Based Photo Filtering
   ========================================================================== */

/* Week Badge on Photo Cards */
.fop-week-badge {
    position: absolute;
    top: 10px;
    left: 10px;
    background: rgba(30, 41, 59, 0.85); /* Neutral slate */
    backdrop-filter: blur(4px);
    color: #fff;
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    padding: 4px 10px;
    border-radius: 12px;
    z-index: 2;
    pointer-events: none;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.15);
}

/* Adjust timeline dot to show active selection state */
.fop-week-timeline-node.is-filtered .fop-week-timeline-circle {
    box-shadow: 0 0 0 4px rgba(33, 150, 243, 0.4); /* Blue highlight */
    border-color: #2196F3;
    background: #2196F3;
    color: #fff;
}

.fop-week-timeline-node.is-filtered .fop-week-timeline-label {
    color: #2196F3;
    font-weight: 700;
}

/* Hide filtered photos */
.fop-photo-card[data-filtered="true"] {
    display: none;
}

/* Dark mode overrides */
body.dark-mode .fop-week-badge,
:root.dark .fop-week-badge {
    background: rgba(75, 85, 99, 0.9);
}
