/* style.css
 *
 * Minimalist yet warm and inviting design inspired by the cosmic and énergétiques
 * ambience of the original Cinq Étoiles Energies website. The layout uses
 * dark backgrounds, gentle gradients and rounded cards to convey serenity.
 */

:root {
    --bg-dark: #0b132b;
    --bg-light: #1e2a47;
    --primary: #927cfb;
    --secondary: #ff946e;
    --text-light: #f5f7fa;
    --text-muted: #cdd7e4;
    --container-width: 1200px;
}

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

body {
    font-family: 'Poppins', sans-serif;
    line-height: 1.6;
    background: var(--bg-dark);
    color: var(--text-light);
    overflow-x: hidden;
}

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

a:hover {
    color: #ffd6c1;
}

.container {
    width: 90%;
    max-width: var(--container-width);
    margin: 0 auto;
}

/* Header / Navigation */
.site-header {
    background: radial-gradient(circle at top left, #1e2a47, #0b132b);
    position: sticky;
    top: 0;
    width: 100%;
    z-index: 100;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.4);
}
.site-header .container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 1rem 0;
}
.logo {
    font-weight: 600;
    font-size: 1.5rem;
    color: var(--primary);
}

.nav-menu ul {
    list-style: none;
    display: flex;
    gap: 1rem;
}
.nav-menu a {
    color: var(--text-light);
    padding: 0.5rem 0.75rem;
    border-radius: 4px;
    font-size: 0.9rem;
}
.nav-menu a:hover,
.nav-menu a:focus,
.nav-menu a.active {
    background: var(--primary);
    color: var(--bg-dark);
}

.nav-toggle {
    display: none;
    background: none;
    border: none;
    font-size: 1.5rem;
    color: var(--text-light);
    cursor: pointer;
}

/* Hero section */
.hero {
    min-height: 70vh;
    /* Use a gentle gradient overlaid on a decorative cosmic background image */
    background: linear-gradient(to bottom right, rgba(30, 42, 71, 0.8), rgba(11, 19, 43, 0.8)), url('../images/hero_bg.png') center/cover no-repeat;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 4rem 2rem;
    position: relative;
    overflow: hidden;
}
.hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: radial-gradient(circle at 30% 30%, rgba(255, 138, 115, 0.3), transparent 60%);
    pointer-events: none;
}
.hero h1 {
    font-size: clamp(1.8rem, 4vw + 1rem, 3rem);
    margin-bottom: 1rem;
    color: var(--secondary);
}
.hero p {
    max-width: 600px;
    margin: 0 auto 2rem;
    color: var(--text-muted);
}
.btn-primary {
    display: inline-block;
    padding: 0.75rem 1.5rem;
    border: none;
    border-radius: 30px;
    background: var(--primary);
    color: var(--bg-dark);
    font-weight: 600;
    cursor: pointer;
    transition: background 0.3s ease;
}
.btn-primary:hover {
    background: #b5a5fa;
}

/* Services section */
.services {
    padding: 4rem 0;
    background: var(--bg-dark);
}
.services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 2rem;
}
.service-card {
    background: var(--bg-light);
    padding: 2rem;
    border-radius: 10px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
    display: flex;
    flex-direction: column;
    align-items: start;
    gap: 1rem;
    transition: transform 0.3s ease;
}
.service-card:hover {
    transform: translateY(-5px);
}
.service-card h3 {
    font-size: 1.2rem;
    color: var(--primary);
}
.service-card p {
    font-size: 0.9rem;
    color: var(--text-muted);
    flex: 1;
}
.service-card .service-link {
    margin-top: auto;
    font-weight: 600;
    color: var(--secondary);
    text-decoration: underline;
    font-size: 0.9rem;
}

/* Reviews section */
.reviews {
    padding: 4rem 0;
    background: var(--bg-light);
}
.reviews h2 {
    text-align: center;
    margin-bottom: 2rem;
    color: var(--secondary);
    font-size: 2rem;
}
.reviews-list {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}
.review-item {
    background: var(--bg-dark);
    padding: 1.5rem;
    border-radius: 8px;
    box-shadow: 0 3px 8px rgba(0, 0, 0, 0.25);
}
.review-item p {
    margin-bottom: 0.5rem;
    color: var(--text-light);
}
.review-item .author {
    font-weight: 600;
    color: var(--primary);
    font-size: 0.9rem;
}

/* Review form */
.review-form {
    margin-top: 2rem;
    display: flex;
    flex-direction: column;
    gap: 1rem;
}
.review-form input,
.review-form textarea {
    padding: 0.75rem;
    border-radius: 5px;
    border: 1px solid #2d3a5c;
    background: #16213a;
    color: var(--text-light);
    font-size: 0.9rem;
    resize: vertical;
}
.review-form input:focus,
.review-form textarea:focus {
    outline: none;
    border-color: var(--primary);
}
.review-form button {
    align-self: flex-start;
    background: var(--primary);
    color: var(--bg-dark);
    border: none;
    padding: 0.75rem 1.5rem;
    border-radius: 20px;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.3s ease;
}
.review-form button:hover {
    background: #b5a5fa;
}

/* Star rating control */
.star-rating {
    display: flex;
    flex-direction: row-reverse;
    justify-content: flex-start;
    font-size: 1.5rem;
    margin-bottom: 0.5rem;
}
.star-rating input {
    display: none;
}
.star-rating label {
    cursor: pointer;
    color: #444;
    margin: 0 2px;
    transition: color 0.2s ease;
}
/* When a star is selected, highlight it and all previous stars */
.star-rating input:checked ~ label,
.star-rating label:hover,
.star-rating label:hover ~ label {
    color: var(--secondary);
}

/* Display of stars in reviews */
.review-item .stars {
    display: flex;
    font-size: 1.2rem;
    margin-bottom: 0.25rem;
    color: var(--secondary);
}
.review-item .star.empty {
    color: #444;
}

/* Contact page */
.contact-section {
    padding: 4rem 0;
    background: var(--bg-dark);
}
.contact-wrapper {
    display: flex;
    flex-wrap: wrap;
    gap: 2rem;
}
.contact-form {
    flex: 2 1 320px;
    display: flex;
    flex-direction: column;
    gap: 1rem;
}
.contact-form h2 {
    margin-bottom: 0.5rem;
    color: var(--secondary);
}
.contact-form input,
.contact-form textarea {
    padding: 0.75rem;
    border-radius: 5px;
    border: 1px solid #2d3a5c;
    background: #16213a;
    color: var(--text-light);
    font-size: 0.9rem;
    resize: vertical;
}
.contact-form input:focus,
.contact-form textarea:focus {
    outline: none;
    border-color: var(--primary);
}
.contact-form button {
    align-self: flex-start;
    background: var(--primary);
    color: var(--bg-dark);
    border: none;
    padding: 0.75rem 1.5rem;
    border-radius: 20px;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.3s ease;
}
.contact-form button:hover {
    background: #b5a5fa;
}
.contact-response {
    margin-top: 1rem;
    font-size: 0.9rem;
}
.contact-info {
    flex: 1 1 260px;
    background: var(--bg-light);
    padding: 2rem;
    border-radius: 10px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.25);
    color: var(--text-light);
}
.contact-info h2 {
    margin-bottom: 0.5rem;
    color: var(--secondary);
}
.contact-info a {
    color: var(--secondary);
}

/* Footer */
.site-footer {
    background: var(--bg-dark);
    padding: 2rem 0;
    text-align: center;
    font-size: 0.8rem;
    color: var(--text-muted);
}
.credits {
    margin-top: 0.5rem;
    font-style: italic;
    color: #859bb6;
}

/* Responsive navigation */
@media (max-width: 768px) {
    .nav-menu ul {
        flex-direction: column;
        background: var(--bg-light);
        position: absolute;
        top: 100%;
        right: 0;
        width: 200px;
        opacity: 0;
        visibility: hidden;
        transform: translateY(-10px);
        transition: opacity 0.3s ease, transform 0.3s ease;
    }
    .nav-menu ul.open {
        opacity: 1;
        visibility: visible;
        transform: translateY(0);
    }
    .nav-toggle {
        display: block;
    }
    .nav-menu a {
        display: block;
        padding: 1rem;
    }
}