/**
 * Styles de la page d'accueil - Design "Neuro-Tech"
 * Intégration parfaite avec style.css
 */

/* ======================================
   SHARED SECTION STYLES
====================================== */
/* Grid pattern mixin - used by all sections */
.hero-section,
.section-light,
.section-bg-alt,
#contact-me {
    position: relative;
    background-size: 40px 40px;
    background-attachment: fixed;
}

/* Container z-index for sections with glows */
.hero-section .container,
.section-light .container,
.section-bg-alt .container {
    position: relative;
    z-index: 1;
}

/* ======================================
   HERO SECTION
====================================== */
.hero-section {
    background-color: #0a0f1e;
    background-image: 
        linear-gradient(rgba(255, 255, 255, 0.05) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255, 255, 255, 0.05) 1px, transparent 1px);
    background-size: 40px 40px;
    background-attachment: fixed;
    padding: 9rem 0 6rem;
    margin-top: 0;
    min-height: 90vh;
    display: flex;
    align-items: center;
    overflow: hidden;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.4) inset, 0 10px 30px rgba(0, 0, 0, 0.3);
}

/* Background glows */
.hero-section::before,
.hero-section::after {
    content: '';
    position: absolute;
    z-index: 0;
    pointer-events: none;
}

.hero-section::before {
    top: -20%;
    right: -10%;
    width: 800px;
    height: 800px;
    background: radial-gradient(circle, rgba(14, 165, 233, 0.15) 0%, transparent 70%);
}

.hero-section::after {
    bottom: -20%;
    left: -10%;
    width: 600px;
    height: 600px;
    background: radial-gradient(circle, rgba(99, 102, 241, 0.1) 0%, transparent 70%);
}

.hero-section h1 {
    color: white !important;
    text-shadow: 0 2px 15px rgba(0,0,0,0.3);
    font-weight: 800;
    line-height: 1.2;
    background: none !important;
    -webkit-text-fill-color: white !important;
}

.hero-section .text-blue {
    color: var(--primary-color) !important;
    text-shadow: 0 0 25px rgba(14, 165, 233, 0.6);
    position: relative;
    display: inline-block;
}

/* Social Icons - Modern Hero Style */
.social-link {
    width: 48px;
    height: 48px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.15);
    color: rgba(255, 255, 255, 0.8) !important;
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    font-size: 1.2rem;
    text-decoration: none;
    backdrop-filter: blur(10px);
    position: relative;
    overflow: hidden;
}

/* Subtle glow on hover */
.social-link::before {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: 50%;
    background: radial-gradient(circle, var(--primary-color), transparent);
    opacity: 0;
    transition: opacity 0.4s ease;
}

.social-link:hover::before {
    opacity: 0.2;
}

.social-link:hover {
    background: var(--primary-color);
    color: white !important;
    transform: translateY(-4px) scale(1.15);
    box-shadow: 0 8px 25px rgba(6, 182, 212, 0.4), 0 0 15px rgba(6, 182, 212, 0.3);
    border-color: var(--primary-color);
}

.social-link i {
    position: relative;
    z-index: 1;
    transition: transform 0.3s ease;
}

.social-link:hover i {
    transform: scale(1.1);
}

/* Social icons container spacing */
.social-icons {
    gap: 1rem !important;
}

/* Profile Image with Tech Ring */
.profile-image-wrapper {
    position: relative;
    padding: 20px;
}

.profile-image-wrapper::before {
    content: '';
    position: absolute;
    inset: 0;
    border: 2px dashed rgba(14, 165, 233, 0.3);
    border-radius: 50%;
    animation: spin 20s linear infinite;
    pointer-events: none;
}

.profile-image-wrapper img {
    border-radius: 24px; /* Modern shape, not fully round or square */
    border: 1px solid rgba(255,255,255,0.1);
    box-shadow: 0 20px 50px rgba(0,0,0,0.3);
    transition: transform 0.5s ease;
}

.profile-image-wrapper:hover img {
    transform: scale(1.02);
}

@keyframes spin {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

/* ======================================
   EXPERTISE SECTION
====================================== */
.section-light {
    background: #1e293b;
    background-image: 
        linear-gradient(rgba(255, 255, 255, 0.04) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255, 255, 255, 0.04) 1px, transparent 1px);
    background-size: 40px 40px;
    background-attachment: fixed;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3) inset, 0 10px 30px rgba(0, 0, 0, 0.25);
    padding: var(--spacing-2xl) 0;
}

/* Background glows */
.section-light::before,
.section-light::after {
    content: '';
    position: absolute;
    z-index: 0;
    pointer-events: none;
}

.section-light::before {
    top: -10%;
    left: -10%;
    width: 700px;
    height: 700px;
    background: radial-gradient(circle, rgba(6, 182, 212, 0.06) 0%, transparent 70%);
}

.section-light::after {
    bottom: -10%;
    right: -10%;
    width: 600px;
    height: 600px;
    background: radial-gradient(circle, rgba(99, 102, 241, 0.05) 0%, transparent 70%);
}

/* Expertise Cards */
.expertise-card {
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid rgba(6, 182, 212, 0.3);
    border-radius: var(--border-radius-md);
    padding: 2rem;
    height: 100%;
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    position: relative;
    overflow: hidden;
}

.expertise-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 0 20px rgba(6, 182, 212, 0.2);
    border-color: var(--primary-color);
}

/* Border glow effect */
.expertise-card::before {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: inherit;
    padding: 1px;
    background: linear-gradient(135deg, var(--primary-color), transparent);
    -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    -webkit-mask-composite: xor;
    mask-composite: exclude;
    opacity: 0.5;
    pointer-events: none;
    transition: opacity 0.4s ease;
}

.expertise-card:hover::before {
    opacity: 1;
}

.expertise-icon {
    width: 70px;
    height: 70px;
    border-radius: 50%; /* Circular icons in design */
    background: rgba(6, 182, 212, 0.1);
    border: 1px solid rgba(6, 182, 212, 0.3);
    color: var(--primary-color);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2rem;
    margin-bottom: 1.5rem;
    transition: all 0.3s ease;
}

.expertise-card:hover .expertise-icon {
    background: var(--primary-color);
    color: white;
    box-shadow: 0 0 20px rgba(6, 182, 212, 0.4);
}

.expertise-card h3 {
    font-size: 1.25rem;
    margin-bottom: 1rem;
    color: white; /* White text for dark mode */
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.expertise-card ul li {
    display: flex;
    align-items: center;
    margin-bottom: 0.5rem;
    font-size: 0.95rem;
    color: rgba(255, 255, 255, 0.8); /* Brighter text for better readability on dark */
}

.expertise-card ul li i {
    color: var(--primary-color);
    font-size: 0.85rem;
    margin-right: 0.75rem;
    background: transparent;
    padding: 0;
}

/* ======================================
   TECH STACK SECTION
====================================== */
.section-bg-alt {
    background: #020617;
    background-image: 
        linear-gradient(rgba(255, 255, 255, 0.04) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255, 255, 255, 0.04) 1px, transparent 1px);
    background-size: 40px 40px;
    background-attachment: fixed;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.4) inset, 0 10px 30px rgba(0, 0, 0, 0.3);
    padding: var(--spacing-2xl) 0;
}

/* Background glows */
.section-bg-alt::before,
.section-bg-alt::after {
    content: '';
    position: absolute;
    z-index: 0;
    pointer-events: none;
}

.section-bg-alt::before {
    top: 50%;
    right: -10%;
    width: 700px;
    height: 700px;
    background: radial-gradient(circle, rgba(99, 102, 241, 0.06) 0%, transparent 70%);
}

.section-bg-alt::after {
    bottom: 50%;
    left: -10%;
    width: 600px;
    height: 600px;
    background: radial-gradient(circle, rgba(6, 182, 212, 0.05) 0%, transparent 70%);
}

.tech-card {
    background: rgba(255, 255, 255, 0.04);
    border: 1.5px solid rgba(6, 182, 212, 0.2);
    border-radius: var(--border-radius-lg);
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    height: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 2.5rem 2rem;
    position: relative;
    overflow: hidden;
    backdrop-filter: blur(8px);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.2);
}

/* Animated border gradient on hover */
.tech-card::before {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: inherit;
    padding: 1px;
    background: linear-gradient(135deg, var(--primary-color), var(--accent-color));
    -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    -webkit-mask-composite: xor;
    mask-composite: exclude;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.4s ease;
}

.tech-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 16px 40px rgba(6, 182, 212, 0.25), 0 0 30px rgba(6, 182, 212, 0.15);
    border-color: var(--primary-color);
    background: rgba(6, 182, 212, 0.06);
}

.tech-card:hover::before {
    opacity: 1;
}

.tech-icon-wrapper {
    width: 120px;
    height: 120px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: white;
    border: 2px solid rgba(6, 182, 212, 0.3);
    border-radius: var(--border-radius-lg);
    margin-bottom: 1.5rem;
    padding: 1rem;
    transition: all 0.4s ease;
    position: relative;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.15);
}

.tech-card:hover .tech-icon-wrapper {
    background: white;
    border-color: var(--primary-color);
    transform: translateY(-6px) scale(1.08);
    box-shadow: 0 12px 30px rgba(6, 182, 212, 0.3);
}

.tech-icon {
    width: 100%;
    height: 100%;
    object-fit: contain;
    transition: all 0.3s ease;
    filter: brightness(1) drop-shadow(0 2px 4px rgba(0, 0, 0, 0.1));
}

.tech-card:hover .tech-icon {
    filter: brightness(1.05) drop-shadow(0 3px 6px rgba(0, 0, 0, 0.15));
    transform: scale(1.1);
}

.tech-card span {
    font-size: 0.95rem;
    font-weight: 600;
    color: white;
    text-align: center;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    transition: color 0.3s ease;
}

.tech-card:hover span {
    color: var(--primary-color);
    text-shadow: 0 0 10px rgba(6, 182, 212, 0.3);
}

/* ======================================
   CONTACT SECTION
====================================== */
#contact-me {
    background: #1e293b;
    padding: var(--spacing-2xl) 0;
    background-image: 
        linear-gradient(rgba(255, 255, 255, 0.04) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255, 255, 255, 0.04) 1px, transparent 1px);
    background-size: 40px 40px;
    background-attachment: fixed;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3) inset, 0 10px 30px rgba(0, 0, 0, 0.25);
}

/* Background glow */
#contact-me::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 800px;
    height: 800px;
    background: radial-gradient(circle, rgba(6, 182, 212, 0.08) 0%, transparent 70%);
    pointer-events: none;
    z-index: 0;
}

/* Contact Cards */
.contact-card {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(6, 182, 212, 0.25);
    border-radius: var(--border-radius-lg);
    overflow: hidden;
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    padding: 3rem 2rem;
    position: relative;
    z-index: 1;
    backdrop-filter: blur(10px);
    height: 100%;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

/* Border glow effect */
.contact-card::before {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: inherit;
    padding: 1px;
    background: linear-gradient(135deg, var(--primary-color), transparent);
    -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    -webkit-mask-composite: xor;
    mask-composite: exclude;
    opacity: 0.3;
    pointer-events: none;
    transition: opacity 0.4s ease;
}

.contact-card:hover {
    border-color: var(--primary-color);
    box-shadow: 0 0 30px rgba(6, 182, 212, 0.2);
    transform: translateY(-8px);
}

.contact-card:hover::before {
    opacity: 1;
}

.contact-icon-wrapper {
    width: 90px;
    height: 90px;
    background: rgba(6, 182, 212, 0.12);
    border: 1px solid rgba(6, 182, 212, 0.3);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 2rem;
    color: var(--primary-color);
    font-size: 2.25rem;
    transition: all 0.4s ease;
}

.contact-card:hover .contact-icon-wrapper {
    background: var(--primary-color);
    color: white;
    transform: scale(1.15);
    box-shadow: 0 0 25px rgba(6, 182, 212, 0.5);
}

.contact-card h3 {
    text-transform: uppercase;
    letter-spacing: 0.05em;
    font-size: 1.3rem;
}

.contact-card p {
    font-size: 0.95rem;
    line-height: 1.6;
}

/* Button improvements within cards */
.contact-card .btn {
    text-transform: uppercase;
    letter-spacing: 0.05em;
    font-weight: 600;
    padding: 0.9rem 1.5rem;
    border-radius: var(--border-radius-md);
}

/* Responsive */
@media (max-width: 991px) {
    .hero-section {
        text-align: center;
        padding-top: 7rem;
    }
    
    .hero-section h1 {
        font-size: 2.5rem;
    }
    
    .social-icons {
        justify-content: center;
    }
    
    .profile-image-wrapper {
        margin-top: 3rem;
        max-width: 400px;
        margin-left: auto;
        margin-right: auto;
    }
    
    .profile-image-wrapper::before {
        display: none; /* Simplify on mobile */
    }
}
