/* Palette Pomelli officielle DG Club — thème nuit par défaut. */
:root {
    color-scheme: dark;
    --brand-navy: #01035D;
    --brand-cyan: #00F0FF;
    --brand-red: #E60101;
    --brand-white: #FFFFFF;
    --primary-color: var(--brand-cyan);
    --secondary-color: var(--brand-red);
    --accent-color: var(--brand-cyan);
    --background-color: var(--brand-navy);
    --surface-color: #080B62;
    --surface-raised: #10146C;
    --border-color: rgba(0, 240, 255, .20);
    --text-color: var(--brand-white);
    --text-light-color: #E8F3FF;
    --text-dark-color: #B8C8E8;
    --link-color: var(--brand-cyan);
}

:root[data-theme="light"] {
    color-scheme: light;
    --primary-color: var(--brand-navy);
    --secondary-color: var(--brand-red);
    --accent-color: var(--brand-navy);
    --background-color: var(--brand-white);
    --surface-color: #F4F6FD;
    --surface-raised: var(--brand-white);
    --border-color: rgba(1, 3, 93, .16);
    --text-color: var(--brand-navy);
    --text-light-color: #17224F;
    --text-dark-color: #354166;
    --link-color: var(--brand-navy);
}

/* Réinitialisation CSS */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Inter', 'SF Pro Display', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, 'Open Sans', 'Helvetica Neue', sans-serif;
    background-color: var(--background-color);
    color: var(--text-color);
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* Typographie */
h1, h2, h3, h4, h5, h6 {
    font-family: 'Inter', 'SF Pro Display', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, 'Open Sans', 'Helvetica Neue', sans-serif;
    font-weight: 700;
    color: var(--text-color);
}

h1 {
    font-size: 3.5em;
    text-align: center;
    margin-bottom: 0.5em;
}

h2 {
    font-size: 2.5em;
    text-align: center;
    margin-bottom: 1em;
    color: var(--primary-color);
}

p {
    font-size: 1.1em;
    color: var(--text-light-color);
}

a {
    color: var(--primary-color);
    text-decoration: none;
    transition: color 0.3s ease;
}

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

/* Layout général */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 2em;
}

section {
    padding: 6em 2em;
    text-align: center;
    opacity: 1;
    transform: none;
}

section.is-visible {
    opacity: 1;
    transform: translateY(0);
}

/* Header et Navigation */
header {
    background-color: var(--surface-color);
    padding: 1em 2em;
    position: sticky;
    top: 0;
    z-index: 1000;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.5);
}

nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    max-width: 1200px;
    margin: 0 auto;
}

.logo {
    display: flex;
    align-items: center;
    justify-content: center;
}

.logo img {
    height: 40px;
    margin-right: 10px;
}

.logo span {
    font-size: 1.8em;
    font-weight: 700;
    color: var(--text-color);
}

nav ul {
    list-style: none;
    display: flex;
}

nav ul li {
    margin-left: 2em;
}

nav ul li a {
    font-weight: 500;
    font-size: 1.1em;
    color: var(--text-light-color);
}

nav ul li a:hover {
    color: var(--primary-color);
}

a{
    color: var(--link-color);
}

/* Banderol */
.Banderol {
    position: absolute;
    top: 9em;
    right: 9em;
    background-color: black;
    border: 3px solid red;
    color: var(--text-color);
    padding: 0.5em 1em;
    border-radius: 50px;
    font-size: 0.9em;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5em;
}

/* Hero Section */
#hero {
    background: linear-gradient(rgba(0, 0, 0, 0.7), rgba(0, 0, 0, 0.7)), url('assets/hero-bg.png') no-repeat center center/cover;
    min-height: 80vh;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    padding: 2em;
}

#hero h1 {
    font-size: 4em;
    margin-bottom: 0.2em;
    color: var(--accent-color);
    text-shadow: 0 0 10px rgba(255, 215, 0, 0.5);
}

#hero p {
    font-size: 1.5em;
    margin-bottom: 2em;
    max-width: 700px;
    font-weight: 400;
}

button {
    background-color: var(--primary-color);
    color: var(--text-color);
    border: none;
    padding: 0.8em 2em;
    font-size: 1.2em;
    border-radius: 50px;
    cursor: pointer;
    transition: background-color 0.3s ease, transform 0.2s ease;
}

button:hover {
    background-color: var(--accent-color);
    transform: translateY(-3px);
}

/* Sections générales */
#about, #tutoriels, #livres, #contact {
    background-color: var(--surface-color);
    margin: 2em auto;
    border-radius: 15px;
    max-width: 1000px;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.3);
}

#about p {
    max-width: 800px;
    margin: 1em auto;
}

/* Grilles de contenu (Bento-like) */
.tutoriel-grid, .book-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(10px, 1fr));
    gap: 2em;
    padding: 2em;
}


.book-grid img{
   width: 60%;
}


.grid-item {
    background-color: var(--background-color);
    padding: 1.5em;
    border-radius: 10px;
    text-align: left;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.2);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-direction: column;
}



.grid-item:hover {
    transform: translateY(-5px);
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.4);
}

.grid-item img {
    max-width: 80%;
    height: auto;
    border-radius: 8px;
    margin-bottom: 1em;
}

.grid-item h3 {
    color: var(--primary-color);
    margin-bottom: 0.5em;
}

.grid-item p {
    font-size: 0.95em;
    color: var(--text-dark-color);
}

/* Formulaire de contact */
#contact form {
    display: flex;
    flex-direction: column;
    max-width: 600px;
    margin: 2em auto;
    gap: 1em;
}

#contact input, #contact textarea {
    padding: 1em;
    border: 1px solid var(--border-color);
    border-radius: 8px;
    background-color: var(--surface-color);
    color: var(--text-color);
    font-size: 1em;
}

#contact input::placeholder, #contact textarea::placeholder {
    color: var(--text-dark-color);
}

#contact button {
    align-self: center;
    width: 50%;
}

/* Footer */
footer {
    background-color: var(--surface-color);
    text-align: center;
    padding: 2em;
    color: var(--text-dark-color);
    font-size: 0.9em;
}

/* Responsive Design */
@media (max-width: 768px) {
    nav {
        flex-direction: column;
    }

    nav ul {
        margin-top: 1em;
        flex-wrap: wrap;
        justify-content: center;
    }

    nav ul li {
        margin: 0.5em 1em;
    }

    #hero h1 {
        font-size: 2.5em;
    }

    #hero p {
        font-size: 1.2em;
    }

    h2 {
        font-size: 2em;
    }

    .tutoriel-grid, .book-grid {
        grid-template-columns: 1fr;
    }
}
