/* ===================================
   BNSI-TP - Professional Website Styles
   =================================== */

/* CSS Variables */
:root {
    --primary-color: #1a5f7a;
    --primary-dark: #134b5f;
    --secondary-color: #f57c00;
    --accent-color: #ffc107;
    --dark-color: #1a1a2e;
    --text-color: #333;
    --text-light: #666;
    --bg-light: #f8f9fa;
    --bg-gray: #e9ecef;
    --white: #ffffff;
    --shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    --shadow-lg: 0 10px 30px rgba(0, 0, 0, 0.15);
    --transition: all 0.3s ease;
    --border-radius: 8px;
}

/* Reset & Base */
*, *::before, *::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Poppins', sans-serif;
    font-size: 16px;
    line-height: 1.7;
    color: var(--text-color);
    background-color: var(--white);
}

h1, h2, h3, h4, h5, h6 {
    font-weight: 600;
    line-height: 1.3;
    margin-bottom: 1rem;
}

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

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

img {
    max-width: 100%;
    height: auto;
}

ul {
    list-style: none;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* Buttons */
.btn {
    display: inline-block;
    padding: 14px 32px;
    font-size: 1rem;
    font-weight: 500;
    text-align: center;
    border-radius: 50px;
    cursor: pointer;
    transition: var(--transition);
    border: none;
}

.btn-primary {
    background: linear-gradient(135deg, var(--primary-color), var(--primary-dark));
    color: var(--white);
}

.btn-primary:hover {
    background: linear-gradient(135deg, var(--secondary-color), #e65100);
    color: var(--white);
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
}

.btn-outline {
    background: transparent;
    color: var(--white);
    border: 2px solid var(--white);
}

.btn-outline:hover {
    background: var(--white);
    color: var(--primary-color);
}

.btn-block {
    width: 100%;
}

/* Navigation */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    padding: 20px 0;
    transition: var(--transition);
}

.navbar.scrolled {
    background: var(--white);
    box-shadow: var(--shadow);
    padding: 15px 0;
}

.navbar .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

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

.logo-img {
    height: 50px;
    width: auto;
    transition: var(--transition);
}

.navbar.scrolled .logo-img {
    height: 45px;
}

.nav-menu {
    display: flex;
    align-items: center;
    gap: 30px;
}

.nav-link {
    color: var(--white);
    font-weight: 500;
    padding: 8px 0;
    position: relative;
}

.navbar.scrolled .nav-link {
    color: var(--text-color);
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--secondary-color);
    transition: var(--transition);
}

.nav-link:hover::after {
    width: 100%;
}

.btn-nav {
    background: var(--secondary-color);
    color: var(--white) !important;
    padding: 10px 24px;
    border-radius: 50px;
}

.btn-nav:hover {
    background: #e65100;
    color: var(--white);
}

.btn-nav::after {
    display: none;
}

/* Mobile Navigation */
.nav-toggle {
    display: none;
    flex-direction: column;
    background: none;
    border: none;
    cursor: pointer;
    padding: 5px;
}

.hamburger {
    width: 25px;
    height: 3px;
    background: var(--white);
    position: relative;
    transition: var(--transition);
}

.hamburger::before,
.hamburger::after {
    content: '';
    position: absolute;
    width: 25px;
    height: 3px;
    background: var(--white);
    transition: var(--transition);
}

.hamburger::before {
    top: -8px;
}

.hamburger::after {
    top: 8px;
}

.navbar.scrolled .hamburger,
.navbar.scrolled .hamburger::before,
.navbar.scrolled .hamburger::after {
    background: var(--text-color);
}

/* Hero Section */
.hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    background: url('../images/hero-bg.jpg') center center / cover no-repeat;
    overflow: hidden;
}

.hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, rgba(26, 95, 122, 0.85) 0%, rgba(19, 75, 95, 0.9) 50%, rgba(26, 26, 46, 0.95) 100%);
}

.hero-content {
    text-align: center;
    color: var(--white);
    z-index: 1;
}

.hero-subtitle {
    display: block;
    font-size: 1rem;
    font-weight: 400;
    letter-spacing: 3px;
    text-transform: uppercase;
    margin-bottom: 10px;
    opacity: 0.9;
}

.hero-title {
    font-family: 'Playfair Display', serif;
    font-size: 5rem;
    font-weight: 700;
    margin-bottom: 20px;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.2);
}

.hero-text {
    font-size: 1.5rem;
    font-weight: 300;
    margin-bottom: 15px;
}

.hero-slogan {
    font-style: italic;
    font-size: 1.1rem;
    opacity: 0.9;
    margin-bottom: 40px;
}

.hero-buttons {
    display: flex;
    gap: 20px;
    justify-content: center;
}

.hero-scroll {
    position: absolute;
    bottom: 30px;
    left: 50%;
    transform: translateX(-50%);
    animation: bounce 2s infinite;
}

.hero-scroll a {
    color: var(--white);
    font-size: 2rem;
}

@keyframes bounce {
    0%, 20%, 50%, 80%, 100% {
        transform: translateX(-50%) translateY(0);
    }
    40% {
        transform: translateX(-50%) translateY(-10px);
    }
    60% {
        transform: translateX(-50%) translateY(-5px);
    }
}

/* Sections */
.section {
    padding: 100px 0;
}

.section-header {
    text-align: center;
    margin-bottom: 60px;
}

.section-tag {
    display: inline-block;
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    color: var(--white);
    padding: 8px 20px;
    border-radius: 50px;
    font-size: 0.85rem;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 15px;
}

.section-title {
    font-size: 2.8rem;
    color: var(--dark-color);
    margin-bottom: 15px;
}

.section-desc {
    font-size: 1.1rem;
    color: var(--text-light);
    max-width: 600px;
    margin: 0 auto;
}

.section-header-light .section-title,
.section-header-light .section-desc {
    color: var(--white);
}

/* About Section */
.about {
    background: var(--bg-light);
}

.about-grid {
    display: grid;
    grid-template-columns: 1.2fr 0.8fr;
    gap: 60px;
    align-items: center;
}

.about-intro {
    font-size: 1.2rem;
    line-height: 1.8;
    margin-bottom: 20px;
}

.about-points {
    margin-top: 30px;
}

.about-point {
    display: flex;
    align-items: flex-start;
    gap: 15px;
    margin-bottom: 15px;
}

.about-point i {
    color: var(--secondary-color);
    font-size: 1.2rem;
    margin-top: 3px;
}

.director-card {
    background: var(--white);
    padding: 40px;
    border-radius: var(--border-radius);
    box-shadow: var(--shadow-lg);
    text-align: center;
}

.director-icon {
    width: 100px;
    height: 100px;
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 20px;
}

.director-icon i {
    font-size: 3rem;
    color: var(--white);
}

.director-card h3 {
    font-size: 1.1rem;
    color: var(--dark-color);
    margin-bottom: 5px;
}

.director-title {
    color: var(--secondary-color);
    font-weight: 600;
    font-size: 0.95rem;
}

.director-role {
    color: var(--text-light);
    font-size: 0.9rem;
    margin-bottom: 20px;
}

.director-quote {
    font-style: italic;
    color: var(--text-light);
    font-size: 0.95rem;
    line-height: 1.7;
    border-left: 3px solid var(--secondary-color);
    padding-left: 20px;
    text-align: left;
}

/* Stats Section */
.stats-section {
    background: linear-gradient(135deg, var(--primary-dark), var(--primary-color));
    padding: 60px 0;
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 40px;
}

.stat-item {
    text-align: center;
    color: var(--white);
}

.stat-icon {
    font-size: 2.5rem;
    margin-bottom: 15px;
    opacity: 0.8;
}

.stat-number {
    font-size: 3rem;
    font-weight: 700;
    line-height: 1;
    margin-bottom: 10px;
}

.stat-label {
    font-size: 0.95rem;
    opacity: 0.9;
}

/* Services Section */
.services-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 30px;
}

.service-card {
    background: var(--white);
    padding: 40px 30px;
    border-radius: var(--border-radius);
    box-shadow: var(--shadow);
    transition: var(--transition);
    border-top: 4px solid transparent;
}

.service-card:hover {
    transform: translateY(-10px);
    box-shadow: var(--shadow-lg);
    border-top-color: var(--secondary-color);
}

.service-card-large {
    grid-column: span 3;
}

.service-icon {
    width: 70px;
    height: 70px;
    background: linear-gradient(135deg, var(--primary-color), var(--primary-dark));
    border-radius: var(--border-radius);
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 25px;
}

.service-icon i {
    font-size: 2rem;
    color: var(--white);
}

.service-title {
    font-size: 1.4rem;
    color: var(--dark-color);
    margin-bottom: 15px;
}

.service-desc {
    color: var(--text-light);
    margin-bottom: 20px;
}

.service-list {
    margin-top: 15px;
}

.service-list li {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 10px;
    color: var(--text-color);
}

.service-list li i {
    color: var(--secondary-color);
    font-size: 0.9rem;
}

.service-cols {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 30px;
}

/* Values Section */
.values {
    background: linear-gradient(135deg, var(--dark-color), #16213e);
}

.values-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 30px;
}

.value-card {
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    padding: 40px 25px;
    border-radius: var(--border-radius);
    text-align: center;
    color: var(--white);
    transition: var(--transition);
}

.value-card:hover {
    background: rgba(255, 255, 255, 0.15);
    transform: translateY(-5px);
}

.value-icon {
    width: 80px;
    height: 80px;
    background: linear-gradient(135deg, var(--secondary-color), #ff9800);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 25px;
}

.value-icon i {
    font-size: 2rem;
    color: var(--white);
}

.value-card h3 {
    font-size: 1.2rem;
    margin-bottom: 15px;
}

.value-card p {
    font-size: 0.95rem;
    opacity: 0.9;
    line-height: 1.6;
}

/* Projects Section */
.projects {
    background: var(--bg-light);
}

.projects-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 30px;
}

.project-card {
    background: var(--white);
    border-radius: var(--border-radius);
    overflow: hidden;
    box-shadow: var(--shadow);
    transition: var(--transition);
}

.project-card:hover {
    transform: translateY(-10px);
    box-shadow: var(--shadow-lg);
}

.project-image {
    height: 220px;
    position: relative;
    background: linear-gradient(135deg, var(--primary-color), var(--primary-dark));
    overflow: hidden;
}

.project-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: var(--transition);
}

.project-card:hover .project-image img {
    transform: scale(1.1);
}

.project-placeholder {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.project-placeholder i {
    font-size: 4rem;
    color: rgba(255, 255, 255, 0.3);
}

.project-status {
    position: absolute;
    top: 15px;
    right: 15px;
    padding: 6px 15px;
    border-radius: 50px;
    font-size: 0.8rem;
    font-weight: 500;
    color: var(--white);
}

.status-en_cours {
    background: var(--secondary-color);
}

.status-finition {
    background: #2196f3;
}

.status-livre {
    background: #4caf50;
}

.project-content {
    padding: 25px;
}

.project-title {
    font-size: 1.2rem;
    color: var(--dark-color);
    margin-bottom: 10px;
}

.project-location {
    color: var(--text-light);
    font-size: 0.9rem;
    margin-bottom: 15px;
}

.project-location i {
    color: var(--secondary-color);
    margin-right: 5px;
}

.project-desc {
    color: var(--text-light);
    font-size: 0.95rem;
    margin-bottom: 15px;
}

.project-partners {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.project-partners span {
    font-size: 0.8rem;
    background: var(--bg-gray);
    padding: 5px 12px;
    border-radius: 50px;
    color: var(--text-light);
}

/* Equipment Section */
.equipment-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 30px;
    margin-bottom: 50px;
}

.equipment-category {
    background: var(--white);
    padding: 30px;
    border-radius: var(--border-radius);
    box-shadow: var(--shadow);
}

.equipment-title {
    font-size: 1.2rem;
    color: var(--primary-color);
    margin-bottom: 20px;
    padding-bottom: 15px;
    border-bottom: 2px solid var(--bg-gray);
}

.equipment-title i {
    margin-right: 10px;
    color: var(--secondary-color);
}

.equipment-list li {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 0;
    border-bottom: 1px solid var(--bg-gray);
}

.equipment-list li:last-child {
    border-bottom: none;
}

.equipment-list li i {
    color: var(--primary-color);
}

.equipment-cta {
    text-align: center;
    background: var(--bg-light);
    padding: 40px;
    border-radius: var(--border-radius);
}

.equipment-cta p {
    font-size: 1.2rem;
    margin-bottom: 20px;
    color: var(--text-color);
}

/* HSE Section */
.hse {
    background: linear-gradient(135deg, var(--secondary-color), #e65100);
    padding: 80px 0;
}

.hse-content {
    display: flex;
    align-items: center;
    gap: 50px;
    color: var(--white);
}

.hse-icon {
    flex-shrink: 0;
    width: 150px;
    height: 150px;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.hse-icon i {
    font-size: 4rem;
}

.hse-text h2 {
    font-size: 2rem;
    margin-bottom: 20px;
}

.hse-text p {
    font-size: 1.1rem;
    line-height: 1.8;
    opacity: 0.95;
    margin-bottom: 15px;
}

/* Contact Section */
.contact {
    background: var(--white);
}

.contact-grid {
    display: grid;
    grid-template-columns: 1fr 1.5fr;
    gap: 60px;
}

.contact-item {
    display: flex;
    gap: 20px;
    margin-bottom: 30px;
}

.contact-icon {
    width: 60px;
    height: 60px;
    background: linear-gradient(135deg, var(--primary-color), var(--primary-dark));
    border-radius: var(--border-radius);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.contact-icon i {
    font-size: 1.5rem;
    color: var(--white);
}

.contact-details h4 {
    font-size: 1.1rem;
    color: var(--dark-color);
    margin-bottom: 5px;
}

.contact-details p {
    color: var(--text-light);
    line-height: 1.6;
}

.contact-form-wrapper {
    background: var(--bg-light);
    padding: 40px;
    border-radius: var(--border-radius);
}

.contact-form .form-row {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
}

.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 500;
    color: var(--text-color);
}

.form-group input,
.form-group textarea {
    width: 100%;
    padding: 14px 18px;
    border: 2px solid var(--bg-gray);
    border-radius: var(--border-radius);
    font-family: inherit;
    font-size: 1rem;
    transition: var(--transition);
}

.form-group input:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--primary-color);
}

.form-group textarea {
    resize: vertical;
    min-height: 120px;
}

/* Footer */
.footer {
    background: var(--dark-color);
    color: var(--white);
    padding: 80px 0 30px;
}

.footer-grid {
    display: grid;
    grid-template-columns: 1.5fr 1fr 1fr 1fr;
    gap: 40px;
    margin-bottom: 50px;
}

.footer-title {
    font-size: 1.8rem;
    margin-bottom: 15px;
}

.footer-desc {
    opacity: 0.8;
    margin-bottom: 10px;
}

.footer-slogan {
    font-style: italic;
    opacity: 0.7;
    font-size: 0.95rem;
}

.footer-subtitle {
    font-size: 1.1rem;
    margin-bottom: 20px;
    position: relative;
    padding-bottom: 10px;
}

.footer-subtitle::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 40px;
    height: 2px;
    background: var(--secondary-color);
}

.footer-list li {
    margin-bottom: 12px;
    opacity: 0.8;
    display: flex;
    align-items: flex-start;
    gap: 10px;
}

.footer-list li i {
    color: var(--secondary-color);
    margin-top: 4px;
}

.footer-list a {
    color: var(--white);
    opacity: 0.8;
}

.footer-list a:hover {
    opacity: 1;
    color: var(--secondary-color);
}

.footer-bottom {
    text-align: center;
    padding-top: 30px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    opacity: 0.7;
}

/* Messages/Alerts */
.messages-container {
    position: fixed;
    top: 100px;
    right: 20px;
    z-index: 1001;
    max-width: 400px;
}

.alert {
    padding: 15px 45px 15px 20px;
    border-radius: var(--border-radius);
    margin-bottom: 10px;
    position: relative;
    box-shadow: var(--shadow);
}

.alert-success {
    background: #d4edda;
    color: #155724;
    border: 1px solid #c3e6cb;
}

.alert-error {
    background: #f8d7da;
    color: #721c24;
    border: 1px solid #f5c6cb;
}

.alert-close {
    position: absolute;
    right: 15px;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    font-size: 1.5rem;
    cursor: pointer;
    opacity: 0.5;
}

.alert-close:hover {
    opacity: 1;
}

/* Responsive */
@media (max-width: 1024px) {
    .about-grid {
        grid-template-columns: 1fr;
    }

    .services-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .service-card-large {
        grid-column: span 2;
    }

    .values-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .projects-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .equipment-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .footer-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    .nav-toggle {
        display: flex;
    }

    .nav-menu {
        position: fixed;
        top: 0;
        right: -100%;
        width: 80%;
        max-width: 300px;
        height: 100vh;
        background: var(--white);
        flex-direction: column;
        padding: 80px 30px;
        box-shadow: var(--shadow-lg);
        transition: var(--transition);
    }

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

    .nav-link {
        color: var(--text-color);
        font-size: 1.1rem;
        padding: 15px 0;
        border-bottom: 1px solid var(--bg-gray);
    }

    .hero-title {
        font-size: 3rem;
    }

    .hero-buttons {
        flex-direction: column;
    }

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

    .stats-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .services-grid {
        grid-template-columns: 1fr;
    }

    .service-card-large {
        grid-column: span 1;
    }

    .service-cols {
        grid-template-columns: 1fr;
    }

    .values-grid {
        grid-template-columns: 1fr;
    }

    .projects-grid {
        grid-template-columns: 1fr;
    }

    .equipment-grid {
        grid-template-columns: 1fr;
    }

    .hse-content {
        flex-direction: column;
        text-align: center;
    }

    .contact-grid {
        grid-template-columns: 1fr;
    }

    .contact-form .form-row {
        grid-template-columns: 1fr;
    }

    .footer-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 480px) {
    .hero-title {
        font-size: 2.5rem;
    }

    .hero-subtitle {
        font-size: 0.85rem;
    }

    .section {
        padding: 60px 0;
    }

    .director-card {
        padding: 30px 20px;
    }

    .stat-number {
        font-size: 2.5rem;
    }
}
