/* === VARIABILI === */
:root {
    --color-bg-primary:    #1e2a3a;
    --color-bg-card:       #16213e;
    --color-bg-hero:       #0f3460;
    --color-accent:        #e8b04b;
    --color-text-primary:  #f0f0f0;
    --color-text-secondary:#aaaaaa;
    --color-text-muted:    #888888;
    --color-border:        rgba(232,176,75,0.2);
    --color-border-hover:  rgba(232,176,75,0.5);
    --color-bg-footer:     #141e28;
    --color-institutional: #c0392b;
    --font-serif:          'Playfair Display', Georgia, serif;
    --font-sans:           'Inter', system-ui, sans-serif;
}

/* === BASE === */
body {
    background-color: var(--color-bg-primary);
    color: var(--color-text-primary);
    font-family: var(--font-sans);
    font-weight: 400;
    line-height: 1.6;
    margin: 0;
}

h1, h2, h3 {
    font-family: var(--font-serif);
    font-weight: 700;
    color: var(--color-text-primary);
}

h4, h5, h6 {
    font-family: var(--font-sans);
    font-weight: 600;
    color: var(--color-text-primary);
}

a {
    color: var(--color-accent);
    text-decoration: none;
}

a:hover {
    color: var(--color-text-primary);
}

a:focus-visible {
    outline: 2px solid var(--color-accent);
    outline-offset: 2px;
    border-radius: 2px;
}

/* === SKIP LINK === */
.skip-link {
    position: absolute;
    top: -100px;
    left: 1rem;
    background: var(--color-accent);
    color: var(--color-bg-primary);
    padding: 0.5rem 1rem;
    font-weight: 600;
    z-index: 9999;
    border-radius: 0 0 4px 4px;
    transition: top 0.2s;
}

.skip-link:focus {
    top: 0;
}

/* === NAVBAR === */
.pub-navbar {
    position: sticky;
    top: 0;
    z-index: 1000;
    background: #ffffff;
    border-bottom: 1px solid #e5e5e5;
    padding: 0.75rem 0;
    transition: background 0.3s ease, box-shadow 0.3s ease, border-color 0.3s ease;
}

.pub-navbar.scrolled {
    background: rgba(15, 15, 35, 0.95);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    box-shadow: 0 2px 20px rgba(0, 0, 0, 0.4);
    border-bottom-color: var(--color-border);
}

.pub-navbar .navbar-brand {
    display: flex;
    align-items: center;
    gap: 0.625rem;
    text-decoration: none;
}

.pub-navbar .brand-icon {
    width: 44px;
    height: 44px;
    background: var(--color-accent);
    border-radius: 4px;
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 2px;
}

.pub-navbar .brand-icon img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.pub-navbar .brand-name {
    font-family: var(--font-sans);
    font-weight: 700;
    font-size: 0.8125rem;
    letter-spacing: 0.08em;
    color: #1a1a2e;
    text-transform: uppercase;
    transition: color 0.3s ease;
}

.pub-navbar.scrolled .brand-name {
    color: var(--color-text-primary);
}

.pub-navbar .nav-link {
    font-family: var(--font-sans);
    font-weight: 600;
    font-size: 0.8125rem;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: #444444;
    padding: 0.375rem 0.75rem;
    border-radius: 3px;
    transition: color 0.3s ease;
}

.pub-navbar.scrolled .nav-link {
    color: var(--color-text-secondary);
}

.pub-navbar .nav-link:hover,
.pub-navbar .nav-link.active,
.pub-navbar.scrolled .nav-link:hover,
.pub-navbar.scrolled .nav-link.active {
    color: var(--color-accent);
}

.pub-navbar .nav-link:focus-visible {
    outline: 2px solid var(--color-accent);
    outline-offset: 2px;
}

/* Search nel navbar */
.pub-navbar .search-form {
    display: flex;
    gap: 0.375rem;
}

.pub-navbar .search-input {
    background: #f5f5f5;
    border: 1px solid #cccccc;
    color: #1a1a2e;
    border-radius: 4px;
    padding: 0.375rem 0.75rem;
    font-size: 0.875rem;
    width: 180px;
}

.pub-navbar .search-input::placeholder {
    color: #666666;
}

.pub-navbar .search-input:focus {
    outline: 2px solid var(--color-accent);
    outline-offset: 0;
    background: #ffffff;
}

/* navbar scrollata: input adattato allo sfondo scuro */
.pub-navbar.scrolled .search-input {
    background: rgba(255,255,255,0.10);
    border-color: var(--color-border);
    color: var(--color-text-primary);
}

.pub-navbar.scrolled .search-input::placeholder {
    color: #999999;
}

.pub-navbar.scrolled .search-input:focus {
    background: rgba(255,255,255,0.16);
}

/* === HAMBURGER === */
.nav-hamburger {
    background: none;
    border: 1.5px solid #cccccc;
    border-radius: 4px;
    padding: 0.375rem 0.5rem;
    cursor: pointer;
    display: flex;
    flex-direction: column;
    gap: 4px;
    transition: border-color 0.2s;
}

.nav-hamburger:focus-visible {
    outline: 2px solid var(--color-accent);
    outline-offset: 2px;
}

.pub-navbar.scrolled .nav-hamburger {
    border-color: var(--color-border);
}

.nav-hamburger__bar {
    display: block;
    width: 20px;
    height: 2px;
    background: #444444;
    border-radius: 2px;
    transition: background 0.3s;
}

.pub-navbar.scrolled .nav-hamburger__bar {
    background: var(--color-text-secondary);
}

/* === MENU MOBILE === */
.nav-mobile-menu {
    display: none;
    background: #ffffff;
    border-top: 1px solid #e5e5e5;
    padding: 0.5rem 0 1rem;
}

.nav-mobile-menu.open {
    display: block;
}

.pub-navbar.scrolled .nav-mobile-menu {
    background: rgba(15,15,35,0.98);
    border-top-color: var(--color-border);
}

.nav-mobile-link {
    display: block;
    padding: 0.625rem 0;
    font-family: var(--font-sans);
    font-weight: 600;
    font-size: 0.9375rem;
    color: #444444;
    text-decoration: none;
    border-bottom: 1px solid #f0f0f0;
}

.pub-navbar.scrolled .nav-mobile-link {
    color: var(--color-text-secondary);
    border-bottom-color: var(--color-border);
}

.nav-mobile-link:hover,
.nav-mobile-link.active {
    color: var(--color-accent);
}

.nav-mobile-link:focus-visible {
    outline: 2px solid var(--color-accent);
    outline-offset: 2px;
}

.nav-mobile-search {
    display: flex;
    gap: 0.375rem;
    padding: 0.75rem 0;
}

.nav-mobile-search .search-input {
    flex: 1;
}

/* === SEARCH BTN === */
.pub-navbar .search-btn {
    background: var(--color-accent);
    color: var(--color-bg-primary);
    border: none;
    border-radius: 4px;
    padding: 0.375rem 0.75rem;
    font-weight: 600;
    cursor: pointer;
    transition: opacity 0.2s;
}

.pub-navbar .search-btn:hover {
    opacity: 0.85;
}

/* === CARD CON OVERLAY === */
.pub-card {
    position: relative;
    border-radius: 8px;
    overflow: hidden;
    background: var(--color-bg-card);
    display: block;
    text-decoration: none;
    transition: transform 0.3s ease;
}

.pub-card:hover {
    transform: scale(1.02);
}

.pub-card:focus-visible {
    outline: 2px solid var(--color-accent);
    outline-offset: 2px;
}

.pub-card__image {
    aspect-ratio: 4 / 3;
    width: 100%;
    object-fit: cover;
    display: block;
}

.pub-card--photo .pub-card__image {
    aspect-ratio: 3 / 2;
}

.pub-card__placeholder {
    aspect-ratio: 4 / 3;
    background: var(--color-bg-hero);
    display: flex;
    align-items: center;
    justify-content: center;
}

.pub-card--photo .pub-card__placeholder {
    aspect-ratio: 3 / 2;
}

.pub-card__overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: linear-gradient(transparent 30%, rgba(0,0,0,0.85) 100%);
    padding: 2rem 0.875rem 0.875rem;
}

.pub-card__title {
    font-family: var(--font-sans);
    font-weight: 600;
    font-size: 0.9375rem;
    color: var(--color-text-primary);
    margin: 0 0 0.25rem;
    line-height: 1.3;
}

.pub-card__meta {
    font-size: 0.8125rem;
    color: var(--color-accent);
    font-weight: 300;
    margin: 0;
}

/* Card compatta (archivio — riga orizzontale di 4 per categoria) */
.pub-card--compact .pub-card__image,
.pub-card--compact .pub-card__placeholder {
    aspect-ratio: 16 / 9;
}

.pub-card--compact .pub-card__title {
    font-size: 0.8125rem;
}

.pub-card--compact .pub-card__meta {
    font-size: 0.75rem;
}

/* Tile categorie home e tile "altri album" — stesso stile */
.pub-category-tile,
.album-more-tile {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    width: 100%;
    border-radius: 8px;
    border: 1px solid rgba(255,255,255,0.12);
    background: var(--color-bg-card);
    color: var(--color-accent);
    text-decoration: none;
    gap: 0.25rem;
    transition: background 0.2s ease;
    aspect-ratio: 16 / 9;
}

.pub-category-tile:hover,
.pub-category-tile:focus-visible,
.album-more-tile:hover,
.album-more-tile:focus-visible {
    background: var(--color-bg-hero);
    outline: 2px solid var(--color-accent);
    outline-offset: 2px;
}

/* Tile categoria: non ha aspect-ratio fisso, cresce con il contenuto */
.pub-category-tile {
    aspect-ratio: unset;
    align-items: flex-start;
    padding: 1.25rem;
    gap: 0.375rem;
}

.pub-category-tile__name {
    font-size: 1rem;
    font-weight: 600;
    color: var(--color-text-primary);
    margin: 0;
    line-height: 1.3;
}

.pub-category-tile__desc {
    font-size: 0.8125rem;
    color: var(--color-text-muted);
    margin: 0;
}

.pub-category-tile__count {
    font-size: 0.75rem;
    color: var(--color-accent);
    margin-top: 0.25rem;
}

.album-more-tile__count {
    font-size: 1.5rem;
    font-weight: 700;
    line-height: 1;
}

.album-more-tile__label {
    font-size: 0.75rem;
    font-weight: 400;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--color-text-muted);
}

/* === SEZIONE LABEL === */
.section-label {
    font-family: var(--font-sans);
    font-weight: 600;
    font-size: 0.75rem;
    letter-spacing: 0.15em;
    text-transform: uppercase;
    color: var(--color-accent);
    margin-bottom: 0.5rem;
}

/* === BOTTONI === */
.btn-pub-primary {
    display: inline-block;
    background: var(--color-accent);
    color: var(--color-bg-primary);
    font-family: var(--font-sans);
    font-weight: 600;
    font-size: 0.875rem;
    padding: 0.5rem 1.25rem;
    border-radius: 4px;
    border: none;
    cursor: pointer;
    text-decoration: none;
    transition: opacity 0.2s;
}

.btn-pub-primary:hover {
    opacity: 0.85;
    color: var(--color-bg-primary);
}

.btn-pub-secondary {
    display: inline-block;
    border: 1.5px solid var(--color-accent);
    color: var(--color-accent);
    background: transparent;
    font-family: var(--font-sans);
    font-weight: 600;
    font-size: 0.875rem;
    padding: 0.5rem 1.25rem;
    border-radius: 4px;
    cursor: pointer;
    text-decoration: none;
    transition: background 0.2s, color 0.2s;
}

.btn-pub-secondary:hover {
    background: rgba(232,176,75,0.12);
    color: var(--color-accent);
}

.btn-pub-primary:focus-visible,
.btn-pub-secondary:focus-visible {
    outline: 2px solid var(--color-accent);
    outline-offset: 2px;
}

/* === PAGE HEADER (pagine interne) === */
.page-header {
    padding: 2.5rem 0 2rem;
}

/* === HERO === */
.pub-hero {
    background: linear-gradient(135deg, var(--color-bg-hero) 0%, var(--color-bg-card) 100%);
    padding: 4rem 0 3rem;
}

.pub-hero__label {
    font-size: 0.75rem;
    letter-spacing: 0.2em;
    text-transform: uppercase;
    color: var(--color-accent);
    font-weight: 600;
    margin-bottom: 1rem;
    display: block;
}

.pub-hero__title {
    font-size: clamp(2rem, 5vw, 3.5rem);
    color: var(--color-text-primary);
    margin-bottom: 1rem;
}

.pub-hero__desc {
    color: var(--color-text-secondary);
    font-size: 1.125rem;
    max-width: 600px;
}

/* === BREADCRUMB === */
.pub-breadcrumb {
    list-style: none;
    padding: 0;
    margin: 0 0 1.5rem;
    display: flex;
    flex-wrap: wrap;
    gap: 0.25rem;
    font-size: 0.875rem;
    color: var(--color-text-muted);
}

.pub-breadcrumb li + li::before {
    content: '/';
    margin-right: 0.25rem;
    color: var(--color-text-muted);
}

.pub-breadcrumb a {
    color: var(--color-text-secondary);
}

.pub-breadcrumb a:hover {
    color: var(--color-accent);
}

/* === SEZIONE METADATI === */
.album-meta-line {
    font-size: 0.875rem;
    color: var(--color-text-muted);
    margin: 0 0 1.5rem;
    line-height: 1.5;
}

/* === BADGE TAG === */
.pub-tag {
    display: inline-block;
    background: rgba(232,176,75,0.12);
    border: 1px solid var(--color-border);
    color: var(--color-accent);
    font-size: 0.75rem;
    font-weight: 600;
    padding: 0.2rem 0.6rem;
    border-radius: 3px;
    margin: 0.1rem;
}

/* === PAGINAZIONE === */
.pagination {
    justify-content: center;
    gap: 0.25rem;
}

.page-link {
    background: var(--color-bg-card);
    border-color: var(--color-border);
    color: var(--color-text-secondary);
    border-radius: 3px;
}

.page-link:hover {
    background: var(--color-bg-hero);
    color: var(--color-accent);
    border-color: var(--color-border-hover);
}

.page-item.active .page-link {
    background: var(--color-accent);
    border-color: var(--color-accent);
    color: var(--color-bg-primary);
}

/* === SORT + LOAD MORE === */
.sort-controls {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    flex-wrap: wrap;
    margin-bottom: 1.25rem;
}

.sort-controls__label {
    font-size: 0.8125rem;
    color: var(--color-text-muted);
    margin-right: 0.25rem;
}

.sort-btn {
    padding: 0.3rem 0.85rem;
    font-size: 0.8125rem;
    border: 1px solid var(--color-border);
    border-radius: 20px;
    background: transparent;
    color: var(--color-text-secondary);
    cursor: pointer;
    transition: background 0.15s, color 0.15s, border-color 0.15s;
    line-height: 1.4;
}

.sort-btn:hover {
    background: var(--color-bg-hero);
    color: var(--color-accent);
    border-color: var(--color-border-hover);
}

.sort-btn--active {
    background: var(--color-accent);
    color: var(--color-bg-primary);
    border-color: var(--color-accent);
}

.sort-btn--active:hover {
    background: var(--color-accent);
    color: var(--color-bg-primary);
}

.albums-counter {
    margin-left: auto;
    font-size: 0.8125rem;
    color: var(--color-text-muted);
}

.pub-load-more {
    display: block;
    margin: 2rem auto 0;
    padding: 0.6rem 2rem;
    font-size: 0.9375rem;
    border: 1px solid var(--color-border);
    border-radius: 4px;
    background: transparent;
    color: var(--color-text-secondary);
    cursor: pointer;
    transition: background 0.15s, color 0.15s, border-color 0.15s;
    min-width: 180px;
    text-align: center;
}

.pub-load-more:hover:not(:disabled) {
    background: var(--color-bg-hero);
    color: var(--color-accent);
    border-color: var(--color-border-hover);
}

.pub-load-more:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

.pub-load-more__spinner {
    display: inline-block;
    width: 0.9em;
    height: 0.9em;
    border: 2px solid currentColor;
    border-top-color: transparent;
    border-radius: 50%;
    animation: spin 0.6s linear infinite;
    vertical-align: middle;
    margin-left: 0.4em;
}

/* === FOOTER === */
.pub-footer {
    background: var(--color-bg-footer);
    border-top: 1px solid rgba(255,255,255,0.08);
    padding: 2.5rem 0 1.5rem;
    margin-top: 2rem;
}

.pub-footer__title {
    font-size: 1rem;
    font-weight: 700;
    color: var(--color-text-primary);
    margin-bottom: 0.25rem;
}

.pub-footer__sub {
    font-size: 0.875rem;
    color: var(--color-text-muted);
    margin-bottom: 0;
}

.pub-footer a {
    color: var(--color-text-secondary);
    font-size: 0.875rem;
    display: block;
    margin-bottom: 0.375rem;
}

.pub-footer a:hover {
    color: var(--color-accent);
}

.pub-footer__brand {
    display: flex;
    align-items: center;
    gap: 0.875rem;
}

.pub-footer__logo {
    height: 62px;
    width: auto;
    flex-shrink: 0;
    filter: brightness(0) invert(1);
    opacity: 0.85;
}

.pub-footer__brand-sep {
    display: block;
    width: 1px;
    height: 52px;
    background: rgba(255,255,255,0.3);
    flex-shrink: 0;
}

.pub-footer__copy {
    border-top: 1px solid var(--color-border);
    margin-top: 1.5rem;
    padding-top: 1rem;
    font-size: 0.8125rem;
    color: var(--color-text-muted);
    text-align: center;
}

/* === FORM AUTH === */
/* #141e28 su testo #f0f0f0: contrasto ~11:1, supera WCAG 2.1 AA e AAA */
.auth-card {
    background: var(--color-bg-footer);
}

/* === FORM RICERCA === */
.pub-search-input {
    background: var(--color-bg-card);
    border: 1px solid var(--color-border);
    color: var(--color-text-primary);
    border-radius: 4px;
    padding: 0.625rem 1rem;
    font-size: 1rem;
    width: 100%;
}

.pub-search-input:focus {
    outline: 2px solid var(--color-accent);
    outline-offset: 0;
    border-color: var(--color-accent);
    background: var(--color-bg-hero);
}

.pub-form-label {
    font-size: 0.8125rem;
    font-weight: 600;
    color: var(--color-text-secondary);
    margin-bottom: 0.375rem;
    display: block;
}

.pub-form-select {
    background: var(--color-bg-card);
    border: 1px solid var(--color-border);
    color: var(--color-text-primary);
    border-radius: 4px;
    padding: 0.5rem 0.75rem;
    width: 100%;
}

.pub-form-select:focus {
    outline: 2px solid var(--color-accent);
    outline-offset: 0;
}

/* === DOWNLOAD CARD === */
.pub-download-card {
    background: var(--color-bg-card);
    border: 1px solid var(--color-border);
    border-radius: 6px;
    padding: 1rem;
}

.pub-download-card h2 {
    font-family: var(--font-sans);
    font-size: 0.8125rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: var(--color-text-muted);
    margin-bottom: 0.75rem;
}

/* === NAVIGAZIONE FOTO === */
.pub-photo-nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.75rem 0;
    border-top: 1px solid var(--color-border);
    border-bottom: 1px solid var(--color-border);
    margin: 1.5rem 0;
}

/* === CONSIGLIERE CARD === */
.councillor-card {
    background: var(--color-bg-card);
    border-radius: 8px;
    overflow: hidden;
    border: 1px solid var(--color-border);
    transition: border-color 0.2s;
    display: block;
    text-decoration: none;
}

.councillor-card:hover {
    border-color: var(--color-border-hover);
}

.councillor-card__img {
    width: 100%;
    aspect-ratio: 3 / 4;
    object-fit: cover;
}

.councillor-card__placeholder {
    width: 100%;
    aspect-ratio: 3 / 4;
    background: var(--color-bg-hero);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--color-text-muted);
    font-size: 2rem;
}

.councillor-card__body {
    padding: 0.75rem;
}

.councillor-card__name {
    font-weight: 700;
    font-size: 0.9375rem;
    color: var(--color-text-primary);
    margin-bottom: 0.25rem;
}

.councillor-card__party {
    font-size: 0.8125rem;
    color: var(--color-text-secondary);
    margin-bottom: 0.125rem;
}

.councillor-card__leg {
    font-size: 0.75rem;
    color: var(--color-text-muted);
}

/* ========================================
   PAGINA FOTO PUBBLICA (foto-show)
   Layout fullscreen no-scroll desktop
   ======================================== */

.foto-show-page {
    height: calc(100vh - 65px); /* compensa navbar */
    display: flex;
    flex-direction: column;
    overflow: hidden;
    background: #111;
    font-family: Georgia, serif;
}

/* Zona superiore: 2/3 foto + 1/3 pannello */
.foto-show-zona {
    display: flex;
    flex: 1;
    min-height: 0;
}

/* Area foto (2/3) */
.foto-show-area {
    flex: 2;
    background: #1a1a1a;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    padding: 20px 52px;
    min-height: 0;
}

.foto-show-img {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
    display: block;
}

/* Frecce prev/next */
.foto-show-freccia {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    color: rgba(255, 255, 255, .3);
    font-size: 2.5rem;
    cursor: pointer;
    padding: 12px;
    line-height: 1;
    transition: color .2s;
    text-decoration: none;
    user-select: none;
    background: none;
    border: none;
}

.foto-show-freccia:hover {
    color: rgba(255, 255, 255, .8);
}

.foto-show-freccia-sx { left: 6px; }
.foto-show-freccia-dx { right: 6px; }

/* Pannello destro (1/3) */
.foto-show-pannello {
    flex: 1;
    background: #111;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    padding: 40px 30px;
}

.foto-show-album-link {
    font-family: Arial, sans-serif;
    font-size: .95rem;
    font-weight: 600;
    color: #fff;
    text-decoration: none;
    letter-spacing: .02em;
}

.foto-show-album-link:hover {
    color: #c9a84c;
}

.foto-show-centro {
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.foto-show-titolo {
    font-family: Arial, sans-serif;
    font-size: 1.2rem;
    font-weight: 700;
    color: #c9a84c;
    line-height: 1.3;
}

.foto-show-didascalia {
    font-family: Georgia, serif;
    font-size: .95rem;
    font-style: italic;
    color: #c9a84c;
    line-height: 1.75;
    opacity: .85;
    margin: 0;
}

/* Data e luogo: #aaa su #111 = ~5.7:1 contrasto, WCAG AA */
.foto-show-meta {
    font-family: Arial, sans-serif;
    font-size: .85rem;
    color: #aaa;
    display: flex;
    flex-direction: column;
    gap: 5px;
}

/* Box inferiori */
.foto-show-box-row {
    display: flex;
    border-top: 3px solid #c9a84c;
    background: #fff;
    flex-shrink: 0;
}

.foto-show-box {
    padding: 16px 20px;
    border-right: 1px solid #eee;
    display: flex;
    flex-direction: column;
    gap: 6px;
    overflow: hidden;
}

.foto-show-box:last-child {
    border-right: none;
}

.foto-show-box-album    { flex: 2; }
.foto-show-box-allegati { flex: 2; }
.foto-show-box-tag      { flex: 1; }
.foto-show-box-download { flex: 1; background: #fafafa; }

.foto-show-box-label {
    font-family: Arial, sans-serif;
    font-size: .75rem;
    font-weight: 700;
    color: #7a6020;
    text-transform: uppercase;
    letter-spacing: .07em;
    margin-bottom: 4px;
}

.foto-show-album-row-link {
    font-family: Arial, sans-serif;
    font-size: .78rem;
    color: #333;
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 6px;
}

.foto-show-album-row-link:hover { color: #000; }

.foto-show-badge-cop {
    background: #c9a84c;
    color: #fff;
    font-size: .75rem;
    padding: 1px 6px;
    border-radius: 2px;
    flex-shrink: 0;
}

/* Breadcrumb dentro box album */
.foto-show-breadcrumb {
    font-family: Arial, sans-serif;
    font-size: .75rem;
    color: #bbb;
    margin-bottom: 8px;
    line-height: 1.4;
}

.foto-show-breadcrumb a {
    color: #bbb;
    text-decoration: none;
}

.foto-show-breadcrumb a:hover { color: #888; }

/* Barra inferiore pagina foto consigliere: breadcrumb + download affiancati */
.cons-photo-bottom-bar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    flex-wrap: wrap;
}

.cons-photo-breadcrumb {
    font-family: var(--font-sans);
    font-size: .875rem;
    color: #555;
    line-height: 1.4;
}

.cons-photo-breadcrumb a {
    font-family: var(--font-sans);
    color: #555;
    text-decoration: underline;
}

.cons-photo-breadcrumb a:hover {
    color: #222;
}

.cons-photo-download-bar {
    display: flex;
    align-items: center;
    gap: .5rem;
    flex-wrap: wrap;
    justify-content: flex-end;
}

.foto-show-allegato-link {
    font-family: Arial, sans-serif;
    font-size: .75rem;
    color: #555;
    text-decoration: none;
    display: block;
}

.foto-show-allegato-link:hover { color: #111; }

.foto-show-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 5px;
}

.foto-show-tag {
    font-family: Arial, sans-serif;
    background: #f5f0e0;
    border-radius: 10px;
    padding: 3px 9px;
    font-size: .75rem;
    color: #7a6020;
}

.foto-show-dl-btn {
    font-family: Arial, sans-serif;
    display: block;
    text-align: center;
    padding: 7px 10px;
    border-radius: 3px;
    font-size: .75rem;
    text-decoration: none;
    margin-bottom: 5px;
}

.foto-show-dl-btn:last-child { margin-bottom: 0; }

.foto-show-dl-btn-outline {
    border: 1px solid #ccc;
    color: #444;
    background: #fff;
}

.foto-show-dl-btn-outline:hover { background: #f5f5f5; color: #222; }

.foto-show-dl-btn-primary {
    background: #1a1a1a;
    color: #c9a84c;
    font-weight: 600;
    border: none;
}

.foto-show-dl-btn-primary:hover { background: #2a2a2a; color: #c9a84c; }

/* === LAYOUT MOBILE (< 992px) === */
@media (max-width: 991.98px) {
    .foto-show-page {
        height: auto;
        overflow: auto;
    }

    .foto-show-zona {
        flex-direction: column;
        flex: none;
    }

    .foto-show-area {
        flex: none;
        min-height: 50vw;
        padding: 16px 44px;
    }

    .foto-show-pannello {
        flex: none;
        justify-content: flex-start;
        gap: 16px;
        padding: 24px 20px;
    }

    .foto-show-box-row {
        flex-direction: column;
    }

    .foto-show-box {
        border-right: none;
        border-bottom: 1px solid #eee;
    }

    .foto-show-box:last-child {
        border-bottom: none;
    }
}

/* === ADVANCED SEARCH FORM === */
#advanced-search .form-label {
    color: #1e2a3a !important;
    font-size: 0.8125rem;
    font-weight: 600;
}

/* === SEARCH SLIDESHOW === */
.search-slideshow {
    position: relative;
    width: 100%;
    aspect-ratio: 4 / 3;
    overflow: hidden;
    border-radius: 8px;
    background: var(--color-bg-card);
    border: 1px solid var(--color-border-hover);
    box-shadow: 0 4px 12px rgba(255, 255, 255, 0.35), 0 0 10px rgba(232, 176, 75, 0.45);
}

.search-slideshow__img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: 0;
    transition: opacity 1.5s ease-in-out;
}

.search-slideshow__img.is-active {
    opacity: 1;
}

.search-slideshow::after {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: 8px;
    box-shadow: inset 0 0 90px rgba(0, 0, 0, 0.95);
    z-index: 1;
    pointer-events: none;
}

@media (prefers-reduced-motion: reduce) {
    .search-slideshow__img {
        transition: none;
    }
}
