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

/* ===== CUSTOM PROPERTIES ===== */
:root {
  --navy: #0f2744;
  --navy-light: #1a3a5c;
  --accent: #e8a838;
  --accent-hover: #d4922e;
  --accent-glow: rgba(232, 168, 56, 0.25);
  --text: #2d3748;
  --text-light: #64748b;
  --bg: #f8fafc;
  --white: #ffffff;
  --card-border: rgba(0, 0, 0, 0.06);
  --header-bg: rgba(255, 255, 255, 0.85);
  --header-border: rgba(0, 0, 0, 0.06);
  --input-bg: rgba(0, 0, 0, 0.04);
  --radius: 16px;
  --radius-sm: 10px;
  --shadow: 0 4px 30px rgba(0, 0, 0, 0.06);
  --shadow-lg: 0 20px 60px rgba(0, 0, 0, 0.1);
  --transition: 0.35s cubic-bezier(0.4, 0, 0.2, 1);
}

[data-theme="dark"] {
  --navy: #e2e8f0;
  --navy-light: #94a3b8;
  --text: #e2e8f0;
  --text-light: #94a3b8;
  --bg: #0c1220;
  --white: #141e30;
  --card-border: rgba(255, 255, 255, 0.06);
  --header-bg: rgba(12, 18, 32, 0.88);
  --header-border: rgba(255, 255, 255, 0.06);
  --input-bg: rgba(255, 255, 255, 0.06);
  --shadow: 0 4px 30px rgba(0, 0, 0, 0.2);
  --shadow-lg: 0 20px 60px rgba(0, 0, 0, 0.35);
}

/* ===== RESET & BASE ===== */
*, *::before, *::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

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

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  color: var(--text);
  line-height: 1.7;
  overflow-x: hidden;
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
}

a {
  text-decoration: none;
  color: inherit;
}

ul { list-style: none; }

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

/* ===== SCROLL REVEAL ===== */
.reveal {
  opacity: 0;
  transform: translateY(40px);
  transition: opacity 0.8s cubic-bezier(0.4, 0, 0.2, 1), transform 0.8s cubic-bezier(0.4, 0, 0.2, 1);
}

.reveal.visible {
  opacity: 1;
  transform: translateY(0);
}

.reveal-delay-1 { transition-delay: 0.1s; }
.reveal-delay-2 { transition-delay: 0.2s; }
.reveal-delay-3 { transition-delay: 0.3s; }
.reveal-delay-4 { transition-delay: 0.4s; }

/* ===== HEADER ===== */
.header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  background: var(--header-bg);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--header-border);
  transition: var(--transition);
}

.header.scrolled {
  box-shadow: var(--shadow);
}

.header-inner {
  max-width: 1280px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 32px;
  transition: padding var(--transition);
}

.header.scrolled .header-inner {
  padding: 10px 32px;
}

.header-logo img {
  height: 38px;
  width: auto;
  transition: var(--transition);
}

.header-logo .logo-dark { display: none; }

[data-theme="dark"] .header-logo .logo-light { display: none; }
[data-theme="dark"] .header-logo .logo-dark { display: block; }

.header-right {
  display: flex;
  align-items: center;
  gap: 36px;
}

.nav-list {
  display: flex;
  gap: 8px;
  align-items: center;
}

.nav-list a {
  font-size: 0.82rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.8px;
  color: var(--text);
  padding: 8px 16px;
  border-radius: 8px;
  transition: var(--transition);
  position: relative;
}

.nav-list a:hover {
  color: var(--accent);
  background: rgba(232, 168, 56, 0.08);
}

.nav-list a.active {
  color: var(--accent);
  background: rgba(232, 168, 56, 0.1);
}

.lang-toggle {
  position: relative;
  display: flex;
  align-items: center;
  padding: 3px;
  background: var(--input-bg);
  border: 1px solid var(--card-border);
  border-radius: 100px;
  cursor: pointer;
  gap: 0;
  font-family: 'Inter', sans-serif;
}

.lang-option {
  position: relative;
  z-index: 1;
  padding: 5px 12px;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.5px;
  color: var(--text-light);
  transition: color var(--transition);
  user-select: none;
}

.lang-option--active {
  color: #fff;
}

.lang-slider {
  position: absolute;
  left: 3px;
  top: 3px;
  width: calc(50% - 3px);
  height: calc(100% - 6px);
  background: var(--accent);
  border-radius: 100px;
  transition: transform var(--transition);
  pointer-events: none;
}

.lang-toggle[data-lang="en"] .lang-slider {
  transform: translateX(100%);
}

.lang-toggle[data-lang="en"] #langFr {
  color: var(--text-light);
}

.lang-toggle[data-lang="en"] #langEn {
  color: #fff;
}

.mobile-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  cursor: pointer;
  background: none;
  border: none;
  padding: 8px;
  border-radius: 8px;
  transition: var(--transition);
}

.mobile-toggle:hover {
  background: var(--input-bg);
}

.mobile-toggle span {
  display: block;
  width: 22px;
  height: 2.5px;
  background: var(--text);
  border-radius: 2px;
  transition: var(--transition);
}

/* ===== HERO ===== */
.hero {
  position: relative;
  min-height: 92vh;
  display: flex;
  align-items: center;
  background: url('/static/images/image.jpg') center center / cover no-repeat;
  background-attachment: fixed;
  margin-top: 70px;
}

.hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, rgba(15, 39, 68, 0.88) 0%, rgba(15, 39, 68, 0.6) 50%, rgba(232, 168, 56, 0.15) 100%);
}

.hero::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 200px;
  background: linear-gradient(to top, var(--bg), transparent);
  pointer-events: none;
}

.hero-content {
  position: relative;
  z-index: 1;
  max-width: 1280px;
  margin: 0 auto;
  padding: 80px 32px;
  width: 100%;
}

/* Home hero */
.hero-home .hero-content {
  display: flex;
  gap: 60px;
  align-items: center;
}

.hero-title-block {
  flex: 1;
}

.hero-title-block h1 {
  color: #fff;
  font-family: 'DM Serif Display', serif;
  font-size: 4rem;
  font-weight: 400;
  line-height: 1.1;
  letter-spacing: -1px;
}

.hero-title-block h1 span {
  display: block;
  color: var(--accent);
}

.hero-tagline {
  display: inline-block;
  margin-top: 24px;
  padding: 8px 20px;
  background: rgba(232, 168, 56, 0.2);
  backdrop-filter: blur(10px);
  border: 1px solid rgba(232, 168, 56, 0.3);
  border-radius: 100px;
  color: var(--accent);
  font-size: 0.82rem;
  font-weight: 600;
  letter-spacing: 1.5px;
  text-transform: uppercase;
}

.hero-desc-block {
  flex: 1;
}

.hero-desc-block p {
  color: rgba(255, 255, 255, 0.85);
  font-size: 1.05rem;
  line-height: 1.85;
  margin-bottom: 20px;
}

.hero-cta {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  margin-top: 12px;
  padding: 14px 32px;
  background: var(--accent);
  color: #fff;
  border-radius: 100px;
  font-weight: 600;
  font-size: 0.9rem;
  transition: var(--transition);
  box-shadow: 0 4px 20px rgba(232, 168, 56, 0.35);
}

.hero-cta:hover {
  background: var(--accent-hover);
  transform: translateY(-2px);
  box-shadow: 0 8px 30px rgba(232, 168, 56, 0.45);
}

.hero-cta svg {
  transition: transform var(--transition);
}

.hero-cta:hover svg {
  transform: translateX(4px);
}

/* Page hero (services, expertise, blog) */
.hero-page {
  min-height: 50vh;
  justify-content: center;
  text-align: center;
}

.hero-page .hero-content {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
}

.hero-page h1 {
  color: #fff;
  font-family: 'DM Serif Display', serif;
  font-size: 3.5rem;
  font-weight: 400;
  letter-spacing: -0.5px;
}

.hero-page .hero-subtitle {
  color: rgba(255, 255, 255, 0.7);
  font-size: 1.1rem;
  margin-top: 16px;
  max-width: 500px;
}

.hero-page h1::after {
  content: '';
  display: block;
  width: 60px;
  height: 3px;
  background: var(--accent);
  margin: 20px auto 0;
  border-radius: 3px;
}

/* ===== SECTION HELPERS ===== */
.section {
  padding: 100px 32px;
}

.section-inner {
  max-width: 1280px;
  margin: 0 auto;
}

.section-title {
  font-family: 'DM Serif Display', serif;
  font-size: 2rem;
  font-weight: 400;
  color: var(--navy);
  margin-bottom: 48px;
  letter-spacing: -0.3px;
}

.section-title::after {
  content: '';
  display: block;
  width: 40px;
  height: 3px;
  background: var(--accent);
  margin-top: 12px;
  border-radius: 3px;
}

.section-title.center {
  text-align: center;
}

.section-title.center::after {
  margin-left: auto;
  margin-right: auto;
}

.section-label {
  display: inline-block;
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 2px;
  color: var(--accent);
  margin-bottom: 12px;
}

/* ===== HOME: MISSION ===== */
.mission {
  display: flex;
  min-height: 500px;
  overflow: hidden;
  border-radius: 0;
}

.mission-text {
  flex: 1;
  background: var(--navy);
  color: #fff;
  padding: 80px 64px;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.mission-text .section-title {
  color: #fff;
}

.mission-text p {
  font-size: 1rem;
  line-height: 2;
  color: rgba(255, 255, 255, 0.8);
}

.mission-image {
  flex: 1;
  background: url('/static/images/visite-de-prévention-des-risques.jpg') center center / cover no-repeat;
  min-height: 400px;
  position: relative;
}

.mission-image::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(to right, var(--navy), transparent 30%);
}

/* ===== HOME: STATS ===== */
.stats {
  padding: 0;
  position: relative;
}

.stats-bar {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  max-width: 1280px;
  margin: -50px auto 0;
  position: relative;
  z-index: 2;
  padding: 0 32px;
}

.stat-item {
  text-align: center;
  padding: 48px 24px;
  background: var(--white);
  border: 1px solid var(--card-border);
  transition: var(--transition);
}

.stat-item:first-child {
  border-radius: var(--radius) 0 0 var(--radius);
}

.stat-item:last-child {
  border-radius: 0 var(--radius) var(--radius) 0;
}

.stat-item:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow-lg);
  z-index: 1;
}

.stat-number {
  font-family: 'DM Serif Display', serif;
  font-size: 3rem;
  font-weight: 400;
  color: var(--accent);
  line-height: 1;
  margin-bottom: 8px;
}

.stat-label {
  font-size: 0.78rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.8px;
  color: var(--text-light);
}

/* ===== HOME: EXPERTISE GRID ===== */
.expertise-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 24px;
}

.expertise-card {
  position: relative;
  border-radius: var(--radius);
  overflow: hidden;
  aspect-ratio: 3/4;
  cursor: pointer;
  box-shadow: var(--shadow);
}

.expertise-card img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}

.expertise-card:hover img {
  transform: scale(1.08);
}

.expertise-card .card-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(15, 39, 68, 0.9) 0%, rgba(15, 39, 68, 0.1) 60%, transparent 100%);
  transition: var(--transition);
}

.expertise-card:hover .card-overlay {
  background: linear-gradient(to top, rgba(232, 168, 56, 0.85) 0%, rgba(15, 39, 68, 0.2) 60%, transparent 100%);
}

.expertise-card .card-label {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  color: #fff;
  padding: 32px 20px 24px;
  font-size: 0.82rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.8px;
  z-index: 1;
}

.expertise-card .card-arrow {
  position: absolute;
  bottom: 24px;
  right: 20px;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.15);
  backdrop-filter: blur(10px);
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  opacity: 0;
  transform: translateX(-10px);
  transition: var(--transition);
  z-index: 1;
}

.expertise-card:hover .card-arrow {
  opacity: 1;
  transform: translateX(0);
}

/* ===== HOME: EXPERIENCES ===== */
.experiences-carousel {
  display: flex;
  align-items: center;
  gap: 48px;
  background: var(--white);
  border-radius: var(--radius);
  padding: 48px;
  box-shadow: var(--shadow);
  border: 1px solid var(--card-border);
}

.carousel-logo {
  flex-shrink: 0;
  width: 180px;
  padding: 16px;
  background: var(--bg);
  border-radius: var(--radius-sm);
}

.carousel-logo img {
  width: 100%;
}

.carousel-text {
  flex: 1;
}

.carousel-text p {
  font-size: 1rem;
  line-height: 1.9;
  color: var(--text-light);
}

.carousel-text p,
.carousel-logo img {
  transition: opacity 0.2s ease;
}

.carousel-dots {
  display: flex;
  gap: 8px;
  margin-top: 20px;
}

.carousel-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  border: none;
  background: rgba(15, 39, 68, 0.15);
  cursor: pointer;
  padding: 0;
  transition: var(--transition);
}

.carousel-dot.active {
  background: var(--accent);
  transform: scale(1.2);
}

[data-theme="dark"] .carousel-dot {
  background: rgba(255, 255, 255, 0.15);
}

[data-theme="dark"] .carousel-dot.active {
  background: var(--accent);
}

.carousel-arrows {
  display: flex;
  gap: 10px;
  margin-top: 16px;
}

.carousel-arrow {
  width: 42px;
  height: 42px;
  border-radius: 50%;
  border: 2px solid rgba(15, 39, 68, 0.15);
  background: transparent;
  color: var(--navy);
  font-size: 1.2rem;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: var(--transition);
}

.carousel-arrow:hover {
  background: var(--navy);
  border-color: var(--navy);
  color: #fff;
}

/* ===== FOOTER ===== */
.footer {
  background: var(--navy);
  color: #fff;
  padding: 80px 32px 0;
  position: relative;
  overflow: hidden;
}

.footer::before {
  content: '';
  position: absolute;
  top: -200px;
  right: -200px;
  width: 500px;
  height: 500px;
  background: radial-gradient(circle, rgba(232, 168, 56, 0.08), transparent 70%);
  pointer-events: none;
}

.footer-inner {
  max-width: 1280px;
  margin: 0 auto;
  display: flex;
  gap: 80px;
}

.footer-left {
  flex: 1;
}

.footer-left .section-title {
  color: #fff;
}

.footer-left p {
  color: rgba(255, 255, 255, 0.7);
  font-size: 0.95rem;
  line-height: 1.8;
  margin-bottom: 32px;
}

.footer-left p a {
  color: var(--accent);
  font-weight: 500;
  transition: var(--transition);
}

.footer-left p a:hover {
  text-decoration: underline;
}

.footer-logo {
  margin-bottom: 20px;
}

.footer-logo img {
  height: 50px;
  width: auto;
}

.footer-social a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.08);
  transition: var(--transition);
}

.footer-social a:hover {
  background: var(--accent);
  transform: translateY(-2px);
}

.footer-social svg {
  width: 18px;
  height: 18px;
  color: rgba(255, 255, 255, 0.8);
  transition: var(--transition);
}

.footer-social a:hover svg {
  color: #fff;
}

.footer-right {
  flex: 1;
}

/* contact-form and btn-send styles moved to floating label section */

.footer-bottom {
  margin-top: 60px;
  padding: 20px 0;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  display: flex;
  justify-content: center;
  gap: 32px;
  font-size: 0.78rem;
  color: rgba(255, 255, 255, 0.35);
  flex-wrap: wrap;
  text-align: center;
}

.footer-bottom a {
  color: rgba(255, 255, 255, 0.35);
  transition: var(--transition);
}

.footer-bottom a:hover {
  color: var(--accent);
}

/* ===== SERVICES PAGE ===== */
.services-section {
  padding: 100px 32px;
}

.services-inner {
  max-width: 1280px;
  margin: 0 auto;
  display: flex;
  gap: 80px;
}

.services-col {
  flex: 1;
}

.services-col h2 {
  font-family: 'DM Serif Display', serif;
  font-size: 1.5rem;
  font-weight: 400;
  color: var(--navy);
  margin-bottom: 32px;
  text-align: center;
  letter-spacing: -0.3px;
}

.service-card {
  margin-bottom: 28px;
  border-radius: var(--radius);
  overflow: hidden;
  background: var(--white);
  box-shadow: var(--shadow);
  border: 1px solid var(--card-border);
  transition: var(--transition);
}

.service-card:hover {
  transform: translateY(-8px);
  box-shadow: var(--shadow-lg);
}

.service-card img {
  width: 100%;
  height: 220px;
  object-fit: cover;
  transition: transform 0.5s ease;
}

.service-card:hover img {
  transform: scale(1.03);
}

.service-card .service-label {
  padding: 20px 24px;
  font-size: 0.92rem;
  font-weight: 600;
  color: var(--navy);
  background: var(--white);
  text-align: center;
}

/* ===== EXPERTISE PAGE ===== */
.expertise-section {
  padding: 100px 32px;
}

.expertise-block {
  max-width: 1280px;
  margin: 0 auto 80px;
  display: flex;
  gap: 64px;
  align-items: stretch;
}

.expertise-block:last-child {
  margin-bottom: 0;
}

.expertise-block.reverse {
  flex-direction: row-reverse;
}

.expertise-block-image {
  flex: 1;
  min-height: 400px;
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow-lg);
}

.expertise-block-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.6s ease;
}

.expertise-block:hover .expertise-block-image img {
  transform: scale(1.03);
}

.expertise-block-text {
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 16px 0;
}

.expertise-block-text h2 {
  font-family: 'DM Serif Display', serif;
  font-size: 1.8rem;
  font-weight: 400;
  color: var(--navy);
  margin-bottom: 24px;
  letter-spacing: -0.3px;
}

.expertise-block-text h2::after {
  content: '';
  display: block;
  width: 40px;
  height: 3px;
  background: var(--accent);
  margin-top: 12px;
  border-radius: 3px;
}

.expertise-block-text p {
  font-size: 0.92rem;
  line-height: 1.9;
  color: var(--text-light);
  margin-bottom: 12px;
}

.expertise-block-text ul {
  margin: 0 0 12px 20px;
  list-style: disc;
  font-size: 0.92rem;
  color: var(--text-light);
  line-height: 1.9;
}

.btn-contact {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-top: 16px;
  padding: 13px 32px;
  background: var(--accent);
  color: #fff;
  border: none;
  border-radius: 100px;
  font-family: 'Inter', sans-serif;
  font-size: 0.85rem;
  font-weight: 600;
  cursor: pointer;
  transition: var(--transition);
  align-self: flex-start;
  box-shadow: 0 4px 15px rgba(232, 168, 56, 0.3);
}

.btn-contact:hover {
  background: var(--accent-hover);
  transform: translateY(-2px);
  box-shadow: 0 8px 25px rgba(232, 168, 56, 0.4);
}

/* ===== ARTICLE BODY ===== */
.article-body {
  color: var(--text-light);
  font-size: 0.95rem;
  line-height: 2;
}

.article-body p {
  margin-bottom: 16px;
}

.article-body h2, .article-body h3 {
  font-family: 'DM Serif Display', serif;
  color: var(--text);
  margin: 32px 0 12px;
  font-weight: 400;
}

.article-body h2 { font-size: 1.5rem; }
.article-body h3 { font-size: 1.2rem; }

.article-body ul, .article-body ol {
  margin: 12px 0 16px 24px;
}

.article-body li {
  margin-bottom: 6px;
}

.article-body img {
  max-width: 100%;
  border-radius: var(--radius-sm);
  margin: 16px 0;
}

.article-body table {
  width: 100%;
  border-collapse: collapse;
  margin: 16px 0;
}

.article-body th, .article-body td {
  padding: 10px 14px;
  border: 1px solid var(--card-border);
  text-align: left;
  font-size: 0.88rem;
}

.article-body th {
  background: var(--input-bg);
  font-weight: 600;
}

/* ===== BLOG PAGE ===== */
.blog-section {
  padding: 100px 32px;
}

.blog-inner {
  max-width: 900px;
  margin: 0 auto;
}

.blog-tabs {
  display: flex;
  gap: 8px;
  margin-bottom: 40px;
  padding: 6px;
  background: var(--white);
  border-radius: 100px;
  box-shadow: var(--shadow);
  border: 1px solid var(--card-border);
  width: fit-content;
}

.blog-tab {
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--text-light);
  cursor: pointer;
  padding: 10px 24px;
  border-radius: 100px;
  border: none;
  background: transparent;
  font-family: 'Inter', sans-serif;
  transition: var(--transition);
}

.blog-tab.active {
  color: #fff;
  background: var(--navy);
}

.blog-tab:hover:not(.active) {
  color: var(--navy);
  background: rgba(15, 39, 68, 0.06);
}

.blog-list {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.blog-card {
  display: flex;
  gap: 24px;
  background: var(--white);
  border-radius: var(--radius);
  overflow: hidden;
  border: 1px solid var(--card-border);
  box-shadow: var(--shadow);
  transition: var(--transition);
}

.blog-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
}

.blog-card-image {
  flex-shrink: 0;
  width: 220px;
  height: 160px;
  overflow: hidden;
}

.blog-card-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease;
}

.blog-card:hover .blog-card-image img {
  transform: scale(1.05);
}

.blog-card-content {
  padding: 24px 24px 24px 0;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.blog-card-content h3 {
  font-family: 'DM Serif Display', serif;
  font-size: 1.1rem;
  font-weight: 400;
  color: var(--navy);
  margin-bottom: 8px;
  letter-spacing: -0.2px;
}

.blog-card-content .blog-meta {
  font-size: 0.78rem;
  color: var(--text-light);
}

.blog-card-content .blog-tag {
  display: inline-block;
  margin-top: 12px;
  padding: 4px 12px;
  background: rgba(232, 168, 56, 0.1);
  color: var(--accent);
  border-radius: 100px;
  font-size: 0.72rem;
  font-weight: 600;
}

/* ===== THEME TOGGLE ===== */
.theme-toggle {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 38px;
  height: 38px;
  border-radius: 10px;
  border: 1px solid var(--card-border);
  background: transparent;
  color: var(--text);
  cursor: pointer;
  transition: var(--transition);
}

.theme-toggle:hover {
  background: var(--input-bg);
}

.theme-toggle .icon-sun,
.theme-toggle .icon-moon {
  transition: var(--transition);
}

.theme-toggle .icon-moon { display: block; }
.theme-toggle .icon-sun { display: none; }

[data-theme="dark"] .theme-toggle .icon-moon { display: none; }
[data-theme="dark"] .theme-toggle .icon-sun { display: block; }

/* Dark mode overrides for elements with hardcoded colors */
[data-theme="dark"] .header-login-btn,
[data-theme="dark"] .header-user-btn {
  color: var(--text);
}

[data-theme="dark"] .login-form .form-eye {
  color: var(--text-light);
}

[data-theme="dark"] .btn-login {
  background: var(--accent);
}

[data-theme="dark"] .btn-login:hover {
  background: var(--accent-hover);
}

[data-theme="dark"] .blog-tab.active {
  background: var(--accent);
}

[data-theme="dark"] .carousel-arrow {
  border-color: var(--card-border);
  color: var(--text);
}

[data-theme="dark"] .carousel-arrow:hover {
  background: var(--accent);
  border-color: var(--accent);
  color: #fff;
}

[data-theme="dark"] .section-title,
[data-theme="dark"] .section-label {
  color: var(--text);
}

[data-theme="dark"] .section-label {
  color: var(--accent);
}

[data-theme="dark"] .mission-text {
  background: #0a1529;
}

[data-theme="dark"] .footer {
  background: #060d18;
}

[data-theme="dark"] .expertise-block-text h2,
[data-theme="dark"] .services-col h2,
[data-theme="dark"] .dash-section-title,
[data-theme="dark"] .dashboard-title,
[data-theme="dark"] .login-panel-title,
[data-theme="dark"] .login-panel-name,
[data-theme="dark"] .dash-card-value,
[data-theme="dark"] .dash-table-name,
[data-theme="dark"] .service-card .service-label,
[data-theme="dark"] .blog-card-content h3 {
  color: var(--text);
}

/* ===== LOGIN PANEL ===== */
.login-wrap {
  position: relative;
}

.header-login-btn,
.header-user-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border-radius: 10px;
  border: 1px solid var(--card-border);
  background: transparent;
  color: var(--navy);
  cursor: pointer;
  transition: var(--transition);
}

.header-login-btn:hover,
.header-user-btn:hover {
  background: var(--input-bg);
}

.user-avatar {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  border-radius: 8px;
  background: var(--accent);
  color: #fff;
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.5px;
}

.user-avatar--lg {
  width: 42px;
  height: 42px;
  font-size: 0.82rem;
  border-radius: 10px;
}

.login-panel {
  position: absolute;
  top: calc(100% + 12px);
  right: 0;
  width: 340px;
  background: var(--white);
  border-radius: var(--radius);
  box-shadow: var(--shadow-lg);
  border: 1px solid var(--card-border);
  padding: 24px;
  opacity: 0;
  visibility: hidden;
  transform: translateY(-8px);
  transition: var(--transition);
  z-index: 100;
}

.login-panel.is-open {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.login-panel-title {
  font-family: 'DM Serif Display', serif;
  font-size: 1.3rem;
  font-weight: 400;
  color: var(--navy);
  margin-bottom: 20px;
}

.login-panel-user {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 4px;
}

.login-panel-name {
  font-weight: 600;
  font-size: 0.92rem;
  color: var(--navy);
}

.login-panel-email {
  font-size: 0.78rem;
  color: var(--text-light);
}

.login-panel-divider {
  height: 1px;
  background: var(--card-border);
  margin: 16px 0;
}

.login-panel-link {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 12px;
  border-radius: 8px;
  font-size: 0.88rem;
  font-weight: 500;
  color: var(--text);
  transition: var(--transition);
}

.login-panel-link:hover {
  background: var(--input-bg);
}

.login-panel-link--danger {
  color: #dc2626;
}

.login-panel-link--danger:hover {
  background: rgba(220, 38, 38, 0.06);
}

.login-alert {
  padding: 10px 14px;
  border-radius: 8px;
  font-size: 0.82rem;
  font-weight: 500;
  margin-bottom: 16px;
}

.login-alert--error {
  background: rgba(220, 38, 38, 0.08);
  color: #dc2626;
  border: 1px solid rgba(220, 38, 38, 0.15);
}

.login-panel-footer {
  margin-top: 16px;
  text-align: center;
  font-size: 0.78rem;
}

.login-panel-footer a {
  color: var(--text-light);
  transition: var(--transition);
}

.login-panel-footer a:hover {
  color: var(--accent);
}

.btn-login {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 13px;
  background: var(--navy);
  color: #fff;
  border: none;
  border-radius: 10px;
  font-family: 'Inter', sans-serif;
  font-size: 0.88rem;
  font-weight: 600;
  cursor: pointer;
  transition: var(--transition);
}

.btn-login:hover {
  background: #0a1e36;
  transform: translateY(-1px);
  box-shadow: 0 4px 15px rgba(15, 39, 68, 0.3);
}

/* ===== FLOATING LABEL FORM ===== */
.form-group {
  position: relative;
}

.form-input {
  width: 100%;
  padding: 16px 16px 8px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: var(--radius-sm);
  background: rgba(255, 255, 255, 0.06);
  color: #fff;
  font-family: 'Inter', sans-serif;
  font-size: 0.9rem;
  outline: none;
  transition: var(--transition);
}

.form-input:focus {
  border-color: var(--accent);
  background: rgba(255, 255, 255, 0.1);
  box-shadow: 0 0 0 3px var(--accent-glow);
}

.form-label {
  position: absolute;
  top: 50%;
  left: 16px;
  transform: translateY(-50%);
  color: rgba(255, 255, 255, 0.4);
  font-size: 0.88rem;
  pointer-events: none;
  transition: var(--transition);
}

.form-textarea ~ .form-label {
  top: 20px;
}

.form-input:focus ~ .form-label,
.form-input:not(:placeholder-shown) ~ .form-label {
  top: 8px;
  transform: translateY(0);
  font-size: 0.68rem;
  font-weight: 600;
  letter-spacing: 0.5px;
  text-transform: uppercase;
  color: var(--accent);
}

.form-textarea {
  min-height: 100px;
  resize: vertical;
  padding-top: 24px;
}

.form-eye {
  position: absolute;
  right: 12px;
  top: 50%;
  transform: translateY(-50%);
  background: none;
  border: none;
  color: rgba(255, 255, 255, 0.4);
  cursor: pointer;
  padding: 4px;
  transition: var(--transition);
}

.form-eye:hover {
  color: var(--accent);
}

/* Login panel form inputs (on white bg) */
.login-panel .form-group { margin-bottom: 14px; }

.login-form .form-input {
  background: var(--input-bg);
  border: 1px solid var(--card-border);
  color: var(--text);
}

.login-form .form-input:focus {
  border-color: var(--accent);
  background: var(--bg);
}

.login-form .form-label {
  color: var(--text-light);
}

.login-form .form-input:focus ~ .form-label,
.login-form .form-input:not(:placeholder-shown) ~ .form-label {
  color: var(--accent);
}

.login-form .form-eye {
  color: var(--text-light);
}

/* Footer contact form */
.contact-form {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.contact-form .form-input::placeholder {
  color: transparent;
}

.btn-send {
  align-self: flex-start;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 14px 36px;
  background: var(--accent);
  color: #fff;
  border: none;
  border-radius: 100px;
  font-family: 'Inter', sans-serif;
  font-size: 0.88rem;
  font-weight: 600;
  cursor: pointer;
  transition: var(--transition);
  box-shadow: 0 4px 15px rgba(232, 168, 56, 0.3);
}

.btn-send:hover {
  background: var(--accent-hover);
  transform: translateY(-2px);
  box-shadow: 0 8px 25px rgba(232, 168, 56, 0.4);
}

/* ===== DASHBOARD ===== */
.dashboard {
  margin-top: 70px;
  padding: 48px 32px 100px;
  background: var(--bg);
  min-height: calc(100vh - 70px);
}

.dashboard-inner {
  max-width: 1280px;
  margin: 0 auto;
}

.dashboard-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 48px;
}

.dashboard-title {
  font-family: 'DM Serif Display', serif;
  font-size: 2.2rem;
  font-weight: 400;
  color: var(--navy);
  margin: 4px 0 8px;
}

.dashboard-subtitle {
  color: var(--text-light);
  font-size: 0.95rem;
}

.dashboard-date {
  color: var(--text-light);
  font-size: 0.85rem;
  padding: 8px 16px;
  background: var(--white);
  border-radius: 100px;
  border: 1px solid var(--card-border);
}

.dashboard-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
  margin-bottom: 48px;
}

.dash-card {
  background: var(--white);
  border-radius: var(--radius);
  padding: 28px;
  border: 1px solid var(--card-border);
  box-shadow: var(--shadow);
  display: flex;
  align-items: center;
  gap: 20px;
  transition: var(--transition);
}

.dash-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
}

.dash-card-icon {
  width: 52px;
  height: 52px;
  border-radius: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.dash-card-icon--blue { background: rgba(59, 130, 246, 0.1); color: #3b82f6; }
.dash-card-icon--amber { background: rgba(232, 168, 56, 0.1); color: var(--accent); }
.dash-card-icon--green { background: rgba(34, 197, 94, 0.1); color: #22c55e; }
.dash-card-icon--red { background: rgba(220, 38, 38, 0.1); color: #dc2626; }

.dash-card-value {
  font-family: 'DM Serif Display', serif;
  font-size: 2rem;
  color: var(--navy);
  line-height: 1;
  margin-bottom: 4px;
}

.dash-card-label {
  font-size: 0.78rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  color: var(--text-light);
}

.dash-section {
  background: var(--white);
  border-radius: var(--radius);
  padding: 32px;
  border: 1px solid var(--card-border);
  box-shadow: var(--shadow);
}

.dash-section-title {
  font-family: 'DM Serif Display', serif;
  font-size: 1.3rem;
  font-weight: 400;
  color: var(--navy);
  margin-bottom: 24px;
}

.dash-table-header,
.dash-table-row {
  display: grid;
  grid-template-columns: 2fr 1.2fr 0.8fr 1fr;
  gap: 16px;
  padding: 14px 16px;
  align-items: center;
}

.dash-table-header {
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: var(--text-light);
  border-bottom: 1px solid var(--card-border);
}

.dash-table-row {
  border-bottom: 1px solid var(--card-border);
  transition: var(--transition);
}

.dash-table-row:last-child {
  border-bottom: none;
}

.dash-table-row:hover {
  background: var(--input-bg);
  border-radius: 8px;
}

.dash-table-name {
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--navy);
}

.dash-table-tag {
  font-size: 0.75rem;
  font-weight: 600;
  padding: 4px 10px;
  border-radius: 100px;
  background: rgba(232, 168, 56, 0.1);
  color: var(--accent);
  width: fit-content;
}

.dash-table-status {
  font-size: 0.78rem;
  font-weight: 600;
}

.dash-table-status--active { color: #3b82f6; }
.dash-table-status--review { color: var(--accent); }
.dash-table-status--done { color: #22c55e; }

.dash-table-date {
  font-size: 0.82rem;
  color: var(--text-light);
}

/* ===== RESPONSIVE ===== */
@media (max-width: 1024px) {
  .hero-home .hero-content {
    flex-direction: column;
    gap: 40px;
  }

  .hero { min-height: 70vh; }

  .hero-title-block h1 {
    font-size: 3rem;
  }

  .mission {
    flex-direction: column;
  }

  .mission-text {
    padding: 60px 40px;
  }

  .mission-image {
    min-height: 300px;
  }

  .stats-bar {
    grid-template-columns: repeat(2, 1fr);
    margin-top: -30px;
  }

  .stat-item:first-child {
    border-radius: var(--radius) 0 0 0;
  }

  .stat-item:nth-child(2) {
    border-radius: 0 var(--radius) 0 0;
  }

  .stat-item:nth-child(3) {
    border-radius: 0 0 0 var(--radius);
  }

  .stat-item:last-child {
    border-radius: 0 0 var(--radius) 0;
  }

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

  .services-inner {
    flex-direction: column;
    gap: 48px;
  }

  .expertise-block,
  .expertise-block.reverse {
    flex-direction: column;
    gap: 32px;
  }

  .expertise-block-image {
    min-height: 300px;
  }

  .footer-inner {
    flex-direction: column;
    gap: 48px;
  }

  .experiences-carousel {
    flex-direction: column;
    text-align: center;
    gap: 32px;
  }

  .carousel-logo { width: 150px; }
  .carousel-arrows { justify-content: center; }
}

@media (max-width: 1024px) {
  .dashboard-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  .dash-table-header,
  .dash-table-row {
    grid-template-columns: 1.5fr 1fr 0.8fr;
  }
  .dash-table-date { display: none; }
}

@media (max-width: 640px) {
  .header-inner {
    padding: 12px 20px;
    flex-wrap: wrap;
  }

  .nav-list {
    display: none;
    flex-direction: column;
    width: 100%;
    gap: 4px;
    padding-top: 16px;
    order: 3;
  }

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

  .nav-list a {
    width: 100%;
    text-align: center;
    padding: 12px;
  }

  .mobile-toggle {
    display: flex;
  }

  .hero {
    min-height: 60vh;
    background-attachment: scroll;
    margin-top: 60px;
  }

  .hero-content {
    padding: 48px 20px;
  }

  .hero-title-block h1 {
    font-size: 2.2rem;
  }

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

  .section {
    padding: 60px 20px;
  }

  .expertise-grid {
    grid-template-columns: 1fr;
    gap: 16px;
  }

  .expertise-card {
    aspect-ratio: 4/3;
  }

  .stats-bar {
    grid-template-columns: 1fr 1fr;
    padding: 0 20px;
  }

  .stat-number {
    font-size: 2.2rem;
  }

  .stat-item {
    padding: 32px 16px;
  }

  .blog-card {
    flex-direction: column;
  }

  .blog-card-image {
    width: 100%;
    height: 180px;
  }

  .blog-card-content {
    padding: 20px;
  }

  .blog-tabs {
    border-radius: var(--radius-sm);
    flex-wrap: wrap;
  }

  .mission-text {
    padding: 48px 24px;
  }

  .footer {
    padding: 60px 20px 0;
  }

  .footer-bottom {
    flex-direction: column;
    gap: 8px;
    margin-top: 40px;
  }

  .services-section,
  .expertise-section,
  .blog-section {
    padding: 60px 20px;
  }

  .login-panel {
    width: 300px;
    right: -20px;
  }

  .dashboard {
    padding: 32px 20px 60px;
  }

  .dashboard-header {
    flex-direction: column;
    gap: 12px;
  }

  .dashboard-title {
    font-size: 1.6rem;
  }

  .dashboard-grid {
    grid-template-columns: 1fr;
  }

  .dash-table-header,
  .dash-table-row {
    grid-template-columns: 1fr 0.7fr;
  }
  .dash-table-tag,
  .dash-table-date { display: none; }
}
