/*
 Theme Name:   Multime Digital
 Theme URI:    https://multimedigital.com
 Description:  Thème enfant Hello Elementor pour Multime Digital — Agence de Communication Digitale & Ingénierie Web de Prestige, Marrakech.
 Author:       Multime Digital
 Author URI:   https://multimedigital.com
 Template:     hello-elementor
 Version:      1.0.0
 License:      GNU General Public License v2 or later
 License URI:  https://www.gnu.org/licenses/gpl-2.0.html
 Text Domain:  multime-digital
 Tags:         agency, elementor, multilingual, rtl-ready
*/

/* ==========================================================================
   1. CSS CUSTOM PROPERTIES (DESIGN TOKENS)
   ========================================================================== */

:root {
    /* — Couleurs primaires — */
    --md-red:            #E3000F;
    --md-red-hover:      #C7000D;
    --md-red-light:      rgba(227, 0, 15, 0.08);
    --md-white:          #FFFFFF;
    --md-black:          #0A0A0A;
    --md-gray-900:       #1A1A1A;
    --md-gray-700:       #333333;
    --md-gray-500:       #666666;
    --md-gray-300:       #B0B0B0;
    --md-gray-100:       #F5F5F5;
    --md-gray-50:        #FAFAFA;

    /* — Typographie — */
    --md-font-heading:   'Plus Jakarta Sans', sans-serif;
    --md-font-body:      'DM Sans', sans-serif;
    --md-font-mono:      'JetBrains Mono', monospace;

    /* — Tailles — */
    --md-fs-hero:        clamp(2.8rem, 5.5vw, 5rem);
    --md-fs-h1:          clamp(2.2rem, 4vw, 3.5rem);
    --md-fs-h2:          clamp(1.8rem, 3vw, 2.5rem);
    --md-fs-h3:          clamp(1.3rem, 2vw, 1.75rem);
    --md-fs-h4:          clamp(1.1rem, 1.5vw, 1.35rem);
    --md-fs-body:        1rem;
    --md-fs-small:       0.875rem;

    /* — Espacements — */
    --md-space-xs:       0.5rem;
    --md-space-sm:       1rem;
    --md-space-md:       2rem;
    --md-space-lg:       4rem;
    --md-space-xl:       6rem;
    --md-space-2xl:      8rem;

    /* — Rayons / Ombres — */
    --md-radius-sm:      4px;
    --md-radius-md:      8px;
    --md-radius-lg:      16px;
    --md-shadow-sm:      0 1px 3px rgba(0,0,0,0.06);
    --md-shadow-md:      0 4px 20px rgba(0,0,0,0.08);
    --md-shadow-lg:      0 12px 40px rgba(0,0,0,0.12);
    --md-shadow-red:     0 8px 30px rgba(227,0,15,0.15);

    /* — Transitions — */
    --md-transition:     0.3s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    --md-transition-slow: 0.5s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}


/* ==========================================================================
   2. CSS RESET & BASE
   ========================================================================== */

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

html {
    scroll-behavior: smooth;
    -webkit-text-size-adjust: 100%;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    text-rendering: optimizeLegibility;
}

body {
    font-family: var(--md-font-body);
    font-size: var(--md-fs-body);
    line-height: 1.7;
    color: var(--md-gray-700);
    background-color: var(--md-white);
    overflow-x: hidden;
}

img,
picture,
video,
canvas,
svg {
    display: block;
    max-width: 100%;
    height: auto;
}

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

a:hover,
a:focus-visible {
    color: var(--md-red-hover);
}

::selection {
    background: var(--md-red);
    color: var(--md-white);
}


/* ==========================================================================
   3. TYPOGRAPHIE
   ========================================================================== */

h1, h2, h3, h4, h5, h6 {
    font-family: var(--md-font-heading);
    font-weight: 700;
    color: var(--md-black);
    line-height: 1.2;
    letter-spacing: -0.02em;
}

h1 { font-size: var(--md-fs-h1); margin-bottom: var(--md-space-md); }
h2 { font-size: var(--md-fs-h2); margin-bottom: var(--md-space-sm); }
h3 { font-size: var(--md-fs-h3); margin-bottom: var(--md-space-sm); }
h4 { font-size: var(--md-fs-h4); margin-bottom: var(--md-space-xs); }

p {
    margin-bottom: var(--md-space-sm);
    max-width: 72ch;
}


/* ==========================================================================
   4. COMPOSANTS UTILITAIRES
   ========================================================================== */

/* — Boutons — */
.md-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.875rem 2rem;
    font-family: var(--md-font-heading);
    font-size: var(--md-fs-small);
    font-weight: 600;
    letter-spacing: 0.05em;
    text-transform: uppercase;
    border: none;
    border-radius: var(--md-radius-sm);
    cursor: pointer;
    transition: all var(--md-transition);
}

.md-btn--primary {
    background: var(--md-red);
    color: var(--md-white);
    box-shadow: var(--md-shadow-red);
}

.md-btn--primary:hover {
    background: var(--md-red-hover);
    transform: translateY(-2px);
    box-shadow: 0 12px 35px rgba(227,0,15,0.25);
}

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

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

/* — Accent rouge (ligne décorative) — */
.md-accent {
    display: block;
    width: 48px;
    height: 3px;
    background: var(--md-red);
    margin-bottom: var(--md-space-sm);
}

/* — Section spacing — */
.md-section {
    padding: var(--md-space-xl) var(--md-space-md);
}

@media (max-width: 768px) {
    .md-section {
        padding: var(--md-space-lg) var(--md-space-sm);
    }
}

/* — Conteneur — */
.md-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 var(--md-space-md);
}


/* ==========================================================================
   5. OVERRIDES HELLO ELEMENTOR / ELEMENTOR
   ========================================================================== */

/* Supprime le padding par défaut d'Elementor sur les sections pleine largeur */
.elementor-section.elementor-section-full_width > .elementor-container {
    max-width: 100%;
}

/* Force la typo du thème dans Elementor */
.elementor-widget-text-editor,
.elementor-widget-heading .elementor-heading-title {
    font-family: var(--md-font-body) !important;
}

.elementor-widget-heading .elementor-heading-title {
    font-family: var(--md-font-heading) !important;
}

/* Boutons Elementor stylisés */
.elementor-button {
    font-family: var(--md-font-heading) !important;
    font-weight: 600 !important;
    letter-spacing: 0.05em !important;
    text-transform: uppercase !important;
    border-radius: var(--md-radius-sm) !important;
    transition: all var(--md-transition) !important;
}

/* Navigation Elementor */
.elementor-nav-menu a {
    font-family: var(--md-font-heading) !important;
    font-weight: 500 !important;
    font-size: var(--md-fs-small) !important;
    letter-spacing: 0.04em !important;
    text-transform: uppercase !important;
}


/* ==========================================================================
   6. RTL SUPPORT (Arabe)
   ========================================================================== */

[dir="rtl"] body,
.rtl body {
    font-family: 'Tajawal', var(--md-font-body);
}

[dir="rtl"] h1,
[dir="rtl"] h2,
[dir="rtl"] h3,
[dir="rtl"] h4,
[dir="rtl"] h5,
[dir="rtl"] h6,
.rtl h1,
.rtl h2,
.rtl h3,
.rtl h4,
.rtl h5,
.rtl h6 {
    font-family: 'Tajawal', var(--md-font-heading);
    letter-spacing: 0;
}

[dir="rtl"] .md-accent {
    margin-left: auto;
    margin-right: 0;
}


/* ==========================================================================
   7. ANIMATIONS D'ENTRÉE
   ========================================================================== */

@keyframes md-fadeUp {
    from { opacity: 0; transform: translateY(30px); }
    to   { opacity: 1; transform: translateY(0); }
}

@keyframes md-fadeIn {
    from { opacity: 0; }
    to   { opacity: 1; }
}

@keyframes md-slideRight {
    from { opacity: 0; transform: translateX(-40px); }
    to   { opacity: 1; transform: translateX(0); }
}

.md-animate {
    opacity: 0;
    animation: md-fadeUp 0.7s var(--md-transition) forwards;
}

.md-animate--delay-1 { animation-delay: 0.15s; }
.md-animate--delay-2 { animation-delay: 0.3s; }
.md-animate--delay-3 { animation-delay: 0.45s; }
.md-animate--delay-4 { animation-delay: 0.6s; }


/* ==========================================================================
   8. PRINT STYLES
   ========================================================================== */

@media print {
    body {
        color: #000;
        background: #fff;
    }
    .md-btn,
    nav,
    footer {
        display: none !important;
    }
}
