/* Palette tirée des visuels : costume olive, cheveux cuivre, chemise rose, bordeaux du logo */
:root {
  --bg: #1b120c;
  --bg-glow: #3a2414;
  --cream: #f4e6c8;
  --cream-dark: #e9d5ab;
  --ink: #2a1a10;
  --ink-soft: #6b4a32;
  --olive: #6f7a3a;
  --mustard: #d9a23b;
  --copper: #d0682c;
  --rust: #9c3b22;
  --wine: #7a1f24;
  --rose: #d98c94;
  --sky: #7fa6cf;
  --serif: "Iowan Old Style", "Palatino Linotype", Palatino, Georgia, serif;
  --sans: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}

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

html { -webkit-text-size-adjust: 100%; }

body {
  min-height: 100vh;
  min-height: 100dvh;
  background:
    radial-gradient(120% 60% at 50% 0%, var(--bg-glow) 0%, transparent 70%),
    var(--bg);
  color: var(--cream);
  font-family: var(--sans);
  line-height: 1.35;
  -webkit-font-smoothing: antialiased;
}

/* Grain de pellicule, SVG inline */
body::after {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  opacity: 0.09;
  background-image: url("data:image/svg+xml;utf8,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.9' numOctaves='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}

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

a:focus-visible,
button:focus-visible {
  outline: 3px solid var(--sky);
  outline-offset: 4px;
}

main {
  width: 100%;
  max-width: 480px;
  margin: 0 auto;
  padding:
    calc(16px + env(safe-area-inset-top))
    calc(16px + env(safe-area-inset-right))
    calc(40px + env(safe-area-inset-bottom))
    calc(16px + env(safe-area-inset-left));
}

/* ---------- Link in bio ---------- */

.bio {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding-top: calc(40px + env(safe-area-inset-top));
}

/* Anneaux 70s autour de la photo */
.avatar {
  width: 120px;
  height: 120px;
  border-radius: 50%;
  object-fit: cover;
  margin-top: 24px;
  box-shadow:
    0 0 0 4px var(--bg),
    0 0 0 9px var(--mustard),
    0 0 0 14px var(--copper),
    0 0 0 19px var(--rust),
    0 0 0 24px var(--rose);
}

.handle {
  margin-top: 44px;
  font-family: var(--serif);
  font-style: italic;
  font-weight: 700;
  font-size: 30px;
  text-shadow: 2px 2px 0 var(--copper), 4px 4px 0 var(--rust);
  overflow-wrap: anywhere;
  text-align: center;
}

.links {
  list-style: none;
  width: 100%;
  margin-top: 32px;
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.links a {
  --shadow: var(--mustard);
  display: flex;
  flex-direction: column;
  justify-content: center;
  width: 100%;
  min-height: 76px;
  padding: 14px 20px;
  background: var(--cream);
  border: 2px solid var(--ink);
  border-radius: 999px;
  box-shadow: 5px 5px 0 var(--shadow);
  color: var(--ink);
  text-decoration: none;
  text-align: center;
  -webkit-tap-highlight-color: transparent;
  transition: transform 0.08s ease, box-shadow 0.08s ease, background-color 0.15s ease;
}

.links li:nth-child(2) a { --shadow: var(--copper); }
.links li:nth-child(3) a { --shadow: var(--olive); }
.links li:nth-child(4) a { --shadow: var(--rose); }

.links a:active {
  transform: translate(4px, 4px);
  box-shadow: 1px 1px 0 var(--shadow);
  background: var(--cream-dark);
}

.title {
  font-family: var(--serif);
  font-size: 19px;
  font-weight: 700;
}

.desc {
  margin-top: 2px;
  font-size: 14px;
  color: var(--ink-soft);
}

.signature {
  margin-top: 40px;
  font-family: var(--serif);
  font-style: italic;
  font-size: 14px;
  color: var(--mustard);
  opacity: 0.8;
}

/* ---------- Pages produit ---------- */

.hero {
  border-radius: 14px;
  overflow: hidden;
  background: #cfc6ba; /* même ton que le fond des mockups pendant le chargement */
}

.hero img { width: 100%; }

.design-name {
  margin-top: 20px;
  font-family: var(--serif);
  font-style: italic;
  font-weight: 700;
  font-size: 26px;
  line-height: 1.2;
}

.price {
  margin-top: 6px;
  font-family: var(--serif);
  font-weight: 700;
  font-size: 34px;
  color: var(--mustard);
}

.cta {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  min-height: 60px;
  margin-top: 18px;
  padding: 14px 20px;
  background: var(--cream);
  border: 2px solid var(--ink);
  border-radius: 999px;
  box-shadow: 5px 5px 0 var(--copper);
  color: var(--ink);
  font-family: var(--serif);
  font-weight: 700;
  font-size: 21px;
  text-decoration: none;
  -webkit-tap-highlight-color: transparent;
  transition: transform 0.08s ease, box-shadow 0.08s ease, background-color 0.15s ease;
}

.cta:active {
  transform: translate(4px, 4px);
  box-shadow: 1px 1px 0 var(--copper);
  background: var(--cream-dark);
}

.others-title {
  margin-top: 40px;
  font-family: var(--serif);
  font-style: italic;
  font-size: 18px;
  color: var(--cream-dark);
}

.grid {
  list-style: none;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  margin-top: 12px;
}

.grid button {
  display: block;
  width: 100%;
  min-height: 48px;
  padding: 0;
  border: 2px solid transparent;
  border-radius: 12px;
  overflow: hidden;
  background: #cfc6ba;
  cursor: pointer;
  font: inherit;
  color: inherit;
  text-align: left;
  -webkit-tap-highlight-color: transparent;
}

.grid button[aria-pressed="true"] {
  border-color: var(--mustard);
  box-shadow: 0 0 0 2px var(--mustard);
}

.grid img {
  width: 100%;
  aspect-ratio: var(--thumb-ratio, 2 / 1);
  object-fit: cover;
}

.grid span {
  display: block;
  padding: 8px 10px;
  background: var(--bg-glow);
  color: var(--cream);
  font-size: 13px;
  line-height: 1.25;
}

.back {
  display: inline-flex;
  align-items: center;
  min-height: 48px;
  margin-top: 28px;
  color: var(--mustard);
  font-family: var(--serif);
  font-style: italic;
  font-size: 16px;
  text-decoration: none;
}

/* ---------- Merci ---------- */

.thanks {
  padding-top: calc(56px + env(safe-area-inset-top));
}

.thanks p {
  font-family: var(--serif);
  font-size: 22px;
  line-height: 1.4;
}

.tally {
  margin-top: 28px;
  padding: 8px 12px;
  background: var(--cream);
  border-radius: 14px;
}

.tally iframe {
  display: block;
  width: 100%;
  height: 230px;
  border: 0;
}

@media (hover: hover) {
  .links a:hover,
  .cta:hover { background: var(--cream-dark); }
  .grid button:hover { border-color: var(--cream-dark); }
}
