/* ============================================
   MIRAMONT ÉCOLIEU - THÈME NATURE & MÉDITATION
   ============================================ */

/* Variables de couleurs */
:root {
    /* Palette Nature Zen Artistique */
    --vert-foret: #1a4d2e;
    --vert-sauge: #6b9080;
    --vert-clair: #a4c3b2;
    --beige-doux: #eaf4f4;
    --terre: #9b6a47;
    --blanc-casse: #f8f9fa;
    --gris-pierre: #4a5568;
    --accent-or: #d4a574;
    --accent-corail: #ff6b6b;

    /* Gradients Artistiques */
    --gradient-nature: linear-gradient(135deg, #6b9080 0%, #1a4d2e 80%, #0d2818 100%);
    --gradient-ciel: linear-gradient(160deg, #eaf4f4 0%, #a4c3b2 50%, #6b9080 100%);
    --gradient-sunset: linear-gradient(135deg, #ff6b6b 0%, #d4a574 50%, #6b9080 100%);
    --gradient-organic: radial-gradient(circle at top right, #a4c3b2 0%, transparent 70%),
                        radial-gradient(circle at bottom left, #6b9080 0%, transparent 70%);

    /* Ombres Artistiques */
    --ombre-douce: 0 10px 30px rgba(26, 77, 46, 0.15);
    --ombre-elevee: 0 20px 60px rgba(26, 77, 46, 0.25);
    --ombre-coloree: 0 15px 45px rgba(107, 144, 128, 0.3);

    /* Espacements */
    --espacement-petit: 1rem;
    --espacement-moyen: 2rem;
    --espacement-grand: 4rem;

    /* Transitions */
    --transition-douce: all 0.5s cubic-bezier(0.4, 0, 0.2, 1);
    --transition-elastic: all 0.6s cubic-bezier(0.68, -0.55, 0.265, 1.55);
}

/* Reset et Base */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    font-size: 16px;
}

body {
    font-family: 'Segoe UI', 'Roboto', 'Helvetica Neue', Arial, sans-serif;
    color: var(--gris-pierre);
    background-color: var(--blanc-casse);
    background-image:
        radial-gradient(circle at 20% 50%, rgba(164, 195, 178, 0.05) 0%, transparent 50%),
        radial-gradient(circle at 80% 80%, rgba(107, 144, 128, 0.05) 0%, transparent 50%);
    line-height: 1.7;
    overflow-x: hidden;
    position: relative;
}

/* Typographie */
h1, h2, h3, h4, h5, h6 {
    font-family: 'Georgia', 'Times New Roman', serif;
    color: var(--vert-foret);
    margin-bottom: 1rem;
    font-weight: 600;
    letter-spacing: 0.5px;
}

h1 {
    font-size: 3.5rem;
    line-height: 1.2;
    margin-bottom: 1.5rem;
    background: var(--gradient-nature);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    text-shadow: 0 4px 20px rgba(26, 77, 46, 0.1);
}

h2 {
    font-size: 2.5rem;
    margin-bottom: 1.5rem;
    position: relative;
    display: inline-block;
}

h2.section-title::after {
    content: '';
    position: absolute;
    bottom: -10px;
    left: 50%;
    transform: translateX(-50%);
    width: 80px;
    height: 4px;
    background: var(--gradient-sunset);
    border-radius: 2px;
}

h3 {
    font-size: 1.8rem;
    position: relative;
}

p {
    margin-bottom: 1rem;
    color: var(--gris-pierre);
}

a {
    color: var(--vert-sauge);
    text-decoration: none;
    transition: var(--transition-elastic);
    position: relative;
}

a:hover {
    color: var(--vert-foret);
}

p a:not(.btn), .infobox a:not(.btn) {
    background: linear-gradient(to right, var(--accent-or) 0%, var(--accent-or) 100%);
    background-size: 0 2px;
    background-repeat: no-repeat;
    background-position: left bottom;
    transition: background-size 0.4s ease;
}

p a:not(.btn):hover, .infobox a:not(.btn):hover {
    background-size: 100% 2px;
}

/* Navigation */
.navbar {
    position: fixed;
    top: 0;
    width: 100%;
    background: rgba(248, 249, 250, 0.85);
    backdrop-filter: blur(20px) saturate(180%);
    box-shadow: 0 8px 32px rgba(26, 77, 46, 0.1);
    z-index: 1000;
    transition: var(--transition-douce);
    border-bottom: 1px solid rgba(107, 144, 128, 0.1);
}

.navbar-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 1rem 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    font-size: 1.8rem;
    font-weight: 700;
    background: var(--gradient-nature);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    font-family: 'Georgia', serif;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    transition: var(--transition-elastic);
}

.logo:hover {
    transform: scale(1.05);
}

.logo-emoji {
    font-size: 2rem;
    filter: drop-shadow(0 2px 4px rgba(26, 77, 46, 0.2));
    animation: gentleFloat 3s ease-in-out infinite;
}

@keyframes gentleFloat {
    0%, 100% {
        transform: translateY(0);
    }
    50% {
        transform: translateY(-5px);
    }
}

.nav-menu {
    display: flex;
    gap: 2rem;
    list-style: none;
    align-items: center;
}

.nav-menu a {
    color: var(--gris-pierre);
    font-weight: 500;
    padding: 0.7rem 1.5rem;
    border-radius: 25px;
    transition: var(--transition-elastic);
    position: relative;
    overflow: hidden;
    z-index: 1;
}

.nav-menu a::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: var(--gradient-nature);
    transform: scaleX(0);
    transform-origin: left;
    transition: transform 0.4s ease;
    border-radius: 25px;
    z-index: -1;
}

.nav-menu a:hover::before,
.nav-menu a.active::before {
    transform: scaleX(1);
}

.nav-menu a:hover,
.nav-menu a.active {
    color: white;
    transform: translateY(-2px);
}

/* Menu burger (mobile) */
.burger {
    display: none;
    flex-direction: column;
    cursor: pointer;
    gap: 5px;
}

.burger span {
    width: 30px;
    height: 3px;
    background: var(--vert-foret);
    border-radius: 3px;
    transition: var(--transition-douce);
}

/* Hero Section */
.hero {
    min-height: 100vh;
    background: var(--gradient-ciel);
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 6rem 2rem 4rem;
    position: relative;
    overflow: hidden;
}

.hero::before {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 200px;
    background: linear-gradient(to top, var(--blanc-casse), transparent);
    z-index: 1;
}

.hero::after {
    content: '';
    position: absolute;
    top: -50%;
    right: -20%;
    width: 800px;
    height: 800px;
    background: radial-gradient(circle, rgba(212, 165, 116, 0.15) 0%, transparent 70%);
    border-radius: 40% 60% 70% 30% / 40% 50% 60% 50%;
    animation: morphing 20s ease-in-out infinite;
    z-index: 0;
}

@keyframes morphing {
    0%, 100% {
        border-radius: 40% 60% 70% 30% / 40% 50% 60% 50%;
        transform: rotate(0deg) scale(1);
    }
    50% {
        border-radius: 70% 30% 50% 50% / 60% 40% 60% 40%;
        transform: rotate(180deg) scale(1.1);
    }
}

.hero-content {
    max-width: 800px;
    position: relative;
    z-index: 1;
    animation: fadeInUp 1s ease-out;
}

.hero-emoji {
    font-size: 6rem;
    margin-bottom: 1rem;
    animation: float 3s ease-in-out infinite;
    filter: drop-shadow(0 10px 30px rgba(107, 144, 128, 0.4));
    position: relative;
    z-index: 2;
}

.hero h1 {
    color: var(--vert-foret);
    margin-bottom: 1.5rem;
}

.hero-subtitle {
    font-size: 1.5rem;
    color: var(--terre);
    margin-bottom: 2rem;
    font-family: 'Georgia', serif;
    font-style: italic;
}

.hero-description {
    font-size: 1.1rem;
    color: var(--gris-pierre);
    margin-bottom: 3rem;
    line-height: 1.8;
}

/* Boutons */
.btn {
    display: inline-block;
    padding: 1.2rem 3rem;
    border-radius: 50px;
    font-weight: 600;
    text-decoration: none;
    transition: var(--transition-elastic);
    cursor: pointer;
    border: none;
    font-size: 1rem;
    letter-spacing: 1px;
    position: relative;
    overflow: hidden;
    z-index: 1;
}

.btn::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.3);
    transform: translate(-50%, -50%);
    transition: width 0.6s ease, height 0.6s ease;
    z-index: -1;
}

.btn:hover::before {
    width: 300px;
    height: 300px;
}

.btn-primary {
    background: var(--gradient-nature);
    color: white;
    box-shadow: var(--ombre-douce);
}

.btn-primary:hover {
    transform: translateY(-5px) scale(1.05);
    box-shadow: var(--ombre-coloree);
}

.btn-secondary {
    background: white;
    color: var(--vert-foret);
    border: 2px solid var(--vert-sauge);
    box-shadow: 0 5px 15px rgba(107, 144, 128, 0.2);
}

.btn-secondary:hover {
    background: var(--vert-foret);
    color: white;
    border-color: var(--vert-foret);
    transform: translateY(-5px) scale(1.05);
    box-shadow: var(--ombre-elevee);
}

.btn-group {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
    justify-content: center;
}

/* Sections */
section {
    padding: var(--espacement-grand) 2rem;
    position: relative;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    position: relative;
    z-index: 1;
}

.section-title {
    text-align: center;
    margin-bottom: var(--espacement-moyen);
    position: relative;
    padding-bottom: 1.5rem;
}

.section-subtitle {
    text-align: center;
    font-size: 1.2rem;
    color: var(--terre);
    max-width: 700px;
    margin: 0 auto 3rem;
}

/* Grille de cartes */
.cards-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
    margin-top: 3rem;
}

.card {
    background: white;
    border-radius: 30px;
    padding: 2.5rem;
    box-shadow: var(--ombre-douce);
    transition: var(--transition-elastic);
    text-align: center;
    position: relative;
    overflow: hidden;
    border: 1px solid rgba(107, 144, 128, 0.1);
}

.card::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(164, 195, 178, 0.08) 0%, transparent 70%);
    opacity: 0;
    transition: opacity 0.6s ease;
}

.card:hover::before {
    opacity: 1;
}

.card:hover {
    transform: translateY(-15px) scale(1.02);
    box-shadow: var(--ombre-coloree);
    border-color: var(--vert-clair);
}

.card:nth-child(odd):hover {
    transform: translateY(-15px) scale(1.02) rotate(-1deg);
}

.card:nth-child(even):hover {
    transform: translateY(-15px) scale(1.02) rotate(1deg);
}

.card-emoji {
    font-size: 4rem;
    margin-bottom: 1.5rem;
    display: block;
    filter: drop-shadow(0 4px 8px rgba(107, 144, 128, 0.3));
    transition: var(--transition-elastic);
    position: relative;
    z-index: 2;
}

.card:hover .card-emoji {
    transform: scale(1.2) rotate(5deg);
    filter: drop-shadow(0 8px 16px rgba(107, 144, 128, 0.4));
}

.card h3 {
    margin-bottom: 1rem;
    color: var(--vert-foret);
}

.card p {
    color: var(--gris-pierre);
}

/* Section avec fond */
.section-alt {
    background: linear-gradient(135deg, var(--beige-doux) 0%, var(--vert-clair) 100%);
    position: relative;
    overflow: hidden;
}

.section-alt::before {
    content: '';
    position: absolute;
    top: -30%;
    left: -10%;
    width: 500px;
    height: 500px;
    background: radial-gradient(circle, rgba(255, 255, 255, 0.4) 0%, transparent 70%);
    border-radius: 50% 40% 60% 50% / 60% 50% 40% 50%;
    animation: floatShape 25s ease-in-out infinite;
}

.section-alt::after {
    content: '';
    position: absolute;
    bottom: -20%;
    right: -10%;
    width: 600px;
    height: 600px;
    background: radial-gradient(circle, rgba(107, 144, 128, 0.08) 0%, transparent 70%);
    border-radius: 60% 50% 40% 60% / 50% 60% 50% 40%;
    animation: floatShape 30s ease-in-out infinite reverse;
}

@keyframes floatShape {
    0%, 100% {
        transform: translate(0, 0) rotate(0deg);
    }
    33% {
        transform: translate(30px, -30px) rotate(120deg);
    }
    66% {
        transform: translate(-20px, 20px) rotate(240deg);
    }
}

/* Features */
.features {
    display: flex;
    justify-content: space-around;
    flex-wrap: wrap;
    gap: 2rem;
    margin: 3rem 0;
}

.feature-item {
    text-align: center;
    flex: 1;
    min-width: 200px;
    padding: 2rem;
    transition: var(--transition-elastic);
    border-radius: 20px;
}

.feature-item:hover {
    background: rgba(255, 255, 255, 0.5);
    transform: translateY(-5px);
}

.feature-icon {
    font-size: 4rem;
    margin-bottom: 1rem;
    display: block;
    filter: drop-shadow(0 4px 12px rgba(107, 144, 128, 0.3));
    transition: var(--transition-elastic);
}

.feature-item:hover .feature-icon {
    transform: scale(1.15) translateY(-5px);
    filter: drop-shadow(0 8px 20px rgba(107, 144, 128, 0.4));
}

.feature-text {
    color: var(--gris-pierre);
    font-weight: 500;
}

/* Infobox */
.infobox {
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.95) 0%, rgba(234, 244, 244, 0.95) 100%);
    border-left: 5px solid var(--accent-or);
    padding: 2.5rem;
    border-radius: 20px;
    margin: 2rem 0;
    box-shadow: var(--ombre-douce);
    position: relative;
    overflow: hidden;
    backdrop-filter: blur(10px);
}

.infobox::before {
    content: '';
    position: absolute;
    top: -50%;
    right: -20%;
    width: 300px;
    height: 300px;
    background: radial-gradient(circle, rgba(212, 165, 116, 0.1) 0%, transparent 70%);
    border-radius: 50%;
    pointer-events: none;
}

.infobox h3 {
    color: var(--vert-foret);
    margin-bottom: 1rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.infobox ul {
    list-style: none;
    padding-left: 0;
}

.infobox li {
    padding: 0.5rem 0;
    color: var(--gris-pierre);
}

.infobox li::before {
    content: '✓';
    color: var(--vert-sauge);
    font-weight: bold;
    margin-right: 0.5rem;
}

/* Formulaire de contact */
.contact-form {
    max-width: 600px;
    margin: 0 auto;
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.98) 0%, rgba(234, 244, 244, 0.98) 100%);
    padding: 3rem;
    border-radius: 30px;
    box-shadow: var(--ombre-coloree);
    position: relative;
    overflow: hidden;
    border: 1px solid rgba(107, 144, 128, 0.2);
}

.contact-form::before {
    content: '';
    position: absolute;
    top: -50%;
    right: -30%;
    width: 400px;
    height: 400px;
    background: radial-gradient(circle, rgba(164, 195, 178, 0.15) 0%, transparent 70%);
    border-radius: 50%;
    pointer-events: none;
}

.form-group {
    margin-bottom: 1.5rem;
}

.form-group label {
    display: block;
    margin-bottom: 0.5rem;
    color: var(--vert-foret);
    font-weight: 500;
}

.form-group input,
.form-group textarea {
    width: 100%;
    padding: 1.2rem;
    border: 2px solid rgba(164, 195, 178, 0.3);
    border-radius: 15px;
    font-family: inherit;
    font-size: 1rem;
    transition: var(--transition-douce);
    background: rgba(255, 255, 255, 0.8);
    position: relative;
    z-index: 1;
}

.form-group input:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--vert-sauge);
    background: white;
    box-shadow: 0 5px 20px rgba(107, 144, 128, 0.15);
    transform: translateY(-2px);
}

.form-group textarea {
    resize: vertical;
    min-height: 150px;
}

/* Footer */
.footer {
    background: linear-gradient(135deg, #1a4d2e 0%, #0d2818 100%);
    color: var(--beige-doux);
    padding: 3rem 2rem 2rem;
    text-align: center;
    position: relative;
    overflow: hidden;
}

.footer::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(212, 165, 116, 0.5), transparent);
}

.footer::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background:
        radial-gradient(circle at 20% 80%, rgba(107, 144, 128, 0.1) 0%, transparent 50%),
        radial-gradient(circle at 80% 20%, rgba(164, 195, 178, 0.08) 0%, transparent 50%);
    pointer-events: none;
    z-index: 0;
}

.footer-content {
    max-width: 1200px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
    text-align: left;
    margin-bottom: 2rem;
    position: relative;
    z-index: 1;
}

.footer-section h3 {
    color: var(--vert-clair);
    margin-bottom: 1rem;
}

.footer-section p,
.footer-section a {
    color: var(--beige-doux);
    line-height: 1.8;
}

.footer-section a:hover {
    color: white;
}

.social-links {
    display: flex;
    gap: 1rem;
    font-size: 2rem;
    position: relative;
    z-index: 1;
}

.social-links a {
    transition: var(--transition-elastic);
    display: inline-block;
    filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.2));
}

.social-links a:hover {
    transform: translateY(-5px) scale(1.2) rotate(10deg);
    filter: drop-shadow(0 5px 10px rgba(212, 165, 116, 0.4));
}

.footer-bottom {
    border-top: 1px solid rgba(232, 220, 196, 0.2);
    padding-top: 2rem;
    margin-top: 2rem;
    font-size: 0.9rem;
    position: relative;
    z-index: 1;
}

/* Animations */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes float {
    0%, 100% {
        transform: translateY(0);
    }
    50% {
        transform: translateY(-20px);
    }
}

/* Responsive */
@media (max-width: 768px) {
    html {
        font-size: 14px;
    }

    h1 {
        font-size: 2.5rem;
    }

    h2 {
        font-size: 2rem;
    }

    .navbar-container {
        padding: 1rem;
    }

    .nav-menu {
        position: fixed;
        left: -100%;
        top: 70px;
        flex-direction: column;
        background: white;
        width: 100%;
        text-align: center;
        transition: 0.3s;
        box-shadow: var(--ombre-douce);
        padding: 2rem 0;
    }

    .nav-menu.active {
        left: 0;
    }

    .burger {
        display: flex;
    }

    .burger.active span:nth-child(1) {
        transform: rotate(-45deg) translate(-5px, 6px);
    }

    .burger.active span:nth-child(2) {
        opacity: 0;
    }

    .burger.active span:nth-child(3) {
        transform: rotate(45deg) translate(-5px, -6px);
    }

    .hero {
        min-height: 80vh;
        padding: 5rem 1rem 3rem;
    }

    .hero-emoji {
        font-size: 3.5rem;
    }

    .btn-group {
        flex-direction: column;
        align-items: stretch;
    }

    .cards-grid {
        grid-template-columns: 1fr;
    }

    .footer-content {
        grid-template-columns: 1fr;
        text-align: center;
    }

    .social-links {
        justify-content: center;
    }
}

@media (max-width: 480px) {
    .contact-form {
        padding: 2rem 1.5rem;
    }
}

/* Utilitaires */
.text-center {
    text-align: center;
}

.mt-2 {
    margin-top: 2rem;
}

.mb-2 {
    margin-bottom: 2rem;
}

.fade-in {
    animation: fadeInUp 0.8s ease-out;
}
