/* ============================================================
   Page d'accueil UML Studio
   Feuille autonome : style.css impose height:100vh / overflow:hidden
   au body, ce qui est incompatible avec une page qui defile.
   Les jetons de couleur sont repris a l'identique de l'editeur.
   ============================================================ */

:root {
    --primary: #2563eb;
    --primary-hover: #1d4ed8;
    --primary-soft: #dbeafe;
    --bg: #f1f5f9;
    --surface: #ffffff;
    --text: #1e293b;
    --text-muted: #64748b;
    --border: #cbd5e1;
    --border-soft: #e2e8f0;

    --usecase: #059669;
    --usecase-soft: #d1fae5;
    --sequence: #7c3aed;
    --sequence-soft: #ede9fe;
    --activity: #f59e0b;
    --activity-soft: #fef3c7;

    --shadow-sm: 0 1px 3px rgba(15, 23, 42, 0.08);
    --shadow-md: 0 4px 16px rgba(15, 23, 42, 0.08);
    --shadow-lg: 0 18px 48px rgba(15, 23, 42, 0.12);
    --radius: 10px;
    --radius-lg: 16px;
    --font: 'Segoe UI', system-ui, -apple-system, sans-serif;
    --mono: 'Consolas', 'Cascadia Code', 'Courier New', monospace;
    --maxw: 1140px;
}

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

html { scroll-behavior: smooth; scroll-padding-top: 80px; }

body {
    font-family: var(--font);
    background: var(--surface);
    color: var(--text);
    line-height: 1.65;
    -webkit-font-smoothing: antialiased;
}

img, svg { max-width: 100%; }
a { color: var(--primary); }

.wrap {
    max-width: var(--maxw);
    margin: 0 auto;
    padding: 0 24px;
}

/* === En-tete === */

.site-header {
    position: sticky;
    top: 0;
    z-index: 50;
    background: rgba(255, 255, 255, 0.92);
    backdrop-filter: blur(8px);
    border-bottom: 1px solid var(--border-soft);
}
.site-header .wrap {
    display: flex;
    align-items: center;
    gap: 24px;
    height: 64px;
}
.brand {
    display: flex;
    align-items: center;
    gap: 9px;
    text-decoration: none;
    color: var(--text);
    font-size: 19px;
    font-weight: 800;
    letter-spacing: -0.3px;
}
.brand span { color: var(--primary); }

.site-nav {
    margin-left: auto;
    display: flex;
    align-items: center;
    gap: 28px;
}
.site-nav a {
    color: var(--text-muted);
    text-decoration: none;
    font-size: 15px;
    font-weight: 500;
}
.site-nav a:hover { color: var(--text); }

/* === Boutons === */

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 11px 22px;
    border-radius: var(--radius);
    font-size: 15px;
    font-weight: 600;
    text-decoration: none;
    border: 1px solid transparent;
    white-space: nowrap;
    transition: background 0.15s, border-color 0.15s, transform 0.15s;
}
.btn-primary {
    background: var(--primary);
    color: #fff;
    box-shadow: var(--shadow-sm);
}
.btn-primary:hover { background: var(--primary-hover); transform: translateY(-1px); }
.btn-ghost {
    background: var(--surface);
    color: var(--text);
    border-color: var(--border);
}
.btn-ghost:hover { border-color: var(--text-muted); }
.btn-lg { padding: 14px 28px; font-size: 16px; }

/* === Hero === */

.hero {
    background:
        radial-gradient(900px 420px at 15% -10%, #e0edff 0%, rgba(224, 237, 255, 0) 65%),
        linear-gradient(180deg, var(--surface) 0%, var(--bg) 100%);
    border-bottom: 1px solid var(--border-soft);
    padding: 84px 0 72px;
}
.hero-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 56px;
    align-items: center;
}
.eyebrow {
    display: inline-block;
    padding: 5px 13px;
    border-radius: 999px;
    background: var(--primary-soft);
    color: var(--primary-hover);
    font-size: 13px;
    font-weight: 700;
    letter-spacing: 0.2px;
    margin-bottom: 20px;
}
.hero h1 {
    font-size: clamp(2rem, 4.2vw, 3rem);
    line-height: 1.12;
    letter-spacing: -1.2px;
    font-weight: 800;
    margin-bottom: 20px;
}
.hero h1 em { font-style: normal; color: var(--primary); }
.hero-lead {
    font-size: 18px;
    color: var(--text-muted);
    margin-bottom: 30px;
    max-width: 34em;
}
.hero-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin-bottom: 22px;
}
.hero-note {
    font-size: 14px;
    color: var(--text-muted);
    display: flex;
    align-items: center;
    gap: 7px;
}
.hero-note svg { flex: none; color: var(--usecase); }

/* === Captures d'ecran === */

.shot {
    margin: 0;
    border-radius: var(--radius-lg);
    border: 1px solid var(--border);
    background: var(--surface);
    box-shadow: var(--shadow-lg);
    overflow: hidden;
}
.shot-bar {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 10px 14px;
    background: #f8fafc;
    border-bottom: 1px solid var(--border-soft);
}
.shot-bar i {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: var(--border);
}
.shot-bar span {
    margin-left: 8px;
    font-size: 12px;
    color: var(--text-muted);
    font-family: var(--mono);
}
.shot img {
    display: block;
    width: 100%;
    height: auto;
}
.shot figcaption {
    padding: 11px 16px;
    font-size: 13px;
    color: var(--text-muted);
    border-top: 1px solid var(--border-soft);
    background: #f8fafc;
}

/* === Rythme des sections === */

.section { padding: 84px 0; }
.section-alt { background: var(--bg); border-block: 1px solid var(--border-soft); }

.section-head {
    max-width: 44em;
    margin: 0 auto 52px;
    text-align: center;
}
.section-head h2 {
    font-size: clamp(1.6rem, 2.8vw, 2.1rem);
    line-height: 1.2;
    letter-spacing: -0.6px;
    font-weight: 800;
    margin-bottom: 14px;
}
.section-head p {
    font-size: 17px;
    color: var(--text-muted);
}

/* === Les 4 diagrammes === */

.diagrams {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 24px;
}
.diagram-card {
    display: flex;
    flex-direction: column;
    background: var(--surface);
    border: 1px solid var(--border-soft);
    border-radius: var(--radius-lg);
    padding: 28px;
    box-shadow: var(--shadow-sm);
    border-top: 3px solid var(--accent, var(--primary));
}
.diagram-card h3 {
    font-size: 19px;
    font-weight: 700;
    margin-bottom: 8px;
}
.diagram-card > p {
    color: var(--text-muted);
    font-size: 15px;
    margin-bottom: 16px;
}
.chip {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    padding: 5px 12px;
    border-radius: 999px;
    font-size: 13px;
    font-weight: 700;
    background: var(--accent-soft, var(--primary-soft));
    color: var(--accent, var(--primary));
    margin-bottom: 15px;
    align-self: flex-start;
}
.tags {
    list-style: none;
    display: flex;
    flex-wrap: wrap;
    gap: 7px;
    margin-top: auto;
}
.tags li {
    font-size: 12.5px;
    color: var(--text-muted);
    background: var(--bg);
    border: 1px solid var(--border-soft);
    border-radius: 6px;
    padding: 3px 9px;
}

.card-class    { --accent: #2563eb; --accent-soft: #dbeafe; }
.card-usecase  { --accent: #059669; --accent-soft: #d1fae5; }
.card-sequence { --accent: #7c3aed; --accent-soft: #ede9fe; }
.card-activity { --accent: #d97706; --accent-soft: #fef3c7; }

/* === Fonctionnalites === */

.features {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 22px;
}
.feature {
    background: var(--surface);
    border: 1px solid var(--border-soft);
    border-radius: var(--radius-lg);
    padding: 26px;
    box-shadow: var(--shadow-sm);
}
.feature-icon {
    width: 42px;
    height: 42px;
    display: grid;
    place-items: center;
    border-radius: 11px;
    background: var(--primary-soft);
    color: var(--primary-hover);
    margin-bottom: 15px;
}
.feature h3 {
    font-size: 17px;
    font-weight: 700;
    margin-bottom: 7px;
}
.feature p {
    font-size: 15px;
    color: var(--text-muted);
}

/* === 3 etapes === */

.steps {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 28px;
    counter-reset: step;
}
.step { position: relative; padding-top: 12px; }
.step::before {
    counter-increment: step;
    content: counter(step);
    display: grid;
    place-items: center;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: var(--primary);
    color: #fff;
    font-size: 19px;
    font-weight: 800;
    margin-bottom: 18px;
    box-shadow: 0 0 0 6px var(--primary-soft);
}
.step h3 {
    font-size: 18px;
    font-weight: 700;
    margin-bottom: 8px;
}
.step p { color: var(--text-muted); font-size: 15px; }

/* === Bandeau final === */

.cta {
    background: linear-gradient(135deg, #1e3a8a 0%, var(--primary) 100%);
    color: #fff;
    padding: 72px 0;
    text-align: center;
}
.cta h2 {
    font-size: clamp(1.6rem, 3vw, 2.2rem);
    font-weight: 800;
    letter-spacing: -0.6px;
    margin-bottom: 14px;
}
.cta p {
    font-size: 17px;
    color: #dbeafe;
    max-width: 38em;
    margin: 0 auto 30px;
}
.cta .btn-primary {
    background: #fff;
    color: var(--primary-hover);
}
.cta .btn-primary:hover { background: #f8fafc; }

/* === Pied de page === */

.site-footer {
    background: #0f172a;
    color: #94a3b8;
    padding: 40px 0;
    font-size: 14px;
}
.site-footer .wrap {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 16px;
}
.site-footer a { color: #cbd5e1; text-decoration: none; }
.site-footer a:hover { color: #fff; text-decoration: underline; }
.footer-links {
    margin-left: auto;
    display: flex;
    flex-wrap: wrap;
    gap: 22px;
}

/* === Accessibilite === */

.skip-link {
    position: absolute;
    left: -9999px;
    top: 0;
    background: var(--primary);
    color: #fff;
    padding: 10px 18px;
    z-index: 100;
    border-radius: 0 0 var(--radius) 0;
}
.skip-link:focus { left: 0; }

:where(a, .btn):focus-visible {
    outline: 3px solid var(--primary);
    outline-offset: 3px;
    border-radius: 4px;
}

@media (prefers-reduced-motion: reduce) {
    html { scroll-behavior: auto; }
    * { transition: none !important; }
}

/* === Responsive === */

@media (max-width: 960px) {
    .hero-grid { grid-template-columns: 1fr; gap: 40px; }
    .hero-lead { max-width: none; }
    .features, .steps { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 720px) {
    .site-nav { gap: 16px; }
    .site-nav .nav-link { display: none; }
    .hero { padding: 56px 0 48px; }
    .section { padding: 56px 0; }
    .diagrams, .features, .steps { grid-template-columns: 1fr; }
    .footer-links { margin-left: 0; width: 100%; gap: 16px; }
}

@media print {
    .site-header, .cta, .hero-actions { display: none; }
}
.site-nav a.btn-primary, .site-nav a.btn-primary:hover {
    color: #fff;
}