/**
 * Style principal du CV - Florian L.
 * Fond uniforme #FFEDB2 avec typographie soignée et composants élégants
 */

@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700&family=Outfit:wght@400;600;700;800&display=swap');

:root {
  --bg-uniform: #FFEDB2;
  --bg-surface: #ffffff;
  --bg-card: rgba(255, 255, 255, 0.75);
  --bg-card-hover: rgba(255, 255, 255, 0.95);
  
  --border-subtle: rgba(180, 150, 90, 0.3);
  --border-accent: rgba(79, 70, 229, 0.45);

  --text-primary: #1e293b;
  --text-secondary: #475569;
  --text-muted: #64748b;

  --accent-primary: #4f46e5;
  --accent-secondary: #0284c7;
  --accent-gradient: linear-gradient(135deg, #4f46e5 0%, #7c3aed 50%, #d97706 100%);
  --accent-glow: 0 4px 20px rgba(79, 70, 229, 0.25);

  --success: #059669;
  --success-glow: 0 4px 14px rgba(5, 150, 105, 0.25);
  --warning: #d97706;

  --font-heading: 'Outfit', sans-serif;
  --font-body: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;

  --radius-sm: 8px;
  --radius-md: 14px;
  --radius-lg: 22px;
  --radius-full: 9999px;

  --transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}

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

html {
  scroll-behavior: smooth;
  background-color: var(--bg-uniform);
}

body {
  font-family: var(--font-body);
  background-color: #FFEDB2 !important;
  background-image: none !important;
  color: var(--text-primary);
  line-height: 1.6;
  min-height: 100vh;
  overflow-x: hidden;
  position: relative;
  padding: 30px;
}

/* Encadré photo 180x180 en haut à gauche avec arrondis et rognage */
.profile-photo-wrapper {
  width: 180px;
  height: 180px;
  border-radius: 20px;
  overflow: hidden;
  border: 3px solid rgba(255, 255, 255, 0.85);
  box-shadow: 0 8px 24px -4px rgba(120, 95, 45, 0.2);
  background-color: #ffffff;
}

.profile-photo {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  display: block;
}

h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-heading);
  color: var(--text-primary);
  letter-spacing: -0.02em;
}

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

a:hover {
  color: var(--accent-secondary);
}

/* Glassmorphism adapté sur fond #FFEDB2 */
.glass-panel {
  background: var(--bg-card);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  box-shadow: 0 6px 20px -4px rgba(120, 95, 45, 0.08);
  transition: var(--transition);
}

.glass-panel:hover {
  background: var(--bg-card-hover);
  border-color: var(--border-accent);
  box-shadow: 0 12px 28px -6px rgba(120, 95, 45, 0.16);
  transform: translateY(-2px);
}

/* Navbar */
.cv-navbar {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(255, 237, 178, 0.92);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--border-subtle);
  padding: 0.85rem 2rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.nav-brand {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 1.25rem;
  color: var(--text-primary);
}

.brand-badge {
  background: var(--accent-gradient);
  color: #fff;
  font-size: 0.75rem;
  padding: 0.2rem 0.6rem;
  border-radius: var(--radius-full);
  font-weight: 600;
  letter-spacing: 0.05em;
  box-shadow: var(--accent-glow);
}

.nav-menu {
  display: flex;
  align-items: center;
  gap: 1.5rem;
  list-style: none;
}

.nav-link {
  color: var(--text-secondary);
  font-size: 0.92rem;
  font-weight: 500;
  padding: 0.35rem 0.75rem;
  border-radius: var(--radius-sm);
  transition: var(--transition);
}

.nav-link:hover {
  color: var(--text-primary);
  background: rgba(255, 255, 255, 0.5);
}

.nav-actions {
  display: flex;
  align-items: center;
  gap: 0.8rem;
}

/* Boutons */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-family: var(--font-body);
  font-weight: 600;
  padding: 0.65rem 1.35rem;
  border-radius: var(--radius-full);
  border: none;
  cursor: pointer;
  transition: var(--transition);
  font-size: 0.9rem;
  text-decoration: none;
}

.btn-primary {
  background: var(--accent-gradient);
  color: #ffffff !important;
  box-shadow: var(--accent-glow);
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 24px rgba(79, 70, 229, 0.4);
  filter: brightness(1.05);
}

.btn-glass {
  background: rgba(255, 255, 255, 0.7);
  color: var(--text-primary) !important;
  border: 1px solid var(--border-subtle);
}

.btn-glass:hover {
  background: #ffffff;
  border-color: rgba(180, 150, 90, 0.5);
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(120, 95, 45, 0.1);
}

.btn-icon-only {
  width: 40px;
  height: 40px;
  padding: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  border: 1px solid var(--border-subtle);
  background: rgba(255, 255, 255, 0.6);
  color: var(--text-primary);
  cursor: pointer;
  transition: var(--transition);
}

.btn-icon-only:hover {
  background: #ffffff;
  border-color: var(--accent-primary);
}

/* Hero Section */
.hero-section {
  max-width: 1200px;
  margin: 3.5rem auto 3rem;
  padding: 0 1.5rem;
}

.hero-grid {
  display: grid;
  grid-template-columns: 1.3fr 0.9fr;
  gap: 3.5rem;
  align-items: center;
}

.status-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  background: rgba(5, 150, 105, 0.12);
  border: 1px solid rgba(5, 150, 105, 0.35);
  color: #065f46;
  font-size: 0.85rem;
  font-weight: 600;
  padding: 0.35rem 0.9rem;
  border-radius: var(--radius-full);
  margin-bottom: 1.25rem;
}

.pulse-dot {
  width: 8px;
  height: 8px;
  background: #059669;
  border-radius: 50%;
  position: relative;
}

.pulse-dot::after {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: 50%;
  background: #059669;
  animation: pulse-ring 1.8s infinite;
}

@keyframes pulse-ring {
  0% { transform: scale(1); opacity: 0.8; }
  100% { transform: scale(2.6); opacity: 0; }
}

.hero-title {
  font-size: 3.4rem;
  font-weight: 800;
  line-height: 1.15;
  margin-bottom: 0.75rem;
  color: #0f172a;
}

.gradient-text {
  background: var(--accent-gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.hero-subtitle {
  font-size: 1.4rem;
  font-weight: 600;
  color: var(--text-secondary);
  margin-bottom: 1.25rem;
}

.hero-bio {
  font-size: 1.05rem;
  color: #334155;
  max-width: 600px;
  margin-bottom: 2rem;
  line-height: 1.7;
}

.hero-cta {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
}

.hero-avatar-area {
  display: flex;
  justify-content: center;
  position: relative;
}

.avatar-frame {
  position: relative;
  width: 320px;
  height: 320px;
  border-radius: 30px;
  padding: 5px;
  background: var(--accent-gradient);
  box-shadow: 0 16px 40px -10px rgba(120, 95, 45, 0.25);
}

.avatar-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 26px;
  display: block;
  background: #ffffff;
}

.server-tag {
  position: absolute;
  bottom: -15px;
  right: -10px;
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(12px);
  border: 1px solid var(--border-subtle);
  padding: 0.65rem 1.15rem;
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  gap: 0.65rem;
  font-size: 0.85rem;
  font-weight: 600;
  color: #0369a1;
  box-shadow: 0 8px 24px rgba(120, 95, 45, 0.12);
}

/* Stats Row */
.stats-section {
  max-width: 1200px;
  margin: 1rem auto 4.5rem;
  padding: 0 1.5rem;
}

.stats-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1.5rem;
}

.stat-card {
  padding: 1.6rem;
  text-align: center;
}

.stat-value {
  font-size: 2.5rem;
  font-weight: 800;
  font-family: var(--font-heading);
  background: var(--accent-gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  display: block;
}

.stat-title {
  color: var(--text-secondary);
  font-size: 0.92rem;
  font-weight: 500;
  margin-top: 0.35rem;
}

/* Common Section */
.section {
  max-width: 1200px;
  margin: 0 auto 5rem;
  padding: 0 1.5rem;
}

.section-head {
  text-align: center;
  margin-bottom: 2.8rem;
}

.section-badge {
  display: inline-block;
  color: var(--accent-primary);
  font-size: 0.85rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  margin-bottom: 0.4rem;
}

.section-title {
  font-size: 2.3rem;
  font-weight: 700;
  color: #0f172a;
}

/* Skills Section */
.filter-bar {
  display: flex;
  justify-content: center;
  gap: 0.65rem;
  margin-bottom: 2.5rem;
  flex-wrap: wrap;
}

.filter-pill {
  background: rgba(255, 255, 255, 0.65);
  color: var(--text-secondary);
  border: 1px solid var(--border-subtle);
  padding: 0.5rem 1.25rem;
  border-radius: var(--radius-full);
  font-size: 0.9rem;
  font-weight: 500;
  cursor: pointer;
  transition: var(--transition);
}

.filter-pill:hover {
  background: #ffffff;
  color: var(--text-primary);
}

.filter-pill.active {
  background: var(--accent-gradient);
  color: #fff;
  border-color: transparent;
  box-shadow: var(--accent-glow);
}

.skills-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 1.35rem;
}

.skill-card {
  padding: 1.5rem;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.skill-top-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 0.5rem;
}

.skill-title {
  font-size: 1.05rem;
  font-weight: 600;
  color: #0f172a;
}

.skill-percent {
  font-size: 0.78rem;
  font-weight: 700;
  background: rgba(79, 70, 229, 0.12);
  color: var(--accent-primary);
  padding: 0.15rem 0.55rem;
  border-radius: var(--radius-full);
}

.skill-desc {
  font-size: 0.86rem;
  color: var(--text-secondary);
  margin-bottom: 1rem;
  line-height: 1.5;
}

.skill-bar {
  width: 100%;
  height: 6px;
  background: rgba(180, 150, 90, 0.25);
  border-radius: var(--radius-full);
  overflow: hidden;
}

.skill-fill {
  height: 100%;
  background: var(--accent-gradient);
  border-radius: var(--radius-full);
  transition: width 0.8s ease-in-out;
}

/* Timeline Expériences */
.timeline-container {
  position: relative;
  max-width: 920px;
  margin: 0 auto;
}

.timeline-container::before {
  content: '';
  position: absolute;
  top: 15px;
  bottom: 15px;
  left: 20px;
  width: 2px;
  background: linear-gradient(to bottom, var(--accent-primary), var(--accent-secondary), rgba(180, 150, 90, 0.4));
}

.timeline-entry {
  position: relative;
  padding-left: 60px;
  margin-bottom: 2.75rem;
}

.timeline-marker {
  position: absolute;
  left: 11px;
  top: 8px;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: #FFEDB2;
  border: 3px solid var(--accent-primary);
  box-shadow: 0 0 10px rgba(79, 70, 229, 0.35);
}

.timeline-box {
  padding: 1.85rem;
}

.timeline-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-bottom: 0.4rem;
}

.timeline-role {
  font-size: 1.3rem;
  font-weight: 700;
  color: #0f172a;
}

.timeline-period {
  font-size: 0.85rem;
  font-weight: 600;
  background: rgba(79, 70, 229, 0.1);
  padding: 0.25rem 0.8rem;
  border-radius: var(--radius-full);
  color: var(--accent-primary);
}

.timeline-company {
  font-weight: 600;
  color: var(--accent-primary);
  font-size: 0.95rem;
  margin-bottom: 0.9rem;
}

.timeline-list {
  list-style: none;
  margin-bottom: 1.25rem;
}

.timeline-list li {
  position: relative;
  padding-left: 1.3rem;
  margin-bottom: 0.5rem;
  font-size: 0.93rem;
  color: #334155;
}

.timeline-list li::before {
  content: '▹';
  position: absolute;
  left: 0;
  color: var(--accent-primary);
}

.tags-group {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
}

.tag-badge {
  background: rgba(255, 255, 255, 0.8);
  border: 1px solid var(--border-subtle);
  font-size: 0.78rem;
  font-weight: 500;
  color: #1e293b;
  padding: 0.25rem 0.7rem;
  border-radius: var(--radius-sm);
}

/* Projects Section */
.projects-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(340px, 1fr));
  gap: 1.85rem;
}

.project-box {
  padding: 1.85rem;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.project-name {
  font-size: 1.3rem;
  font-weight: 700;
  margin-bottom: 0.65rem;
  color: #0f172a;
}

.project-summary {
  font-size: 0.92rem;
  color: #334155;
  margin-bottom: 1.35rem;
  line-height: 1.6;
}

.project-bottom {
  margin-top: auto;
}

.project-links {
  display: flex;
  gap: 0.85rem;
  margin-top: 1.35rem;
}

/* Education / Formations */
.education-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(360px, 1fr));
  gap: 1.5rem;
}

.education-card {
  padding: 1.75rem;
}

.edu-degree {
  font-size: 1.2rem;
  font-weight: 700;
  margin-bottom: 0.4rem;
  color: #0f172a;
}

.edu-school {
  color: var(--accent-primary);
  font-weight: 600;
  font-size: 0.95rem;
  margin-bottom: 0.25rem;
}

.edu-period {
  font-size: 0.85rem;
  color: var(--accent-secondary);
  font-weight: 500;
  margin-bottom: 0.75rem;
}

.edu-details {
  font-size: 0.9rem;
  color: #334155;
  line-height: 1.5;
}

/* Contact & Server Section */
.contact-layout {
  display: grid;
  grid-template-columns: 1fr 1.3fr;
  gap: 2.75rem;
}

.contact-details {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.contact-row {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.contact-icon-bubble {
  width: 48px;
  height: 48px;
  border-radius: var(--radius-sm);
  background: rgba(79, 70, 229, 0.12);
  color: var(--accent-primary);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.25rem;
  flex-shrink: 0;
}

.contact-label {
  font-size: 0.82rem;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  font-weight: 600;
}

.contact-val {
  color: var(--text-primary);
  font-weight: 600;
  font-size: 1rem;
}

.server-info-card {
  margin-top: 1.5rem;
  padding: 1.35rem;
  border-left: 4px solid var(--accent-primary);
}

.server-info-card h4 {
  font-size: 1.05rem;
  margin-bottom: 0.4rem;
  color: var(--accent-primary);
}

.server-info-card p {
  font-size: 0.88rem;
  color: var(--text-secondary);
}

.contact-form-box {
  padding: 2.25rem;
}

.input-group {
  margin-bottom: 1.25rem;
}

.input-label {
  display: block;
  font-size: 0.85rem;
  font-weight: 600;
  color: #1e293b;
  margin-bottom: 0.45rem;
}

.form-control {
  width: 100%;
  background: rgba(255, 255, 255, 0.9);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-sm);
  padding: 0.8rem 1rem;
  color: var(--text-primary);
  font-family: inherit;
  font-size: 0.95rem;
  transition: var(--transition);
}

.form-control:focus {
  outline: none;
  background: #ffffff;
  border-color: var(--accent-primary);
  box-shadow: 0 0 0 3px rgba(79, 70, 229, 0.2);
}

textarea.form-control {
  resize: vertical;
  min-height: 120px;
}

.alert-message {
  padding: 1rem 1.25rem;
  border-radius: var(--radius-sm);
  margin-bottom: 1.25rem;
  font-size: 0.92rem;
  display: none;
}

.alert-success {
  background: rgba(5, 150, 105, 0.15);
  border: 1px solid rgba(5, 150, 105, 0.4);
  color: #065f46;
}

.alert-error {
  background: rgba(239, 68, 68, 0.15);
  border: 1px solid rgba(239, 68, 68, 0.4);
  color: #991b1b;
}

/* Footer */
.cv-footer {
  border-top: 1px solid var(--border-subtle);
  padding: 3rem 1.5rem;
  text-align: center;
  color: #475569;
  font-size: 0.9rem;
}

.cv-footer a {
  color: var(--accent-primary);
}

/* PRINT STYLES - Exportation / Impression PDF propre */
@media print {
  body {
    background: #ffffff !important;
    color: #111827 !important;
    font-size: 10.5pt;
  }

  .cv-navbar,
  .nav-actions,
  .filter-bar,
  .project-links,
  .contact-form-box,
  .btn,
  .cv-footer,
  .server-tag,
  .btn-icon-only {
    display: none !important;
  }

  .glass-panel {
    background: transparent !important;
    border: 1px solid #e5e7eb !important;
    box-shadow: none !important;
  }

  .hero-section {
    margin: 0 !important;
    padding: 0 0 1rem !important;
  }

  .hero-title, .gradient-text {
    color: #111827 !important;
    -webkit-text-fill-color: initial !important;
  }

  .status-badge {
    border: 1px solid #059669 !important;
    color: #059669 !important;
    background: transparent !important;
  }

  .timeline-container::before {
    background: #9ca3af !important;
  }

  .timeline-marker {
    border-color: #4b5563 !important;
  }

  .timeline-role, .project-name, .edu-degree, h1, h2, h3 {
    color: #111827 !important;
  }

  .timeline-list li, .skill-desc, .project-summary, .edu-details {
    color: #374151 !important;
  }

  .tag-badge {
    background: #f3f4f6 !important;
    color: #1f2937 !important;
    border: 1px solid #d1d5db !important;
  }

  .section {
    margin-bottom: 2rem !important;
    page-break-inside: avoid;
  }

  .hero-avatar-area {
    display: none !important;
  }
}

/* Responsive */
@media (max-width: 960px) {
  .hero-grid {
    grid-template-columns: 1fr;
    text-align: center;
  }

  .hero-bio {
    margin-left: auto;
    margin-right: auto;
  }

  .hero-cta {
    justify-content: center;
  }

  .stats-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .contact-layout {
    grid-template-columns: 1fr;
  }

  .nav-menu {
    display: none;
  }
}

@media (max-width: 600px) {
  .hero-title {
    font-size: 2.5rem;
  }
  
  .stats-grid {
    grid-template-columns: 1fr;
  }
}
