/* ============================================================
   NEOBRUTALISM — Conrad Pringiers
   Bold borders, hard shadows, loud colors.
   ============================================================ */

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

:root {
    --bg: #fdf6e3;
    --text: #1a1a1a;
    --text-light: #444;
    --card-bg: #ffffff;

    /* Neubrutalist palette */
    --yellow: #ffdc58;
    --red: #ff6b6b;
    --blue: #6baaff;
    --green: #5cdb5c;
    --purple: #c084fc;
    --pink: #ff8fab;
    --orange: #ffb347;
    --teal: #4dd9c1;
    --lime: #d4ff47;

    --border: 3px solid #1a1a1a;
    --shadow-sm: 4px 4px 0 #1a1a1a;
    --shadow-md: 6px 6px 0 #1a1a1a;
    --shadow-lg: 8px 8px 0 #1a1a1a;

    --font-display: "Lexend", sans-serif;
    --font-mono: "Space Mono", monospace;
}

html {
    scroll-behavior: smooth;
    font-size: 16px;
}

body {
    font-family: var(--font-display);
    background: var(--bg);
    color: var(--text);
    line-height: 1.55;
    min-height: 100vh;
    -webkit-font-smoothing: antialiased;
    background-image: radial-gradient(
        circle,
        rgba(0, 0, 0, 0.04) 1px,
        transparent 1px
    );
    background-size: 24px 24px;
}

img {
    display: block;
    max-width: 100%;
}
a {
    color: inherit;
    text-decoration: none;
}

/* ============================================================
   BENTO GRID
   ============================================================ */

.bento {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1.5rem;
    max-width: 1200px;
    margin: 0 auto;
    padding: 2rem 1.5rem;
}

/* ============================================================
   CARDS — base neubrutalist style
   ============================================================ */

.card {
    background: var(--card-bg);
    border: var(--border);
    box-shadow: var(--shadow-md);
    transition:
        box-shadow 0.35s cubic-bezier(0.34, 1.56, 0.64, 1),
        transform 0.35s cubic-bezier(0.34, 1.56, 0.64, 1);
    position: relative;
}

.card:hover {
    box-shadow: var(--shadow-lg);
    transform: translate(-3px, -3px);
}

.card__inner {
    padding: 1.75rem;
    height: 100%;
    display: flex;
    flex-direction: column;
}

.card__title {
    font-size: 1.35rem;
    font-weight: 800;
    margin-bottom: 1rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    letter-spacing: -0.02em;
    text-transform: uppercase;
}

/* ============================================================
   SVG ICONS
   ============================================================ */

.icon {
    width: 26px;
    height: 26px;
    flex-shrink: 0;
}

.icon-sm {
    width: 20px;
    height: 20px;
    flex-shrink: 0;
}

.icon-lg {
    width: 32px;
    height: 32px;
    flex-shrink: 0;
}

.icon-xs {
    width: 16px;
    height: 16px;
    flex-shrink: 0;
    display: inline-block;
    vertical-align: middle;
    margin-left: 4px;
}

/* ============================================================
   CARD COLORS & POSITIONS
   ============================================================ */

.card--intro {
    grid-column: span 2;
    grid-row: span 2;
    background: var(--yellow);
}
.card--intro .card__title {
    color: #1a1a1a;
}

.card--parcours {
    grid-column: span 2;
    grid-row: span 2;
    background: var(--blue);
}
.card--parcours .card__title {
    color: #1a1a1a;
}

.card--skills {
    grid-column: span 2;
    grid-row: span 2;
    background: var(--green);
}
.card--skills .card__title {
    color: #1a1a1a;
}

.card--skills-extra {
    grid-column: span 1;
    grid-row: span 2;
    background: var(--purple);
}

.card--valeurs {
    grid-column: span 1;
    grid-row: span 2;
    background: var(--pink);
}

.card--flowscript {
    grid-column: span 3;
    grid-row: span 2;
    background: var(--teal);
}
.card--flowscript .card__title {
    color: #1a1a1a;
}

.card--netral {
    grid-column: span 1;
    grid-row: span 1;
    background: var(--orange);
}
.card--netral .card__title {
    color: #1a1a1a;
}

.card--allo {
    grid-column: span 2;
    grid-row: span 1;
    background: var(--lime);
}
.card--allo .card__title {
    color: #1a1a1a;
}

/* ============================================================
   INTRO CARD
   ============================================================ */

.card--intro .card__inner {
    flex-direction: row;
    align-items: center;
    gap: 2rem;
}

.intro-left {
    flex-shrink: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0;
}

.intro-avatar {
    flex-shrink: 0;
    width: 140px;
    height: 140px;
    border: var(--border);
    box-shadow: var(--shadow-sm);
    overflow: hidden;
    background: white;
}

.intro-photo {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.intro-text {
    flex: 1;
}

.intro-greeting {
    font-size: 0.95rem;
    font-weight: 600;
    margin-bottom: 0.15rem;
    color: #1a1a1a;
    opacity: 0.7;
}

.intro-name {
    font-family: var(--font-display);
    font-size: 2.8rem;
    font-weight: 900;
    line-height: 1.05;
    letter-spacing: -0.04em;
    margin-bottom: 0.75rem;
    color: #1a1a1a;
    text-transform: uppercase;
}

.intro-desc {
    font-size: 0.95rem;
    color: #333;
    line-height: 1.6;
    margin-bottom: 1rem;
    max-width: 480px;
}

.intro-tags {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
}

.tag {
    background: white;
    padding: 0.35rem 0.9rem;
    font-size: 0.8rem;
    font-weight: 700;
    color: #1a1a1a;
    border: var(--border);
    box-shadow: 2px 2px 0 #1a1a1a;
    text-transform: uppercase;
    letter-spacing: 0.03em;
}

/* ---- Intro Social Links ---- */

.intro-socials {
    display: flex;
    justify-content: center;
    gap: 0.5rem;
    margin-top: 0.75rem;
}

.social-link {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    background: white;
    border: var(--border);
    box-shadow: 2px 2px 0 #1a1a1a;
    color: #1a1a1a;
    transition:
        box-shadow 0.25s cubic-bezier(0.34, 1.56, 0.64, 1),
        transform 0.25s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.social-link svg {
    width: 18px;
    height: 18px;
}

.social-link:hover {
    box-shadow: 4px 4px 0 #1a1a1a;
    transform: translate(-2px, -2px);
}

/* ============================================================
   PARCOURS / TIMELINE
   ============================================================ */

.card--parcours .card__title {
    color: #1a1a1a;
}

.timeline {
    position: relative;
    padding-left: 2rem;
    display: flex;
    flex-direction: column;
    gap: 0;
    flex: 1;
}

.timeline::before {
    content: "";
    position: absolute;
    left: 0.35rem;
    top: 0.5rem;
    bottom: 0.5rem;
    width: 4px;
    background: #1a1a1a;
    border: 2px solid #1a1a1a;
}

.timeline-item {
    position: relative;
    padding-bottom: 1.5rem;
}

.timeline-item:last-child {
    padding-bottom: 0;
}

.timeline-dot {
    position: absolute;
    left: -2rem;
    top: 0.4rem;
    width: 16px;
    height: 16px;
    background: white;
    border: 3px solid #1a1a1a;
    z-index: 1;
    transition:
        transform 0.2s ease,
        background 0.2s ease;
}

.timeline-dot.future {
    background: repeating-linear-gradient(
        45deg,
        transparent,
        transparent 3px,
        #1a1a1a 3px,
        #1a1a1a 4px
    );
}

.timeline-item:hover .timeline-dot {
    transform: scale(1.35);
    background: #1a1a1a;
}

.timeline-content {
    background: white;
    padding: 0.9rem 1.1rem;
    border: var(--border);
    box-shadow: var(--shadow-sm);
    transition: box-shadow 0.2s ease;
}

.timeline-content.future-box {
    border-style: dashed;
    background: rgba(255, 255, 255, 0.6);
}

.timeline-item:hover .timeline-content {
    box-shadow: var(--shadow-md);
}

.timeline-date {
    font-size: 0.72rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: #1a1a1a;
    font-family: var(--font-mono);
}

.timeline-content h3 {
    font-size: 1.05rem;
    font-weight: 800;
    margin: 0.25rem 0 0.25rem;
    text-transform: uppercase;
}

.timeline-content p {
    font-size: 0.85rem;
    color: #444;
}

/* ---- Expand Toggle ---- */

.expand-toggle {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    width: 100%;
    padding: 0.6rem 1.1rem;
    margin-top: 0.5rem;
    margin-bottom: 0.5rem;
    background: white;
    border: var(--border);
    font-family: var(--font-mono);
    font-size: 0.75rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: #1a1a1a;
    cursor: pointer;
    position: relative;
    z-index: 1;
    transition:
        box-shadow 0.25s cubic-bezier(0.34, 1.56, 0.64, 1),
        transform 0.25s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.expand-toggle:hover {
    box-shadow: var(--shadow-sm);
    transform: translate(-1px, -1px);
}

.expand-chevron {
    transition: transform 0.35s cubic-bezier(0.34, 1.56, 0.64, 1);
    margin-left: auto;
}

.expand-toggle[aria-expanded="true"] .expand-chevron {
    transform: rotate(180deg);
}

.expand-content {
    max-height: 0;
    overflow: hidden;
    transition:
        max-height 0.4s cubic-bezier(0.4, 0, 0.2, 1),
        padding 0.4s ease,
        margin 0.4s ease;
    background: rgba(255, 255, 255, 0.5);
    border: none;
    margin-top: 0;
    padding: 0 1.1rem;
}

.expand-content.open {
    max-height: 300px;
    padding: 0.9rem 1.1rem;
    margin-bottom: 1rem;
    border: 2px dashed #1a1a1a;
}

.expand-content p {
    font-size: 0.85rem;
    color: #333;
    line-height: 1.6;
}

/* ============================================================
   SKILLS CARD
   ============================================================ */

.card--skills .card__title {
    color: #1a1a1a;
}

.skills-group {
    margin-bottom: 1rem;
}
.skills-group:last-child {
    margin-bottom: 0;
}

.skills-cat {
    font-size: 0.95rem;
    font-weight: 800;
    margin-bottom: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 0.02em;
    display: flex;
    align-items: center;
    gap: 0.4rem;
}

.skill-bar-wrap {
    margin-bottom: 0.9rem;
}
.skill-bar-wrap:last-child {
    margin-bottom: 0;
}

.skill-info {
    display: flex;
    justify-content: space-between;
    font-size: 0.85rem;
    font-weight: 700;
    margin-bottom: 0.3rem;
    font-family: var(--font-mono);
}

.skill-bar {
    width: 100%;
    height: 14px;
    background: white;
    border: var(--border);
    overflow: hidden;
}

.skill-fill {
    height: 100%;
    width: var(--w);
    background: #1a1a1a;
    transition: width 1.2s cubic-bezier(0.22, 0.61, 0.36, 1);
    width: 0;
}

.card--skills.revealed .skill-fill {
    width: var(--w);
}

/* ============================================================
   SKILLS EXTRA CARD
   ============================================================ */

.card--skills-extra .skills-cat {
    color: #1a1a1a;
}

.skills-desc {
    font-size: 0.88rem;
    color: #222;
    line-height: 1.65;
}

/* ============================================================
   VALUES CARD
   ============================================================ */

.card--valeurs .card__title {
    color: #1a1a1a;
}

.card--valeurs .card__inner {
    min-height: 420px;
}

.valeurs-list {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 0.4rem;
}

.val-item {
    display: flex;
    align-items: center;
    gap: 0.55rem;
    padding: 0.5rem 0.65rem;
    background: white;
    border: var(--border);
    box-shadow: 2px 2px 0 #1a1a1a;
    cursor: pointer;
    transition:
        box-shadow 0.25s cubic-bezier(0.34, 1.56, 0.64, 1),
        transform 0.25s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.val-item:hover,
.val-item.active {
    box-shadow: 4px 4px 0 #1a1a1a;
    transform: translate(-2px, -2px);
}

.val-item .icon-sm {
    flex-shrink: 0;
    color: #1a1a1a;
}

.val-item strong {
    font-size: 0.82rem;
    text-transform: uppercase;
    letter-spacing: 0.02em;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.valeurs-detail {
    margin-top: 1rem;
    padding: 0.85rem 1rem;
    background: white;
    border: var(--border);
    border-left: 5px solid #1a1a1a;
    min-height: 85px;
    display: flex;
    align-items: center;
    transition: opacity 0.2s ease;
}

.valeurs-detail p {
    font-size: 0.83rem;
    color: #333;
    line-height: 1.55;
}

/* ============================================================
   PROJECT CARDS
   ============================================================ */

.project-badge {
    display: inline-block;
    font-size: 0.68rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.07em;
    padding: 0.3rem 0.75rem;
    margin-bottom: 0.75rem;
    width: fit-content;
    font-family: var(--font-mono);
}

.badge--coming {
    background: #1a1a1a;
    color: var(--teal);
}

.badge--progress {
    background: #1a1a1a;
    color: var(--lime);
}

.project-title-lg {
    font-size: 1.8rem !important;
    margin-bottom: 0.25rem !important;
}

.project-subtitle {
    font-size: 0.95rem;
    font-weight: 600;
    margin-bottom: 1rem;
    opacity: 0.75;
}

.project-desc {
    font-size: 0.9rem;
    line-height: 1.7;
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    flex: 1;
}

.project-desc strong {
    font-weight: 800;
}

.project-overline {
    font-size: 0.65rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    margin-bottom: 0.4rem;
    font-family: var(--font-mono);
    opacity: 0.6;
}

.project-link {
    display: inline-flex;
    align-items: center;
    margin-top: auto;
    padding-top: 1rem;
    font-weight: 800;
    font-size: 0.85rem;
    text-decoration: underline;
    text-decoration-thickness: 2px;
    text-underline-offset: 3px;
    font-family: var(--font-mono);
    transition: text-underline-offset 0.2s ease;
}

.project-link:hover {
    text-underline-offset: 6px;
}

.project-quote {
    font-size: 0.9rem;
    font-weight: 500;
    padding: 0.75rem 1rem;
    background: white;
    border: var(--border);
    border-left: 5px solid #1a1a1a;
}

.highlight-box {
    background: white;
    padding: 1rem 1.25rem;
    border: var(--border);
    box-shadow: var(--shadow-sm);
}

.highlight-box p {
    font-size: 0.9rem;
}

/* ============================================================
   FOOTER
   ============================================================ */

.footer {
    text-align: center;
    padding: 2.5rem 1.5rem 3rem;
    font-size: 0.8rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    font-family: var(--font-mono);
    opacity: 0.5;
}

/* ============================================================
   SCROLL REVEAL ANIMATIONS
   ============================================================ */

.card[data-reveal] {
    opacity: 0;
    transform: translateY(40px);
    transition:
        opacity 0.6s ease,
        transform 0.6s ease;
}

.card[data-reveal].revealed {
    opacity: 1;
    transform: translateY(0);
}

/* ============================================================
   RESPONSIVE — Tablet
   ============================================================ */

@media (max-width: 1024px) {
    .bento {
        grid-template-columns: repeat(3, 1fr);
        gap: 1.25rem;
        padding: 1.5rem 1rem;
    }

    .card--intro {
        grid-column: span 3;
        grid-row: span 1;
    }
    .card--parcours {
        grid-column: span 2;
        grid-row: span 2;
    }
    .card--skills {
        grid-column: span 2;
        grid-row: span 2;
    }
    .card--skills-extra {
        grid-column: span 1;
        grid-row: span 2;
    }
    .card--valeurs {
        grid-column: span 1;
        grid-row: span 2;
    }
    .card--flowscript {
        grid-column: span 3;
        grid-row: span 1;
    }
    .card--netral {
        grid-column: span 1;
        grid-row: span 1;
    }
    .card--allo {
        grid-column: span 2;
        grid-row: span 1;
    }

    .intro-name {
        font-size: 2.2rem;
    }
    .intro-avatar {
        width: 110px;
        height: 110px;
    }
}

/* ============================================================
   RESPONSIVE — Small Tablet / Large Phone
   ============================================================ */

@media (min-width: 641px) and (max-width: 768px) {
    .bento {
        grid-template-columns: repeat(2, 1fr);
        gap: 1rem;
        padding: 1rem 0.75rem;
    }

    .card--intro {
        grid-column: span 2;
    }
    .card--parcours {
        grid-column: span 2;
    }
    .card--skills {
        grid-column: span 2;
    }
    .card--skills-extra {
        grid-column: span 1;
    }
    .card--valeurs {
        grid-column: span 1;
    }
    .card--flowscript {
        grid-column: span 2;
    }
    .card--netral {
        grid-column: span 1;
    }
    .card--allo {
        grid-column: span 2;
    }

    .card--intro .card__inner {
        flex-direction: column;
        text-align: center;
        align-items: center;
    }
}

/* ============================================================
   RESPONSIVE — Mobile
   ============================================================ */

@media (max-width: 640px) {
    .bento {
        grid-template-columns: 1fr;
        gap: 1rem;
        padding: 0.75rem;
    }

    .card--intro,
    .card--parcours,
    .card--skills,
    .card--skills-extra,
    .card--valeurs,
    .card--flowscript,
    .card--netral,
    .card--allo {
        grid-column: span 1 !important;
        grid-row: span 1 !important;
    }

    .card--intro .card__inner {
        flex-direction: column;
        text-align: center;
        align-items: center;
    }

    .intro-name {
        font-size: 2rem;
    }
    .intro-avatar {
        width: 100px;
        height: 100px;
    }
    .intro-tags {
        justify-content: center;
    }

    .card__inner {
        padding: 1.25rem;
    }
    .project-title-lg {
        font-size: 1.4rem !important;
    }

    :root {
        --shadow-sm: 3px 3px 0 #1a1a1a;
        --shadow-md: 4px 4px 0 #1a1a1a;
        --shadow-lg: 5px 5px 0 #1a1a1a;
    }
}
