/* ============================================================
   EasyEPS · identité « papier » (brouillon du 28-10-2026)
   Feuilles posées, scotch, surligneur, stylo rouge du correcteur,
   post-it, schémas dessinés. Aucune photo : la matière, c'est le papier.
   ============================================================ */

@import url('https://fonts.googleapis.com/css2?family=Fraunces:opsz,wght@9..144,500;9..144,600;9..144,700;9..144,800&family=Inter:wght@400;500;600;700;800&family=Caveat:wght@500;600;700&display=swap');

:root {
  --papier: #F6F1E7;          /* le bureau */
  --feuille: #FFFDF8;         /* la feuille */
  --encre: #22262a;
  --encre-douce: #4b5157;
  --gris: #7a7f85;
  --teal: #1D8286;
  --teal-dark: #156265;
  --teal-light: #e3f1f1;
  --surligneur: #FFE27A;
  --surligneur-vert: #C9F0C2;
  --rouge: #C8452C;           /* stylo du correcteur */
  --bleu: #2C5DA8;            /* stylo bille */
  --ligne: #dbe5ee;           /* lignes de cahier */
  --marge: #f0b8b0;           /* marge rouge du cahier */
  --scotch: rgba(29,130,134,.20);
  --scotch-jaune: rgba(255,214,102,.55);
  --ombre: 0 1px 2px rgba(60,45,20,.06), 0 8px 24px rgba(60,45,20,.10);
  --ombre-forte: 0 2px 4px rgba(60,45,20,.08), 0 18px 40px rgba(60,45,20,.16);
  --titre: 'Fraunces', Georgia, serif;
  --corps: 'Inter', system-ui, sans-serif;
  --main: 'Caveat', 'Comic Sans MS', cursive;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0; color: var(--encre); font-family: var(--corps); font-size: 1.02rem; line-height: 1.7;
  background-color: var(--papier);
  /* grain du papier, très léger */
  background-image: url("data:image/svg+xml,%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%3CfeColorMatrix values='0 0 0 0 0.35 0 0 0 0 0.28 0 0 0 0 0.15 0 0 0 .05 0'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}
img { max-width: 100%; }
a { color: var(--teal-dark); }

/* ---------- typographie ---------- */
h1, h2, h3 { font-family: var(--titre); font-weight: 700; line-height: 1.15; letter-spacing: -.01em; margin: 0 0 .8rem; }
h1 { font-size: clamp(2.1rem, 5.2vw, 3.6rem); font-weight: 800; }
h2 { font-size: clamp(1.6rem, 3.6vw, 2.4rem); }
h3 { font-size: 1.25rem; }
p { margin: 0 0 1rem; }
.main { font-family: var(--main); font-weight: 600; }
.kicker { font-family: var(--main); font-size: 1.45rem; color: var(--rouge); transform: rotate(-2deg); display: inline-block; margin-bottom: .3rem; }
.lead { font-size: 1.15rem; color: var(--encre-douce); }

/* surligneur : un vrai trait de feutre, irrégulier */
.surligne {
  background: linear-gradient(100deg, transparent 0 1%, var(--surligneur) 2% 97%, transparent 99%) no-repeat 0 72% / 100% 46%;
  padding: 0 .12em; border-radius: 2px; box-decoration-break: clone; -webkit-box-decoration-break: clone;
}
.surligne.vert { background-image: linear-gradient(100deg, transparent 0 1%, var(--surligneur-vert) 2% 97%, transparent 99%); }
/* entouré au stylo rouge */
.entoure { position: relative; white-space: nowrap; }
.entoure::after {
  content: ''; position: absolute; inset: -.18em -.35em; border: 2.5px solid var(--rouge); border-radius: 50% 46% 52% 44% / 58% 50% 54% 46%;
  transform: rotate(-2deg); pointer-events: none; opacity: .85;
}
/* souligné à la main */
.souligne { background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 200 10' preserveAspectRatio='none'%3E%3Cpath d='M2 7 C 40 3, 90 9, 130 5 S 190 4, 198 6' fill='none' stroke='%23C8452C' stroke-width='3' stroke-linecap='round'/%3E%3C/svg%3E") no-repeat bottom / 100% .35em; padding-bottom: .1em; }

/* ---------- mise en page ---------- */
.wrap { max-width: 1120px; margin: 0 auto; padding: 0 1.5rem; }
.wrap-etroit { max-width: 760px; margin: 0 auto; padding: 0 1.5rem; }
.bloc { padding: 5rem 0; position: relative; }
.centre { text-align: center; }
.grille-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 2.5rem; align-items: center; }
.grille-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.6rem; }
.grille-4 { display: grid; grid-template-columns: repeat(4, 1fr); gap: 1.2rem; }

/* fonds de section */
.fond-carreaux {
  background-color: var(--feuille);
  background-image: linear-gradient(var(--ligne) 1px, transparent 1px), linear-gradient(90deg, var(--ligne) 1px, transparent 1px);
  background-size: 22px 22px; background-position: -1px -1px;
}
.fond-lignes {
  background-color: var(--feuille);
  background-image: linear-gradient(90deg, transparent 54px, var(--marge) 54px 56px, transparent 56px), repeating-linear-gradient(transparent 0 31px, var(--ligne) 31px 32px);
}
.fond-encre { background: #1f3b3c; color: #f4efe4; }
.fond-encre h2, .fond-encre h3 { color: #fff; }

/* ---------- la feuille ---------- */
.feuille {
  background: var(--feuille); border-radius: 3px; box-shadow: var(--ombre); padding: 1.6rem 1.6rem 1.4rem; position: relative;
}
.feuille.lignee { background-image: repeating-linear-gradient(transparent 0 27px, var(--ligne) 27px 28px); background-position: 0 14px; }
.feuille.coin::before { /* coin corné */
  content: ''; position: absolute; right: 0; top: 0; width: 26px; height: 26px;
  background: linear-gradient(225deg, var(--papier) 50%, #e9e1d0 50%); box-shadow: -2px 2px 3px rgba(0,0,0,.06);
}
.penche-g { transform: rotate(-1.6deg); }
.penche-d { transform: rotate(1.4deg); }
.penche-g2 { transform: rotate(-3deg); }
.penche-d2 { transform: rotate(2.6deg); }

/* scotch */
.scotch::after {
  content: ''; position: absolute; top: -11px; left: 50%; width: 92px; height: 24px; transform: translateX(-50%) rotate(-3deg);
  background: var(--scotch); border-left: 1px dashed rgba(255,255,255,.5); border-right: 1px dashed rgba(255,255,255,.5);
  box-shadow: 0 1px 1px rgba(0,0,0,.04);
}
.scotch.jaune::after { background: var(--scotch-jaune); }
.scotch.gauche::after { left: 18%; transform: translateX(-50%) rotate(-8deg); }
/* trombone */
.trombone::before {
  content: ''; position: absolute; top: -18px; right: 34px; width: 16px; height: 48px; border: 3px solid #9aa3aa; border-radius: 10px; transform: rotate(8deg); z-index: 2;
}

/* post-it */
.postit {
  background: #fff3a8; padding: 1.2rem 1.2rem 1.4rem; box-shadow: 0 10px 18px -8px rgba(60,45,20,.35); position: relative;
  font-family: var(--main); font-size: 1.35rem; line-height: 1.3; color: #3c3a2e;
}
.postit.rose { background: #ffd6dd; } .postit.vert { background: #d4f3d0; } .postit.bleu { background: #d5ebfb; }
.postit .signe { display: block; margin-top: .6rem; font-family: var(--corps); font-size: .82rem; color: #6b6450; font-weight: 600; }

/* note manuscrite dans la marge */
.annot { font-family: var(--main); color: var(--rouge); font-size: 1.3rem; line-height: 1.15; font-weight: 600; }
.annot.bleu { color: var(--bleu); }
.fleche { display: inline-block; width: 60px; height: 34px; vertical-align: middle; }

/* onglets de classeur */
.onglets { display: flex; gap: .4rem; flex-wrap: wrap; }
.onglet {
  background: var(--feuille); border: 1.5px solid var(--encre); border-bottom: none; border-radius: 10px 10px 0 0; padding: .55rem 1.1rem;
  font-weight: 700; text-decoration: none; color: var(--encre); font-size: .95rem; position: relative; top: 1.5px;
}
.onglet.t1 { background: #d9efef; } .onglet.t2 { background: #fde9b8; } .onglet.t3 { background: #f6d6cf; }

/* boutons : encre et décalage */
.btn {
  display: inline-flex; align-items: center; gap: .5rem; font-weight: 700; text-decoration: none; border-radius: 10px; padding: .95rem 1.6rem;
  border: 2px solid var(--encre); transition: transform .12s, box-shadow .12s; font-family: var(--corps); font-size: 1rem; cursor: pointer;
}
.btn-encre { background: var(--teal); color: #fff; box-shadow: 4px 4px 0 var(--encre); }
.btn-encre:hover { transform: translate(-2px, -2px); box-shadow: 6px 6px 0 var(--encre); }
.btn-feuille { background: var(--feuille); color: var(--encre); box-shadow: 4px 4px 0 var(--encre); }
.btn-feuille:hover { transform: translate(-2px, -2px); box-shadow: 6px 6px 0 var(--encre); }
.lien-main { font-family: var(--main); font-size: 1.4rem; color: var(--rouge); text-decoration: none; font-weight: 700; }

/* tampon de prix */
.tampon {
  display: inline-flex; flex-direction: column; align-items: center; justify-content: center; width: 96px; height: 96px; border-radius: 50%;
  border: 3px double var(--rouge); color: var(--rouge); transform: rotate(-12deg); font-family: var(--titre); font-weight: 800; line-height: 1;
  background: rgba(255,253,248,.85);
}
.tampon b { font-size: 1.85rem; } .tampon s { font-family: var(--corps); font-weight: 600; font-size: .78rem; opacity: .7; margin-bottom: 2px; }
.tampon small { font-family: var(--corps); font-size: .62rem; letter-spacing: .08em; text-transform: uppercase; margin-top: 3px; }

/* étiquette */
.etiquette { display: inline-block; font-size: .72rem; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; padding: .28rem .7rem; border-radius: 4px; background: var(--encre); color: #fff; }
.etiquette.teal { background: var(--teal); } .etiquette.jaune { background: var(--surligneur); color: var(--encre); } .etiquette.rouge { background: var(--rouge); }

/* listes cochées à la main */
.coche { list-style: none; padding: 0; margin: 0 0 1rem; }
.coche li { position: relative; padding-left: 2rem; margin-bottom: .55rem; }
.coche li::before { content: '✓'; position: absolute; left: .2rem; top: -.15rem; font-family: var(--main); font-size: 1.6rem; color: var(--teal); font-weight: 700; }

/* fiche bristol (pack par épreuve) */
.bristol {
  background: var(--feuille); box-shadow: var(--ombre); border-radius: 3px; padding: 1.2rem 1.3rem; position: relative;
  background-image: linear-gradient(transparent 52px, var(--marge) 52px 54px, transparent 54px), repeating-linear-gradient(transparent 0 25px, var(--ligne) 25px 26px);
  background-position: 0 0, 0 70px;
}
.bristol h3 { font-size: 1.15rem; margin-bottom: 1.6rem; }

/* pochette cartonnée (pack complet) */
.pochette { position: relative; padding-top: 22px; }
.pochette .onglet-pochette {
  position: absolute; top: 0; left: 18px; height: 26px; padding: 0 1rem; border-radius: 8px 8px 0 0; font-size: .74rem; font-weight: 800; letter-spacing: .06em;
  text-transform: uppercase; display: flex; align-items: center; color: var(--encre);
}
.pochette .corps-pochette { border-radius: 4px 12px 12px 12px; padding: 1.6rem 1.5rem 1.4rem; box-shadow: var(--ombre-forte); position: relative; }
.pochette.c1 .onglet-pochette, .pochette.c1 .corps-pochette { background: #cfe8e8; }
.pochette.c2 .onglet-pochette, .pochette.c2 .corps-pochette { background: #fbe4ac; }
.pochette.c3 .onglet-pochette, .pochette.c3 .corps-pochette { background: #f3cfc6; }
.pochette .tampon { position: absolute; right: -14px; top: -26px; }

/* FAQ sur feuille lignée */
details.q { border-bottom: 1px dashed #cdbfa6; padding: 1rem 0; }
details.q summary { cursor: pointer; font-weight: 700; list-style: none; display: flex; gap: .7rem; }
details.q summary::before { content: '+'; font-family: var(--main); font-size: 1.6rem; line-height: 1; color: var(--rouge); width: 1rem; }
details.q[open] summary::before { content: '−'; }
details.q p { margin: .6rem 0 0 1.7rem; color: var(--encre-douce); }

/* schémas dessinés */
.schema { width: 100%; height: auto; overflow: visible; }
.schema text { font-family: var(--main); }
.trait { fill: none; stroke: var(--encre); stroke-width: 2.4; stroke-linecap: round; stroke-linejoin: round; }

/* nav */
.nav { position: sticky; top: 0; z-index: 50; background: rgba(246,241,231,.9); backdrop-filter: blur(10px); border-bottom: 1.5px solid rgba(34,38,42,.12); }
.nav .wrap { display: flex; align-items: center; justify-content: space-between; height: 66px; gap: 1rem; }
.logo { display: flex; align-items: center; gap: .5rem; font-family: var(--titre); font-weight: 800; font-size: 1.3rem; color: var(--encre); text-decoration: none; }
.logo img { height: 30px; }
.nav-liens { display: flex; gap: 1.4rem; align-items: center; }
.nav-liens a { color: var(--encre); text-decoration: none; font-weight: 600; font-size: .95rem; }
.nav .btn { padding: .55rem 1rem; font-size: .9rem; box-shadow: 3px 3px 0 var(--encre); }

/* ruban promo */
.ruban { background: var(--encre); color: #fff; text-align: center; font-size: .92rem; padding: .55rem 1rem; }
.ruban b { background: var(--surligneur); color: var(--encre); padding: .05rem .4rem; border-radius: 3px; font-family: monospace; font-size: .95rem; }

/* pied */
.pied { padding: 3rem 0 6rem; font-size: .88rem; color: var(--gris); border-top: 1.5px dashed #cdbfa6; }
.pied a { color: var(--encre-douce); }

@media (max-width: 900px) {
  .grille-2, .grille-3, .grille-4 { grid-template-columns: 1fr; }
  .nav-liens a:not(.btn) { display: none; }
  .bloc { padding: 3.5rem 0; }
  .penche-g2, .penche-d2 { transform: rotate(-1deg); }
}
