/**
 * Theme Name: Cubedefrahim Photo Theme
 * Template: cubedefrahim
 */
 
:root {
    --collection-card-width: 250px;
    --collection-gap: 30px;

    --font-primary: 'Hubot Sans', system-ui, sans-serif;
    --font-secondary: 'Grenze', system-ui, sans-serif;
}

body {
    font-family: var(--font-primary);
    font-stretch: 80%;
}

.page-title {
    text-align: center;
    font-size: 2rem;
    font-weight: 600;
}

.page-content {
    padding: 0 5vw;
}

/*--------------*/
/* Collections */
/*-------------*/
.collections {
    display: flex;
    flex-wrap: wrap;
    gap: 30px;
    justify-content: center;
    margin: 5vh 5vw;
}

.collection-title {
    font-family: var(--font-secondary);
    font-size: 1rem;
    color: black;
    text-align: center;
    max-width: var(--collection-card-width);
}

.collections a {
    text-decoration: none;
}

.collection-cover {
    width: var(--collection-card-width);
    height: var(--collection-card-width);
    object-fit: cover;
    display: block;
}  


/*--------------*/
/* single collection */
/*-------------*/

.collection-layout {
    display: flex;
    gap: 3rem;
    padding: 1vh 5vw;
}

.sc-title {
    font-family: var(--font-secondary);
    font-size: 2rem;
    text-align: center;
    margin: 0;
}

.sc-thumbnails {
    display: flex;
    flex-wrap: wrap;
    justify-content:center;
}

.sc-description {
    font-family: var(--font-secondary);
    font-size: 1.4rem;
    font-weight: 300;
    text-align: center;
    margin : 0 25%
}

.collection-viewer {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1.5rem;
}


.collection-thumbnails {
    display: flex;
    gap: 0.75rem;
    overflow-x: auto;
    max-width: 100%;
    padding-bottom: 0.5rem;
}

.thumb-btn {
    border: 2px solid transparent;
    padding: 0;
    background: none;
    cursor: pointer;
    flex-shrink: 0;
}

.thumb-btn img {
    display: block;
    width: 80px;
    height: 80px;
    object-fit: cover;
}

.thumb-btn.active {
    border-color: var(--color-primary, #1a1a1a);
}

/* ---------- Image principale ---------- */
.sc-main-image {
    width: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.75rem;
}

.sc-stage {
    display: grid;
    grid-template-columns: 44px minmax(0, 1fr) 44px; /* flèches à largeur fixe */
    column-gap: 1rem;
    align-items: center;
    width: 100%;
    max-width: 1000px;
    height: 530px;
}

.sc-main-image img {
    width: 100%;
    height: 530px;          /* même hauteur que .sc-stage */
    object-fit: contain;    /* l'image remplit la zone sans déformation */
    cursor: zoom-in;
}
/* ---------- Boutons ronds (flèches + icône) ---------- */
.nav-btn {
    width: 44px;
    height: 44px;
    border: none;
    border-radius: 50%;
    background: rgba(0, 0, 0, 0.45);
    color: #fff;
    font-size: 2rem;
    line-height: 1;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    text-decoration: none;
    transition: background 0.2s;
}
.nav-btn:hover { background: rgba(0, 0, 0, 0.75); }

/* ---------- Bouton télécharger (sous l'image principale) ---------- */
.download-btn {
    display: inline-block;
    padding: 0.5rem 1rem;
    border: 1px solid currentColor;
    border-radius: 4px;
    font-size: 0.9rem;
    text-decoration: none;
    color: inherit;
    transition: background 0.2s, color 0.2s;
}
.download-btn:hover {
    background: var(--color-primary, #1a1a1a);
    color: #fff;
}

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

.lightbox img {
    max-width: calc(100vw - 220px);
    max-height: 90vh;
    object-fit: contain;
}

/* Colonnes de boutons collées aux bords de l'écran */
.lb-side {
    position: fixed;
    top: 50%;
    transform: translateY(-50%);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.75rem;
}
.lb-side-left  { left: 1.5rem; }
.lb-side-right { right: 1.5rem; }
.nav-prev { grid-column: 1; }
.sc-main-image img { grid-column: 2; }
.nav-next { grid-column: 3; }

.lb-close {
    position: absolute;
    top: 1rem;
    right: 1.25rem;
    background: none;
    border: none;
    color: #fff;
    font-size: 2.5rem;
    line-height: 1;
    cursor: pointer;
}

/* ---------- Mobile ---------- */
@media (max-width: 768px) {
    .sc-stage {
        grid-template-columns: 36px minmax(0, 1fr) 36px;
        column-gap: 0.5rem;
        height: 350px;
    }
    .sc-main-image img { max-height: 350px; }

    .nav-btn { width: 36px; height: 36px; font-size: 1.5rem; }

    .lightbox img { max-width: calc(100vw - 130px); }
    .lb-side-left  { left: 0.5rem; }
    .lb-side-right { right: 0.5rem; }

    .collection-layout { flex-direction: column; }
}

/*--------------*/
/* A propos */
/*-------------*/

.ap-content {
    display: flex;
    gap: 2rem;
}

.ap-image-section,
.ap-texte-section {
    flex: 1;
}

.ap-image-section img {
    max-height: 70vh;
    width: auto;
    max-width: 100%;
    height: auto;
}

.ap-image-container {
    margin-top: 2vh;
    padding: 30px;
    text-align: center;
}

.ap-titre-image {
    font-style: italic;
    font-size: 1.1rem;
}

/*--------------*/
/* Contact */
/*-------------*/

.prenom, .nom {
    font-size: 1.3rem;
    font-weight: 500;
}
.nom {
    text-transform: uppercase;
}

.label {
    color: grey;
}

.c-line {
    display: flex;
    gap: 5px;
    margin:3vh 0;
    font-size: 1.2rem;
}

.c-page .page-content {
    padding: 0 20vw 10vh 20vw;
}

.c-mentions-legales {
    margin-top: 5vh;
    display: block;
}

.c-mentions-legales-title {
    font-size: 1.3 rem;
    font-weight: 500;
}

.c-mentions-legales-texte {
    font-size: 1.2rem;
    color : grey;
    
}

/*--------------*/
/* Accueil */
/*-------------*/


.photo-moment { text-align: center; margin-bottom: 4rem; }
 
.photo-moment-label {
    font-family: var(--font-secondary);
    text-transform: uppercase;
    letter-spacing: 0.15em;
    font-size: 1rem;
    margin: 0 0 1rem;
}
 
.photo-moment-img {
    max-width: 100%;
    max-height: 70vh;
    width: auto;
    height: auto;
    object-fit: contain;
}
 
.photo-moment-title {
    font-family: var(--font-secondary);
    margin: 1rem 0 0.5rem;
}
 
.photo-moment-text {
    font-family: var(--font-secondary);
    font-size: 1.2rem;
    margin: 1.5rem auto;
    max-width: 700px;
}
 
 
/* =========================================================
   PAGE D'UNE PHOTO : cadre + flèche de fermeture
   ========================================================= */
 
.photo-single { position: relative; padding: 1vh 5vw; }
 
.photo-single-close {
    position: absolute;
    top: 1rem;
    left: 5vw;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: rgba(0, 0, 0, 0.45);
    color: #fff;
    font-size: 1.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    text-decoration: none;
    transition: background 0.2s;
}
.photo-single-close:hover { background: rgba(0, 0, 0, 0.75); }
 
 
/* =========================================================
   PHOTOS PRÉCÉDENTES (accueil + liste de toutes les photos)
   ========================================================= */
 
.photo-previous { text-align: center; }
.photo-previous-heading { font-family: var(--font-secondary); font-size: 1.4rem; }
 
.photo-previous-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
    gap: 1rem;
    margin: 1.5rem 0;
}
.photo-previous-item { text-decoration: none; color: inherit; display: block; }
.photo-previous-img { width: 100%; aspect-ratio: 1 / 1; object-fit: cover; display: block; }
.photo-previous-title { display: block; margin-top: 0.4rem; font-size: 0.9rem; }
 
.photo-all-btn {
    display: inline-block;
    padding: 0.7rem 1.5rem;
    border: 1px solid currentColor;
    text-decoration: none;
    color: inherit;
    transition: background 0.2s, color 0.2s;
}
.photo-all-btn:hover { background: var(--color-primary, #1a1a1a); color: #fff; }
 
 
/* =========================================================
   PAGE « TOUTES LES PHOTOS DU MOMENT »
   ========================================================= */
 
.photo-archive { padding: 1vh 5vw; }
.photo-archive-title { font-family: var(--font-secondary); text-align: center; }
.photo-archive-intro { text-align: center; margin-bottom: 2rem; }
.photo-archive-pagination { text-align: center; margin: 2rem 0; }
.photo-archive-pagination .page-numbers { margin: 0 0.4rem; text-decoration: none; color: inherit; }
.photo-archive-pagination .current { font-weight: bold; }
 