:root {
    --bg: #0a0d12;
    --surface: rgba(255, 255, 255, 0.028);
    --surface-hover: rgba(255, 255, 255, 0.055);
    --line: rgba(255, 255, 255, 0.09);
    --line-hover: rgba(94, 234, 212, 0.45);
    --text: #e8eef6;
    --muted: #8b98a8;
    --accent: #5eead4;
    --accent-soft: rgba(94, 234, 212, 0.12);
    --radius: 14px;
    --font: ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto,
        "Helvetica Neue", Arial, "Noto Sans", sans-serif;
    --mono: ui-monospace, SFMono-Regular, "SF Mono", Menlo, Consolas,
        "Liberation Mono", monospace;
}

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

html {
    color-scheme: dark;
}

body {
    margin: 0;
    min-height: 100vh;
    background-color: var(--bg);
    background-image:
        radial-gradient(60rem 60rem at 50% -18rem, rgba(94, 234, 212, 0.13), transparent 65%),
        radial-gradient(45rem 45rem at 100% 110%, rgba(122, 162, 255, 0.10), transparent 60%);
    background-repeat: no-repeat;
    color: var(--text);
    font-family: var(--font);
    font-size: 16px;
    line-height: 1.55;
    -webkit-font-smoothing: antialiased;
    text-rendering: optimizeLegibility;
}

.page {
    max-width: 62rem;
    margin: 0 auto;
    padding: clamp(2.5rem, 7vw, 5.5rem) clamp(1.25rem, 5vw, 2.5rem) 2.5rem;
    display: flex;
    flex-direction: column;
    gap: clamp(2.5rem, 6vw, 4rem);
    min-height: 100vh;
}

/* ---------- En-tête ---------- */

.hero {
    text-align: center;
}

.hero__logo {
    width: 72px;
    height: 72px;
    margin-bottom: 1.5rem;
    filter: drop-shadow(0 6px 24px rgba(94, 234, 212, 0.28));
}

.hero__eyebrow {
    margin: 0 0 0.4rem;
    font-family: var(--mono);
    font-size: 0.72rem;
    letter-spacing: 0.22em;
    text-transform: uppercase;
    color: var(--muted);
}

.hero__title {
    margin: 0;
    font-size: clamp(2.4rem, 8vw, 4.25rem);
    font-weight: 700;
    letter-spacing: -0.035em;
    line-height: 1.02;
}

.hero__tld {
    background: linear-gradient(100deg, var(--accent), #7aa2ff);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}

.hero__owner {
    margin: 0.9rem 0 0;
    font-size: clamp(1rem, 2.6vw, 1.18rem);
    font-weight: 600;
    letter-spacing: 0.02em;
}

.hero__lede {
    max-width: 34rem;
    margin: 0.75rem auto 0;
    color: var(--muted);
    font-size: 0.95rem;
}

/* ---------- Projets ---------- */

.projects__head {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 1rem;
    padding-bottom: 0.75rem;
    border-bottom: 1px solid var(--line);
}

.projects__head h2 {
    margin: 0;
    font-size: 1.02rem;
    font-weight: 600;
    letter-spacing: 0.01em;
}

.projects__count {
    font-family: var(--mono);
    font-size: 0.74rem;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--muted);
}

.cards {
    list-style: none;
    margin: 1.5rem 0 0;
    padding: 0;
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(min(100%, 17rem), 1fr));
    gap: 0.9rem;
}

.card {
    display: flex;
    flex-direction: column;
    gap: 0.35rem;
    height: 100%;
    padding: 1.15rem 1.2rem 1.05rem;
    background: var(--surface);
    border: 1px solid var(--line);
    border-radius: var(--radius);
    color: inherit;
    text-decoration: none;
    transition: background-color 0.18s ease, border-color 0.18s ease,
        transform 0.18s ease;
}

.card:hover,
.card:focus-visible {
    background: var(--surface-hover);
    border-color: var(--line-hover);
    transform: translateY(-3px);
}

.card:focus-visible {
    outline: 2px solid var(--accent);
    outline-offset: 3px;
}

.card__name {
    font-family: var(--mono);
    font-size: 0.72rem;
    letter-spacing: 0.06em;
    color: var(--accent);
    opacity: 0.85;
}

.card__title {
    font-size: 1.06rem;
    font-weight: 650;
    letter-spacing: -0.01em;
}

.card__desc {
    color: var(--muted);
    font-size: 0.9rem;
}

.card__go {
    margin-top: auto;
    padding-top: 0.6rem;
    font-size: 0.8rem;
    font-weight: 600;
    letter-spacing: 0.02em;
    color: var(--text);
    opacity: 0.75;
}

.card:hover .card__go,
.card:focus-visible .card__go {
    color: var(--accent);
    opacity: 1;
}

.empty {
    margin: 1.5rem 0 0;
    padding: 1.5rem;
    border: 1px dashed var(--line);
    border-radius: var(--radius);
    color: var(--muted);
    text-align: center;
    font-size: 0.92rem;
}

/* ---------- Pied de page ---------- */

.foot {
    margin-top: auto;
    padding-top: 2rem;
    border-top: 1px solid var(--line);
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 0.5rem;
    font-size: 0.8rem;
    color: var(--muted);
}

.foot__sep {
    opacity: 0.5;
}

@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        transition: none !important;
    }
}
