/* ==========================================================================
   DUNYON — Site vitrine
   ========================================================================== */

/* ── Tokens ─────────────────────────────────────────────────────────────── */
:root {
    --f-bg:          #06111F;
    --f-bg-2:        #0D1B2A;
    --f-card-bg:     rgba(255, 255, 255, 0.04);
    --f-card-border: rgba(255, 255, 255, 0.08);
    --f-cyan:        #54D2FF;
    --f-green:       #5EE9B5;
    --f-text:        #FFFFFF;
    --f-text-muted:  rgba(255, 255, 255, 0.6);
    --f-radius:      20px;
    --f-section-py:  100px;
}

/* ── Reset / base ────────────────────────────────────────────────────────── */
body.dunyon-front {
    background-color: var(--f-bg);
    color: var(--f-text-muted);
    font-family: 'Inter', system-ui, sans-serif;
    font-size: 1rem;
    line-height: 1.7;
    margin: 0;
}

body.dunyon-front *, body.dunyon-front *::before, body.dunyon-front *::after {
    box-sizing: border-box;
}

body.dunyon-front h1, body.dunyon-front h2, body.dunyon-front h3,
body.dunyon-front h4, body.dunyon-front h5 {
    color: var(--f-text);
    font-weight: 700;
    line-height: 1.2;
    margin: 0 0 1rem;
}

body.dunyon-front a:not([class*="d-btn"]) {
    color: var(--f-cyan);
    text-decoration: none;
    transition: color 0.2s;
}
body.dunyon-front a:not([class*="d-btn"]):hover { color: var(--f-green); }

/* Couleurs des boutons — spécificité explicite pour ne pas être écrasée par la règle a */
body.dunyon-front .d-btn--primary         { color: var(--f-bg); }
body.dunyon-front .d-btn--primary:hover   { color: var(--f-bg); }
body.dunyon-front .d-btn--secondary       { color: var(--f-text); }
body.dunyon-front .d-btn--secondary:hover { color: var(--f-text); }

/* ── Container ───────────────────────────────────────────────────────────── */
.d-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 24px;
}

/* ── Nav ─────────────────────────────────────────────────────────────────── */
.d-nav {
    position: sticky;
    top: 0;
    z-index: 100;
    background: rgba(6, 17, 31, 0.85);
    backdrop-filter: blur(12px);
    border-bottom: 1px solid var(--f-card-border);
}
.d-nav__inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 64px;
}

/* ── Logo ────────────────────────────────────────────────────────────────── */
.d-logo {
    display: flex;
    align-items: center;
    text-decoration: none;
}
.d-logo__img {
    height: 32px;
    width: auto;
}
.d-logo--stacked {
    flex-direction: column;
    align-items: center;
    gap: 6px;
}
.d-logo__tagline {
    font-size: 0.72rem;
    color: var(--f-text-muted);
    font-weight: 400;
}

/* ── Nav actions ─────────────────────────────────────────────────────────── */
.d-nav__actions {
    display: flex;
    align-items: center;
    gap: 1rem;
}
.d-nav__login {
    font-size: 0.875rem;
    color: var(--f-text-muted) !important;
    text-decoration: none;
    transition: color 0.2s;
}
.d-nav__login:hover { color: var(--f-text) !important; }

/* ── Buttons ─────────────────────────────────────────────────────────────── */
.d-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 0.75rem 2rem;
    border-radius: 9999px;
    font-weight: 600;
    font-size: 0.95rem;
    font-family: inherit;
    cursor: pointer;
    border: none;
    text-decoration: none;
    transition: background 0.2s, color 0.2s, transform 0.15s;
}
.d-btn--primary {
    background: var(--f-cyan);
    color: var(--f-bg);
}
.d-btn--primary:hover {
    background: var(--f-green);
    color: var(--f-bg);
    transform: translateY(-1px);
}
.d-btn--secondary {
    background: transparent;
    border: 1px solid rgba(255, 255, 255, 0.3);
    color: var(--f-text);
}
.d-btn--secondary:hover {
    background: rgba(255, 255, 255, 0.06);
    color: var(--f-text);
}
.d-btn--lg { padding: 1rem 2.5rem; font-size: 1.05rem; }
.d-btn--sm { padding: 0.45rem 1.2rem; font-size: 0.875rem; }

/* ── Sections ────────────────────────────────────────────────────────────── */
.d-section {
    padding: var(--f-section-py) 0;
}
.d-section--alt {
    background: var(--f-bg-2);
}
.d-section--hero {
    position: relative;
    overflow: hidden;
    padding: 120px 0 100px;
    text-align: center;
}
.d-section--cta {
    background: linear-gradient(135deg, rgba(84, 210, 255, 0.06) 0%, rgba(94, 233, 181, 0.06) 100%);
    text-align: center;
}
.d-section__title {
    font-size: clamp(1.8rem, 3vw, 2.5rem);
    font-weight: 700;
    letter-spacing: -0.02em;
    margin-bottom: 3rem;
    color: var(--f-text);
    text-align: center;
}
.d-section__subtitle {
    color: var(--f-text-muted);
    max-width: 600px;
    margin: -2rem auto 3rem;
    text-align: center;
}

/* ── Hero ────────────────────────────────────────────────────────────────── */
.d-hero__bg-lines {
    position: absolute;
    inset: 0;
    pointer-events: none;
}
.d-hero__content {
    position: relative;
    z-index: 1;
    max-width: 900px;
    margin: 0 auto;
    padding: 0 24px;
}
.d-hero__headline {
    font-size: clamp(2.5rem, 5vw, 4rem);
    font-weight: 700;
    letter-spacing: -0.03em;
    margin-bottom: 1.5rem;
    background: linear-gradient(135deg, var(--f-text) 50%, var(--f-cyan) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}
.d-hero__subheadline {
    font-size: clamp(1.1rem, 2vw, 1.3rem);
    color: var(--f-text-muted);
    max-width: 700px;
    margin: 0 auto 2.5rem;
    line-height: 1.6;
}

/* ── Grid ────────────────────────────────────────────────────────────────── */
.d-grid { display: grid; gap: 1.5rem; }
.d-grid--3 { grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); }
.d-grid--2 { grid-template-columns: repeat(auto-fit, minmax(320px, 1fr)); }

/* ── Cards ───────────────────────────────────────────────────────────────── */
.d-card {
    background: var(--f-card-bg);
    border: 1px solid var(--f-card-border);
    border-radius: var(--f-radius);
    padding: 2rem;
    transition: background 0.2s;
}
.d-card:hover {
    background: rgba(255, 255, 255, 0.07);
}
.d-card__icon {
    color: var(--f-cyan);
    margin-bottom: 1rem;
}
.d-card__title {
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--f-text);
    margin-bottom: 0.5rem;
}
.d-card__label {
    font-size: 1.2rem;
    font-weight: 600;
    color: var(--f-cyan);
    margin-bottom: 0.5rem;
}
.d-card__desc {
    color: var(--f-text-muted);
    font-size: 0.95rem;
    margin: 0;
}

/* ── Steps ───────────────────────────────────────────────────────────────── */
.d-steps {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 2rem;
}
.d-step {
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 1rem;
}
.d-step__number {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    background: rgba(84, 210, 255, 0.12);
    border: 1px solid rgba(84, 210, 255, 0.3);
    color: var(--f-cyan);
    font-weight: 700;
    font-size: 1.1rem;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}
.d-step__title {
    font-size: 1.05rem;
    font-weight: 600;
    color: var(--f-text);
    margin: 0;
}
.d-step__desc {
    color: var(--f-text-muted);
    font-size: 0.9rem;
    margin: 0;
}

/* ── CTA ─────────────────────────────────────────────────────────────────── */
.d-cta {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 2rem;
}
.d-cta__headline {
    font-size: clamp(1.8rem, 3vw, 2.5rem);
    letter-spacing: -0.02em;
}

/* ── Prose (text block) ──────────────────────────────────────────────────── */
.d-prose {
    max-width: 800px;
    color: var(--f-text-muted);
    line-height: 1.8;
}
.d-prose h2, .d-prose h3 { color: var(--f-text); }
.d-prose a { color: var(--f-cyan); }
.d-prose strong { color: var(--f-text); }

/* ── Contact form ────────────────────────────────────────────────────────── */
.d-contact {
    display: grid;
    grid-template-columns: 1fr 2fr;
    gap: 4rem;
    align-items: start;
}
@media (max-width: 768px) {
    .d-contact { grid-template-columns: 1fr; gap: 2rem; }
}
.d-form { display: flex; flex-direction: column; gap: 1.25rem; }
.d-form__row { display: grid; gap: 1.25rem; }
.d-form__row--2 { grid-template-columns: 1fr 1fr; }
@media (max-width: 600px) { .d-form__row--2 { grid-template-columns: 1fr; } }
.d-form__field { display: flex; flex-direction: column; gap: 6px; }
.d-form__field label { font-size: 0.875rem; color: var(--f-text-muted); font-weight: 500; }

.d-input {
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid var(--f-card-border);
    border-radius: 10px;
    padding: 0.75rem 1rem;
    color: var(--f-text);
    font-family: inherit;
    font-size: 0.95rem;
    width: 100%;
    transition: border-color 0.2s, box-shadow 0.2s;
}
.d-input:focus {
    outline: none;
    border-color: var(--f-cyan);
    box-shadow: 0 0 0 3px rgba(84, 210, 255, 0.12);
}
.d-input::placeholder { color: rgba(255, 255, 255, 0.25); }
.d-input--textarea { resize: vertical; min-height: 120px; }

/* Form errors */
.d-form .form-error-message {
    font-size: 0.8rem;
    color: #FF8CA0;
}

/* ── Flash messages ──────────────────────────────────────────────────────── */
.d-flash {
    padding: 1rem 1.5rem;
    border-radius: 8px;
    font-size: 0.95rem;
    max-width: 700px;
    margin: 1.5rem auto;
}
.d-flash--success {
    background: rgba(94, 233, 181, 0.12);
    border: 1px solid rgba(94, 233, 181, 0.3);
    color: #5EE9B5;
}
.d-flash--error {
    background: rgba(255, 140, 160, 0.12);
    border: 1px solid rgba(255, 140, 160, 0.3);
    color: #FF8CA0;
}

/* ── Footer ──────────────────────────────────────────────────────────────── */
.d-footer {
    background: var(--f-bg-2);
    border-top: 1px solid var(--f-card-border);
    padding: 3rem 0;
}
.d-footer__inner {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1.5rem;
    text-align: center;
}
.d-footer__links {
    display: flex;
    gap: 2rem;
    flex-wrap: wrap;
    justify-content: center;
}
.d-footer__links a {
    color: var(--f-text-muted);
    font-size: 0.875rem;
    transition: color 0.2s;
}
.d-footer__links a:hover { color: var(--f-cyan); }
.d-footer__copy {
    color: rgba(255, 255, 255, 0.3);
    font-size: 0.8rem;
    margin: 0;
}

/* ── Responsive ──────────────────────────────────────────────────────────── */
@media (max-width: 768px) {
    :root { --f-section-py: 60px; }
    .d-section--hero { padding: 80px 0 60px; }
}
