* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    overflow-y: scroll;
    scrollbar-width: none; /* Firefox */
    -ms-overflow-style: none; /* IE and Edge */
}
html::-webkit-scrollbar {
    display: none; /* Chrome, Safari, Opera */
}

body {
    #font-family: 'Helvetica Neue', Arial, sans-serif;
    font-family: "Noto Sans JP", "Noto Sans", "Noto Sans CJK JP", sans-serif;
    line-height: 1.6;
    color: #333;
    background-image: url('resources/bg-funambule.jpg');
    background-size: cover;
    background-position: left;
    background-attachment: fixed;
    background-repeat: no-repeat;
    min-height: 100vh;
}


/* Navigation Bar */
.navbar {
    background-color: rgba(255, 255, 255, 0.95);
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    position: sticky;
    top: 0;
    z-index: 1000;
    backdrop-filter: blur(10px);
}

.nav-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 80px;
}

.logo img {
    height: 60px;
    width: auto;
    transition: transform 0.3s ease;
}

.logo img:hover {
    transform: scale(1.05);
}

.nav-menu {
    display: flex;
    list-style: none;
    /* gap: 2rem; */
}

.nav-menu a {
    text-decoration: none;
    color: #333;
    font-weight: 500;
    font-size: 1rem;
    padding: 0.5rem 0.3rem;
    border-radius: 4px;
    transition: all 0.3s ease;
}

.nav-menu a:hover {
    background-color: #f0f0f0;
    color: #000;
}

.nav-toggle {
    display: none;
    flex-direction: column;
    background: none;
    border: none;
    cursor: pointer;
    padding: 0;
}

.nav-toggle span {
    width: 25px;
    height: 3px;
    background-color: #333;
    margin: 3px 0;
    transition: 0.3s;
    border-radius: 3px;
}

/* Main Content */
main {
    padding: 2rem 0;
}

.section {
    background-color: rgba(255, 255, 255, 0.9);
    margin: 15rem auto; /* zone verticale non floutée entre les sections */
    padding: 3rem 2rem;
    /* max-width: 1200px; */
    border-radius: 8px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
    backdrop-filter: blur(10px);
    min-height: calc(100vh - 80px);

}

.container {
    max-width: 900px;
    margin: 0 auto;
}

.section h1 {
    font-size: 2.5rem;
    margin-bottom: 1rem;
    /* color: #222; */
    color: #4b4b4b;
    text-align: center;
}

.section p {
    font-size: 1.1rem;
    color: #666;
    line-height: 1.8;
}

/* Exhibitions Table */
.exhibitions-table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 2rem;
    background-color: white;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
    overflow: hidden;
    border-radius: 8px;
}

.exhibitions-table thead {
    background-color: #f8f9fa;
    border-bottom: 2px solid #dee2e6;
}

.exhibitions-table th {
    padding: 1rem;
    text-align: left;
    font-weight: 600;
    color: #333;
    font-size: 0.95rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.exhibitions-table tbody tr {
    border-bottom: 1px solid #e9ecef;
    transition: background-color 0.2s ease;
}

.exhibitions-table tbody tr:hover {
    background-color: #f8f9fa;
}

.exhibitions-table tbody tr:last-child {
    border-bottom: none;
}

.exhibitions-table td {
    padding: 0.9rem 1rem;
    color: #555;
    font-size: 0.95rem;
}

.exhibitions-table td.period {
    font-weight: 600;
    color: #333;
    width: 10%;
}

.exhibitions-table td.label {
    width: 35%;
}

.exhibitions-table td.label a {
    color: #007bff;
    text-decoration: none;
    transition: color 0.2s ease;
    position: relative;
}

.exhibitions-table td.label a:hover {
    color: #0056b3;
    text-decoration: underline;
}

.exhibitions-table td.label a::after {
    content: ' ↗';
    font-size: 0.85em;
    opacity: 0.7;
}

.exhibitions-table td.location {
    width: 20%;
}

.exhibitions-table td.category {
    width: 15%;
    text-transform: capitalize;
}

.exhibitions-table td.domain {
    width: 20%;
    text-transform: capitalize;
}

.error {
    color: #dc3545;
    font-weight: 500;
    padding: 1rem;
    background-color: #f8d7da;
    border-radius: 4px;
    margin-top: 1rem;
}

.empty-message {
    font-size: 1.1rem;
    color: #666;
    line-height: 1.8;
}

/* Work Items */
#work-content {
    margin-top: 2rem;
}

.work-item {
    margin-bottom: 3rem;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.work-item:last-child {
    margin-bottom: 0;
}

.work-image {
    width: 100%;
    max-width: 900px;
    height: auto;
    border-radius: 8px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.work-image:hover {
    transform: scale(1.02);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.2);
}

.work-video {
    width: 100%;
    max-width: 900px;
    border-radius: 8px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    background-color: #000;
}

.work-text {
    margin-top: 1.5rem;
    width: 100%;
    max-width: 900px;
    color: #444;
    line-height: 1.8;
    font-size: 1rem;
}

.work-text-only {
    margin-top: 0;
    padding: 1.5rem;
    background-color: rgba(255, 255, 255, 0.95);
    border-radius: 8px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.work-text p {
    margin-bottom: 1rem;
}

.work-text p:last-child {
    margin-bottom: 0;
}

.work-text strong {
    font-weight: 600;
    color: #222;
}

.work-text em {
    font-style: italic;
}

.work-text a {
    color: #007bff;
    text-decoration: none;
    transition: color 0.2s ease;
}

.work-text a:hover {
    color: #0056b3;
    text-decoration: underline;
}

/* Headers in work text */
.work-text h1,
.work-text h2,
.work-text h3,
.work-text h4,
.work-text h5,
.work-text h6 {
    margin-top: 1.5rem;
    margin-bottom: 0.8rem;
    color: #222;
    font-weight: 600;
    line-height: 1.3;
}

.work-text h1:first-child,
.work-text h2:first-child,
.work-text h3:first-child,
.work-text h4:first-child,
.work-text h5:first-child,
.work-text h6:first-child {
    margin-top: 0;
}

.work-text h1 { font-size: 2rem; }
.work-text h2 { font-size: 1.75rem; }
.work-text h3 { font-size: 1.5rem; }
.work-text h4 { font-size: 1.25rem; }
.work-text h5 { font-size: 1.1rem; }
.work-text h6 { font-size: 1rem; }

/* Lists in work text */
.work-text ul,
.work-text ol {
    margin: 1rem 0;
    padding-left: 2rem;
}

.work-text ul {
    list-style-type: disc;
}

.work-text ol {
    list-style-type: decimal;
}

.work-text li {
    margin-bottom: 0.5rem;
    line-height: 1.6;
}

.work-text li:last-child {
    margin-bottom: 0;
}

/* News Items */
#news-content {
    margin-top: 2rem;
}

.news-item {
    margin-bottom: 2.5rem;
    padding: 1.5rem;
    background-color: rgba(255, 255, 255, 0.95);
    border-radius: 8px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.news-item:last-child {
    margin-bottom: 0;
}

.news-date {
    font-size: 1.3rem;
    font-weight: 600;
    color: #222;
    margin-bottom: 1rem;
    padding-bottom: 0.5rem;
    border-bottom: 2px solid #e9ecef;
}

.news-content {
    color: #444;
    line-height: 1.8;
    font-size: 1rem;
}

.news-content p {
    margin-bottom: 1rem;
}

.news-content p:last-child {
    margin-bottom: 0;
}

.news-content strong {
    font-weight: 600;
    color: #222;
}

.news-content em {
    font-style: italic;
}

.news-content a {
    color: #007bff;
    text-decoration: none;
    transition: color 0.2s ease;
}

.news-content a:hover {
    color: #0056b3;
    text-decoration: underline;
}

/* Headers in news content */
.news-content h1,
.news-content h2,
.news-content h3,
.news-content h4,
.news-content h5,
.news-content h6 {
    margin-top: 1.5rem;
    margin-bottom: 0.8rem;
    color: #222;
    font-weight: 600;
    line-height: 1.3;
}

.news-content h1:first-child,
.news-content h2:first-child,
.news-content h3:first-child,
.news-content h4:first-child,
.news-content h5:first-child,
.news-content h6:first-child {
    margin-top: 0;
}

.news-content h1 { font-size: 1.8rem; }
.news-content h2 { font-size: 1.6rem; }
.news-content h3 { font-size: 1.4rem; }
.news-content h4 { font-size: 1.2rem; }

/* Lists in news content */
.news-content ul,
.news-content ol {
    margin: 1rem 0;
    padding-left: 2rem;
}

.news-content ul {
    list-style-type: disc;
}

.news-content ol {
    list-style-type: decimal;
}

.news-content li {
    margin-bottom: 0.5rem;
    line-height: 1.6;
}

.news-content li:last-child {
    margin-bottom: 0;
}

/* Contact Form */
.contact-form {
    margin-top: 2rem;
    max-width: 600px;
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.contact-form input[type="text"],
.contact-form input[type="email"],
.contact-form textarea {
    width: 100%;
    padding: 0.9rem 1rem;
    font-size: 1rem;
    font-family: "Noto Sans JP", "Noto Sans", "Noto Sans CJK JP", sans-serif;
    border: 2px solid #e9ecef;
    border-radius: 6px;
    background-color: rgba(255, 255, 255, 0.95);
    transition: border-color 0.3s ease, box-shadow 0.3s ease;
}

.contact-form input[type="text"]:focus,
.contact-form input[type="email"]:focus,
.contact-form textarea:focus {
    outline: none;
    border-color: #007bff;
    box-shadow: 0 0 0 3px rgba(0, 123, 255, 0.1);
}

.contact-form textarea {
    min-height: 150px;
    resize: vertical;
}

.contact-form button {
    padding: 0.9rem 2rem;
    font-size: 1rem;
    font-weight: 600;
    font-family: "Noto Sans JP", "Noto Sans", "Noto Sans CJK JP", sans-serif;
    color: white;
    background-color: #007bff;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    transition: background-color 0.3s ease, transform 0.2s ease;
    align-self: flex-start;
}

.contact-form button:hover {
    background-color: #0056b3;
    transform: translateY(-1px);
}

.contact-form button:active {
    transform: translateY(0);
}


#default-page,
#mon-travail,
#expositions,
#portfolio,
#explorations,
#news,
#contact
{
    background-color: transparent;
    /* background-color: rgba(255, 255, 255, 0.0); */
}


/* Default Page */
#default-page {
    min-height: calc(100vh - 80px);
    max-height: calc(100vh - 80px);
    height: calc(100vh - 80px);
    overflow-y: hidden;
    padding: 0;
    display: flex;
    visibility: hidden;
    align-items: center;
    justify-content: center;
}

#default-page .container {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    height: 100%;
}

/* Portfolio Carousel */
#portfolio {
    min-height: calc(100vh - 80px);
    max-height: calc(100vh - 80px);
    height: calc(100vh - 80px);
    overflow-y: hidden;
    touch-action: pan-y;
    overscroll-behavior-x: contain;
    -webkit-overflow-scrolling: touch;
    padding: 0;
    display: flex;
    align-items: center;
    justify-content: center;

}

#portfolio .container {
    display: flex;
    flex-direction: column;
    align-items: center;
    height: 100%;
    transition: opacity 0.3s ease-in-out;
}

#portfolio .container.fading {
    opacity: 0;
}

.portfolio-header {
    padding-top: 48px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 2rem;
    margin-bottom: 1.5rem;
    width: 100%;
}

.portfolio-header h1 {
    margin: 0;
    flex-shrink: 0;
}

.carousel-controls {
    display: none;
}

.nav-btn {
    width: 50px;
    height: 50px;
    background-color: rgba(255, 255, 255, 0.9);
    border: 2px solid #e9ecef;
    border-radius: 8px;
    font-size: 1.2rem;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}

.nav-btn:hover:not(:disabled) {
    background-color: #007bff;
    color: white;
    border-color: #007bff;
    transform: scale(1.1);
}

.nav-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    background-color: #f8f9fa;
}

.first-btn,
.last-btn {
    color: #000;
}

.first-btn:hover:not(:disabled),
.last-btn:hover:not(:disabled) {
    color: white;
}

.artwork-display {
    flex: 1;
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 0;
    overflow: hidden;
    width: 100%;
    max-width: calc(100% - 24px);        

}

.portfolio-image {
    max-width: 100%;
    max-height: 100%;
    width: auto;
    height: auto;
    object-fit: contain;
    border-radius: 8px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    transition: transform 0.3s ease;
    cursor: pointer;
}

.portfolio-image:hover {
    transform: scale(1.02);
}

.image-tooltip {
    position: fixed;
    bottom: 2rem;
    left: 50%;
    transform: translateX(-50%);
    background-color: rgba(0, 0, 0, 0.85);
    color: white;
    padding: 1rem 1.5rem;
    border-radius: 8px;
    font-size: 0.95rem;
    text-align: center;
    z-index: 1000;
    opacity: 0;
    transition: opacity 0.3s ease;
    pointer-events: none;
    max-width: 90%;
}

.image-tooltip.show {
    opacity: 1;
}

.artwork-info {
    text-align: center;
    max-width: 900px;
    width: 100%;
    padding-top: 1rem;
    padding-bottom: 1rem;
    padding-left: 0.5rem;
    padding-right: 0.5rem;    
}

.artwork-title {
    font-size: 1rem;
    font-weight: 600;
    /* color: #222; */
    color: #4b4b4b;
    /* margin-bottom: 0.3rem; */
}

.image-index,
.artwork-materials,
.artwork-themes {
    font-size: 1rem;
    /* color: #666; */
    color: #4b4b4b;
    line-height: 1.6;
    /* margin-bottom: 0.3rem; */
}

.artwork-materials {
    font-style: italic;
}


/* Responsive Design */
@media screen and (max-width: 768px) {
    .nav-toggle {
        display: flex;
    }

    .nav-menu {
        position: fixed;
        left: -100%;
        top: 80px;
        flex-direction: column;
        background-color: rgba(255, 255, 255, 0.98);
        width: 100%;
        text-align: center;
        transition: 0.3s;
        box-shadow: 0 10px 27px rgba(0, 0, 0, 0.05);
        gap: 0;
        padding: 1rem 0;
    }

    .nav-menu.active {
        left: 0;
    }

    .nav-menu li {
        padding: 0.5rem 0;
    }

    .nav-menu a {
        display: block;
        width: 100%;
        padding: 1rem;
    }

    .section {
        /* margin: 1rem; */
        padding: 2rem 1rem;
    }

    .section h1 {
        font-size: 2rem;
    }

    .section p {
        font-size: 1rem;
    }

    /* Responsive table */
    .exhibitions-table {
        font-size: 0.85rem;
    }

    .exhibitions-table th,
    .exhibitions-table td {
        padding: 0.7rem 0.5rem;
    }

    .exhibitions-table th {
        font-size: 0.8rem;
    }

    /* Work items responsive */
    .work-text {
        font-size: 0.95rem;
    }

    .work-text-only {
        padding: 1.2rem;
    }

    .work-text h1 { font-size: 1.75rem; }
    .work-text h2 { font-size: 1.5rem; }
    .work-text h3 { font-size: 1.25rem; }
    .work-text h4 { font-size: 1.1rem; }

    /* News items responsive */
    .news-item {
        padding: 1.2rem;
    }

    .news-date {
        font-size: 1.2rem;
    }

    .news-content {
        font-size: 0.95rem;
    }

    .news-content h1 { font-size: 1.6rem; }
    .news-content h2 { font-size: 1.4rem; }
    .news-content h3 { font-size: 1.2rem; }
    .news-content h4 { font-size: 1.05rem; }

    /* Contact form responsive */
    .contact-form {
        max-width: 100%;
    }

    .contact-form input[type="text"],
    .contact-form input[type="email"],
    .contact-form textarea {
        font-size: 0.95rem;
    }

    .contact-form button {
        font-size: 0.95rem;
    }

    /* Portfolio carousel responsive */
    .portfolio-header {
        padding-top: 48px;
        gap: 1rem;
    }

    .nav-btn {
        width: 45px;
        height: 45px;
        font-size: 1rem;
    }

    .image-index,
    .artwork-title,
    .artwork-materials,
    .artwork-themes {
        font-size: 0.95rem;
    }
}

@media screen and (max-width: 480px) {
    .nav-container {
        height: 70px;
        padding: 0 15px;
    }

    .logo img {
        height: 50px;
    }

    .nav-menu {
        top: 70px;
    }

    .section h1 {
        font-size: 1.75rem;
    }

    .section {
        padding: 1.5rem 1rem;
    }

    /* Make table scrollable on small screens */
    #exhibitions-table {
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
    }

    .exhibitions-table {
        font-size: 0.75rem;
        min-width: 600px;
    }

    .exhibitions-table th,
    .exhibitions-table td {
        padding: 0.6rem 0.4rem;
    }

    /* Work items responsive */
    .work-item {
        margin-bottom: 2rem;
    }

    .work-text {
        font-size: 0.9rem;
        margin-top: 1rem;
    }

    .work-text-only {
        padding: 1rem;
        font-size: 0.9rem;
    }

    .work-text h1 { font-size: 1.5rem; }
    .work-text h2 { font-size: 1.35rem; }
    .work-text h3 { font-size: 1.2rem; }
    .work-text h4 { font-size: 1.05rem; }

    .work-text ul,
    .work-text ol {
        padding-left: 1.5rem;
    }

    /* News items responsive */
    .news-item {
        margin-bottom: 2rem;
        padding: 1rem;
    }

    .news-date {
        font-size: 1.1rem;
    }

    .news-content {
        font-size: 0.9rem;
    }

    .news-content h1 { font-size: 1.4rem; }
    .news-content h2 { font-size: 1.25rem; }
    .news-content h3 { font-size: 1.1rem; }
    .news-content h4 { font-size: 1rem; }

    .news-content ul,
    .news-content ol {
        padding-left: 1.5rem;
    }

    /* Contact form responsive */
    .contact-form input[type="text"],
    .contact-form input[type="email"],
    .contact-form textarea {
        font-size: 0.9rem;
        padding: 0.8rem;
    }

    .contact-form button {
        font-size: 0.9rem;
        padding: 0.8rem 1.5rem;
        width: 100%;
        align-self: stretch;
    }

    /* Portfolio carousel responsive */
    .portfolio-header {
        padding-top: 24px;
        gap: 0.3rem;
    }

    /* .portfolio-header h1 {
        font-size: 1.5rem;
    } */

    .nav-btn {
        width: 35px;
        height: 35px;
        font-size: 0.85rem;
    }

    .artwork-display {
        justify-content: center;
        /* max-width: calc(100% - 24px);         */
        width: 100%;
    }

    #portfolio {
        min-height: calc(100vh - 70px);
        max-height: calc(100vh - 70px);
    }

    #default-page {
        min-height: calc(100vh - 70px);
        max-height: calc(100vh - 70px);
    }

    .image-index,
    .artwork-title,
    .artwork-materials,
    .artwork-themes {
        font-size: 0.9rem;
    }
}
