/* ============================================================
   SENYU — Comportementaliste félin
   Système visuel partagé · éditorial / premium / serein
   ============================================================ */

/* ---- Tokens (overridden live by the Tweaks panel) ---- */
:root {
  --bg:        #F2ECE1;
  --surface:   #F8F3EB;
  --surface-2: #ECE4D5;
  --ink:       #211C16;
  --ink-soft:  #57503F;
  --ink-faint: #8C8472;
  --line:      rgba(33,28,22,0.14);
  --line-2:    rgba(33,28,22,0.08);

  --accent:      #B0664A;
  --accent-deep: #8F4E36;
  --accent-tint: rgba(176,102,74,0.10);
  --on-accent:   #F7F0E6;

  --radius: 20px;
  --radius-s: 12px;

  --serif: 'Newsreader', Georgia, 'Times New Roman', serif;
  --sans:  'Hanken Grotesk', system-ui, -apple-system, sans-serif;

  --shadow-card: 0 28px 60px -34px rgba(33,28,22,0.42);
  --shadow-soft: 0 18px 44px -28px rgba(33,28,22,0.30);
  --ease: cubic-bezier(.22,.61,.36,1);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 17px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}
img { max-width: 100%; display: block; }
a { color: inherit; }
::selection { background: var(--accent); color: var(--on-accent); }

/* Page grain overlay */
.grain {
  position: fixed; inset: 0; pointer-events: none; z-index: 1; opacity: .5; mix-blend-mode: multiply;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='180' height='180'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.8' numOctaves='2' stitchTiles='stitch'/%3E%3CfeColorMatrix type='saturate' values='0'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='0.05'/%3E%3C/svg%3E");
}

/* ---- Layout ---- */
.wrap { width: min(1240px, 92vw); margin: 0 auto; }
.wrap-n { width: min(1040px, 90vw); margin: 0 auto; }
section { position: relative; z-index: 2; }
.pad { padding: clamp(70px, 9vw, 132px) 0; }
.pad-t { padding-top: clamp(70px, 9vw, 132px); }

/* ---- Typography ---- */
.eyebrow {
  font-size: 12px; letter-spacing: .26em; text-transform: uppercase;
  font-weight: 600; color: var(--accent);
  display: inline-flex; align-items: center; gap: 12px;
}
.eyebrow::before { content: ""; width: 26px; height: 1px; background: var(--accent); opacity: .7; }
.eyebrow.center::before { display: none; }

h1, h2, h3 { font-family: var(--serif); font-weight: 400; letter-spacing: -0.018em; margin: 0; }
.display { font-size: clamp(46px, 6.4vw, 92px); line-height: 0.98; font-weight: 380; }
h2.title { font-size: clamp(34px, 4.4vw, 62px); line-height: 1.04; }
h3 { font-size: clamp(21px, 2vw, 27px); line-height: 1.18; }
em.acc { font-style: italic; color: var(--accent); }
.lead { font-size: clamp(17px, 1.4vw, 20px); line-height: 1.62; color: var(--ink-soft); }
.muted { color: var(--ink-soft); }
.faint { color: var(--ink-faint); }
.serif-it { font-family: var(--serif); font-style: italic; }

.section-head { max-width: 640px; }
.section-head h2 { margin-top: 18px; }
.section-head p { margin-top: 20px; }
.section-head.center { margin-left: auto; margin-right: auto; text-align: center; }
.section-head.center .eyebrow { justify-content: center; }

/* ---- Buttons ---- */
.btn {
  --c: var(--ink); --t: var(--bg);
  display: inline-flex; align-items: center; gap: 10px;
  font-family: var(--sans); font-size: 14.5px; font-weight: 500; letter-spacing: .015em;
  padding: 15px 26px; border-radius: 100px; border: 1px solid var(--c);
  background: var(--c); color: var(--t); cursor: pointer; text-decoration: none;
  transition: transform .35s var(--ease), background .35s var(--ease), color .35s var(--ease), box-shadow .35s var(--ease);
  white-space: nowrap;
}
.btn:hover { transform: translateY(-2px); box-shadow: var(--shadow-soft); }
.btn .arr { transition: transform .35s var(--ease); }
.btn:hover .arr { transform: translateX(4px); }
.btn-accent { --c: var(--accent); --t: var(--on-accent); border-color: var(--accent); }
.btn-ghost { background: transparent; color: var(--ink); border-color: var(--line); }
.btn-ghost:hover { background: var(--ink); color: var(--bg); border-color: var(--ink); }
.link-line {
  display: inline-flex; align-items: center; gap: 8px; text-decoration: none;
  font-size: 14.5px; font-weight: 500; color: var(--ink); padding-bottom: 3px;
  border-bottom: 1px solid var(--accent);
  transition: gap .3s var(--ease);
}
.link-line:hover { gap: 13px; }
.link-line .arr { color: var(--accent); }

/* ---- Header / Nav ---- */
.nav {
  position: fixed; top: 0; left: 0; right: 0; z-index: 50;
  display: flex; align-items: center; justify-content: space-between;
  padding: 20px clamp(20px, 4vw, 56px);
  transition: background .4s var(--ease), padding .4s var(--ease), box-shadow .4s var(--ease), border-color .4s var(--ease);
  border-bottom: 1px solid transparent;
}
.nav.solid {
  background: color-mix(in srgb, var(--bg) 82%, transparent);
  -webkit-backdrop-filter: blur(16px) saturate(140%); backdrop-filter: blur(16px) saturate(140%);
  border-bottom: 1px solid var(--line-2); padding-top: 14px; padding-bottom: 14px;
}
.brand { display: flex; align-items: center; gap: 13px; text-decoration: none; color: var(--ink); }
.brand .mark { width: 38px; height: 38px; flex: none; }
.brand .mark svg { width: 100%; height: 100%; display: block; }
.brand .name { display: flex; flex-direction: column; line-height: 1; }
.brand .name .over { font-size: 9.5px; letter-spacing: .26em; text-transform: uppercase; color: var(--ink-faint); margin-bottom: 4px; font-family: var(--sans); font-weight: 600; }
.brand .name b { font-family: var(--serif); font-weight: 500; font-size: 23px; letter-spacing: .01em; line-height: .9; }
.brand .name span { font-size: 9.5px; letter-spacing: .22em; text-transform: uppercase; color: var(--ink-faint); margin-top: 4px; }
.nav-links { display: flex; align-items: center; gap: 32px; }
.nav-links a { text-decoration: none; font-size: 14.5px; color: var(--ink); opacity: .82; position: relative; padding: 6px 0; transition: opacity .25s; }
.nav-links a::after { content: ""; position: absolute; left: 0; bottom: 0; height: 1px; width: 0; background: var(--accent); transition: width .3s var(--ease); }
.nav-links a:hover { opacity: 1; }
.nav-links a:hover::after, .nav-links a.active::after { width: 100%; }
.nav-links a.active { opacity: 1; }
.nav-right { display: flex; align-items: center; gap: 22px; }
.nav-cta { padding: 11px 20px; font-size: 13.5px; }
.burger { display: none; width: 42px; height: 42px; border: 1px solid var(--line); border-radius: 50%; background: transparent; cursor: pointer; position: relative; }
.burger i { position: absolute; left: 11px; right: 11px; height: 1.4px; background: var(--ink); transition: .3s var(--ease); }
.burger i:nth-child(1){ top: 16px; } .burger i:nth-child(2){ bottom: 16px; }
.burger.open i:nth-child(1){ top: 20px; transform: rotate(45deg); }
.burger.open i:nth-child(2){ bottom: 20px; transform: rotate(-45deg); }

/* Mobile menu */
.mobile-menu { position: fixed; inset: 0; z-index: 49; background: var(--bg); display: flex; flex-direction: column; justify-content: center; padding: 0 8vw; transform: translateY(-100%); transition: transform .5s var(--ease); }
.mobile-menu.open { transform: translateY(0); }
.mobile-menu a { font-family: var(--serif); font-size: 38px; text-decoration: none; color: var(--ink); padding: 14px 0; border-bottom: 1px solid var(--line-2); display: flex; justify-content: space-between; align-items: center; }
.mobile-menu a .n { font-family: var(--sans); font-size: 13px; color: var(--ink-faint); }

/* ---- Placeholder media ---- */
.ph {
  position: relative; overflow: hidden; background:
    radial-gradient(120% 95% at 68% 18%, #CBAA8B 0%, #AB7A5C 44%, #6E4A38 100%);
}
.ph::after { content: attr(data-label); position: absolute; left: 18px; bottom: 15px; font-size: 10px; letter-spacing: .2em; text-transform: uppercase; color: rgba(255,255,255,0.6); }
.ph .gr { position: absolute; inset: 0; mix-blend-mode: overlay; opacity: .5;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='120' height='120'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E"); }
.ph.sage { background: radial-gradient(120% 95% at 68% 18%, #AEB69A 0%, #7E876E 46%, #4C5340 100%); }
.ph.slate { background: radial-gradient(120% 95% at 68% 18%, #9BB0C2 0%, #6C879C 46%, #3C4F5E 100%); }

/* ---- Cards / grids ---- */
.grid { display: grid; gap: clamp(16px, 1.6vw, 24px); }
.card {
  background: var(--surface); border: 1px solid var(--line-2); border-radius: var(--radius);
  padding: clamp(24px, 2.4vw, 34px); position: relative; overflow: hidden;
  transition: transform .45s var(--ease), box-shadow .45s var(--ease), border-color .45s var(--ease);
}
.card:hover { transform: translateY(-5px); box-shadow: var(--shadow-card); border-color: var(--line); }

/* Problématique card */
.case { display: flex; flex-direction: column; gap: 14px; min-height: 196px; }
.case .num { font-family: var(--serif); font-style: italic; font-size: 15px; color: var(--ink-faint); }
.case .ico { width: 40px; height: 40px; color: var(--accent); }
.case .ico svg { width: 100%; height: 100%; }
.case h3 { font-size: 22px; }
.case p { font-size: 14.5px; color: var(--ink-soft); line-height: 1.55; margin: 0; }
.case .tail { margin-top: auto; font-size: 12.5px; letter-spacing: .04em; color: var(--accent); display: flex; align-items: center; gap: 7px; opacity: 0; transform: translateX(-6px); transition: .35s var(--ease); }
.card:hover .case .tail { opacity: 1; transform: translateX(0); }

/* ---- Footer ---- */
.footer { position: relative; z-index: 2; background: var(--ink); color: var(--bg); padding: clamp(64px, 7vw, 100px) 0 40px; }
.footer a { color: inherit; text-decoration: none; opacity: .72; transition: opacity .25s; }
.footer a:hover { opacity: 1; }
.footer-top { display: grid; grid-template-columns: 1.6fr 1fr 1fr 1.1fr; gap: 40px; }
.footer .f-brand b { font-family: var(--serif); font-size: 30px; }
.footer .f-brand p { color: rgba(255,255,255,.6); max-width: 280px; margin: 18px 0 0; font-size: 15px; }
.footer h4 { font-family: var(--sans); font-size: 11px; letter-spacing: .18em; text-transform: uppercase; color: rgba(255,255,255,.45); font-weight: 600; margin: 0 0 18px; }
.footer ul { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 11px; font-size: 15px; }
.footer-bottom { margin-top: clamp(48px, 6vw, 80px); padding-top: 26px; border-top: 1px solid rgba(255,255,255,.14); display: flex; justify-content: space-between; align-items: center; gap: 20px; font-size: 12.5px; color: rgba(255,255,255,.5); flex-wrap: wrap; }

/* ---- Reveal animation ---- */
.reveal { opacity: 0; transform: translateY(26px); transition: opacity .9s var(--ease), transform .9s var(--ease); }
.reveal.in { opacity: 1; transform: none; }
.reveal[data-d="1"]{ transition-delay: .08s; }
.reveal[data-d="2"]{ transition-delay: .16s; }
.reveal[data-d="3"]{ transition-delay: .24s; }
.reveal[data-d="4"]{ transition-delay: .32s; }
.reveal[data-d="5"]{ transition-delay: .40s; }
@media (prefers-reduced-motion: reduce) { .reveal { opacity: 1 !important; transform: none !important; } html { scroll-behavior: auto; } }

/* ---- Dark ambiance adjustments ---- */
[data-dark="true"] .grain { mix-blend-mode: screen; opacity: .35; }
[data-dark="true"] .ph { background: radial-gradient(120% 95% at 68% 18%, #6E5848 0%, #4A3A2E 46%, #2A2018 100%); }

/* ---- Shared interior page hero ---- */
.page-hero { padding: clamp(140px, 18vh, 210px) 0 clamp(40px, 5vw, 70px); position: relative; }
.page-hero .eyebrow { margin-bottom: 22px; }
.page-hero h1 { font-size: clamp(44px, 6vw, 84px); line-height: 1; }
.page-hero .lead { margin-top: 26px; max-width: 600px; }
.page-hero.center { text-align: center; }
.page-hero.center .eyebrow { justify-content: center; }
.page-hero.center .lead { margin-left: auto; margin-right: auto; }
.crumbs { font-size: 12.5px; letter-spacing: .04em; color: var(--ink-faint); margin-bottom: 26px; display: flex; gap: 8px; align-items: center; }
.crumbs a { text-decoration: none; color: var(--ink-faint); } .crumbs a:hover { color: var(--accent); }
.crumbs .sep { opacity: .5; }
.divider { height: 1px; background: var(--line); border: 0; margin: 0; }

/* ---- Marquee ---- */
.marquee { overflow: hidden; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); padding: 20px 0; }
.marquee-track { display: flex; gap: 54px; width: max-content; animation: mq 34s linear infinite; }
.marquee:hover .marquee-track { animation-play-state: paused; }
.marquee-track span { font-family: var(--serif); font-size: 22px; color: var(--ink-soft); display: inline-flex; align-items: center; gap: 54px; white-space: nowrap; }
.marquee-track span::after { content: "·"; color: var(--accent); }
@keyframes mq { to { transform: translateX(-50%); } }

/* ---- Pricing ---- */
.price-card { display: flex; flex-direction: column; gap: 20px; }
.price-card.featured { background: var(--ink); color: var(--bg); border-color: var(--ink); }
.price-card.featured .muted, .price-card.featured .faint { color: rgba(255,255,255,.62); }
.price-card .tag { font-size: 11px; letter-spacing: .16em; text-transform: uppercase; color: var(--accent); font-weight: 600; }
.price-card.featured .tag { color: var(--on-accent); background: var(--accent); padding: 4px 10px; border-radius: 100px; align-self: flex-start; }
.price-card .amount { font-family: var(--serif); font-size: 46px; line-height: 1; }
.price-card .amount small { font-size: 15px; font-family: var(--sans); color: var(--ink-faint); }
.price-card.featured .amount small { color: rgba(255,255,255,.6); }
.price-card ul { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 12px; font-size: 14.5px; }
.price-card li { display: flex; gap: 11px; align-items: flex-start; color: var(--ink-soft); }
.price-card.featured li { color: rgba(255,255,255,.78); }
.price-card li::before { content: ""; flex: none; width: 17px; height: 17px; margin-top: 3px; background: var(--accent);
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 14 14'%3E%3Cpath d='M2.4 7.3l2.7 2.7L11.6 4' fill='none' stroke='black' stroke-width='1.7' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center/contain no-repeat;
  mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 14 14'%3E%3Cpath d='M2.4 7.3l2.7 2.7L11.6 4' fill='none' stroke='black' stroke-width='1.7' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center/contain no-repeat; }

/* ---- Steps / timeline ---- */
.steps { display: grid; gap: 2px; }
.step { display: grid; grid-template-columns: 88px 1fr; gap: clamp(20px, 3vw, 48px); padding: clamp(26px, 3vw, 42px) 0; border-top: 1px solid var(--line); align-items: start; }
.step:last-child { border-bottom: 1px solid var(--line); }
.step .idx { font-family: var(--serif); font-size: clamp(34px, 4vw, 52px); color: var(--accent); line-height: 1; }
.step h3 { margin-bottom: 10px; }
.step p { margin: 0; color: var(--ink-soft); max-width: 560px; }
.step:hover .idx { transform: translateY(-3px); transition: transform .4s var(--ease); }

/* ---- Accordion (FAQ) ---- */
.acc { border-top: 1px solid var(--line); }
.acc-item { border-bottom: 1px solid var(--line); }
.acc-q { width: 100%; text-align: left; background: none; border: none; cursor: pointer; padding: 26px 0; display: flex; justify-content: space-between; align-items: center; gap: 24px; font-family: var(--serif); font-size: clamp(19px, 2vw, 25px); color: var(--ink); }
.acc-q .pm { flex: none; width: 26px; height: 26px; position: relative; }
.acc-q .pm::before, .acc-q .pm::after { content: ""; position: absolute; background: var(--accent); transition: transform .3s var(--ease); }
.acc-q .pm::before { left: 0; right: 0; top: 12.5px; height: 1.5px; }
.acc-q .pm::after { top: 0; bottom: 0; left: 12.5px; width: 1.5px; }
.acc-item.open .pm::after { transform: scaleY(0); }
.acc-a { max-height: 0; overflow: hidden; transition: max-height .45s var(--ease); }
.acc-a div { padding: 0 0 28px; color: var(--ink-soft); max-width: 760px; }

/* ---- Form ---- */
.field { display: flex; flex-direction: column; gap: 8px; }
.field label { font-size: 12.5px; letter-spacing: .04em; color: var(--ink-soft); font-weight: 500; }
.field input, .field select, .field textarea {
  font-family: var(--sans); font-size: 15.5px; color: var(--ink);
  background: var(--surface); border: 1px solid var(--line); border-radius: 12px;
  padding: 14px 16px; outline: none; transition: border-color .25s, box-shadow .25s; width: 100%;
}
.field textarea { resize: vertical; min-height: 130px; }
.field input:focus, .field select:focus, .field textarea:focus { border-color: var(--accent); box-shadow: 0 0 0 4px var(--accent-tint); }
.field.err input, .field.err select, .field.err textarea { border-color: #C0563E; box-shadow: 0 0 0 4px rgba(192,86,62,.12); }
.field .msg { font-size: 12px; color: #C0563E; min-height: 14px; }
.chip-row { display: flex; flex-wrap: wrap; gap: 9px; }
.chip { font-size: 13px; padding: 8px 15px; border: 1px solid var(--line); border-radius: 100px; cursor: pointer; user-select: none; transition: .25s var(--ease); background: var(--surface); }
.chip.on { background: var(--accent); color: var(--on-accent); border-color: var(--accent); }

/* ---- Stat block ---- */
.stat .n { font-family: var(--serif); font-size: clamp(38px, 4vw, 54px); line-height: 1; }
.stat .l { font-size: 13px; letter-spacing: .03em; color: var(--ink-faint); margin-top: 8px; }

/* ============================================================
   TWEAKS PANEL (vanilla)
   ============================================================ */
#senyu-tweaks { position: fixed; right: 18px; bottom: 18px; z-index: 2147483646; width: 270px;
  background: color-mix(in srgb, var(--surface) 88%, transparent);
  -webkit-backdrop-filter: blur(22px) saturate(150%); backdrop-filter: blur(22px) saturate(150%);
  border: 1px solid var(--line); border-radius: 16px; box-shadow: 0 18px 50px rgba(0,0,0,.22);
  font-family: var(--sans); color: var(--ink); overflow: hidden; display: none; }
#senyu-tweaks.show { display: block; }
.tw-hd { display: flex; align-items: center; justify-content: space-between; padding: 13px 12px 12px 16px; cursor: move; border-bottom: 1px solid var(--line-2); }
.tw-hd b { font-family: var(--serif); font-size: 16px; font-weight: 500; }
.tw-hd button { border: none; background: transparent; color: var(--ink-faint); width: 24px; height: 24px; border-radius: 6px; cursor: pointer; font-size: 15px; }
.tw-hd button:hover { background: var(--line-2); color: var(--ink); }
.tw-body { padding: 14px 16px 18px; display: flex; flex-direction: column; gap: 16px; max-height: 70vh; overflow-y: auto; }
.tw-sect { font-size: 10px; letter-spacing: .14em; text-transform: uppercase; color: var(--ink-faint); font-weight: 600; }
.tw-sw { display: grid; grid-template-columns: repeat(5, 1fr); gap: 8px; margin-top: 9px; }
.tw-sw button { aspect-ratio: 1; border-radius: 9px; border: 1px solid var(--line); cursor: pointer; position: relative; overflow: hidden; padding: 0; transition: transform .2s var(--ease); }
.tw-sw button:hover { transform: scale(1.06); }
.tw-sw button.on { box-shadow: 0 0 0 2px var(--bg), 0 0 0 4px var(--accent); }
.tw-sw button span { position: absolute; inset: 0; }
.tw-seg { display: flex; gap: 4px; margin-top: 9px; padding: 3px; background: var(--line-2); border-radius: 10px; }
.tw-seg button { flex: 1; border: none; background: transparent; padding: 8px 4px; border-radius: 7px; font-family: var(--sans); font-size: 12.5px; color: var(--ink-soft); cursor: pointer; transition: .2s; }
.tw-seg button.on { background: var(--surface); color: var(--ink); box-shadow: 0 1px 3px rgba(0,0,0,.12); }
.tw-name { font-size: 12px; color: var(--ink-faint); margin-top: 8px; }
.tw-cc { display: flex; align-items: center; gap: 10px; margin-top: 10px; padding: 7px 10px; border: 1px solid var(--line); border-radius: 9px; cursor: pointer; }
.tw-cc input[type="color"] { width: 26px; height: 26px; padding: 0; border: none; border-radius: 6px; background: none; cursor: pointer; flex: none; }
.tw-cc input[type="color"]::-webkit-color-swatch-wrapper { padding: 0; }
.tw-cc input[type="color"]::-webkit-color-swatch { border: 1px solid var(--line); border-radius: 6px; }
.tw-cc span { font-size: 12px; color: var(--ink-soft); }
.tw-cc .tw-hex { margin-left: auto; font-family: var(--serif); font-style: italic; color: var(--ink-faint); }
.tw-input { width: 100%; margin-top: 9px; font-family: var(--sans); font-size: 12.5px; color: var(--ink); background: var(--surface); border: 1px solid var(--line); border-radius: 9px; padding: 9px 11px; outline: none; transition: border-color .2s, box-shadow .2s; }
.tw-input:focus { border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-tint); }
.tw-input::placeholder { color: var(--ink-faint); }
.tw-reset { width: 100%; margin-top: 4px; font-family: var(--sans); font-size: 12px; letter-spacing: .04em; color: var(--ink-soft); background: transparent; border: 1px solid var(--line); border-radius: 9px; padding: 9px; cursor: pointer; transition: .2s; }
.tw-reset:hover { background: var(--ink); color: var(--bg); border-color: var(--ink); }

/* ============================================================
   RESPONSIVE
   ============================================================ */
@media (max-width: 980px) {
  .nav-links, .nav-right .nav-cta { display: none; }
  .burger { display: block; }
  .footer-top { grid-template-columns: 1fr 1fr; gap: 36px; }
}
@media (max-width: 680px) {
  body { font-size: 16px; }
  .footer-top { grid-template-columns: 1fr; }
  .step { grid-template-columns: 54px 1fr; }
}
