:root {
  --navy: #0B1F33; --navy-2: #1C3550; --sand: #F1ECE2; --sun: #E2703A; --sun-dark: #B9531F;
  --white: #FFFFFF; --muted: #4A5A6A; --line: #D9D2C5; --ph: #C9D3DC; --ocean: #DCE6EE; --danger: #B3261E;
  --safe-b: env(safe-area-inset-bottom, 0px); --safe-t: env(safe-area-inset-top, 0px);
  --h: "Archivo", system-ui, sans-serif; --b: "Inter", system-ui, sans-serif;
}
* { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }
html, body { margin: 0; height: 100%; background: var(--sand); color: var(--navy); font: 15px/1.4 var(--b); }
body { overscroll-behavior-y: none; }
button, input, select, textarea { font: inherit; color: inherit; }
img { max-width: 100%; display: block; }
a { color: var(--navy); }
.h { font-family: var(--h); font-stretch: 125%; font-weight: 800; letter-spacing: .02em; text-transform: uppercase; margin: 0; }
.muted { color: var(--muted); }
.small { font-size: 12px; }
.kicker { font: 600 11px var(--b); letter-spacing: .08em; text-transform: uppercase; color: var(--sun-dark); }
.splash { height: 100vh; display: grid; place-content: center; justify-items: center; gap: 12px; }
.splash .h { font-size: 28px; }

/* Layout */
.screen { min-height: 100vh; padding: calc(var(--safe-t) + 8px) 16px calc(110px + var(--safe-b)); max-width: 640px; margin: 0 auto; display: flex; flex-direction: column; gap: 14px; }
.topbar { display: flex; align-items: center; justify-content: space-between; min-height: 52px; gap: 8px; }
.brand { display: flex; align-items: center; gap: 8px; text-decoration: none; }
.brand .h { font-size: 20px; }
.topbar .title { font-size: 16px; text-align: center; flex: 1; }
.iconbtn { width: 44px; height: 44px; border: none; background: none; display: inline-flex; align-items: center; justify-content: center; border-radius: 12px; cursor: pointer; color: var(--navy); }
.iconbtn:active { background: rgba(11,31,51,.08); }

.tabbar { position: fixed; left: 0; right: 0; bottom: 0; z-index: 30; background: var(--navy); height: calc(76px + var(--safe-b)); padding-bottom: var(--safe-b); display: flex; justify-content: space-around; align-items: flex-start; padding-top: 8px; }
.tabbar a { color: #A9B9C9; text-decoration: none; display: flex; flex-direction: column; align-items: center; gap: 3px; font: 600 11px var(--b); min-width: 60px; min-height: 48px; justify-content: center; }
.tabbar a.on { color: var(--sun); }
.tabbar .fab { width: 58px; height: 58px; border-radius: 29px; background: var(--sun); color: var(--white); margin-top: -24px; box-shadow: 0 6px 16px rgba(11,31,51,.28); min-width: 58px; }

/* Cards */
.card { background: var(--white); border: 1px solid var(--line); border-radius: 18px; padding: 16px; }
.card.dark { background: var(--navy); color: var(--white); border-color: var(--navy); }
.card.dark .muted { color: #C9D3DC; }
.stats { display: flex; }
.stat { flex: 1; display: flex; flex-direction: column; align-items: center; gap: 2px; text-align: center; }
.stat svg { color: var(--sun); }
.stat b { font: 700 15px var(--b); }
.stat span { font: 500 11px var(--b); color: var(--muted); }
.row { display: flex; align-items: center; gap: 10px; }
.between { justify-content: space-between; }
.wrap { flex-wrap: wrap; }
.grow { flex: 1; min-width: 0; }
.grid2 { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.list > * + * { border-top: 1px solid var(--line); }
.list-item { display: flex; align-items: center; gap: 12px; padding: 12px 0; text-decoration: none; color: inherit; }
.ellipsis { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

.avatar { width: 32px; height: 32px; border-radius: 50%; background: var(--navy); color: var(--white); display: inline-flex; align-items: center; justify-content: center; font: 700 13px var(--b); flex: none; }
.avatar.sun { background: var(--sun); }
.avatar.lg { width: 42px; height: 42px; font-size: 16px; }

.photo { border-radius: 14px; background: var(--ph); width: 100%; object-fit: cover; aspect-ratio: 4/3; display: flex; align-items: center; justify-content: center; color: var(--navy); }
.thumb { width: 56px; height: 56px; border-radius: 12px; background: var(--ph); object-fit: cover; flex: none; display: inline-flex; align-items: center; justify-content: center; }
video.photo { background: #000; }

/* Chips & buttons */
.chips { display: flex; gap: 8px; overflow-x: auto; scrollbar-width: none; padding-bottom: 2px; }
.chips::-webkit-scrollbar { display: none; }
.chip { text-decoration: none; padding: 8px 13px; border-radius: 99px; font: 600 13px var(--b); white-space: nowrap; background: var(--white); color: var(--navy); border: 1px solid var(--line); cursor: pointer; min-height: 36px; display: inline-flex; align-items: center; gap: 6px; }
.chip.on, .chip[aria-pressed="true"] { background: var(--navy); color: var(--white); border-color: var(--navy); }
.btn { min-height: 48px; border: none; border-radius: 12px; background: var(--navy); color: var(--white); font: 700 15px var(--b); display: inline-flex; align-items: center; justify-content: center; gap: 8px; padding: 0 16px; cursor: pointer; text-decoration: none; }
.btn.sun { background: var(--sun); }
.btn.ghost { background: var(--white); color: var(--navy); border: 1.5px solid var(--navy); }
.btn.dashed { background: none; color: var(--navy); border: 1.5px dashed var(--navy); }
.btn.danger { background: none; color: var(--danger); border: 1.5px solid var(--danger); }
.btn.sm { min-height: 38px; font-size: 13px; padding: 0 12px; border-radius: 10px; }
.btn:disabled { opacity: .5; }
.btn-row { display: flex; gap: 10px; }
.btn-row > * { flex: 1; }

/* Forms */
form { display: flex; flex-direction: column; gap: 14px; }
label.f { display: flex; flex-direction: column; gap: 6px; font: 600 12px var(--b); color: var(--muted); flex: 1; min-width: 0; }
.f input, .f select, .f textarea { min-height: 46px; border-radius: 12px; border: 1px solid var(--line); background: var(--white); padding: 10px 12px; font: 600 15px var(--b); color: var(--navy); width: 100%; }
.f textarea { min-height: 80px; font-weight: 500; resize: vertical; }
.f input:focus, .f select:focus, .f textarea:focus { outline: 2px solid var(--sun); outline-offset: 1px; }
.hint { font: 500 12px var(--b); color: var(--muted); }
.switch { display: flex; align-items: center; justify-content: space-between; font: 600 15px var(--b); min-height: 44px; }
.switch input { appearance: none; width: 50px; height: 30px; border-radius: 15px; background: var(--line); position: relative; cursor: pointer; transition: background .15s; }
.switch input::after { content: ""; position: absolute; top: 3px; left: 3px; width: 24px; height: 24px; border-radius: 12px; background: var(--white); transition: left .15s; }
.switch input:checked { background: var(--sun); }
.switch input:checked::after { left: 23px; }
.drop { border: 1.5px dashed var(--navy); border-radius: 14px; min-height: 110px; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 6px; font: 600 13px var(--b); cursor: pointer; position: relative; overflow: hidden; background: var(--white); }
.drop input { position: absolute; inset: 0; opacity: 0; cursor: pointer; }
.drop img, .drop video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.posbox { background: var(--navy); color: var(--white); border-radius: 14px; padding: 12px; display: flex; flex-direction: column; gap: 8px; }
.posbox .muted { color: #C9D3DC; }
.posbox .chip { background: var(--navy-2); color: var(--white); border-color: var(--navy-2); }

/* Map */
.mapwrap { position: fixed; inset: 0; bottom: calc(76px + var(--safe-b)); }
#map, .minimap { width: 100%; height: 100%; }
.minimap { height: 220px; border-radius: 16px; overflow: hidden; }
.map-top { position: fixed; top: calc(var(--safe-t) + 10px); left: 12px; right: 12px; z-index: 5; display: flex; flex-direction: column; gap: 8px; max-width: 640px; margin: 0 auto; }
.search { flex-direction: row; gap: 8px; height: 48px; background: var(--white); border-radius: 14px; display: flex; align-items: center; gap: 8px; padding: 0 6px 0 14px; box-shadow: 0 4px 14px rgba(11,31,51,.14); }
.search input { border: none; outline: none; flex: 1; font: 500 15px var(--b); background: none; min-width: 0; }
.map-fabs { position: fixed; right: 12px; bottom: calc(96px + var(--safe-b)); z-index: 5; display: flex; flex-direction: column; gap: 10px; }
.map-fabs .iconbtn { background: var(--white); box-shadow: 0 4px 14px rgba(11,31,51,.18); width: 48px; height: 48px; }
.sheet { position: fixed; left: 12px; right: 12px; bottom: calc(88px + var(--safe-b)); z-index: 6; background: var(--white); border-radius: 20px; padding: 16px; box-shadow: 0 8px 24px rgba(11,31,51,.2); max-width: 616px; margin: 0 auto; }
.crosshair { position: fixed; left: 50%; top: 50%; transform: translate(-50%, -100%); z-index: 4; pointer-events: none; }
.pin { width: 26px; height: 34px; cursor: pointer; }
.maplibregl-ctrl-attrib { font-size: 10px; }

.badge-vis { display: inline-flex; align-items: center; gap: 4px; padding: 4px 10px; border-radius: 99px; background: var(--sand); font: 600 11px var(--b); }
.banner { background: var(--sun); color: var(--white); border-radius: 14px; padding: 10px 14px; display: flex; align-items: center; justify-content: space-between; gap: 10px; font: 600 13px var(--b); }
.empty { text-align: center; padding: 28px 12px; color: var(--muted); display: flex; flex-direction: column; align-items: center; gap: 10px; }
.timeline .list-item .time { width: 44px; font: 700 12px var(--b); color: var(--muted); }
.dot { width: 10px; height: 10px; border-radius: 5px; background: var(--sun); flex: none; }

#toast { position: fixed; left: 50%; bottom: calc(100px + var(--safe-b)); transform: translateX(-50%) translateY(20px); background: var(--navy); color: var(--white); padding: 12px 16px; border-radius: 12px; font: 600 14px var(--b); opacity: 0; transition: all .2s; z-index: 100; pointer-events: none; max-width: 90vw; text-align: center; }
#toast.show { opacity: 1; transform: translateX(-50%) translateY(0); }
.modal { position: fixed; inset: 0; background: rgba(11,31,51,.5); z-index: 50; display: flex; align-items: flex-end; justify-content: center; }
.modal .card { width: 100%; max-width: 640px; border-radius: 22px 22px 0 0; max-height: 85vh; overflow: auto; padding-bottom: calc(20px + var(--safe-b)); }
.install { font-size: 13px; }

.auth { min-height: 100vh; display: flex; flex-direction: column; justify-content: center; gap: 18px; padding: 24px; max-width: 440px; margin: 0 auto; }
.auth .logo { width: 100%; max-width: 320px; margin: 0 auto 8px; }
@media (min-width: 700px) { .screen { padding-top: 20px; } }
.shortcuts{display:grid;grid-template-columns:repeat(4,1fr);gap:8px}
.shortcuts a{background:var(--white);border:1px solid var(--line);border-radius:14px;min-height:72px;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:6px;text-decoration:none;font:600 12px var(--b);color:var(--navy);text-align:center;padding:6px}
.shortcuts a svg{color:var(--sun)}
.fday summary::-webkit-details-marker{display:none}
.score{width:58px;height:58px;border-radius:50%;border:4px solid var(--c);display:flex;flex-direction:column;align-items:center;justify-content:center;line-height:1;flex:none}
.score b{font:800 18px var(--b)}.score span{font:600 9px var(--b);color:var(--muted)}
.months{display:grid;grid-template-columns:repeat(12,1fr);gap:4px;align-items:end;height:92px}
.months div{display:flex;flex-direction:column;align-items:center;justify-content:flex-end;gap:4px;height:100%}
.months span{display:block;width:100%;background:var(--sun);border-radius:4px 4px 0 0;min-height:2px}
.months small{font:600 10px var(--b);color:var(--muted)}

/* Sorties, réservations, chat */
.shortcuts{grid-template-columns:repeat(3,1fr)}
.pill{display:inline-flex;align-items:center;padding:4px 10px;border-radius:99px;font:700 11px var(--b);color:#fff;background:var(--pc);white-space:nowrap;flex:none}
.vbadge{display:inline-flex;align-items:center;gap:4px;padding:3px 8px;border-radius:99px;background:#1E7A46;color:#fff;font:700 11px var(--b);margin-top:4px}
.ogrid{display:grid;grid-template-columns:repeat(auto-fill,minmax(min(100%,260px),1fr));gap:14px}
.ocard{padding:0;overflow:hidden;text-decoration:none;color:inherit;display:flex;flex-direction:column}
.ophoto{position:relative;aspect-ratio:16/9;background:var(--navy);color:var(--sun);display:grid;place-items:center}
.ophoto img{position:absolute;inset:0;width:100%;height:100%;object-fit:cover}
.otag{position:absolute;top:10px;left:10px;display:inline-flex;align-items:center;gap:4px;background:var(--navy);color:#fff;font:700 11px var(--b);padding:4px 8px;border-radius:99px}
.hscroll{display:grid;grid-auto-flow:column;grid-auto-columns:min(78%,280px);gap:12px;overflow-x:auto;scroll-snap-type:x mandatory;padding-bottom:4px;scrollbar-width:none}
.hscroll::-webkit-scrollbar{display:none}
.hscroll>*{scroll-snap-align:start}
.cgrid{display:grid;grid-template-columns:repeat(auto-fill,minmax(min(46%,200px),1fr));gap:12px}
.dotn{position:absolute;top:-6px;right:-6px;min-width:20px;height:20px;border-radius:10px;background:var(--sun);color:#fff;font:800 11px var(--b);display:grid;place-items:center;padding:0 5px}
.pricebox{background:var(--white)}
.plan{background:var(--sand);border-radius:12px;padding:10px 12px;margin-top:8px}
.okline{display:flex;align-items:center;gap:6px;margin:10px 0 0;color:#1E7A46;font-weight:700}
.paybtns{display:flex;flex-wrap:wrap;gap:8px;margin-top:12px}
.paybtns .btn:not(.sm){flex:1 1 140px}
.chatscreen{padding-bottom:calc(90px + var(--safe-b))}
.chat{display:flex;flex-direction:column}
#msgs{display:flex;flex-direction:column;gap:8px}
.msg{align-self:flex-start;max-width:82%;background:var(--white);border:1px solid var(--line);border-radius:16px 16px 16px 4px;padding:9px 12px;white-space:pre-wrap;word-wrap:break-word}
.msg.me{align-self:flex-end;background:var(--navy);color:#fff;border-color:var(--navy);border-radius:16px 16px 4px 16px}
.msg .t{display:block;font:500 10px var(--b);opacity:.6;margin-top:3px;text-align:right}
.msg.bank{background:#FFF7F1;border-color:var(--sun);color:var(--navy)}
.msg.bank .btn{color:var(--navy)}
.sysmsg{align-self:center;text-align:center;font:600 12px var(--b);color:var(--muted);background:rgba(11,31,51,.06);border-radius:99px;padding:6px 12px;margin:2px 0;max-width:92%}
.sysmsg span{font-weight:500;opacity:.7;margin-left:6px}
.composer{position:fixed;left:0;right:0;bottom:0;z-index:20;flex-direction:row;gap:8px;align-items:center;background:var(--sand);border-top:1px solid var(--line);padding:10px 12px calc(10px + var(--safe-b))}
.composer input{flex:1;min-height:46px;border-radius:23px;border:1px solid var(--line);background:#fff;padding:0 16px;font:500 15px var(--b);min-width:0}
.composer input:focus{outline:2px solid var(--sun)}
.sendbtn{background:var(--sun);color:#fff;border-radius:23px;width:46px;height:46px;flex:none;transform:rotate(90deg)}
@media (min-width:700px){.composer{max-width:640px;margin:0 auto;border-left:1px solid var(--line);border-right:1px solid var(--line)}}
a.banner{color:#fff}
[hidden]{display:none !important}
.gallery{display:grid;grid-auto-flow:column;grid-auto-columns:100%;overflow-x:auto;scroll-snap-type:x mandatory;border-radius:14px;scrollbar-width:none;background:var(--ph)}
.gallery::-webkit-scrollbar{display:none}
.gallery img{width:100%;aspect-ratio:4/3;object-fit:cover;scroll-snap-align:start}
.gdots{display:flex;justify-content:center;gap:6px;margin-top:-6px}
.gdots span{width:7px;height:7px;border-radius:4px;background:var(--line);transition:all .2s}
.gdots span.on{background:var(--sun);width:18px}
.phgrid{display:grid;grid-template-columns:repeat(3,1fr);gap:8px}
.phitem{position:relative;aspect-ratio:1;border-radius:12px;overflow:hidden;background:var(--ph)}
.phitem img{width:100%;height:100%;object-fit:cover}
.phx{position:absolute;top:4px;right:4px;width:28px;height:28px;border-radius:14px;border:none;background:rgba(11,31,51,.75);color:#fff;font-size:13px;cursor:pointer}
.phcover{position:absolute;left:4px;bottom:4px;background:var(--sun);color:#fff;font:700 10px var(--b);padding:3px 7px;border-radius:99px}
.phadd{min-height:0;aspect-ratio:1}
.okbox{display:flex;align-items:center;gap:8px;margin:0 0 4px;padding:10px 12px;border-radius:12px;background:#E6F2EA;color:#1E7A46;font:600 13px var(--b)}

/* Likes & commentaires */
.actions { display: flex; align-items: center; gap: 6px; margin-top: 10px; }
.likebtn { display: inline-flex; align-items: center; gap: 6px; min-height: 40px; padding: 0 10px; border: none; background: none; border-radius: 10px; font: 700 14px var(--b); color: var(--navy); cursor: pointer; text-decoration: none; }
.likebtn svg { transition: transform .12s; }
.likebtn.on { color: var(--sun-dark); }
.likebtn.on svg { fill: var(--sun); stroke: var(--sun); }
.likebtn:active svg { transform: scale(1.25); }
.cmts { display: flex; flex-direction: column; gap: 12px; }
.cmt { display: flex; gap: 10px; align-items: flex-start; }
.cmt .avatar { margin-top: 2px; }
.cmt-form { display: flex; gap: 8px; align-items: center; margin-top: 14px; }
.cmt-form input { flex: 1; min-width: 0; min-height: 44px; border-radius: 22px; border: 1px solid var(--line); background: #fff; padding: 0 16px; font: 500 15px var(--b); color: var(--navy); }
.cmt-form input:focus { outline: 2px solid var(--sun); }

/* Prises à plusieurs photos */
.gal { position: relative; }
.gal-track { display: flex; gap: 8px; overflow-x: auto; scroll-snap-type: x mandatory; scrollbar-width: none; border-radius: 14px; -webkit-overflow-scrolling: touch; }
.gal-track::-webkit-scrollbar { display: none; }
.gal-track .photo { flex: 0 0 100%; scroll-snap-align: center; }
.gal-count { position: absolute; top: 10px; right: 10px; display: inline-flex; align-items: center; gap: 4px; background: rgba(15, 29, 46, .72); color: #fff; font: 600 12px var(--font-body, inherit); padding: 4px 9px; border-radius: 99px; pointer-events: none; }
.pcount { position: absolute; bottom: 8px; right: 8px; background: rgba(15, 29, 46, .78); color: #fff; font: 600 12px/1 var(--font-body, inherit); padding: 5px 9px; border-radius: 99px; }
.pstrip { display: flex; flex-wrap: wrap; gap: 8px; margin-top: -4px; }
.pstrip[hidden] { display: none; }
.pth { position: relative; width: 64px; height: 64px; }
.pth .pimg { width: 100%; height: 100%; padding: 0; border: 2px solid transparent; border-radius: 12px; overflow: hidden; background: none; cursor: pointer; }
.pth.cover .pimg { border-color: var(--sun, #D4764A); }
.pth img { width: 100%; height: 100%; object-fit: cover; display: block; }
.pth .prm { position: absolute; top: -6px; right: -6px; width: 22px; height: 22px; border-radius: 50%; border: none; background: var(--navy, #0F1D2E); color: #fff; font-size: 11px; line-height: 1; cursor: pointer; }

/* ---- Amis, notifications, installation ---- */
.bell{position:relative}
.bell .nb{position:absolute;top:2px;right:0;min-width:18px;height:18px;padding:0 5px;border-radius:9px;background:var(--sun);color:#fff;font:700 11px/18px Inter,sans-serif;text-align:center}
.notif .nicon{flex:none;width:38px;height:38px;border-radius:50%;background:var(--sand);display:grid;place-items:center;color:var(--navy-2)}
.notif.unread .nicon{background:var(--sun);color:#fff}
.notif .dot{flex:none;width:10px;height:10px;border-radius:50%;background:var(--sun)}
.linkbtn{background:none;border:none;padding:0;color:var(--sun-dark);font:inherit;font-weight:600;text-decoration:underline;cursor:pointer}
.inst-steps{margin:0;padding-left:20px;display:flex;flex-direction:column;gap:8px}
.inst-warn{background:#FFF3E8;border:1px solid #F3C9A8;border-radius:12px;padding:10px 12px;margin-bottom:10px;font-size:14px}
.card.install{background:#fff}
.srch input{font-size:16px}

.basepin{display:flex;align-items:center;gap:5px;background:var(--navy);color:#fff;border:2px solid #fff;border-radius:16px;padding:3px 10px 3px 7px;font:700 12px Inter,sans-serif;box-shadow:0 2px 8px rgba(0,0,0,.35);white-space:nowrap;pointer-events:none}

/* ---- Mobile web : pas de zoom automatique iOS, hauteur réelle de l'écran ---- */
input, select, textarea, .f input, .f select, .f textarea, .search input { font-size: 16px; }
@supports (height: 100dvh) {
  .splash { height: 100dvh; }
  .screen { min-height: 100dvh; }
}
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; }

/* =====================================================================
   Mouvement et nouveaux écrans
   ===================================================================== */
:root { --ease: cubic-bezier(.2, .8, .2, 1); }

/* Barre de progression pendant le chargement d'un écran */
#prog { position: fixed; top: 0; left: 0; height: 3px; width: 0; background: var(--sun); z-index: 200; opacity: 0; pointer-events: none; border-radius: 0 3px 3px 0; }
#prog.run { opacity: 1; width: 82%; transition: width 6s cubic-bezier(.05, .7, .1, 1); }
#prog.done { opacity: 0; width: 100%; transition: width .2s, opacity .3s .15s; }

/* Entrée des écrans : les blocs montent l'un après l'autre */
@keyframes rise { from { opacity: 0; transform: translateY(14px); } to { opacity: 1; transform: none; } }
@keyframes slideback { from { opacity: 0; transform: translateX(-16px); } to { opacity: 1; transform: none; } }
@keyframes pop { from { opacity: 0; transform: translateY(10px) scale(.985); } to { opacity: 1; transform: none; } }
.screen.enter > *:not(.composer) { animation: rise .42s var(--ease) both; }
.screen.enter-back > *:not(.composer) { animation: slideback .3s var(--ease) both; }
.screen.enter > :nth-child(2) { animation-delay: 40ms; } .screen.enter > :nth-child(3) { animation-delay: 80ms; }
.screen.enter > :nth-child(4) { animation-delay: 120ms; } .screen.enter > :nth-child(5) { animation-delay: 160ms; }
.screen.enter > :nth-child(6) { animation-delay: 200ms; } .screen.enter > :nth-child(7) { animation-delay: 240ms; }
.screen.enter > :nth-child(n+8) { animation-delay: 280ms; }
.pop { animation: pop .4s var(--ease) both; animation-delay: var(--d, 0ms); }
.stagger > * { animation: pop .4s var(--ease) both; }
.stagger > :nth-child(2) { animation-delay: 50ms; } .stagger > :nth-child(3) { animation-delay: 100ms; } .stagger > :nth-child(4) { animation-delay: 150ms; }
.stagger > :nth-child(5) { animation-delay: 200ms; } .stagger > :nth-child(6) { animation-delay: 250ms; } .stagger > :nth-child(n+7) { animation-delay: 300ms; }

/* Retour tactile */
.btn, .chip, .press, .ocard, .tabbar a, .iconbtn, .setrow, .addit, .quick a, a.card, .list-item[href] { transition: transform .14s var(--ease), background-color .15s, box-shadow .15s, opacity .15s; }
.btn:active, .chip:active, .press:active, .ocard:active, a.card:active, .addit:active { transform: scale(.97); }
.iconbtn:active, .tabbar a:active { transform: scale(.9); }
.list-item[href]:active, .setrow.press:active { background: rgba(11, 31, 51, .05); }

/* Squelettes de chargement */
@keyframes shimmer { to { background-position: -200% 0; } }
.sk { display: block; background: linear-gradient(90deg, rgba(11, 31, 51, .07) 25%, rgba(11, 31, 51, .14) 37%, rgba(11, 31, 51, .07) 63%); background-size: 200% 100%; animation: shimmer 1.3s linear infinite; }
.hero .sk { background: linear-gradient(90deg, rgba(255, 255, 255, .08) 25%, rgba(255, 255, 255, .18) 37%, rgba(255, 255, 255, .08) 63%); background-size: 200% 100%; }

/* Barre d'onglets : indicateur et icône qui réagit */
@keyframes tabpop { 0% { transform: translateY(0) scale(1); } 45% { transform: translateY(-4px) scale(1.14); } 100% { transform: none; } }
.tabbar a:not(.fab) { position: relative; }
.tabbar a:not(.fab)::before { content: ""; position: absolute; top: -8px; left: 50%; width: 26px; height: 3px; border-radius: 0 0 3px 3px; background: var(--sun); transform: translateX(-50%) scaleX(0); transition: transform .28s var(--ease); }
.tabbar a.on::before { transform: translateX(-50%) scaleX(1); }
.tabbar a.on svg { animation: tabpop .38s var(--ease); }
.tabbar .fab { transition: transform .18s var(--ease), box-shadow .18s; }
.tabbar .fab:active { transform: scale(.9) rotate(45deg); }
@keyframes fabring { 0% { box-shadow: 0 6px 16px rgba(11, 31, 51, .28), 0 0 0 0 rgba(226, 112, 58, .5); } 70%, 100% { box-shadow: 0 6px 16px rgba(11, 31, 51, .28), 0 0 0 14px rgba(226, 112, 58, 0); } }
.tabbar .fab { animation: fabring 2.6s ease-out 1s 2; }

/* Fenêtres du bas */
@keyframes sheetup { from { transform: translateY(100%); } to { transform: none; } }
@keyframes fadein { from { opacity: 0; } to { opacity: 1; } }
.modal { animation: fadein .2s both; backdrop-filter: blur(2px); -webkit-backdrop-filter: blur(2px); }
.modal .card { animation: sheetup .32s var(--ease) both; position: relative; padding-top: 22px; }
.grab { position: absolute; top: 8px; left: 50%; width: 40px; height: 4px; border-radius: 2px; background: var(--line); transform: translateX(-50%); }
.sheet { animation: pop .28s var(--ease) both; }

/* Menu du bouton + */
.addlist { display: flex; flex-direction: column; gap: 8px; }
.addit { display: flex; align-items: center; gap: 12px; padding: 12px; border-radius: 16px; background: var(--sand); text-decoration: none; color: var(--navy); min-height: 64px; animation: pop .35s var(--ease) both; }
.addit:nth-child(2) { animation-delay: 40ms; } .addit:nth-child(3) { animation-delay: 80ms; } .addit:nth-child(4) { animation-delay: 120ms; } .addit:nth-child(5) { animation-delay: 160ms; }
.addit b { display: block; font: 700 15px var(--b); }
.addit small { display: block; font: 500 12px var(--b); color: var(--muted); margin-top: 2px; }
.addic { width: 44px; height: 44px; border-radius: 14px; background: var(--white); color: var(--sun-dark); display: grid; place-items: center; flex: none; }
.addit.main { background: var(--sun); color: #fff; }
.addit.main small { color: rgba(255, 255, 255, .88); }
.addit.main .addic { background: rgba(255, 255, 255, .2); color: #fff; }

/* Accueil */
.hello .h { font-size: 24px; line-height: 1.1; }
.hero { position: relative; display: flex; flex-direction: column; gap: 14px; overflow: hidden; text-decoration: none; color: #fff; border-radius: 22px; padding: 18px 18px 46px; background: radial-gradient(120% 90% at 100% 0%, #24507A 0%, rgba(36, 80, 122, 0) 60%), linear-gradient(160deg, #0B1F33 0%, #12324F 100%); box-shadow: 0 10px 26px rgba(11, 31, 51, .22); }
.hero .kicker { color: #F2A27C; margin: 0; }
.hero-head { display: flex; align-items: center; gap: 12px; }
.hero-v { font: 800 21px/1.15 var(--b); margin: 6px 0 0; letter-spacing: -.01em; }
.hero-s { font: 500 13px var(--b); color: #C9D6E3; margin: 5px 0 0; }
.ring-v { stroke-dashoffset: var(--off); animation: ringin 1s var(--ease) both; }
@keyframes ringin { from { stroke-dashoffset: var(--c); } to { stroke-dashoffset: var(--off); } }
.hero-stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; }
.hero-stats .stat { background: rgba(255, 255, 255, .09); border-radius: 12px; padding: 9px 4px; gap: 3px; min-width: 0; }
.hero-stats .stat svg { color: #F2A27C; }
.hero-stats .stat b { font: 700 14px var(--b); white-space: nowrap; }
.hero-stats .stat { justify-content: flex-start; }
.hero-stats .stat span { color: #C9D6E3; font-size: 10.5px; line-height: 1.15; max-width: 100%; }
.hero-stats .stat:nth-child(2) { --d: 60ms; } .hero-stats .stat:nth-child(3) { --d: 120ms; } .hero-stats .stat:nth-child(4) { --d: 180ms; }
.week { display: grid; grid-template-columns: repeat(7, 1fr); gap: 6px; align-items: end; min-height: 62px; }
.week:empty { display: none; }
.wd { display: flex; flex-direction: column; align-items: center; justify-content: flex-end; gap: 5px; }
@keyframes grow { from { transform: scaleY(0); } to { transform: none; } }
.wd i { display: block; width: 100%; max-width: 26px; height: var(--h); border-radius: 6px; background: var(--c); transform-origin: bottom; animation: grow .5s var(--ease) both; animation-delay: var(--d); opacity: .85; }
.wd small { font: 600 10px var(--b); color: #C9D6E3; text-transform: capitalize; }
.wd.on small { color: #fff; font-weight: 800; }
.hero-more { position: absolute; right: 16px; bottom: 12px; z-index: 2; display: inline-flex; align-items: center; gap: 3px; font: 700 12px var(--b); color: #fff; }
.hero-waves { position: absolute; left: 0; bottom: 0; width: 200%; height: 40px; pointer-events: none; }
.hero-waves path { fill: rgba(255, 255, 255, .07); }
.hero-waves .w2 { fill: rgba(226, 112, 58, .3); }
@keyframes drift { to { transform: translateX(-25%); } }
.hero-waves .w1 { animation: drift 9s linear infinite; }
.hero-waves .w2 { animation: drift 14s linear infinite reverse; transform: translateX(-25%); }

.quick { display: flex; gap: 6px; overflow-x: auto; scrollbar-width: none; margin: 0 -16px; padding: 2px 16px; scroll-snap-type: x proximity; }
.quick::-webkit-scrollbar { display: none; }
.quick a { flex: 0 0 auto; width: 76px; display: flex; flex-direction: column; align-items: center; gap: 7px; text-decoration: none; color: var(--navy); font: 600 11.5px/1.2 var(--b); text-align: center; scroll-snap-align: start; }
.qic { width: 56px; height: 56px; border-radius: 18px; background: var(--white); border: 1px solid var(--line); display: grid; place-items: center; color: var(--sun-dark); box-shadow: 0 2px 6px rgba(11, 31, 51, .05); }
.quick a:active .qic { background: var(--sun); color: #fff; border-color: var(--sun); }

.datebox { width: 52px; height: 56px; border-radius: 14px; background: var(--navy); color: #fff; display: flex; flex-direction: column; align-items: center; justify-content: center; flex: none; line-height: 1; }
.datebox b { font: 800 21px var(--b); } .datebox small { font: 700 10px var(--b); text-transform: uppercase; letter-spacing: .05em; margin-top: 3px; color: #F2A27C; }
.datebox.ghost { background: var(--sand); color: var(--sun-dark); }
.count { background: #FBE6DA; color: var(--sun-dark); font: 800 12px var(--b); padding: 6px 10px; border-radius: 99px; white-space: nowrap; }

.podium { display: grid; grid-template-columns: 1fr 1.1fr 1fr; gap: 8px; align-items: end; }
.pod { display: flex; flex-direction: column; align-items: center; gap: 2px; text-decoration: none; color: var(--navy); min-width: 0; text-align: center; }
.pod b, .pod small { max-width: 100%; }
.pod > b { font: 700 13px var(--b); margin-top: 5px; } .pod small { font: 500 11px var(--b); color: var(--muted); }
.podbar { margin-top: 6px; width: 100%; border-radius: 12px 12px 4px 4px; background: var(--sand); display: flex; flex-direction: column; align-items: center; justify-content: space-between; padding: 8px 4px 6px; transform-origin: bottom; animation: grow .55s var(--ease) both; }
.podbar b { font: 800 14px var(--b); color: var(--sun-dark); min-height: 17px; } .podbar i { font: 800 18px var(--h); font-style: normal; color: rgba(11, 31, 51, .28); }
.p1 .podbar { height: 92px; background: var(--navy); animation-delay: .1s; } .p1 .podbar b { color: #fff; } .p1 .podbar i { color: var(--sun); }
.p2 .podbar { height: 70px; } .p3 .podbar { height: 56px; animation-delay: .18s; }
.pod.off { opacity: .5; }

.post { padding: 0; overflow: hidden; }
.post-head { padding: 12px 14px; }
.post-ph { position: relative; margin: 0; }
.post-ph .photo { border-radius: 0; aspect-ratio: 4/3.4; }
.post-cap { position: absolute; left: 0; right: 0; bottom: 0; display: flex; align-items: flex-end; justify-content: space-between; gap: 10px; padding: 34px 14px 12px; color: #fff; background: linear-gradient(to top, rgba(7, 18, 31, .82), rgba(7, 18, 31, 0)); pointer-events: none; }
.post-cap .h { font-size: 20px; line-height: 1.05; text-shadow: 0 1px 6px rgba(0, 0, 0, .35); }
.post-cap b { background: var(--sun); color: #fff; font: 800 15px var(--b); padding: 5px 11px; border-radius: 99px; white-space: nowrap; }
.post-noph { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 4px 14px 10px; }
.post-noph .h { font-size: 18px; } .post-noph b { color: var(--sun-dark); font-size: 18px; }
.post-lure { margin: 10px 14px 0; padding: 8px; background: var(--sand); border-radius: 12px; }
.post .actions { padding: 2px 6px 6px; margin-top: 4px; }
.tag-rel { font: 700 11px var(--b); color: #1E7A46; background: #E6F2EA; padding: 4px 9px; border-radius: 99px; flex: none; }
.bigheart { position: absolute; inset: 0; display: grid; place-items: center; color: #fff; opacity: 0; pointer-events: none; }
.bigheart svg { fill: #fff; filter: drop-shadow(0 4px 14px rgba(0, 0, 0, .4)); }
@keyframes bigheart { 0% { opacity: 0; transform: scale(.4); } 25% { opacity: 1; transform: scale(1.15); } 45% { transform: scale(1); } 80% { opacity: 1; } 100% { opacity: 0; transform: scale(1.05); } }
.post-ph.liked .bigheart { animation: bigheart .8s var(--ease) both; }
@keyframes burst { 0% { transform: scale(1); } 35% { transform: scale(1.5); } 60% { transform: scale(.88); } 100% { transform: scale(1); } }
.likebtn.burst svg { animation: burst .45s var(--ease); }
.nb, .dotn { animation: pop .35s var(--ease) both; }

/* Profil */
.pcard { position: relative; overflow: hidden; padding-bottom: 38px; }
.pcard .hero-waves { height: 30px; }
.pstats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin-top: 16px; position: relative; z-index: 1; }
.pstats a { background: rgba(255, 255, 255, .09); border-radius: 14px; padding: 10px 4px; text-align: center; color: #fff; text-decoration: none; }
.pstats b { display: block; font: 800 22px var(--b); } .pstats span { font: 600 11px var(--b); color: #C9D6E3; }
.setlist { padding: 4px 14px; }
.setrow { display: flex; align-items: center; gap: 12px; padding: 12px 2px; min-height: 56px; text-decoration: none; color: var(--navy); border-radius: 10px; }
.setrow + .setrow { border-top: 1px solid var(--line); border-radius: 0; }
.setrow b { display: block; font: 700 15px var(--b); } .setrow small { display: block; font: 500 12px var(--b); color: var(--muted); margin-top: 1px; }
.setic { width: 38px; height: 38px; border-radius: 12px; background: var(--sand); color: var(--sun-dark); display: grid; place-items: center; flex: none; }
.setrow > svg { color: #9AA7B5; flex: none; }

/* Stats */
.bigstat { display: flex; align-items: flex-end; justify-content: space-between; gap: 12px; }
.bignum { margin: 6px 0 0; font: 600 15px var(--b); color: #C9D6E3; } .bignum b { font: 800 40px/1 var(--b); color: #fff; margin-right: 4px; }
.months span { transform-origin: bottom; animation: grow .5s var(--ease) both; animation-delay: var(--d, 0ms); }

/* Carte : boutons libellés */
.map-fabs .iconbtn.lab { width: 54px; height: 54px; flex-direction: column; gap: 2px; border-radius: 16px; }
.map-fabs .iconbtn.lab small { font: 700 9.5px var(--b); letter-spacing: .01em; }
.map-fabs { gap: 8px; }

/* Divers */
.empty svg { color: var(--sun); }
.card.install { animation: pop .4s var(--ease) both; }
#toast { transition: all .28s var(--ease); }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; animation-delay: 0ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; }
}

/* Formulaires par étapes */
.step { display: flex; align-items: center; gap: 10px; margin: 10px 0 -2px; }
.step:first-child { margin-top: 0; }
.step i { width: 28px; height: 28px; border-radius: 14px; background: var(--navy); color: #fff; font: 800 13px var(--b); font-style: normal; display: grid; place-items: center; flex: none; }
.step b { display: block; font: 800 16px var(--b); } .step small { display: block; font: 500 12px var(--b); color: var(--muted); }
.sticky-cta { position: sticky; bottom: calc(10px + var(--safe-b)); z-index: 5; display: flex; padding: 8px; margin: 4px -8px 0; border-radius: 18px; background: rgba(241, 236, 226, .86); backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px); box-shadow: 0 6px 18px rgba(11, 31, 51, .14); }
.sticky-cta .btn { flex: 1; }
.drop { transition: transform .14s var(--ease), border-color .15s; } .drop:active { transform: scale(.98); border-color: var(--sun); }
.chip.on { animation: pop .25s var(--ease); }
