/* ============================================================
   Heianui Tapare — Portfolio
   Palette : abysse tropical (teal profond, or bronze, corail)
   ============================================================ */

:root {
  --bg: #071B1D;
  --bg-alt: #0F2B2A;
  --bg-alt-2: #123634;
  --panel-border: rgba(199, 154, 75, 0.22);
  --ink: #F1EAD9;
  --ink-dim: #B9C9C6;
  --ink-faint: #7C948F;
  --gold: #C79A4B;
  --gold-soft: #E4C486;
  --teal: #3FBFAE;
  --coral: #E2724A;

  --font-display: "Fraunces", "Iowan Old Style", serif;
  --font-body: "Space Grotesk", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;

  --container: 1120px;
  --radius: 4px;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  * { animation-duration: 0.001ms !important; animation-iteration-count: 1 !important; transition-duration: 0.001ms !important; }
}

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

h1, h2, h3 {
  font-family: var(--font-display);
  font-weight: 500;
  line-height: 1.12;
  margin: 0 0 0.5em;
  color: var(--ink);
}

h2 { font-size: clamp(1.9rem, 3.4vw, 2.7rem); font-weight: 400; letter-spacing: -0.01em; }
h3 { font-size: 1.3rem; font-weight: 600; }

p { margin: 0 0 1em; color: var(--ink-dim); max-width: 62ch; }

a { color: var(--teal); }

.skip-link {
  position: absolute;
  left: -999px;
  top: 0;
  background: var(--gold);
  color: var(--bg);
  padding: 0.6em 1em;
  z-index: 999;
}
.skip-link:focus { left: 1em; top: 1em; }

:focus-visible {
  outline: 2px solid var(--teal);
  outline-offset: 3px;
}

/* Background atoll texture */
.atoll-bg {
  position: fixed;
  inset: 0;
  z-index: -1;
  background:
    radial-gradient(ellipse 900px 500px at 12% -10%, rgba(63, 191, 174, 0.10), transparent 60%),
    radial-gradient(ellipse 700px 600px at 105% 20%, rgba(199, 154, 75, 0.09), transparent 55%),
    var(--bg);
}

.section-inner {
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 1.75rem;
}

/* ---------- Header ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  backdrop-filter: blur(10px);
  background: rgba(7, 27, 29, 0.82);
  border-bottom: 1px solid var(--panel-border);
}

.header-inner {
  max-width: var(--container);
  margin: 0 auto;
  padding: 0.9rem 1.75rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.mark {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  text-decoration: none;
  color: var(--ink);
}

.mark-glyph {
  font-family: var(--font-display);
  font-size: 1.4rem;
  width: 2.1rem;
  height: 2.1rem;
  display: grid;
  place-items: center;
  border: 1px solid var(--gold);
  border-radius: 50%;
  color: var(--gold-soft);
}
.mark-glyph.small { width: 1.6rem; height: 1.6rem; font-size: 1rem; margin-right: 0.5rem; }

.mark-text { font-family: var(--font-display); font-size: 1.05rem; letter-spacing: 0.01em; }

.primary-nav {
  display: flex;
  align-items: center;
  gap: 2rem;
}

.primary-nav a {
  color: var(--ink-dim);
  text-decoration: none;
  font-size: 0.95rem;
  position: relative;
  padding: 0.3rem 0;
}
.primary-nav a:hover { color: var(--ink); }
.primary-nav a.is-active { color: var(--gold-soft); }
.primary-nav a.is-active::after { transform: scaleX(1); background: var(--gold); }
.primary-nav a::after {
  content: "";
  position: absolute;
  left: 0; right: 0; bottom: -2px;
  height: 1px;
  background: var(--teal);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.25s ease;
}
.primary-nav a:hover::after { transform: scaleX(1); }

.nav-cta {
  color: var(--gold-soft) !important;
  border: 1px solid var(--gold);
  border-radius: var(--radius);
  padding: 0.45rem 1rem !important;
}
.nav-cta::after { display: none; }

.nav-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 0.5rem;
}
.nav-toggle span {
  width: 22px;
  height: 2px;
  background: var(--ink);
  display: block;
}

/* ---------- Hero ---------- */
.hero {
  position: relative;
  padding: 6.5rem 1.75rem 8rem;
  overflow: hidden;
}

.hero-inner {
  max-width: 760px;
  margin: 0 auto;
  text-align: center;
  position: relative;
  z-index: 2;
}

.hero-kicker {
  font-size: 0.85rem;
  letter-spacing: 0.06em;
  color: var(--teal);
  margin-bottom: 1.2rem;
}

.hero-title {
  font-size: clamp(2.3rem, 5.2vw, 3.6rem);
  font-weight: 400;
  letter-spacing: -0.015em;
}

.hero-lede {
  font-size: 1.1rem;
  max-width: 54ch;
  margin: 0 auto 2.2rem;
}

.hero-actions {
  display: flex;
  gap: 1rem;
  justify-content: center;
  flex-wrap: wrap;
}

.btn {
  display: inline-block;
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 0.95rem;
  text-decoration: none;
  padding: 0.85rem 1.7rem;
  border-radius: var(--radius);
  border: 1px solid transparent;
  cursor: pointer;
  transition: transform 0.15s ease, background 0.15s ease, border-color 0.15s ease;
}
.btn-primary {
  background: var(--coral);
  color: #fff;
}
.btn-primary:hover { background: #ec8763; transform: translateY(-1px); }
.btn-ghost {
  color: var(--ink);
  border-color: rgba(241, 234, 217, 0.35);
}
.btn-ghost:hover { border-color: var(--gold); color: var(--gold-soft); }
.btn-block { width: 100%; text-align: center; }

.hero-contour {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  z-index: 1;
  opacity: 0.55;
}
.contour {
  fill: none;
  stroke-width: 1.2;
}
.c1 { stroke: rgba(63, 191, 174, 0.45); }
.c2 { stroke: rgba(199, 154, 75, 0.35); }
.c3 { stroke: rgba(226, 114, 74, 0.25); }
.nodes circle { fill: var(--gold-soft); opacity: 0.7; }

/* ---------- Sections ---------- */
.section { padding: 6rem 0; }
.section-lede { font-size: 1.05rem; max-width: 58ch; margin-bottom: 3rem; }

/* Story */
.story-grid {
  display: grid;
  grid-template-columns: 0.85fr 1.15fr;
  gap: 4rem;
  align-items: start;
}

.story-visual {
  position: sticky;
  top: 6.5rem;
}

.visual-card {
  background: linear-gradient(160deg, var(--bg-alt), var(--bg-alt-2));
  border: 1px solid var(--panel-border);
  border-radius: var(--radius);
  padding: 2.5rem 2rem;
  display: flex;
  flex-direction: column;
  gap: 0.15rem;
}

.visual-line {
  font-family: var(--font-display);
  font-size: 1.5rem;
  line-height: 1.25;
  color: var(--ink);
}
.visual-line.accent { color: var(--gold-soft); }
.visual-line.small { font-size: 1rem; color: var(--ink-faint); margin: 0.2rem 0; }

.visual-tag {
  margin-top: 1.5rem;
  font-size: 0.85rem;
  color: var(--teal);
  border-top: 1px solid var(--panel-border);
  padding-top: 1.2rem;
}

.story-text p { max-width: 60ch; }
.story-text em { color: var(--gold-soft); font-style: normal; }

/* Timeline */
.timeline {
  list-style: none;
  margin: 0;
  padding: 0;
  position: relative;
}
.timeline::before {
  content: "";
  position: absolute;
  left: 9px;
  top: 6px;
  bottom: 6px;
  width: 1px;
  background: linear-gradient(var(--gold), var(--teal));
  opacity: 0.4;
}

.tl-item {
  position: relative;
  padding-left: 2.75rem;
  margin-bottom: 2.75rem;
}
.tl-item:last-child { margin-bottom: 0; }

.tl-marker {
  position: absolute;
  left: 0;
  top: 6px;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  border: 1px solid var(--gold);
  background: var(--bg);
}
.tl-marker::after {
  content: "";
  position: absolute;
  inset: 5px;
  border-radius: 50%;
  background: var(--teal);
}

.tl-phase {
  display: inline-block;
  font-size: 0.78rem;
  color: var(--coral);
  margin-bottom: 0.35rem;
}

.tl-content h3 { margin-bottom: 0.4rem; }
.tl-content p { margin-bottom: 0.6rem; }

.tl-link {
  font-size: 0.9rem;
  text-decoration: none;
  border-bottom: 1px solid rgba(63, 191, 174, 0.4);
}
.tl-link:hover { border-color: var(--teal); }

/* Tarifs */
.pricing-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1.25rem;
}

.price-card {
  background: var(--bg-alt);
  border: 1px solid var(--panel-border);
  border-radius: var(--radius);
  padding: 1.9rem 1.5rem;
  display: flex;
  flex-direction: column;
}

.price-card.featured {
  border-color: var(--gold);
  background: linear-gradient(165deg, var(--bg-alt-2), var(--bg-alt));
  box-shadow: 0 0 0 1px var(--gold) inset;
}

.price-card.devis {
  background: var(--bg);
  border-color: rgba(226, 114, 74, 0.35);
}

.price-eyebrow {
  font-family: var(--font-display);
  font-size: 1.35rem;
  color: var(--ink);
  display: block;
}

.price-tag {
  font-size: 0.85rem;
  color: var(--ink-faint);
  margin-bottom: 1.3rem;
}

.price-amounts { margin-bottom: 1.4rem; }

.price-main, .price-sub {
  display: flex;
  align-items: baseline;
  gap: 0.4rem;
  flex-wrap: wrap;
  font-size: 0.95rem;
  color: var(--ink-dim);
  margin-bottom: 0.5rem;
}
.price-main strong { font-family: var(--font-display); font-size: 1.7rem; color: var(--gold-soft); font-weight: 500; }
.price-sub strong { font-family: var(--font-display); font-size: 1.15rem; color: var(--teal); font-weight: 500; }
.price-main span, .price-sub span {
  display: block;
  width: 100%;
  font-size: 0.78rem;
  color: var(--ink-faint);
}

.price-main.devis-main {
  font-family: var(--font-display);
  font-size: 1.6rem;
  color: var(--coral);
}
.price-devis-note { font-size: 0.85rem; color: var(--ink-faint); margin-top: 0.4rem; }

.price-features {
  list-style: none;
  margin: 0 0 1.5rem;
  padding: 0;
  flex-grow: 1;
}
.price-features li {
  font-size: 0.88rem;
  color: var(--ink-dim);
  padding-left: 1.2rem;
  position: relative;
  margin-bottom: 0.55rem;
}
.price-features li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.5em;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--teal);
}

.price-footline {
  font-size: 0.85rem;
  color: var(--ink-faint);
  border-top: 1px solid var(--panel-border);
  padding-top: 1rem;
  margin: 0;
  text-align: center;
}

.pricing-notes {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem 2rem;
  justify-content: center;
  margin: 3rem 0 0;
  padding: 1.5rem 0 0;
  border-top: 1px solid var(--panel-border);
}
.pricing-notes li {
  font-size: 0.85rem;
  color: var(--ink-faint);
}

/* Contact */
.contact-grid {
  display: grid;
  grid-template-columns: 0.9fr 1.1fr;
  gap: 4rem;
}

.contact-meta {
  margin-top: 2rem;
  display: flex;
  flex-direction: column;
  gap: 1.2rem;
}
.contact-meta dt {
  font-size: 0.78rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--teal);
  margin-bottom: 0.2rem;
}
.contact-meta dd {
  margin: 0;
  color: var(--ink-dim);
  font-size: 0.92rem;
}

.contact-form {
  background: var(--bg-alt);
  border: 1px solid var(--panel-border);
  border-radius: var(--radius);
  padding: 2rem;
  display: flex;
  flex-direction: column;
  gap: 1.1rem;
}

.field { display: flex; flex-direction: column; gap: 0.4rem; }
.field label { font-size: 0.85rem; color: var(--ink-dim); }
.field label span { color: var(--ink-faint); }

.field input,
.field textarea {
  background: var(--bg);
  border: 1px solid rgba(199, 154, 75, 0.25);
  border-radius: var(--radius);
  padding: 0.75rem 0.9rem;
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 0.95rem;
}
.field input:focus,
.field textarea:focus {
  border-color: var(--teal);
  outline: none;
}

.hp { position: absolute; left: -9999px; }

.form-status {
  font-size: 0.85rem;
  min-height: 1.2em;
  margin: 0;
}
.form-status.ok { color: var(--teal); }
.form-status.err { color: var(--coral); }

/* ---------- Footer ---------- */
.site-footer {
  border-top: 1px solid var(--panel-border);
  padding: 3rem 0;
}
.footer-inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.5rem;
  text-align: center;
  color: var(--ink-faint);
  font-size: 0.85rem;
}
.footer-inner > div:first-child {
  display: flex;
  align-items: center;
  color: var(--ink-dim);
  font-family: var(--font-display);
  font-size: 1rem;
  margin-bottom: 0.5rem;
}
.footer-legal { font-size: 0.78rem; }

/* ---------- Responsive ---------- */
@media (max-width: 860px) {
  .story-grid, .contact-grid { grid-template-columns: 1fr; gap: 2.5rem; }
  .story-visual { position: static; }
  .pricing-grid { grid-template-columns: repeat(2, 1fr); }

  .nav-toggle { display: flex; }
  .primary-nav {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: var(--bg-alt);
    border-bottom: 1px solid var(--panel-border);
    flex-direction: column;
    align-items: flex-start;
    padding: 1rem 1.75rem 1.5rem;
    gap: 1rem;
    display: none;
  }
  .primary-nav.open { display: flex; }
  .nav-cta { align-self: flex-start; }
}

@media (max-width: 560px) {
  .pricing-grid { grid-template-columns: 1fr; }
  .section { padding: 4rem 0; }
  .hero { padding: 5rem 1.25rem 6rem; }
}
