/* Kanou — couche "application iOS" (blanc + rose conservés). 3 styles : cristal (défaut), douceur, epure.
   Chargée APRES style.css ; ne touche pas aux pages connexion / inscription (layout wizard). */
/* Pas de transition entre pages (supprimée : provoquait des pages qui clignotent). */
:root{
  --ios-ease:cubic-bezier(.22,1,.36,1);
  --ios-spring:cubic-bezier(.34,1.56,.64,1);
  --r-card:22px;--r-btn:14px;--r-input:16px;
  --glass:rgba(255,255,255,.72);--glass-line:rgba(216,27,96,.08);
  --sh-ios:0 1px 2px rgba(45,20,34,.04),0 10px 30px rgba(45,20,34,.07);
  --sh-ios-hi:0 2px 4px rgba(45,20,34,.05),0 20px 44px rgba(216,27,96,.14);
  --tab-h:64px;
}
html[data-ui=douceur]{--r-card:28px;--r-btn:999px;--r-input:22px;--sh-ios:0 12px 34px rgba(216,27,96,.10);--glass:rgba(255,248,251,.78)}
html[data-ui=epure]{--r-card:14px;--r-btn:12px;--r-input:12px;--sh-ios:0 0 0 1px #f0e8ed;--sh-ios-hi:0 0 0 1px #f3c4d6;--glass:rgba(255,255,255,.9)}

body:not(.layout-wizard){
  -webkit-font-smoothing:antialiased;-webkit-tap-highlight-color:transparent;
  text-rendering:optimizeLegibility;overscroll-behavior-y:none;
  font-feature-settings:"cv11","ss01";
}
body:not(.layout-wizard) *{-webkit-tap-highlight-color:transparent}
html{scroll-behavior:smooth}
@media(prefers-reduced-motion:reduce){html{scroll-behavior:auto}*{animation-duration:.01ms!important;transition-duration:.01ms!important}}

/* ---- Barre du haut : verre dépoli, collée ---- */
body:not(.layout-wizard):not(.layout-admin) .topbar{
  position:sticky;top:0;z-index:40;background:var(--glass);
  -webkit-backdrop-filter:saturate(180%) blur(22px);backdrop-filter:saturate(180%) blur(22px);
  border-bottom:1px solid transparent;transition:border-color .25s,box-shadow .25s;
  padding-top:env(safe-area-inset-top);
}
body.is-scrolled .topbar{border-bottom-color:var(--glass-line);box-shadow:0 8px 24px rgba(45,20,34,.05)}
.logo{transition:transform .25s var(--ios-spring)}.logo:active{transform:scale(.94)}

/* ---- Boutons : pressés comme sur iOS ---- */
body:not(.layout-wizard) .btn,body:not(.layout-wizard) button.btn{
  border-radius:var(--r-btn);min-height:44px;
  transition:transform .35s var(--ios-spring),box-shadow .25s,background .2s,opacity .2s;
}
body:not(.layout-wizard) .btn:active{transform:scale(.95);opacity:.92}
body:not(.layout-wizard) .btn-primary{background:linear-gradient(135deg,#e5247a,#D81B60);box-shadow:0 8px 20px rgba(216,27,96,.28)}
body:not(.layout-wizard) .btn-primary:hover{background:linear-gradient(135deg,#d81b6e,#b91550)}
body:not(.layout-wizard) .btn-light{background:#fff0f6}
body:not(.layout-wizard) .btn-outline{background:#fff;border-color:#f0dce5}
.btn:focus-visible,a:focus-visible,button:focus-visible{outline:3px solid rgba(216,27,96,.35);outline-offset:2px}

/* ---- Cartes : grands rayons, ombre douce, soulèvement ---- */
body:not(.layout-wizard) .profile-card,body:not(.layout-wizard) .panel,body:not(.layout-wizard) .form-card,
body:not(.layout-wizard) .stat-card,body:not(.layout-wizard) .feature,body:not(.layout-wizard) .filters,
body:not(.layout-wizard) .locked{
  border-radius:var(--r-card);border-color:transparent;box-shadow:var(--sh-ios);background:#fff;
}
html[data-ui=epure] body:not(.layout-wizard) .profile-card,html[data-ui=epure] body:not(.layout-wizard) .panel,
html[data-ui=epure] body:not(.layout-wizard) .form-card,html[data-ui=epure] body:not(.layout-wizard) .stat-card,
html[data-ui=epure] body:not(.layout-wizard) .feature{border-color:#f0e8ed}
.profile-card{transition:transform .45s var(--ios-ease),box-shadow .35s;will-change:transform}
.profile-photo,.profile-card img{transition:transform .8s var(--ios-ease)}
@media(hover:hover){.profile-card:hover{transform:translateY(-4px);box-shadow:var(--sh-ios-hi)}.profile-card:hover img{transform:scale(1.04)}}
.profile-card:active{transform:scale(.985)}
.profile-photo{overflow:hidden}

/* ---- Accueil ---- */
body:not(.layout-wizard) .hero{background:radial-gradient(120% 90% at 85% 0%,#ffe3ee 0%,transparent 55%),linear-gradient(180deg,#fff8fb,#fff)}
body:not(.layout-wizard) .hero h1{letter-spacing:-2px;font-weight:900}
body:not(.layout-wizard) .hero-art{border-radius:32px;box-shadow:var(--sh-ios-hi)}
body:not(.layout-wizard) .floating-note{background:var(--glass);-webkit-backdrop-filter:blur(16px);backdrop-filter:blur(16px);border-radius:16px;animation:ios-float 6s ease-in-out infinite}
.note-two{animation-delay:-3s!important}
@keyframes ios-float{50%{transform:translateY(-6px)}}
.eyebrow{background:#fff0f6;border:1px solid #fbd6e6}
.section{padding:52px 0}
.section-head h2{font-size:28px;letter-spacing:-1px;font-weight:850}

/* ---- Formulaires : champs larges façon iOS ---- */
body:not(.layout-wizard) .field input,body:not(.layout-wizard) .field select,body:not(.layout-wizard) .field textarea,
body:not(.layout-wizard) .filters select,body:not(.layout-wizard) .filters input{
  min-height:52px;border-radius:var(--r-input);border:1.5px solid #f0e6ec;background:#fffafc;padding:0 16px;font-size:16px;
  transition:border-color .2s,box-shadow .25s,background .2s,transform .3s var(--ios-spring);
}
body:not(.layout-wizard) .field textarea{padding:14px 16px;min-height:110px}
body:not(.layout-wizard) .field input:focus,body:not(.layout-wizard) .field select:focus,body:not(.layout-wizard) .field textarea:focus{
  background:#fff;border-color:var(--pink);box-shadow:0 0 0 4px rgba(216,27,96,.12)}
.field label{font-size:13px;font-weight:800;letter-spacing:-.1px}
.tag,.chip,.status{border-radius:999px}

/* ---- Menu espace membre : pastilles défilantes ---- */
.sidebar{border-radius:var(--r-card)!important;border-color:transparent!important;box-shadow:var(--sh-ios);scroll-snap-type:x proximity;scrollbar-width:none}
.sidebar::-webkit-scrollbar{display:none}
.side-link{border-radius:12px;scroll-snap-align:start;transition:background .2s,color .2s,transform .3s var(--ios-spring)}
.side-link:active{transform:scale(.95)}
.flash{border-radius:16px}

/* ---- Pied de page + messages ---- */
.footer{border-radius:32px 32px 0 0}

/* ---- Barre d'onglets (mobile) ---- */
.ios-tabbar{display:none}
@media(max-width:699px){
  body:not(.layout-wizard):not(.layout-admin){padding-bottom:calc(var(--tab-h) + env(safe-area-inset-bottom) + 12px)}
  .ios-tabbar{
    display:flex;position:fixed;z-index:50;left:12px;right:12px;bottom:calc(10px + env(safe-area-inset-bottom));
    height:var(--tab-h);padding:6px;border-radius:26px;
    background:var(--glass);-webkit-backdrop-filter:saturate(180%) blur(24px);backdrop-filter:saturate(180%) blur(24px);
    border:1px solid var(--glass-line);box-shadow:0 14px 40px rgba(45,20,34,.16);
    transform:translateY(0);transition:transform .45s var(--ios-ease);
  }
  body.tab-hide .ios-tabbar{transform:translateY(calc(100% + 30px))}
  .ios-tabbar a{flex:1;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:3px;border-radius:20px;
    color:#8a8189;font-size:10.5px;font-weight:700;letter-spacing:-.1px;position:relative;transition:color .2s,background .25s,transform .35s var(--ios-spring)}
  .ios-tabbar a:active{transform:scale(.88)}
  .ios-tabbar svg{width:23px;height:23px;fill:none;stroke:currentColor;stroke-width:1.9;stroke-linecap:round;stroke-linejoin:round}
  .ios-tabbar a.on{color:var(--pink);background:#fff0f6}
  .ios-tabbar a.on svg{fill:rgba(216,27,96,.14)}
  .ios-tabbar a.cta{color:#fff;background:linear-gradient(135deg,#e5247a,#D81B60);box-shadow:0 8px 18px rgba(216,27,96,.38);flex:.9}
  .ios-tabbar a.cta svg{stroke-width:2.4}
  .mobile-menu[data-mobile-menu]{display:none}
}
@media(min-width:700px){.container{max-width:1160px}}

/* ---- Sélecteur de propositions (aperçu) ---- */
.ui-picker{position:fixed;z-index:60;left:50%;transform:translateX(-50%);bottom:calc(var(--tab-h) + 26px + env(safe-area-inset-bottom));display:flex;gap:4px;padding:5px;border-radius:999px;
  background:var(--glass);-webkit-backdrop-filter:blur(20px);backdrop-filter:blur(20px);box-shadow:0 10px 30px rgba(45,20,34,.16);font-size:12px;font-weight:800}
.ui-picker a{padding:7px 12px;border-radius:999px;color:#6b646d}
.ui-picker a.on{background:var(--pink);color:#fff}

/* ---- Mode sombre : on garde la logique existante, on adoucit le verre ---- */
html[data-theme=dark]{--glass:rgba(28,24,30,.72);--glass-line:rgba(255,255,255,.08)}
html[data-theme=dark] .ios-tabbar a.on{background:rgba(216,27,96,.18)}

@media(min-width:700px){.ui-picker{bottom:18px}}

/* ---- Hero : la photo ne prend plus tout l'écran (cadre fixe, recadrage haut) ---- */
body:not(.layout-wizard) .hero-art.hero-art-photo{
  height:clamp(300px,82vw,420px);overflow:hidden;border-radius:32px;display:block;position:relative;
  background:linear-gradient(150deg,#fff0f6,#ffe3ee);box-shadow:var(--sh-ios-hi);
}
body:not(.layout-wizard) .hero-art-photo>img{width:100%;height:100%;object-fit:cover;object-position:50% 18%;mix-blend-mode:normal}
body:not(.layout-wizard) .hero-art-photo .floating-note{z-index:3}
@media(min-width:900px){body:not(.layout-wizard) .hero-art.hero-art-photo{height:480px}}
.hero{padding:26px 0 34px}
