/* ==========================================================================
   Variables & reset
   ========================================================================== */
:root {
  --bg: #0f1420;
  --bg-alt: #161d2c;
  --bg-card: #1b2436;
  --border: #2a3448;
  --text: #e7ebf3;
  --text-muted: #9aa7bd;
  --accent: #4c8dff;
  --accent-dark: #2f6fe0;
  --accent-soft: rgba(76, 141, 255, 0.12);
  --radius: 10px;
  --max-width: 1080px;
  --font: "Segoe UI", system-ui, -apple-system, "Helvetica Neue", Arial, sans-serif;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: var(--font);
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

img {
  max-width: 100%;
  display: block;
}

a {
  color: var(--accent);
  text-decoration: none;
}

a:hover {
  text-decoration: underline;
}

ul {
  padding-left: 1.2rem;
}

.container {
  width: 100%;
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 1.5rem;
}

@media (max-width: 480px) {
  .container {
    padding: 0 1.85rem;
  }
}

/* ==========================================================================
   Header / navigation
   ========================================================================== */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(15, 20, 32, 0.92);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--border);
}

.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1rem 1.5rem;
  max-width: var(--max-width);
  margin: 0 auto;
}

.nav-brand {
  font-weight: 700;
  font-size: 1.15rem;
  color: var(--text);
  letter-spacing: 0.02em;
}

.nav-brand:hover {
  text-decoration: none;
  color: var(--accent);
}

.nav-toggle {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 0.4rem;
}

.nav-toggle span {
  width: 24px;
  height: 2px;
  background: var(--text);
  border-radius: 2px;
}

.nav-links {
  display: flex;
  gap: 1.75rem;
  list-style: none;
  margin: 0;
  padding: 0;
}

.nav-links a {
  color: var(--text-muted);
  font-weight: 500;
  font-size: 0.95rem;
  padding: 0.3rem 0;
  border-bottom: 2px solid transparent;
}

.nav-links a:hover,
.nav-links a.active {
  color: var(--text);
  text-decoration: none;
  border-bottom-color: var(--accent);
}

@media (max-width: 720px) {
  .nav-toggle {
    display: flex;
  }

  .nav-links {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    flex-direction: column;
    background: var(--bg-alt);
    border-bottom: 1px solid var(--border);
    padding: 1rem 1.5rem;
    gap: 1rem;
    display: none;
  }

  .nav-links.open {
    display: flex;
  }
}

/* ==========================================================================
   Hero / page header
   ========================================================================== */
.page-hero {
  padding: 3rem 0 2rem;
  border-bottom: 1px solid var(--border);
}

.page-hero h1 {
  font-size: 2rem;
  margin: 0 0 0.5rem;
}

.page-hero p {
  color: var(--text-muted);
  max-width: 640px;
  margin: 0;
}

/* ==========================================================================
   Sections & cards
   ========================================================================== */
section {
  padding: 3rem 0;
}

section + section {
  border-top: 1px solid var(--border);
}

.section-title {
  font-size: 1.5rem;
  margin: 0 0 1.75rem;
  display: flex;
  align-items: center;
  gap: 0.6rem;
}

.section-title::before {
  content: "";
  width: 4px;
  height: 1.3rem;
  background: var(--accent);
  border-radius: 2px;
}

.card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.5rem;
}

.card + .card {
  margin-top: 1.25rem;
}

.card h3 {
  margin: 0 0 0.25rem;
  font-size: 1.15rem;
}

.card .meta {
  color: var(--text-muted);
  font-size: 0.88rem;
  margin: 0 0 1rem;
}

.tag-list {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  list-style: none;
  padding: 0;
  margin: 1rem 0 0;
}

.tag {
  background: var(--accent-soft);
  color: var(--accent);
  border-radius: 999px;
  padding: 0.25rem 0.75rem;
  font-size: 0.82rem;
  font-weight: 500;
}

.placeholder {
  border: 1px dashed var(--border);
  border-radius: var(--radius);
  padding: 1.5rem;
  color: var(--text-muted);
  font-style: italic;
}

/* ==========================================================================
   Home / CV layout
   ========================================================================== */
.cv-layout {
  display: grid;
  grid-template-columns: 280px 1fr;
  gap: 2.5rem;
  padding-top: 3rem;
  padding-bottom: 3rem;
  align-items: start;
}

@media (max-width: 780px) {
  .cv-layout {
    grid-template-columns: 1fr;
  }
}

.cv-sidebar {
  position: sticky;
  top: 90px;
  display: flex;
  flex-direction: column;
  gap: 1.75rem;
}

@media (max-width: 780px) {
  .cv-sidebar {
    position: static;
  }
}

.cv-photo {
  width: 100%;
  aspect-ratio: 1 / 1;
  border-radius: var(--radius);
  object-fit: cover;
  background: var(--bg-card);
  border: 1px solid var(--border);
}

.cv-name h1 {
  font-size: 1.4rem;
  margin: 0 0 0.2rem;
}

.cv-name p {
  color: var(--accent);
  font-weight: 600;
  margin: 0;
  font-size: 0.95rem;
}

.cv-block h4 {
  text-transform: uppercase;
  letter-spacing: 0.05em;
  font-size: 0.78rem;
  color: var(--text-muted);
  margin: 0 0 0.6rem;
}

.cv-block ul {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
  font-size: 0.92rem;
}

.skill-bar {
  display: flex;
  justify-content: space-between;
  font-size: 0.9rem;
  margin-bottom: 0.3rem;
}

.skill-bar-track {
  height: 6px;
  background: var(--bg);
  border-radius: 999px;
  overflow: hidden;
  margin-bottom: 0.9rem;
}

.skill-bar-fill {
  height: 100%;
  background: var(--accent);
  border-radius: 999px;
}

.cv-main .card {
  margin-bottom: 1.25rem;
}

.timeline-item {
  position: relative;
  padding-left: 1.2rem;
  border-left: 2px solid var(--border);
  padding-bottom: 1.5rem;
}

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

.timeline-item::before {
  content: "";
  position: absolute;
  left: -7px;
  top: 4px;
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: var(--accent);
  border: 2px solid var(--bg);
}

/* ==========================================================================
   Contact
   ========================================================================== */
.contact-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 1.25rem;
}

.contact-item {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.25rem;
  display: flex;
  flex-direction: column;
  gap: 0.3rem;
}

.contact-item span {
  color: var(--text-muted);
  font-size: 0.82rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.contact-item a,
.contact-item strong {
  font-size: 1rem;
}

/* ==========================================================================
   Veille technologique — flux RSS
   ========================================================================== */
.feed-controls {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
  margin-bottom: 2rem;
}

.feed-filters {
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem;
}

.date-filter {
  background: var(--bg-card);
  color: var(--text);
  border: 1px solid var(--border);
  border-radius: 999px;
  padding: 0.45rem 1rem;
  font-size: 0.85rem;
  font-family: inherit;
  cursor: pointer;
}

.date-filter:hover {
  border-color: var(--accent);
}

.feed-show-more {
  display: flex;
  justify-content: center;
  margin-top: 2rem;
}

.show-more-btn {
  padding: 0.55rem 1.5rem;
}

.filter-btn {
  background: var(--bg-card);
  color: var(--text-muted);
  border: 1px solid var(--border);
  border-radius: 999px;
  padding: 0.4rem 1rem;
  font-size: 0.85rem;
  cursor: pointer;
  transition: background 0.15s, color 0.15s, border-color 0.15s;
}

.filter-btn:hover {
  color: var(--text);
  border-color: var(--accent);
}

.filter-btn.active {
  background: var(--accent);
  color: #fff;
  border-color: var(--accent);
}

.feed-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 1.25rem;
}

.feed-card {
  display: block;
  color: var(--text);
  transition: border-color 0.15s, transform 0.15s;
}

.feed-card:hover {
  text-decoration: none;
  border-color: var(--accent);
  transform: translateY(-2px);
}

.feed-card h3 {
  font-size: 1rem;
  line-height: 1.4;
}

/* ==========================================================================
   Footer
   ========================================================================== */
.site-footer {
  border-top: 1px solid var(--border);
  padding: 2rem 0;
  color: var(--text-muted);
  font-size: 0.88rem;
}

.footer-inner {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 1rem;
}

.footer-links {
  display: flex;
  gap: 1.25rem;
  list-style: none;
  padding: 0;
  margin: 0;
}
