/* Reset et styles de base */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Lato', sans-serif;
    line-height: 1.6;
    color: #2c3e50;
    background-color: #ffffff;
    font-size: 16px;
}

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

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

h1 { font-size: 3.5rem; }
h2 { font-size: 3rem; }
h3 { font-size: 2.5rem; }
h4 { font-size: 2rem; }
h5 { font-size: 1.75rem; }
h6 { font-size: 1.5rem; }

p {
    margin-bottom: 1rem;
    color: #666;
    font-size: 1.1rem;
}

/* Buttons */
.btn {
    display: inline-block;
    padding: 14px 28px;
    border: none;
    border-radius: 6px;
    text-decoration: none;
    font-weight: 600;
    font-size: 1rem;
    cursor: pointer;
    transition: all 0.3s ease;
    text-align: center;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.btn-primary {
    background: linear-gradient(135deg, #ED1516 0%, #c41212 100%);
    color: white;
    box-shadow: 0 4px 15px rgba(237, 21, 22, 0.3);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(237, 21, 22, 0.4);
    background: linear-gradient(135deg, #c41212 0%, #a00f0f 100%);
}

.btn-secondary {
    background: transparent;
    color: #ED1516;
    border: 2px solid #ED1516;
}

.btn-secondary:hover {
    background: #ED1516;
    color: white;
    transform: translateY(-2px);
}

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

.btn-outline:hover {
    background: white;
    color: #ED1516;
    transform: translateY(-2px);
}

.btn-success {
    background: linear-gradient(135deg, #07A709 0%, #059606 100%);
    color: white;
    box-shadow: 0 4px 15px rgba(7, 167, 9, 0.3);
}

.btn-success:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(7, 167, 9, 0.4);
    background: linear-gradient(135deg, #059606 0%, #047a05 100%);
}

.btn-large {
    padding: 16px 32px;
    font-size: 1.1rem;
}

.btn-apply {
    background: #059706 !important;
    border-color: #059706 !important;
    color: white !important;
}

.btn-apply:hover {
    background: #047a05 !important;
    border-color: #047a05 !important;
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(5, 151, 6, 0.4);
}

/* Header */
.header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    background: rgba(255, 255, 255, 0.98);
    backdrop-filter: blur(15px);
    z-index: 1000;
    box-shadow: 0 2px 20px rgba(30, 58, 138, 0.1);
    border-bottom: 1px solid rgba(30, 58, 138, 0.1);
}

.navbar {
    padding: 0.8rem 0;
}

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

.nav-logo {
    display: flex;
    align-items: center;
    gap: 12px;
}

.nav-logo a {
    display: flex;
    align-items: center;
    gap: 12px;
    text-decoration: none;
    transition: transform 0.3s ease;
}

.nav-logo a:hover {
    transform: scale(1.05);
}

.logo {
    width: 45px;
    height: 45px;
    border-radius: 8px;
}

.logo-text {
    font-size: 2rem;
    font-weight: 700;
    color: #ED1516;
    letter-spacing: -0.5px;
}

.nav-menu {
    display: flex;
}

.nav-list {
    display: flex;
    list-style: none;
    gap: 0.5rem;
    align-items: center;
}

.nav-link {
    text-decoration: none;
    color: #2c3e50;
    font-weight: 500;
    font-size: 0.95rem;
    transition: all 0.3s ease;
    position: relative;
    padding: 0.5rem 0.75rem;
    border-radius: 6px;
}

.nav-link:hover,
.nav-link.active {
    color: #ED1516;
    background: rgba(237, 21, 22, 0.1);
}

.nav-link.active::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 50%;
    transform: translateX(-50%);
    width: 20px;
    height: 2px;
    background: #07A709;
    border-radius: 1px;
}

/* Dropdown */
.dropdown {
    position: relative;
}

.dropdown-menu {
    position: absolute;
    top: 100%;
    left: 0;
    background: white;
    min-width: 200px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    border-radius: 8px;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: all 0.3s ease;
    list-style: none;
    padding: 1rem 0;
}

.dropdown:hover .dropdown-menu {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.dropdown-menu li {
    padding: 0;
}

.dropdown-menu a {
    display: block;
    padding: 0.5rem 1rem;
    color: #333;
    text-decoration: none;
    transition: background 0.3s ease;
}

.dropdown-menu a:hover {
    background: #f8f9ff;
    color: #667eea;
}

/* Mobile Toggle */
.nav-toggle {
    display: none;
    flex-direction: column;
    cursor: pointer;
}

.bar {
    width: 25px;
    height: 3px;
    background: #333;
    margin: 3px 0;
    transition: 0.3s;
}

/* Hero Section */
.hero {
    padding: 120px 0 80px;
    background: linear-gradient(135deg, rgba(237, 21, 22, 0.8) 0%, rgba(196, 18, 18, 0.8) 50%, rgba(7, 167, 9, 0.8) 100%), 
                url('../images/hero-medical-consultation.jpg') center/cover no-repeat;
    color: white;
    overflow: hidden;
    position: relative;
}

.hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 1000 1000"><defs><pattern id="grid" width="50" height="50" patternUnits="userSpaceOnUse"><path d="M 50 0 L 0 0 0 50" fill="none" stroke="rgba(255,255,255,0.1)" stroke-width="1"/></pattern></defs><rect width="100%" height="100%" fill="url(%23grid)"/></svg>');
    opacity: 0.3;
}

.hero-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
    position: relative;
    z-index: 2;
    min-height: 500px;
}


.hero-left {
    text-align: left;
}

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

.hero-title {
    font-size: 3.5rem;
    font-weight: 700;
    margin-bottom: 1.5rem;
    line-height: 1.1;
}

.highlight {
    background: linear-gradient(45deg, #fbbf24, #f59e0b);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.hero-description {
    font-size: 1.2rem;
    margin-bottom: 2rem;
    color: rgba(255, 255, 255, 0.9);
}

.hero-buttons {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
    align-items: center;
    justify-content: flex-start;
}

.hero-image {
    position: relative;
    display: block;
}

.hero-img {
    width: 100%;
    height: 400px;
    object-fit: cover;
    border-radius: 20px;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.2);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.hero-img:hover {
    transform: translateY(-5px);
    box-shadow: 0 25px 50px rgba(0, 0, 0, 0.3);
}

/* Présentation Institut */
.institute-presentation {
    padding: 80px 0;
    background-image: url('../images/institute-background.jpg');
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    position: relative;
    overflow: hidden;
}

.institute-presentation::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, rgba(248, 250, 252, 0.9) 0%, rgba(226, 232, 240, 0.9) 100%);
    z-index: 1;
}

.institute-presentation::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 1000 1000"><defs><pattern id="institute-pattern" width="60" height="60" patternUnits="userSpaceOnUse"><path d="M30,0 L60,30 L30,60 L0,30 Z" fill="none" stroke="rgba(237,21,22,0.1)" stroke-width="1"/></pattern></defs><rect width="100%" height="100%" fill="url(%23institute-pattern)"/></svg>');
    opacity: 0.3;
    z-index: 2;
}

.presentation-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
    position: relative;
    z-index: 3;
}

.presentation-title {
    font-size: 3rem;
    color: #ED1516;
    margin-bottom: 1.5rem;
    font-weight: 700;
    line-height: 1.2;
    position: relative;
    z-index: 4;
}

.presentation-description {
    font-size: 1.1rem;
    color: #64748b;
    line-height: 1.6;
    margin-bottom: 2rem;
    position: relative;
    z-index: 4;
}

.presentation-stats {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2rem;
}

.presentation-stats .stat-item {
    text-align: center;
    padding: 1.5rem;
    background: white;
    border-radius: 12px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.08);
}

.presentation-stats .stat-number {
    font-size: 3rem;
    font-weight: 700;
    color: #07A709;
    margin-bottom: 0.5rem;
}

.presentation-stats .stat-label {
    font-size: 0.9rem;
    color: #64748b;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.presentation-image {
    position: relative;
    z-index: 4;
}

.presentation-image img {
    width: 100%;
    height: 400px;
    object-fit: cover;
    border-radius: 20px;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.15);
}

/* Filières Mises en Avant */
.filiere-highlight {
    padding: 80px 0;
    background: white;
}

.filiere-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(500px, 1fr));
    gap: 3rem;
    margin-top: 3rem;
}

.filiere-card {
    background: white;
    border-radius: 20px;
    overflow: hidden;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    border: 1px solid #e2e8f0;
}

.filiere-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.15);
}

.filiere-image {
    position: relative;
    height: 250px;
    overflow: hidden;
}

.filiere-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.filiere-card:hover .filiere-image img {
    transform: scale(1.05);
}

.filiere-badge {
    position: absolute;
    top: 1rem;
    right: 1rem;
    background: linear-gradient(135deg, #07A709, #059606);
    color: white;
    padding: 0.5rem 1rem;
    border-radius: 20px;
    font-size: 1rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    box-shadow: 0 4px 15px rgba(7, 167, 9, 0.3);
}

.filiere-content {
    padding: 2rem;
}

.filiere-title {
    font-size: 2.2rem;
    color: #ED1516;
    margin-bottom: 1rem;
    font-weight: 700;
}

.filiere-description {
    color: #64748b;
    line-height: 1.6;
    margin-bottom: 1.5rem;
    font-size: 1rem;
}

.filiere-features {
    list-style: none;
    padding: 0;
    margin-bottom: 2rem;
}

.filiere-features li {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 0.5rem;
    color: #64748b;
    font-weight: 500;
}

.filiere-features i {
    color: #07A709;
    font-size: 1rem;
}

/* Actualités Récentes */
.recent-news {
    padding: 80px 0;
    background: linear-gradient(135deg, #f8fafc 0%, #e2e8f0 100%);
}

.news-cta {
    text-align: center;
    margin-top: 3rem;
}

/* Features Section */
.features {
    padding: 80px 0;
    background: linear-gradient(135deg, #f8fafc 0%, #e2e8f0 100%);
}

.section-header {
    text-align: center;
    margin-bottom: 4rem;
}

.section-title {
    font-size: 3rem;
    color: #ED1516;
    margin-bottom: 1rem;
    font-weight: 700;
}

.section-description {
    font-size: 1.1rem;
    color: #64748b;
    max-width: 600px;
    margin: 0 auto;
    font-weight: 400;
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 2rem;
}

.feature-card {
    background: white;
    padding: 2rem;
    border-radius: 16px;
    text-align: center;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.08);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.feature-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.15);
}

.feature-icon {
    width: 90px;
    height: 90px;
    background: linear-gradient(135deg, #ED1516, #c41212);
    border-radius: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1.5rem;
    box-shadow: 0 8px 25px rgba(237, 21, 22, 0.3);
}

.feature-icon i {
    font-size: 2rem;
    color: white;
}

.feature-title {
    font-size: 1.8rem;
    color: #ED1516;
    margin-bottom: 1rem;
    font-weight: 600;
}

.feature-description {
    color: #64748b;
    line-height: 1.6;
    font-weight: 400;
}

/* Programs Preview */
.programs-preview {
    padding: 80px 0;
}

.programs-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 2rem;
}

.program-card {
    background: white;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.08);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.program-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.15);
}

.program-image {
    height: 200px;
    overflow: hidden;
}

.program-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.program-card:hover .program-image img {
    transform: scale(1.05);
}

.program-content {
    padding: 2rem;
}

.program-title {
    font-size: 1.5rem;
    color: #333;
    margin-bottom: 1rem;
}

.program-description {
    color: #666;
    margin-bottom: 1.5rem;
    line-height: 1.6;
}

.program-link {
    color: #667eea;
    text-decoration: none;
    font-weight: 500;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    transition: color 0.3s ease;
}

.program-link:hover {
    color: #764ba2;
}

/* Stats Section */
.stats {
    padding: 80px 0;
    background: linear-gradient(135deg, #ED1516 0%, #c41212 50%, #07A709 100%);
    color: white;
    position: relative;
}

.stats::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 1000 1000"><defs><pattern id="dots" width="40" height="40" patternUnits="userSpaceOnUse"><circle cx="20" cy="20" r="1" fill="rgba(255,255,255,0.1)"/></pattern></defs><rect width="100%" height="100%" fill="url(%23dots)"/></svg>');
    opacity: 0.5;
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 2rem;
    text-align: center;
}

.stat-item {
    padding: 2rem;
}

.stat-number {
    font-size: 3rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
    color: #fbbf24;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

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

/* News Section */
.news {
    padding: 80px 0;
    background: linear-gradient(135deg, #f8fafc 0%, #e2e8f0 100%);
}

.news-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 2rem;
}

.news-card {
    background: white;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.08);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.news-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.15);
}

.news-image {
    position: relative;
    height: 200px;
    overflow: hidden;
}

.news-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.news-card:hover .news-image img {
    transform: scale(1.05);
}

.news-date {
    position: absolute;
    top: 1rem;
    left: 1rem;
    background: linear-gradient(135deg, #1e3a8a, #3b82f6);
    color: white;
    padding: 0.5rem;
    border-radius: 8px;
    text-align: center;
    min-width: 60px;
    box-shadow: 0 4px 15px rgba(30, 58, 138, 0.3);
}

.news-date .day {
    display: block;
    font-size: 1.2rem;
    font-weight: 700;
}

.news-date .month {
    display: block;
    font-size: 0.8rem;
    text-transform: uppercase;
}

.news-content {
    padding: 2rem;
}

.news-title {
    font-size: 1.3rem;
    color: #1e3a8a;
    margin-bottom: 1rem;
    line-height: 1.3;
    font-weight: 600;
}

.news-excerpt {
    color: #64748b;
    margin-bottom: 1.5rem;
    line-height: 1.6;
    font-weight: 400;
}

.news-link {
    color: #10b981;
    text-decoration: none;
    font-weight: 600;
    transition: color 0.3s ease;
    text-transform: uppercase;
    font-size: 0.9rem;
    letter-spacing: 0.5px;
}

.news-link:hover {
    color: #059669;
}

/* CTA Section */
.cta {
    padding: 80px 0;
    background: linear-gradient(135deg, #ED1516 0%, #c41212 50%, #07A709 100%);
    color: white;
    text-align: center;
    position: relative;
}

.cta::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 1000 1000"><defs><pattern id="waves" width="100" height="100" patternUnits="userSpaceOnUse"><path d="M0,50 Q25,0 50,50 T100,50" fill="none" stroke="rgba(255,255,255,0.1)" stroke-width="2"/></pattern></defs><rect width="100%" height="100%" fill="url(%23waves)"/></svg>');
    opacity: 0.3;
}

.cta-content {
    max-width: 800px;
    margin: 0 auto;
    position: relative;
    z-index: 2;
}

.cta-title {
    font-size: 3rem;
    margin-bottom: 1.5rem;
}

.cta-description {
    font-size: 1.2rem;
    margin-bottom: 2rem;
    opacity: 0.9;
}

.cta-buttons {
    display: flex;
    gap: 1rem;
    justify-content: center;
    flex-wrap: wrap;
}

/* Footer */
.footer {
    background: linear-gradient(135deg, #0f172a 0%, #1e293b 100%);
    color: white;
    padding: 60px 0 20px;
    position: relative;
}

.footer::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 1000 1000"><defs><pattern id="grid-dark" width="50" height="50" patternUnits="userSpaceOnUse"><path d="M 50 0 L 0 0 0 50" fill="none" stroke="rgba(255,255,255,0.05)" stroke-width="1"/></pattern></defs><rect width="100%" height="100%" fill="url(%23grid-dark)"/></svg>');
    opacity: 0.5;
}

.footer-content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
    margin-bottom: 2rem;
    position: relative;
    z-index: 2;
}

.footer-logo {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 1rem;
}

.footer-logo a {
    display: flex;
    align-items: center;
    gap: 10px;
    text-decoration: none;
    transition: transform 0.3s ease;
}

.footer-logo a:hover {
    transform: scale(1.05);
}

.footer-logo .logo {
    width: 40px;
    height: 40px;
}

.footer-logo .logo-text {
    font-size: 1.8rem;
    font-weight: 700;
    color: #ED1516;
}

.footer-description {
    color: #ccc;
    margin-bottom: 1.5rem;
    line-height: 1.6;
}

.social-links {
    display: flex;
    gap: 1rem;
}

.social-link {
    width: 40px;
    height: 40px;
    background: rgba(237, 21, 22, 0.1);
    border: 1px solid rgba(237, 21, 22, 0.3);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #ED1516;
    text-decoration: none;
    transition: all 0.3s ease;
}

.social-link:hover {
    background: #ED1516;
    color: white;
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(237, 21, 22, 0.3);
}

.footer-title {
    font-size: 1.2rem;
    margin-bottom: 1rem;
    color: white;
}

.footer-links {
    list-style: none;
}

.footer-links li {
    margin-bottom: 0.5rem;
}

.footer-links a {
    color: #94a3b8;
    text-decoration: none;
    transition: color 0.3s ease;
}

.footer-links a:hover {
    color: #ED1516;
}

.contact-info {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.contact-item {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: #94a3b8;
}

.contact-item i {
    color: #ED1516;
    width: 20px;
}

.footer-bottom {
    border-top: 1px solid rgba(237, 21, 22, 0.2);
    padding-top: 2rem;
    position: relative;
    z-index: 2;
}

.footer-bottom-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 1rem;
}

.footer-bottom-links {
    display: flex;
    gap: 2rem;
}

.footer-bottom-links a {
    color: #94a3b8;
    text-decoration: none;
    transition: color 0.3s ease;
}

.footer-bottom-links a:hover {
    color: #ED1516;
}

/* Animations */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.fade-in-up {
    animation: fadeInUp 0.6s ease-out;
}

/* Scroll animations */
.animate-on-scroll {
    opacity: 0;
    transform: translateY(30px);
    transition: all 0.6s ease;
}

.animate-on-scroll.animated {
    opacity: 1;
    transform: translateY(0);
}
