/* ============================================================
   Khadija Bousselam — Portfolio
   Warm & approachable · cream + terracotta
   ============================================================ */

:root {
  --bg:        #F7F1E8;
  --bg-warm:   #F1E7D8;
  --surface:   #FFFFFF;
  --surface-2: #FCF7EF;
  --ink:       #221C15;
  --ink-soft:  #6E6356;
  --ink-faint: #9B9080;
  --line:      rgba(34, 28, 21, 0.12);
  --line-soft: rgba(34, 28, 21, 0.07);

  --accent:    #E2552E;   /* primary coral-terracotta */
  --accent-ink:#B23E1C;   /* deeper, for text on cream */
  --accent-2:  #C9763E;   /* warm ochre */
  --sand:      #EBD9C2;
  --sand-2:    #E3CDAE;

  --dark:      #221C15;
  --dark-2:    #2C251C;

  --radius-sm: 14px;
  --radius:    22px;
  --radius-lg: 30px;
  --radius-xl: 40px;

  --shadow-sm: 0 2px 8px rgba(34,28,21,0.05);
  --shadow:    0 18px 50px -22px rgba(34,28,21,0.30);
  --shadow-lift: 0 30px 70px -30px rgba(178,62,28,0.45);

  --maxw: 1200px;
  --ease: cubic-bezier(0.22, 1, 0.36, 1);

  --font-display: "Bricolage Grotesque", "Hanken Grotesk", system-ui, sans-serif;
  --font-body: "Hanken Grotesk", system-ui, sans-serif;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: var(--font-body);
  background: var(--bg);
  color: var(--ink);
  font-size: 17px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}

h1, h2, h3, h4 {
  font-family: var(--font-display);
  font-weight: 700;
  line-height: 1.04;
  letter-spacing: -0.02em;
  margin: 0;
  text-wrap: balance;
}

p { margin: 0; text-wrap: pretty; }
a { color: inherit; text-decoration: none; }
img { display: block; max-width: 100%; }

.wrap {
  width: 100%;
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 0 40px;
}

section { position: relative; }

/* lang visibility */
[data-i18n] .fr { display: none; }
body[data-lang="fr"] [data-i18n] .en { display: none; }
body[data-lang="fr"] [data-i18n] .fr { display: inline; }

/* ---------- buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 16px;
  padding: 15px 26px;
  border-radius: 999px;
  border: 1.5px solid transparent;
  cursor: pointer;
  transition: transform .35s var(--ease), background .25s, color .25s, box-shadow .35s var(--ease);
  white-space: nowrap;
}
.btn svg { width: 18px; height: 18px; }
.btn-primary {
  background: var(--accent);
  color: #fff;
  box-shadow: var(--shadow-lift);
}
.btn-primary:hover { transform: translateY(-3px); background: #cf4a25; }
.btn-ghost {
  background: transparent;
  color: var(--ink);
  border-color: var(--line);
}
.btn-ghost:hover { transform: translateY(-3px); border-color: var(--ink); background: rgba(34,28,21,0.03); }
.btn-light {
  background: var(--surface-2);
  color: var(--ink);
}
.btn-light:hover { transform: translateY(-3px); box-shadow: var(--shadow); }

/* ---------- nav ---------- */
.nav {
  position: sticky;
  top: 0;
  z-index: 50;
  background: color-mix(in srgb, var(--bg) 82%, transparent);
  backdrop-filter: blur(14px);
  border-bottom: 1px solid transparent;
  transition: border-color .3s, background .3s;
}
.nav.scrolled { border-bottom-color: var(--line-soft); }
.nav-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 78px;
}
.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 18px;
  letter-spacing: -0.02em;
}
.brand .mono {
  display: grid;
  place-items: center;
  width: 40px; height: 40px;
  border-radius: 12px;
  background: var(--accent);
  color: #fff;
  font-size: 17px;
  letter-spacing: 0;
  box-shadow: var(--shadow-sm);
}
.brand small { display: block; font-family: var(--font-body); font-weight: 500; font-size: 12px; color: var(--ink-soft); letter-spacing: 0.01em; }
.nav-links {
  display: flex;
  align-items: center;
  gap: 34px;
}
.nav-links a.navlink {
  font-size: 15.5px;
  font-weight: 500;
  color: var(--ink-soft);
  position: relative;
  transition: color .2s;
}
.nav-links a.navlink:hover { color: var(--ink); }
.nav-links a.navlink::after {
  content: "";
  position: absolute;
  left: 0; bottom: -6px;
  width: 0; height: 2px;
  background: var(--accent);
  border-radius: 2px;
  transition: width .3s var(--ease);
}
.nav-links a.navlink:hover::after { width: 100%; }
.nav-right { display: flex; align-items: center; gap: 18px; }

.lang-toggle {
  display: inline-flex;
  border: 1.5px solid var(--line);
  border-radius: 999px;
  overflow: hidden;
  font-weight: 600;
  font-size: 13px;
}
.lang-toggle button {
  border: none;
  background: transparent;
  color: var(--ink-soft);
  padding: 7px 13px;
  cursor: pointer;
  font-family: var(--font-body);
  font-weight: 600;
  transition: background .2s, color .2s;
}
.lang-toggle button.active { background: var(--ink); color: var(--bg); }

.nav-cta { padding: 11px 20px; font-size: 15px; }

.menu-btn { display: none; }

/* ---------- hero ---------- */
.hero { padding: 70px 0 90px; }
.hero-grid {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 64px;
  align-items: center;
}
.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-size: 14px;
  font-weight: 600;
  letter-spacing: 0.02em;
  color: var(--accent-ink);
  background: color-mix(in srgb, var(--accent) 12%, transparent);
  padding: 8px 16px;
  border-radius: 999px;
  margin-bottom: 26px;
}
.eyebrow .dot {
  width: 8px; height: 8px; border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 0 0 4px color-mix(in srgb, var(--accent) 22%, transparent);
}
.hero h1 {
  font-size: clamp(40px, 6vw, 74px);
  letter-spacing: -0.035em;
}
.hero h1 .em { color: var(--accent); font-style: italic; font-weight: 700; }
.hero .lead {
  font-size: clamp(18px, 2vw, 21px);
  color: var(--ink-soft);
  max-width: 30em;
  margin-top: 26px;
  line-height: 1.55;
}
.hero-cta { display: flex; gap: 14px; margin-top: 38px; flex-wrap: wrap; }

.hero-figure {
  position: relative;
  justify-self: center;
}
.hero-photo {
  position: relative;
  width: min(420px, 80vw);
  aspect-ratio: 1 / 1.08;
  border-radius: var(--radius-xl);
  overflow: hidden;
  box-shadow: var(--shadow);
  z-index: 2;
}
.hero-photo img { width: 100%; height: 100%; object-fit: cover; object-position: center 18%; }
.hero-blob {
  position: absolute;
  inset: auto -28px -34px auto;
  width: 78%; height: 78%;
  background: radial-gradient(circle at 30% 30%, var(--accent) 0%, var(--accent-2) 100%);
  border-radius: var(--radius-xl);
  z-index: 1;
  filter: blur(2px);
  opacity: 0.9;
}
.hero-badge {
  position: absolute;
  z-index: 3;
  background: var(--surface);
  border-radius: 18px;
  padding: 14px 18px;
  box-shadow: var(--shadow);
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 14px;
  font-weight: 600;
}
.hero-badge .pill { width: 38px; height: 38px; border-radius: 11px; display: grid; place-items: center; background: var(--sand); color: var(--accent-ink); }
.hero-badge.top { top: 24px; left: -34px; }
.hero-badge.bot { bottom: 30px; right: -40px; }
.hero-badge small { display: block; font-weight: 500; color: var(--ink-soft); font-size: 12px; }

/* hero variant: centered */
body[data-hero="centered"] .hero-grid {
  grid-template-columns: 1fr;
  text-align: center;
  justify-items: center;
  gap: 50px;
}
body[data-hero="centered"] .hero .lead { margin-left: auto; margin-right: auto; }
body[data-hero="centered"] .hero-cta { justify-content: center; }
body[data-hero="centered"] .eyebrow { margin-inline: auto; }
body[data-hero="centered"] .hero-photo { width: min(560px, 90vw); aspect-ratio: 16 / 9; }
body[data-hero="centered"] .hero-photo img { object-position: center 30%; }
body[data-hero="centered"] .hero-badge.top { left: 5%; }
body[data-hero="centered"] .hero-badge.bot { right: 5%; }

/* hero variant: overlap (editorial) */
body[data-hero="overlap"] .hero { padding-top: 40px; }
body[data-hero="overlap"] .hero-grid {
  grid-template-columns: 1fr;
  gap: 0;
}
body[data-hero="overlap"] .hero-copy { position: relative; z-index: 4; }
body[data-hero="overlap"] .hero h1 { font-size: clamp(46px, 9vw, 120px); }
body[data-hero="overlap"] .hero-figure {
  justify-self: end;
  margin-top: -120px;
  margin-right: 2%;
}
body[data-hero="overlap"] .hero-photo { width: min(380px, 64vw); }
body[data-hero="overlap"] .hero .lead { margin-top: 30px; }
body[data-hero="overlap"] .hero-cta { margin-top: 30px; }

/* ---------- marquee / tools ---------- */
.strip {
  border-top: 1px solid var(--line-soft);
  border-bottom: 1px solid var(--line-soft);
  padding: 26px 0;
  overflow: hidden;
  background: var(--bg-warm);
}
.strip-label { font-size: 13px; font-weight: 600; letter-spacing: 0.14em; text-transform: uppercase; color: var(--ink-faint); margin-bottom: 16px; }
.marquee { display: flex; gap: 56px; width: max-content; animation: scroll 26s linear infinite; }
.marquee span { font-family: var(--font-display); font-weight: 600; font-size: 26px; color: var(--ink-soft); display: inline-flex; align-items: center; gap: 56px; white-space: nowrap; }
.marquee span::after { content: "✦"; color: var(--accent); font-size: 16px; }
@keyframes scroll { to { transform: translateX(-50%); } }
.strip:hover .marquee { animation-play-state: paused; }

/* ---------- section heading ---------- */
.sec { padding: 110px 0; }
.sec-head { max-width: 640px; margin-bottom: 60px; }
.sec-tag {
  display: inline-flex; align-items: center; gap: 9px;
  font-size: 13px; font-weight: 700; letter-spacing: 0.13em; text-transform: uppercase;
  color: var(--accent-ink);
  margin-bottom: 20px;
}
.sec-tag .ln { width: 26px; height: 2px; background: var(--accent); border-radius: 2px; }
.sec-head h2 { font-size: clamp(32px, 4.4vw, 52px); }
.sec-head p { color: var(--ink-soft); font-size: 19px; margin-top: 20px; }
.sec-head.center { margin-inline: auto; text-align: center; }
.sec-head.center .sec-tag { justify-content: center; }

/* ---------- about ---------- */
.about { background: var(--surface-2); border-radius: var(--radius-xl); }
.about-grid {
  display: grid;
  grid-template-columns: 0.85fr 1.15fr;
  gap: 70px;
  align-items: center;
}
.about-photo {
  position: relative;
  border-radius: var(--radius-lg);
  overflow: hidden;
  aspect-ratio: 4 / 5;
  box-shadow: var(--shadow);
}
.about-photo img { width: 100%; height: 100%; object-fit: cover; object-position: center 20%; }
.about-photo .frame {
  position: absolute; inset: 0;
  border: 8px solid var(--bg);
  border-radius: var(--radius-lg);
  pointer-events: none;
}
.about-body h2 { font-size: clamp(28px, 3.6vw, 42px); margin-bottom: 26px; }
.about-body p { color: var(--ink-soft); font-size: 18px; margin-bottom: 18px; }
.about-body p strong { color: var(--ink); font-weight: 600; }
.about-stats { display: flex; gap: 40px; margin-top: 38px; flex-wrap: wrap; }
.about-stats .stat .n { font-family: var(--font-display); font-weight: 700; font-size: 38px; color: var(--accent-ink); letter-spacing: -0.02em; }
.about-stats .stat .l { font-size: 14px; color: var(--ink-soft); margin-top: 2px; }

/* ---------- services ---------- */
.services-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 26px; }
.svc {
  background: var(--surface);
  border: 1px solid var(--line-soft);
  border-radius: var(--radius-lg);
  padding: 38px 34px 40px;
  transition: transform .4s var(--ease), box-shadow .4s var(--ease), border-color .3s;
  position: relative;
  overflow: hidden;
}
.svc::before {
  content: "";
  position: absolute; inset: 0 0 auto 0; height: 5px;
  background: linear-gradient(90deg, var(--accent), var(--accent-2));
  transform: scaleX(0); transform-origin: left;
  transition: transform .45s var(--ease);
}
.svc:hover { transform: translateY(-8px); box-shadow: var(--shadow); border-color: transparent; }
.svc:hover::before { transform: scaleX(1); }
.svc-num { font-family: var(--font-display); font-weight: 700; font-size: 15px; color: var(--ink-faint); }
.svc-ico {
  width: 60px; height: 60px; border-radius: 18px;
  display: grid; place-items: center;
  background: color-mix(in srgb, var(--accent) 12%, transparent);
  color: var(--accent-ink);
  margin: 22px 0 24px;
}
.svc-ico svg { width: 28px; height: 28px; }
.svc h3 { font-size: 24px; margin-bottom: 14px; }
.svc p { color: var(--ink-soft); font-size: 16px; line-height: 1.6; }
.svc-tags { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 22px; }
.svc-tags span {
  font-size: 13px; font-weight: 500;
  padding: 6px 12px; border-radius: 999px;
  background: var(--surface-2);
  border: 1px solid var(--line-soft);
  color: var(--ink-soft);
}

/* ---------- work / case studies ---------- */
.work { }
.case {
  display: grid;
  grid-template-columns: 0.95fr 1.05fr;
  gap: 0;
  background: var(--surface);
  border: 1px solid var(--line-soft);
  border-radius: var(--radius-xl);
  overflow: hidden;
  margin-bottom: 34px;
  transition: box-shadow .4s var(--ease), transform .4s var(--ease);
}
.case:hover { box-shadow: var(--shadow); transform: translateY(-4px); }
.case:nth-child(even) .case-visual { order: 2; }
.case-visual {
  position: relative;
  min-height: 380px;
  display: grid;
  place-items: center;
  padding: 40px;
  background:
    radial-gradient(120% 90% at 20% 10%, color-mix(in srgb, var(--accent) 16%, transparent), transparent 60%),
    var(--bg-warm);
  overflow: hidden;
}
.case-visual .ph {
  position: relative; z-index: 2;
  width: 100%; max-width: 320px;
  aspect-ratio: 4/3;
  border-radius: var(--radius);
  background: var(--surface);
  box-shadow: var(--shadow);
  display: grid; place-items: center;
  color: var(--ink-faint);
  font-weight: 600; font-size: 14px;
  text-align: center;
  border: 1px dashed var(--line);
  gap: 10px;
}
.case-visual .ph svg { width: 38px; height: 38px; opacity: .55; }
.case-num {
  position: absolute; top: 24px; left: 28px; z-index: 3;
  font-family: var(--font-display); font-weight: 700;
  font-size: 64px; color: rgba(34,28,21,0.10); line-height: 1;
}
.case-body { padding: 46px 48px; }
.case-cat { font-size: 13px; font-weight: 700; letter-spacing: 0.1em; text-transform: uppercase; color: var(--accent-ink); }
.case-body h3 { font-size: 30px; margin: 14px 0 22px; }
.case-meta { display: flex; gap: 10px; flex-wrap: wrap; margin-bottom: 26px; }
.case-meta .role { font-size: 13px; font-weight: 600; padding: 6px 13px; border-radius: 999px; background: var(--ink); color: var(--bg); }
.case-row { margin-bottom: 18px; }
.case-row .k {
  display: inline-flex; align-items: center; gap: 8px;
  font-size: 12px; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase;
  color: var(--ink-faint); margin-bottom: 6px;
}
.case-row .k::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: var(--accent); }
.case-row p { color: var(--ink-soft); font-size: 16px; }
.case-deliv { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 26px; padding-top: 26px; border-top: 1px solid var(--line-soft); }
.case-deliv span {
  display: inline-flex; align-items: center; gap: 7px;
  font-size: 13px; font-weight: 600;
  padding: 7px 13px; border-radius: 10px;
  background: color-mix(in srgb, var(--accent) 10%, transparent);
  color: var(--accent-ink);
}
.case-deliv span::before { content: "✓"; font-size: 12px; }

/* ---------- contact (dark) ---------- */
.contact {
  background: var(--dark);
  color: var(--bg);
  border-radius: var(--radius-xl);
  margin: 0 24px;
  overflow: hidden;
  position: relative;
}
.contact::after {
  content: "";
  position: absolute;
  width: 520px; height: 520px;
  right: -160px; top: -160px;
  background: radial-gradient(circle, var(--accent) 0%, transparent 68%);
  opacity: 0.45;
  pointer-events: none;
}
.contact-inner { padding: 100px 0; position: relative; z-index: 2; }
.contact .sec-tag { color: #F2B79E; }
.contact h2 { font-size: clamp(36px, 6vw, 68px); color: #fff; max-width: 14ch; }
.contact h2 .em { color: var(--accent); font-style: italic; }
.contact .lead { color: rgba(247,241,232,0.72); font-size: 20px; max-width: 40ch; margin-top: 26px; }
.contact-actions { display: flex; gap: 14px; margin-top: 40px; flex-wrap: wrap; }
.contact .btn-light { background: var(--accent); color: #fff; }
.contact .btn-light:hover { background: #cf4a25; }
.contact .btn-ghost { color: var(--bg); border-color: rgba(247,241,232,0.25); }
.contact .btn-ghost:hover { border-color: var(--bg); background: rgba(247,241,232,0.06); }
.contact-links { display: flex; gap: 36px; margin-top: 56px; flex-wrap: wrap; padding-top: 40px; border-top: 1px solid rgba(247,241,232,0.14); }
.clink { display: flex; align-items: center; gap: 14px; }
.clink .ic { width: 44px; height: 44px; border-radius: 13px; display: grid; place-items: center; background: rgba(247,241,232,0.08); color: #F2B79E; }
.clink .ic svg { width: 20px; height: 20px; }
.clink .t small { display: block; font-size: 12px; color: rgba(247,241,232,0.5); }
.clink .t b { font-weight: 600; font-size: 16px; }
.clink:hover .ic { background: var(--accent); color: #fff; }

/* ---------- footer ---------- */
.foot { padding: 50px 0 60px; }
.foot-inner { display: flex; align-items: center; justify-content: space-between; gap: 20px; flex-wrap: wrap; }
.foot small { color: var(--ink-soft); font-size: 14px; }
.foot-soc { display: flex; gap: 10px; }
.foot-soc a { width: 40px; height: 40px; border-radius: 11px; display: grid; place-items: center; border: 1px solid var(--line); color: var(--ink-soft); transition: all .25s; }
.foot-soc a:hover { background: var(--ink); color: var(--bg); border-color: var(--ink); transform: translateY(-3px); }
.foot-soc a svg { width: 18px; height: 18px; }

/* ---------- reveal (transform-only entrance — never hides content) ---------- */
.reveal { opacity: 1; }
@media (prefers-reduced-motion: no-preference) {
  .reveal { transform: translateY(22px); transition: transform .7s var(--ease); }
  .reveal.in { transform: none; }
}

/* ---------- responsive ---------- */
@media (max-width: 940px) {
  .wrap { padding: 0 24px; }
  .nav-links { display: none; }
  .hero-grid { grid-template-columns: 1fr; gap: 48px; }
  body[data-hero="overlap"] .hero-figure { margin-top: 24px; justify-self: center; }
  .about-grid { grid-template-columns: 1fr; gap: 40px; }
  .about-photo { max-width: 420px; }
  .services-grid { grid-template-columns: 1fr; }
  .case { grid-template-columns: 1fr; }
  .case:nth-child(even) .case-visual { order: 0; }
  .case-visual { min-height: 280px; }
  .case-body { padding: 36px 30px; }
  .sec { padding: 80px 0; }
  .contact { margin: 0 14px; }
}
@media (max-width: 560px) {
  body { font-size: 16px; }
  .wrap { padding: 0 18px; }
  .nav-cta { display: none; }
  .hero-badge { display: none; }
  .hero-cta .btn { flex: 1; justify-content: center; }
  .about-stats { gap: 28px; }
  .case-body { padding: 30px 22px; }
  .contact-inner { padding: 64px 0; }
}
