/* Whole baskets proposed on a profile: full-screen space, discreet link in Mes courses, row on profiles. */
html.profile-baskets-locked{overflow:hidden}
.profile-baskets-page{box-sizing:border-box;position:fixed;inset:0;width:100vw;max-width:none;height:100dvh;max-height:none;margin:0;padding:0;border:0;border-radius:0;background:var(--bg,#f1f5f6);color:var(--ink,#142b26);overflow:auto;overscroll-behavior:contain}
.profile-baskets-page::backdrop{background:var(--bg,#f1f5f6)}
.profile-baskets-page-head{position:sticky;top:0;z-index:2;display:grid;grid-template-columns:44px 1fr 44px;align-items:center;gap:8px;padding:10px 12px;padding-top:max(10px,env(safe-area-inset-top));background:var(--bg,#f1f5f6);border-bottom:1px solid var(--edge,#ccd7dc)}
.profile-baskets-page-head h2{margin:0;text-align:center;font:700 1.2rem/1.3 Georgia,serif;color:var(--accent,#a9542d);overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.profile-baskets-icon-btn{display:grid;place-items:center;width:44px;height:44px;padding:0;border:0;border-radius:50%;background:transparent;color:var(--ink,#142b26);cursor:pointer}
.profile-baskets-icon-btn:hover{background:var(--soft,#e3eaed)}
.profile-baskets-icon-btn:focus-visible{outline:3px solid var(--accent,#a9542d);outline-offset:2px}
.profile-baskets-icon-spacer{width:44px}
.profile-baskets-page-body{box-sizing:border-box;display:grid;gap:16px;align-content:start;width:min(640px,100%);margin:0 auto;padding:16px 16px calc(32px + env(safe-area-inset-bottom))}
.profile-baskets-page-body .meta{margin:0}
.profile-baskets-subtitle{margin:4px 0 0;font:700 1.1rem/1.3 Georgia,serif;color:var(--ink,#142b26)}
.profile-baskets-step{margin:0;color:var(--muted,#5b6b70);font-size:.85rem;font-weight:700;letter-spacing:.04em;text-transform:uppercase}
.profile-baskets-create{display:grid;gap:12px;padding:0;border:0;border-radius:0;background:transparent}
.profile-baskets-create p{margin:0;line-height:1.45}
.profile-baskets-create .btn{min-height:48px}
.profile-baskets-list{list-style:none;margin:0;padding:0;display:grid;gap:10px}
.profile-basket-summary{display:flex;align-items:center;gap:12px;width:100%;padding:10px;border:1px solid var(--edge,#ccd7dc);border-radius:18px;background:var(--surface,#fff);color:var(--ink,#142b26);font:inherit;text-align:start;cursor:pointer}
.profile-basket-summary:focus-visible{outline:3px solid var(--accent,#a9542d);outline-offset:2px}
.profile-basket-summary>svg{flex:none;color:var(--muted,#5b6b70)}
.profile-basket-summary-text{display:grid;gap:2px;flex:1;min-width:0}
.profile-basket-summary-text strong{font:700 1.05rem/1.3 Georgia,serif;overflow-wrap:anywhere}
/* Photo mosaic standing for the basket. */
.profile-basket-mosaic{flex:none;display:grid;gap:2px;overflow:hidden;border-radius:14px;background:var(--soft,#e3eaed)}
.profile-basket-mosaic img{width:100%;height:100%;object-fit:cover;display:block;min-width:0;min-height:0}
.profile-basket-mosaic.is-card{width:64px;height:64px}
.profile-basket-mosaic.is-hero{width:96px;height:96px;border-radius:18px}
.profile-basket-mosaic.n2,.profile-basket-mosaic.n3,.profile-basket-mosaic.n4{grid-template-columns:1fr 1fr}
.profile-basket-mosaic.n3 img:first-child{grid-row:span 2}
.profile-basket-mosaic.n2{grid-template-rows:1fr}
.profile-basket-mosaic.n4{grid-template-rows:1fr 1fr}
.profile-basket-hero{display:flex;align-items:center;gap:14px;min-width:0}
.profile-basket-hero>div,.profile-basket-hero>label{display:grid;gap:4px;flex:1;min-width:0}
.profile-basket-hero h3{margin:0;font:700 1.35rem/1.25 Georgia,serif;overflow-wrap:anywhere}
/* Recipe lines. */
.profile-basket-recipes{list-style:none;margin:0;padding:0;display:grid;gap:4px}
.profile-basket-recipe{display:flex;align-items:center;gap:10px;min-width:0;padding:6px 0;border-bottom:1px solid var(--edge,#dfe6e9)}
.profile-basket-recipe:last-child{border-bottom:0}
.profile-basket-recipe>button[data-detail]{display:flex;align-items:center;gap:12px;flex:1;min-width:0;min-height:56px;padding:0;border:0;background:transparent;color:var(--ink,#142b26);font:inherit;text-align:start;cursor:pointer}
.profile-basket-recipe>button[data-detail]:focus-visible{outline:3px solid var(--accent,#a9542d);outline-offset:2px;border-radius:12px}
.profile-basket-recipe-text{display:grid;gap:2px;min-width:0}
.profile-basket-recipe-text>span{overflow-wrap:anywhere}
.profile-basket-in-shop{color:var(--muted,#5b6b70);font-size:.85rem;font-style:italic}
.profile-basket-thumb{flex:none;width:56px;height:56px;border-radius:12px;object-fit:cover;background:var(--soft,#eef2f4)}
.profile-basket-recipe.is-loading{color:var(--muted,#5b6b70);min-height:56px}
.profile-basket-recipe.is-excluded>button[data-detail]{opacity:.45}
.profile-basket-recipe.is-excluded .profile-basket-recipe-text>span{text-decoration:line-through}
.profile-basket-toggle{flex:none;min-height:40px;padding:0 14px;border:1px solid var(--edge,#ccd7dc);border-radius:999px;background:var(--surface,#fff);color:var(--ink,#142b26);font:inherit;font-size:.9rem;cursor:pointer}
.profile-basket-toggle[aria-pressed="false"]{border-color:var(--accent,#a9542d);color:var(--accent,#a9542d)}
/* Form and actions. */
.profile-basket-form{display:grid;gap:14px}
.profile-basket-form label{font-weight:700}
.profile-basket-form input{box-sizing:border-box;width:100%;min-height:48px;padding:0 14px;border:1px solid var(--edge,#ccd7dc);border-radius:12px;background:#fff;color:var(--ink,#142b26);font:inherit;font-weight:400}
.profile-basket-footer{display:grid;gap:12px;justify-items:stretch}
.profile-basket-footer .btn{min-height:48px}
.profile-basket-actions{display:flex;flex-wrap:wrap;gap:8px}
.profile-basket-actions .btn{flex:1 1 auto;min-height:44px}
.profile-basket-confirm{display:grid;gap:10px;padding:14px;border-radius:16px;background:var(--soft,#eef2f4)}
.profile-basket-confirm .btn.danger{background:#a3261f;border-color:#a3261f;color:#fff}
.profile-basket-link-danger{justify-self:center;min-height:44px;padding:0 12px;border:0;background:transparent;color:#a3261f;font:inherit;text-decoration:underline;cursor:pointer}
.profile-baskets-notice{display:flex;flex-wrap:wrap;align-items:center;gap:8px;margin:0;padding:10px 14px;border-radius:14px;background:var(--soft,#e3eaed);color:var(--ink,#142b26)}
/* Discreet entry in Mes courses. */
.profile-baskets-share-row{display:flex;justify-content:center;margin:6px 0 0}
.profile-baskets-share-link{display:inline-flex;align-items:center;gap:6px;min-height:40px;padding:0 10px;border:0;background:transparent;color:var(--muted,#5b6b70);font:inherit;font-size:.9rem;text-decoration:underline;text-underline-offset:3px;cursor:pointer}
.profile-baskets-share-link:hover{color:var(--ink,#142b26)}
/* Row of baskets on a profile (own or someone else's). */
.profile-baskets-strip{display:grid;gap:8px;margin:14px 0 4px;min-width:0}
.profile-baskets-strip>header{display:flex;align-items:center;justify-content:space-between;gap:8px}
.profile-baskets-strip h3{display:flex;align-items:center;gap:6px;margin:0;font:700 1.05rem/1.3 Georgia,serif;color:var(--ink,#142b26)}
.profile-baskets-strip h3 svg{color:var(--accent,#a9542d)}
.profile-baskets-strip-all{min-height:40px;padding:0 6px;border:0;background:transparent;color:var(--accent,#a9542d);font:inherit;font-weight:700;cursor:pointer}
.profile-baskets-strip ul{list-style:none;margin:0;padding:2px 2px 6px;display:flex;gap:10px;overflow-x:auto;scroll-snap-type:x mandatory;scrollbar-width:none}
.profile-baskets-strip ul::-webkit-scrollbar{display:none}
.profile-baskets-strip li{flex:none;scroll-snap-align:start}
.profile-baskets-strip-card{display:grid;gap:4px;justify-items:start;width:132px;padding:8px;border:1px solid var(--edge,#ccd7dc);border-radius:16px;background:var(--surface,#fff);color:var(--ink,#142b26);font:inherit;text-align:start;cursor:pointer}
.profile-baskets-strip-card .profile-basket-mosaic{width:114px;height:86px;border-radius:12px}
.profile-baskets-strip-card strong{width:100%;font-size:.92rem;line-height:1.25;overflow:hidden;display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical}
.profile-baskets-strip-card .meta{font-size:.8rem;margin:0}
.profile-baskets-strip-card:focus-visible,.profile-baskets-strip-all:focus-visible,.profile-baskets-share-link:focus-visible,.profile-basket-toggle:focus-visible,.profile-basket-link-danger:focus-visible{outline:3px solid var(--accent,#a9542d);outline-offset:2px}
/* Private / public choice. */
.profile-basket-visibility{justify-self:start;font-size:.72rem;font-weight:700;border-radius:999px;padding:2px 8px;background:var(--soft,#eef3f5);color:var(--muted,#5b6b70)}
.profile-basket-visibility.is-public{background:#e3f3e4;color:#2f7a3a}
.profile-basket-public{display:flex;gap:10px;align-items:flex-start;margin:12px 0;padding:12px 14px;border:1px solid var(--border,#c7d5d9);border-radius:14px;background:var(--card,#fff);cursor:pointer}
.profile-basket-public input{width:20px;height:20px;margin:2px 0 0;flex:0 0 auto;accent-color:var(--ink,#1d2b30)}
.profile-basket-public span{display:grid;gap:2px}.profile-basket-public small{color:var(--muted,#5b6b70);font-size:.8rem}
.profile-basket-done-note{margin:0;text-align:center;color:var(--muted,#5b6b70);font-size:.92rem}
.profile-basket-row{display:flex;flex-wrap:wrap;gap:10px}.profile-basket-row:empty{display:none}.profile-basket-row>.btn{flex:1 1 0;min-width:0;padding-left:10px;padding-right:10px}.profile-basket-row>p{flex-basis:100%;margin:0}.profile-basket-footer .profile-basket-link-danger{min-height:36px;font-size:.9rem}
/* 30/11/2026: an opened basket lists its recipes like « Mes courses »; « Liste / Cases » switches to the feed cards. */
#profile-baskets-dialog .pb-view-toggle{display:inline-flex;gap:4px;margin:4px 0 12px;padding:4px;border:1px solid var(--line,#c7d5d9);border-radius:999px;background:var(--surface,#fffdf9)}
#profile-baskets-dialog .pb-view-toggle button{min-height:36px;padding:6px 16px;border:0;border-radius:999px;background:none;color:var(--ink,#203448);font:600 .92rem Arial,sans-serif;cursor:pointer}
#profile-baskets-dialog .pb-view-toggle button[aria-pressed=true]{background:var(--accent,#a4512c);color:#fff}
#profile-baskets-dialog .pb-shop-lines{list-style:none;margin:0;padding:0}
#profile-baskets-dialog .pb-shop-line{position:relative;display:grid;grid-template-columns:78px minmax(0,1fr);gap:12px;align-items:center;padding:10px 0;border-bottom:1px solid var(--line,#c7d5d9)}
#profile-baskets-dialog .pb-shop-photo{width:78px;height:78px;border-radius:12px;object-fit:cover}
#profile-baskets-dialog .pb-shop-open{position:absolute;inset:0;border:0;background:none;cursor:pointer}
#profile-baskets-dialog .pb-shop-body{display:grid;gap:6px;min-width:0}
#profile-baskets-dialog .pb-shop-body>strong{font:italic 700 1.05rem/1.2 Georgia,serif;color:var(--ink,#203448);white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
#profile-baskets-dialog .work-shop-information{display:grid;grid-template-columns:minmax(0,1fr) auto;gap:6px;align-items:center;min-width:0}
#profile-baskets-dialog .work-shop-facts{grid-column:1/-1;display:flex;flex-wrap:wrap;gap:5px;font:700 .8rem/1.2 Arial,sans-serif;color:var(--ink,#203448)}
#profile-baskets-dialog .work-shop-facts>*{padding:4px 6px;border:1px solid var(--line,#c7d5d9);border-radius:7px;background:var(--surface,#fffdf9);font:inherit;color:inherit;white-space:nowrap}
#profile-baskets-dialog .work-shop-score{grid-column:1;justify-self:start}
#profile-baskets-dialog .work-shop-score ct-i{display:flex;align-items:center;gap:1px}
#profile-baskets-dialog .work-shop-score .ctl-strip i{display:grid;place-items:center;width:12px;height:17px;border-radius:3px;color:#fff;font:700 .58rem Arial,sans-serif;font-style:normal;opacity:.55}
#profile-baskets-dialog .work-shop-score .ctl-strip i.on{width:22px;height:26px;border-radius:6px;font-size:.9rem;opacity:1}
#profile-baskets-dialog .work-shop-portions{grid-column:2;justify-self:end;display:flex;gap:4px;align-items:baseline;padding:4px 7px;border-radius:7px;background:#f5e2cf;color:var(--accent,#a4512c);white-space:nowrap}
#profile-baskets-dialog .work-shop-portions b{font-size:1rem}#profile-baskets-dialog .work-shop-portions small{font-size:.8rem;font-weight:700}
/* Grid test (two columns): « Sociale » and « Recettes », without nutrition. */
#profile-baskets-dialog .pb-grid-kind{margin-top:-4px}
#profile-baskets-dialog .pb-grid{list-style:none;margin:0;padding:0;display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:12px 10px}
#profile-baskets-dialog .pb-grid-tile{position:relative;display:flex;flex-direction:column;gap:6px;min-width:0;padding:0 0 8px;border:1px solid var(--line,#c7d5d9);border-radius:16px;background:var(--surface,#fffdf9);overflow:hidden}
#profile-baskets-dialog .pb-grid-photo{display:block;aspect-ratio:1/1;background:#e9eef0}
#profile-baskets-dialog .pb-grid-tile.is-recipes .pb-grid-photo{aspect-ratio:4/5}
#profile-baskets-dialog .pb-grid-photo img{width:100%;height:100%;object-fit:cover;display:block}
#profile-baskets-dialog .pb-grid-open{position:absolute;inset:0 0 auto 0;aspect-ratio:1/1;border:0;background:none;cursor:pointer}
#profile-baskets-dialog .pb-grid-tile.is-recipes .pb-grid-open{aspect-ratio:4/5}
#profile-baskets-dialog .pb-grid-text{display:grid;gap:4px;padding:0 10px;min-width:0}
#profile-baskets-dialog .pb-grid-title{font:700 .95rem/1.2 Georgia,serif;color:var(--ink,#203448);display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden}
#profile-baskets-dialog .pb-grid-author{display:flex;align-items:center;gap:6px;min-width:0;font:.78rem Arial,sans-serif;color:var(--muted,#5b6b78)}
#profile-baskets-dialog .pb-grid-author img{width:20px;height:20px;border-radius:50%;object-fit:cover;flex:none}
#profile-baskets-dialog .pb-grid-author span{white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
#profile-baskets-dialog .pb-grid-tile .wide-recipe-social{display:flex;justify-content:space-between;align-items:center;gap:0;margin:0;padding:2px 6px 0;border:0}
#profile-baskets-dialog .pb-grid-tile .wide-recipe-social button{display:inline-flex;align-items:center;gap:3px;min-width:0;min-height:32px;padding:2px 4px;border:0;background:none;color:var(--muted,#5b6b78);font:.78rem Arial,sans-serif}
#profile-baskets-dialog .pb-grid-tile .wide-recipe-social svg{width:17px;height:17px}
#profile-baskets-dialog .pb-grid-chips{position:absolute;left:8px;top:8px;display:flex;gap:4px;pointer-events:none}
#profile-baskets-dialog .pb-grid-chips span{padding:3px 7px;border-radius:999px;background:rgba(255,253,249,.92);color:var(--ink,#203448);font:700 .74rem Arial,sans-serif}
#profile-baskets-dialog .pb-grid-rating{font:.78rem Arial,sans-serif;color:var(--muted,#5b6b78)}
#profile-baskets-dialog .pb-grid-add{margin:2px 10px 0;min-height:36px;padding:6px 8px;font-size:.85rem;border-radius:999px}
#profile-baskets-dialog .pb-grid-rating{display:flex;align-items:center;gap:3px}#profile-baskets-dialog .pb-grid-rating svg{width:13px!important;height:13px!important;flex:none}#profile-baskets-dialog .pb-grid-rating *{font-size:.78rem!important}
#profile-baskets-dialog .pb-grid-tile .pb-grid-photo,#profile-baskets-dialog .pb-grid-tile .pb-grid-open{aspect-ratio:6/5}#profile-baskets-dialog .pb-grid-tile .pb-grid-add{margin-top:4px}
/* Every tile the same size: a fixed 6:5 photo frame (the « Cases » format), a two-line title, a one-line author. */
#profile-baskets-dialog .pb-grid{align-items:stretch}
#profile-baskets-dialog .pb-grid-tile .pb-grid-photo{position:relative;aspect-ratio:auto!important;height:0!important;padding-top:83.333%!important;overflow:hidden}
#profile-baskets-dialog .pb-grid-tile .pb-grid-photo img{position:absolute!important;inset:0!important;width:100%!important;height:100%!important;max-width:none!important;max-height:none!important;object-fit:cover!important}
#profile-baskets-dialog .pb-grid-tile .pb-grid-open{aspect-ratio:auto!important;height:0;padding-top:83.333%}
#profile-baskets-dialog .pb-grid-title{line-height:1.2!important;height:2.4em;-webkit-line-clamp:2!important}
#profile-baskets-dialog .pb-grid-author{height:20px}
#profile-baskets-dialog .pb-grid-tile .pb-grid-add{margin-top:auto}
