/* Ma cave : tableau de bord du membre (ma-cave.html) */

.cv-page { background: var(--background-light); padding-bottom: 4rem; }
.cv-page [hidden] { display: none !important; }

/* En-tête sombre */
.cv-hero { background: radial-gradient(circle at 85% 0%, #5A3420 0%, #2C1810 55%); color: #FBF9F7; padding: 2.4rem 0 2.6rem; }
.cv-hero-top { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: flex-start; gap: 1rem; margin-bottom: 1.8rem; }
.cv-hello { margin: 0 0 0.3rem; color: #E9B98A; font-weight: 600; }
.cv-hero h1 { margin: 0; font-size: clamp(2rem, 5vw, 2.9rem); font-weight: 800; letter-spacing: -0.02em; color: #FFFFFF; }
.cv-reminders { display: inline-flex; align-items: center; gap: 0.45rem; height: 40px; padding: 0 1rem; border-radius: 999px; border: 1.5px solid rgba(255, 255, 255, 0.22); background: transparent; color: #B8A595; font: inherit; font-size: 0.85rem; font-weight: 600; white-space: nowrap; cursor: pointer; transition: background 0.15s, border-color 0.15s, color 0.15s; }
.cv-reminders[hidden] { display: none; }
.cv-reminders:hover { border-color: #F3B26B; color: #FFD9A8; }
.cv-reminders .cv-on { display: none; }
.cv-reminders.is-on { background: rgba(243, 178, 107, 0.16); border-color: #F3B26B; color: #FFD9A8; }
.cv-reminders.is-on .cv-on { display: inline; color: #FFD66B; }
.cv-reminders.is-on .cv-off { display: none; }
.cv-hero-actions { display: flex; flex-wrap: wrap; align-items: center; justify-content: flex-end; gap: 0.6rem; }
.cv-share-btn { display: inline-flex; align-items: center; gap: 0.5rem; height: 40px; padding: 0 1.1rem; border: 0; border-radius: 999px; background: linear-gradient(135deg, #FFD66B, #E8A23A); color: #2C1810; font: inherit; font-size: 0.9rem; font-weight: 700; cursor: pointer; box-shadow: 0 6px 18px rgba(232, 162, 58, 0.3); transition: transform 0.15s; }
.cv-share-btn:hover { transform: translateY(-1px); }
.cv-profile-btn { display: inline-flex; align-items: center; gap: 0.5rem; height: 40px; padding: 0 1.1rem; border: 1.5px solid rgba(255, 255, 255, 0.25); border-radius: 999px; background: rgba(255, 255, 255, 0.06); color: #FBF0DF; font: inherit; font-size: 0.9rem; font-weight: 600; cursor: pointer; transition: background 0.15s, border-color 0.15s; }
.cv-profile-btn:hover { background: rgba(255, 255, 255, 0.12); border-color: rgba(255, 255, 255, 0.45); }
.cv-kpis { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 1rem; }
.cv-kpis div { display: flex; flex-direction: column; gap: 0.25rem; padding: 1.1rem 1.2rem; border-radius: 18px; background: rgba(255, 255, 255, 0.06); border: 1px solid rgba(255, 255, 255, 0.08); }
.cv-kpis strong { font-size: 1.9rem; font-weight: 800; line-height: 1; color: #FFFFFF; }
.cv-kpis span { font-size: 0.85rem; color: #D9C6B0; }

/* Barres de progression */
@keyframes cv-grow { from { transform: scaleX(0); } to { transform: scaleX(1); } }
.cv-bar { height: 12px; border-radius: 999px; background: #F1E8DD; overflow: hidden; }
.cv-bar > span { display: block; height: 100%; border-radius: inherit; background: linear-gradient(90deg, #F3B26B, #D2691E); transform-origin: left center; animation: cv-grow 0.9s cubic-bezier(0.2, 0.8, 0.2, 1); }
.cv-bar-thin { height: 8px; }
.cv-step .cv-step-next { margin-top: 0.35rem; font-weight: 600; color: var(--primary-color); }
.cv-step-next i { font-size: 0.8em; margin-right: 0.2rem; }
.cv-bar { position: relative; }
/* Repères du calendrier de la recette (retraits, goûter) : creux tant qu'ils ne sont pas faits */
.cv-bar-mark { position: absolute; top: 50%; width: 8px; height: 8px; margin: -4px 0 0 -4px; border-radius: 50%; background: #FFFFFF; box-shadow: 0 0 0 2px #B5651D; }
.cv-bar-mark.is-done { background: #B5651D; box-shadow: 0 0 0 2px #FFFFFF; }
.cv-static .cv-bar > span { animation: none; }

/* Mise en page */
.cv-layout { display: flex; flex-direction: column; gap: 2rem; margin-top: 2rem; }
.cv-layout > * { min-width: 0; }
.cv-section-head { display: flex; justify-content: space-between; align-items: center; gap: 1rem; margin-bottom: 1rem; }
.cv-section-head h2, .cv-today h2 { margin: 0; font-size: 1.4rem; font-weight: 800; }
.cv-card { padding: 1.5rem; border-radius: 24px; background: #FFFFFF; border: 1px solid var(--border-color); }
.cv-more-link { font-size: 0.88rem; font-weight: 600; color: var(--primary-color); text-decoration: none; }

/* Aujourd'hui */
.cv-today { padding: 1.5rem; border-radius: 24px; background: #FFF8F1; border: 1px solid #F1DCC4; }
.cv-today h2 { display: flex; align-items: center; gap: 0.5rem; margin-bottom: 1rem; }
.cv-today h2 i { color: #F3A33B; }
.cv-tasks { display: flex; flex-direction: column; gap: 0.7rem; }
.cv-task { display: flex; align-items: center; gap: 0.9rem; padding: 0.8rem 0.9rem; border-radius: 16px; background: #FFFFFF; }
.cv-task-icon { flex-shrink: 0; display: grid; place-items: center; width: 42px; height: 42px; border-radius: 12px; background: #F4E6D6; color: var(--primary-color); }
.cv-task.is-ready .cv-task-icon { background: #E8F4EC; color: #1F7A4D; }
.cv-task-text { flex: 1; display: flex; flex-direction: column; gap: 0.1rem; min-width: 0; }
.cv-task-text strong { font-size: 0.95rem; }
.cv-task-text span { font-size: 0.85rem; color: var(--text-light); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

/* Aujourd'hui dans le bandeau sombre du haut de page */
.cv-hero .cv-today { margin-bottom: 1.2rem; padding: 1.1rem 1.2rem; border-radius: 20px; background: rgba(255, 255, 255, 0.06); border: 1px solid rgba(255, 243, 226, 0.14); }
.cv-hero .cv-today h2 { margin-bottom: 0.8rem; font-size: 1.15rem; color: #FFFFFF; }
.cv-hero .cv-today h2 i { color: #FFD66B; }
.cv-hero .cv-tasks { gap: 0.5rem; }
.cv-hero .cv-task { padding: 0.65rem 0.75rem; background: rgba(255, 255, 255, 0.07); border-radius: 14px; }
.cv-hero .cv-task-icon { width: 38px; height: 38px; background: rgba(243, 178, 107, 0.18); color: #F3B26B; }
.cv-hero .cv-task.is-ready .cv-task-icon { background: rgba(127, 203, 155, 0.2); color: #7FCB9B; }
.cv-hero .cv-task-text strong { color: #FFFFFF; }
.cv-hero .cv-task-text span { color: #D9C6B0; }
.cv-hero .cv-task .btn-outline { background: transparent; border-color: #F3B26B; color: #FFD9A8; }
.cv-hero .cv-task .btn-outline:hover { background: #F3B26B; color: #2C1810; }

/* Filtres */
.cv-filters { display: flex; flex-wrap: wrap; gap: 0.5rem; margin-bottom: 1rem; }
.cv-filters button { display: inline-flex; align-items: center; gap: 0.45rem; height: 40px; padding: 0 1rem; border-radius: 999px; border: 1.5px solid var(--border-color); background: #FFFFFF; color: var(--text-dark); font: inherit; font-size: 0.88rem; font-weight: 600; cursor: pointer; }
.cv-filters button span { padding: 0.05rem 0.45rem; border-radius: 999px; background: #F4E6D6; color: var(--primary-color); font-size: 0.75rem; }
.cv-filters button.is-active { background: #2C1810; border-color: #2C1810; color: #FBF9F7; }
.cv-filters button.is-active span { background: rgba(255, 255, 255, 0.18); color: #FBF9F7; }

/* Bocaux */
.cv-list { display: grid; grid-template-columns: minmax(0, 1fr); gap: 1.1rem; }
@media (min-width: 1000px) { .cv-list { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1.4rem; } }
.cv-jar { display: flex; flex-direction: column; gap: 1rem; padding: 1.4rem; border-radius: 24px; background: #FFFFFF; border: 1.5px solid var(--border-color); }
.cv-jar.cv-ready { border-color: #2E9E62; box-shadow: 0 8px 24px rgba(31, 122, 77, 0.1); }
.cv-jar-head { display: flex; align-items: center; gap: 1rem; }
.cv-jar-icon { flex-shrink: 0; display: flex; flex-direction: column; align-items: center; width: 46px; }
.cv-jar-lid { width: 28px; height: 8px; border-radius: 3px; background: var(--primary-color); }
.cv-jar-glass { position: relative; width: 42px; height: 50px; border-radius: 11px; background: #F6EFE6; border: 2px solid #D8C8B4; overflow: hidden; }
.cv-jar-glass span { position: absolute; left: 0; right: 0; bottom: 0; background: linear-gradient(180deg, #F3B26B, #C8752E); transition: height 0.8s ease; }
.cv-ready .cv-jar-glass span { background: linear-gradient(180deg, #7FCB9B, #2E9E62); }
.cv-done .cv-jar-glass span { background: linear-gradient(180deg, #C9A27A, #8B4513); }
.cv-jar-title { flex: 1; display: flex; flex-direction: column; gap: 0.2rem; min-width: 0; }
.cv-jar-title a { font-size: 1.1rem; font-weight: 700; color: var(--text-dark); text-decoration: none; line-height: 1.3; }
.cv-jar-title a:hover { color: var(--primary-color); }
.cv-jar-title span { font-size: 0.85rem; color: var(--text-light); }
.cv-jar-badge { flex-shrink: 0; font-size: 1.15rem; font-weight: 800; color: var(--primary-color); }
.cv-ready .cv-jar-badge { color: #1F7A4D; }
.cv-done .cv-jar-badge { font-size: 0.85rem; padding: 0.25rem 0.7rem; border-radius: 999px; background: #F4E6D6; }
.cv-ready .cv-bar > span { background: linear-gradient(90deg, #7FCB9B, #2E9E62); }
.cv-bar-legend { display: flex; justify-content: space-between; gap: 1rem; margin-top: -0.5rem; font-size: 0.85rem; color: var(--text-light); }
.cv-step { display: flex; align-items: center; gap: 1rem; padding: 0.9rem 1rem; border-radius: 16px; background: #FBF5EE; }
.cv-ready .cv-step { background: #E8F4EC; }
.cv-step > div { flex: 1; display: flex; flex-direction: column; gap: 0.2rem; }
.cv-step strong { font-size: 0.95rem; color: var(--primary-color); }
.cv-ready .cv-step strong { color: #1F7A4D; }
.cv-step span { font-size: 0.88rem; line-height: 1.5; color: #4A3226; }
.cv-step .btn { flex-shrink: 0; }
.cv-jar-foot { display: flex; align-items: center; justify-content: space-between; gap: 0.6rem; flex-wrap: wrap; margin-top: auto; } /* toujours en bas : les cartes d'une même rangée gardent la même structure */
.cv-chip { display: inline-flex; align-items: center; gap: 0.45rem; height: 40px; padding: 0 1rem; border-radius: 999px; border: 1.5px solid var(--border-color); background: #FFFFFF; color: var(--text-dark); font: inherit; font-size: 0.88rem; font-weight: 600; cursor: pointer; }
.cv-chip:hover { border-color: var(--primary-color); color: var(--primary-color); }
.cv-chip-main { border-color: var(--secondary-color); color: var(--secondary-color); }
/* Poubelle en haut à droite de la carte */
.cv-jar-remove { flex-shrink: 0; display: grid; place-items: center; width: 34px; height: 34px; border: 0; border-radius: 10px; background: none; color: var(--text-muted); font-size: 0.85rem; cursor: pointer; transition: background 0.15s, color 0.15s; }
.cv-jar-remove:hover { background: #FDECEA; color: #B3261E; }

/* Actions secondaires dans le pied de carte */
/* Rangée sous un séparateur, actions regroupées au centre avec un espacement régulier */
.cv-jar-actions { display: flex; align-items: center; justify-content: center; flex-wrap: wrap; gap: 0.4rem 1rem; width: 100%; padding-top: 0.7rem; border-top: 1px solid var(--border-color); }
.cv-short { display: none; }
@media (max-width: 520px) {
    .cv-long { display: none; }
    .cv-short { display: inline; }
    .cv-jar-actions > * { padding: 0 0.4rem; }
}
.cv-jar-link { display: inline-flex; align-items: center; gap: 0.4rem; height: 36px; padding: 0 0.85rem; border-radius: 999px; font-size: 0.82rem; font-weight: 600; color: var(--text-light); text-decoration: none; transition: background 0.15s, color 0.15s; white-space: nowrap; }
.cv-jar-link:hover { background: var(--background-light); color: var(--primary-color); }
.cv-jar-link i { font-size: 0.78rem; }
.cv-jar-notify { display: inline-flex; align-items: center; gap: 0.4rem; height: 34px; padding: 0 0.85rem; border-radius: 999px; border: 1.5px solid var(--border-color); font-size: 0.82rem; font-weight: 600; color: var(--text-muted); cursor: pointer; transition: background 0.15s, color 0.15s, border-color 0.15s; white-space: nowrap; }
.cv-jar-notify:hover { border-color: var(--primary-color); color: var(--primary-color); }
.cv-jar-notify i { font-size: 0.78rem; }
.cv-jar-notify .cv-on { display: none; }
.cv-jar-notify:has(input:checked) { background: #FDF0E1; border-color: #F3B26B; color: var(--primary-color); }
.cv-jar-notify:has(input:checked) .cv-on { display: inline; }
.cv-jar-notify:has(input:checked) .cv-off { display: none; }
.cv-jar-notify:has(input:focus-visible) { outline: 3px solid var(--primary-color); outline-offset: 2px; }
.cv-jar-notify--disabled { opacity: 0.5; cursor: pointer; }
.cv-jar-notify--disabled input { cursor: pointer; }

/* Bocal vide */
.cv-empty { display: flex; flex-direction: column; align-items: center; text-align: center; gap: 0.8rem; padding: 2.5rem 1.5rem; border-radius: 24px; background: #FFFFFF; border: 1.5px dashed #D8C8B4; }
.cv-empty-jar { display: block; width: 64px; height: 76px; border-radius: 16px; border: 3px solid #D8C8B4; position: relative; background: #F6EFE6; }
.cv-empty-jar::before { content: ''; position: absolute; top: -12px; left: 12px; right: 12px; height: 10px; border-radius: 4px; background: var(--primary-color); }
.cv-empty-jar span { position: absolute; left: 6px; right: 6px; bottom: 6px; height: 30%; border-radius: 8px; background: linear-gradient(180deg, #F3B26B, #C8752E); opacity: 0.6; }
.cv-empty h3 { margin: 0.4rem 0 0; font-size: 1.35rem; }
.cv-empty p { margin: 0; max-width: 460px; color: var(--text-light); line-height: 1.6; }
/* Deux boutons de même largeur, côte à côte ; l'un sous l'autre sur mobile */
.cv-empty-actions { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0.75rem; width: 100%; max-width: 480px; margin-top: 0.6rem; }
.cv-empty-actions .btn { justify-content: center; min-height: 50px; }
@media (max-width: 520px) { .cv-empty-actions { grid-template-columns: minmax(0, 1fr); max-width: 320px; } }

/* Sauvegarde — bandeau pleine largeur dans le hero (fond sombre) */
.cv-save--hero { display: flex; align-items: center; gap: 1.1rem; padding: 1rem 1.3rem; margin-top: -0.4rem; margin-bottom: 1.6rem; border-radius: 16px; background: rgba(176, 42, 20, 0.22); border: 1px solid rgba(220, 80, 50, 0.45); }
.cv-save--hero .cv-save-icon { flex-shrink: 0; display: grid; place-items: center; width: 42px; height: 42px; border-radius: 12px; background: rgba(220, 80, 50, 0.25); color: #F0846A; font-size: 1.05rem; }
.cv-save--hero div { flex: 1; display: flex; flex-direction: column; gap: 0.2rem; min-width: 0; }
.cv-save--hero strong { font-size: 0.95rem; font-weight: 700; color: #FFFFFF; line-height: 1.3; }
.cv-save--hero span { font-size: 0.85rem; color: #D9C6B0; line-height: 1.5; }
.cv-save-btn { flex-shrink: 0; background: #FFFFFF; color: #2C1810; border: none; font-weight: 700; }
.cv-save-btn:hover { background: #F1DCC4; }

/* Pour quand ? */
.cv-occasions { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 0.6rem; }
.cv-occasion { display: flex; align-items: center; gap: 0.9rem; padding: 0.8rem; border-radius: 16px; background: var(--background-light); color: inherit; text-decoration: none; transition: background 0.15s; }
.cv-occasion:hover { background: #FFF3E3; }
.cv-occasion-emoji { flex-shrink: 0; display: grid; place-items: center; width: 44px; height: 44px; border-radius: 12px; background: #FFFFFF; font-size: 1.4rem; }
.cv-occasion-text { flex: 1; display: flex; flex-direction: column; gap: 0.1rem; min-width: 0; }
.cv-occasion-text strong { font-size: 0.98rem; }
.cv-occasion-text small { font-size: 0.8rem; color: var(--text-muted); }
.cv-occasion-text em { font-style: normal; font-size: 0.82rem; font-weight: 600; color: #1F7A4D; }
.cv-occasion-text em.cv-urgent { color: #B3261E; }
.cv-occasion > i { color: var(--text-muted); font-size: 0.8rem; }

/* Défis et badges */
.cv-badges-count { font-size: 0.85rem; font-weight: 600; color: var(--text-light); }
.cv-badges-total { height: 8px; margin: -0.3rem 0 1.2rem; border-radius: 999px; background: #F1E8DD; overflow: hidden; }
.cv-badges-total span { display: block; height: 100%; border-radius: inherit; background: linear-gradient(90deg, #F3B26B, #D2691E); transition: width 0.6s ease; }
.cv-badge-list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 0.5rem; }
.cv-badge > a, .cv-badge > div { display: flex; align-items: center; gap: 0.9rem; padding: 0.7rem; border-radius: 16px; color: inherit; text-decoration: none; }
.cv-badge > a:hover { background: var(--background-light); }
.cv-badge-icon { flex-shrink: 0; display: grid; place-items: center; width: 44px; height: 44px; border-radius: 50%; background: #F1E8DD; color: #A8927C; font-size: 1.05rem; }
.cv-badge.is-on .cv-badge-icon { background: linear-gradient(135deg, #F3B26B, #D2691E); color: #FFFFFF; box-shadow: 0 4px 12px rgba(210, 105, 30, 0.3); }
.cv-badge-body { flex: 1; display: flex; flex-direction: column; gap: 0.35rem; min-width: 0; }
.cv-badge-row { display: flex; justify-content: space-between; gap: 0.5rem; align-items: baseline; }
.cv-badge-row strong { font-size: 0.92rem; }
.cv-badge-row em { font-style: normal; font-size: 0.78rem; font-weight: 700; color: var(--text-muted); white-space: nowrap; }
.cv-badge.is-on .cv-badge-row em { color: #1F7A4D; }
.cv-badge.is-on .cv-bar > span { background: linear-gradient(90deg, #7FCB9B, #2E9E62); }
.cv-badge-body small { font-size: 0.78rem; color: var(--text-muted); }

/* Envies */
.cv-wish-list { display: grid; grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); gap: 0.6rem; }
.cv-wish { display: flex; align-items: center; gap: 0.6rem; padding: 0.7rem 0.8rem; border-radius: 14px; background: var(--background-light); }
.cv-wish > div { flex: 1; display: flex; flex-direction: column; min-width: 0; }
.cv-wish a { font-weight: 600; font-size: 0.92rem; color: var(--text-dark); text-decoration: none; }
.cv-wish span { font-size: 0.78rem; color: var(--text-muted); }
.cv-icon-btn { flex-shrink: 0; display: grid; place-items: center; width: 36px; height: 36px; border: 0; border-radius: 50%; background: none; color: var(--text-muted); cursor: pointer; }
.cv-icon-btn:hover { background: #F7E3E0; color: #B3261E; }

@media (max-width: 640px) {
    .cv-hero { padding: 1.6rem 0 1.8rem; }
    .cv-kpis { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0.6rem; }
    .cv-kpis div { padding: 0.9rem; }
    .cv-kpis strong { font-size: 1.6rem; }
    .cv-layout { margin-top: 1.4rem; gap: 1.6rem; }
    .cv-jar { padding: 1.1rem; }
    .cv-step { flex-direction: column; align-items: stretch; }
    .cv-task { flex-wrap: wrap; }
    .cv-task-text { flex-basis: calc(100% - 60px); }
    .cv-task-text span { white-space: normal; }
    .cv-task .btn { width: 100%; justify-content: center; }
    .cv-step .btn { justify-content: center; }
    .cv-save, .cv-save--hero { flex-wrap: wrap; align-items: flex-start; }
    .cv-save--hero div { flex-basis: calc(100% - 60px); }
    .cv-save--hero .cv-save-btn { width: 100%; }
    .cv-card, .cv-today { padding: 1.2rem; }
}

/* Partager ma cave (js/cave-share.js) */
button.cv-jar-link { border: 0; background: none; font: inherit; font-size: 0.82rem; font-weight: 600; cursor: pointer; }
.cs-sheet { gap: 1rem; }
.cs-intro { margin: 0; color: var(--text-light); font-size: 0.92rem; line-height: 1.55; }
/* Interrupteurs on / off */
.cs-visibility { border: 1.5px solid var(--border-color); border-radius: 16px; background: #FFFFFF; overflow: hidden; }
.cs-toggle { display: flex; align-items: center; justify-content: space-between; gap: 1rem; padding: 0.8rem 1rem; cursor: pointer; }
.cs-toggle > span { display: flex; flex-direction: column; gap: 0.15rem; font-size: 0.92rem; font-weight: 600; color: var(--text-dark); }
.cs-toggle > span i { color: var(--primary-color); width: 1.2em; }
.cs-toggle small { font-weight: 400; font-size: 0.8rem; color: var(--text-light); }
.cs-toggle-main { padding: 0.95rem 1rem; }
.cs-show { border-top: 1px solid var(--border-color); background: var(--background-light); }
.cs-show .cs-toggle > span { display: block; }
.cs-show .cs-toggle + .cs-toggle { border-top: 1px solid #EFE6DB; }
.cs-switch { appearance: none; -webkit-appearance: none; flex-shrink: 0; position: relative; width: 46px; height: 26px; margin: 0; border-radius: 999px; background: #D8CCBF; cursor: pointer; transition: background 0.2s; }
.cs-switch::before { content: ""; position: absolute; top: 3px; left: 3px; width: 20px; height: 20px; border-radius: 50%; background: #FFFFFF; box-shadow: 0 1px 3px rgba(0, 0, 0, 0.25); transition: transform 0.2s; }
.cs-switch:checked { background: var(--primary-color); }
.cs-switch:checked::before { transform: translateX(20px); }
.cs-switch:focus-visible { outline: 3px solid var(--primary-color); outline-offset: 2px; }
.cs-share { display: flex; flex-direction: column; gap: 0.8rem; padding-top: 1rem; border-top: 1px solid var(--border-color); }
.cs-share h3 { margin: 0; font-size: 1.05rem; }
.cs-share-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.cs-preview { align-self: center; font-size: 0.88rem; font-weight: 600; color: var(--primary-color); text-decoration: none; }
.cs-preview:hover { text-decoration: underline; }
@media (max-width: 640px) {
    .cv-hero-actions { justify-content: flex-start; }
}

/* Sans pseudo : la fenêtre de partage renvoie vers « Mon profil » */
.cs-need-pseudo { display: flex; flex-direction: column; align-items: flex-start; gap: 0.7rem; padding: 1rem; border-radius: 16px; background: #FDF0E1; border: 1px solid #F3D3AE; }
.cs-need-pseudo p { margin: 0; font-size: 0.92rem; line-height: 1.5; color: #4A3226; }

/* Mon profil (js/profile-edit.js) */
.pe-sheet { gap: 1.2rem; }
.pe-block { display: flex; flex-direction: column; gap: 0.5rem; }
.pe-block + .pe-block { padding-top: 1.2rem; border-top: 1px solid var(--border-color); }
.pe-label { font-size: 0.85rem; font-weight: 700; color: var(--text-light); }
.pe-row { display: flex; gap: 0.5rem; align-items: center; }
.pe-row input { flex: 1; min-width: 0; min-height: 44px; padding: 0 0.8rem; border: 1.5px solid var(--border-color); border-radius: 12px; font: inherit; background: #FFFFFF; }
.pe-row input:focus { outline: none; border-color: var(--primary-color); }
.pe-row .btn { flex-shrink: 0; min-height: 44px; }
.pe-row [hidden], .pe-email-form[hidden], .pe-row[hidden] { display: none; }
.pe-current { justify-content: space-between; padding: 0.6rem 0.6rem 0.6rem 0.9rem; border-radius: 12px; background: var(--background-light); }
.pe-current span { font-weight: 600; word-break: break-all; }
.pe-email-form { display: flex; flex-direction: column; gap: 0.5rem; }
.pe-status { font-size: 0.8rem; line-height: 1.45; color: var(--text-muted); }
.pe-status.is-ok { color: #1F7A4D; font-weight: 600; }
.pe-status.is-bad { color: #B3261E; font-weight: 600; }
/* Déconnexion et suppression du compte, en bas de Mon profil */
.pe-account-actions { display: flex; align-items: stretch; gap: 0.6rem; }
.pe-account-actions .btn { flex: 1 1 0; min-width: 0; min-height: 44px; justify-content: center; gap: 0.4rem; padding: 0 0.6rem; white-space: nowrap; }
/* Supprimer mon compte : même bouton que « Se déconnecter », en rouge */
.pe-delete-open { border: 2px solid #B3261E; background: #FFFFFF; color: #B3261E; }
.pe-delete-open:hover, .pe-delete-open[aria-expanded="true"] { background: #B3261E; color: #FFFFFF; }
@media (max-width: 480px) { .pe-delete-open .pe-long { display: none; } }
.pe-delete { display: flex; flex-direction: column; gap: 0.6rem; padding: 1rem; border-radius: 14px; background: #FDF0EE; border: 1px solid #F2C9C3; }
.pe-delete[hidden] { display: none; }
.pe-delete p { margin: 0; font-size: 0.88rem; line-height: 1.5; color: #4A3226; }
.pe-danger { background: #B3261E; color: #FFFFFF; border: none; }
.pe-danger:disabled { opacity: 0.45; cursor: not-allowed; }

/* Brassages sur la barre : petits traits (pleins quand c'est fait) */
.cv-bar-tick { position: absolute; top: 3px; bottom: 3px; width: 2px; margin-left: -1px; border-radius: 2px; background: rgba(181, 101, 29, 0.35); }
.cv-bar-tick.is-done { background: rgba(255, 255, 255, 0.9); }

/* « Voir toutes les étapes » : calendrier daté du bocal */
.cv-plan { margin-top: -0.25rem; }
.cv-plan summary { display: inline-flex; align-items: center; gap: 0.4rem; cursor: pointer; list-style: none; font-size: 0.9rem; font-weight: 600; color: var(--primary-color); padding: 0.2rem 0; }
.cv-plan summary::-webkit-details-marker { display: none; }
.cv-plan summary span { font-weight: 400; color: var(--text-light); }
.cv-plan summary i { font-size: 0.75em; transition: transform 0.2s; }
.cv-plan[open] summary i { transform: rotate(180deg); }
.cv-plan ol { list-style: none; margin: 0.5rem 0 0; padding: 0 0 0 0.25rem; display: grid; gap: 0; }
.cv-plan li { position: relative; display: grid; grid-template-columns: 6.2rem 1.4rem 1fr auto; align-items: center; gap: 0.4rem; padding: 0.4rem 0; font-size: 0.88rem; color: #4A3226; border-bottom: 1px dashed #EADCCB; }
.cv-plan li:last-child { border-bottom: 0; }
.cv-plan time { color: var(--text-light); font-variant-numeric: tabular-nums; white-space: nowrap; }
.cv-plan li > i { color: #B5651D; text-align: center; }
.cv-plan li.is-done { color: #8A7565; }
.cv-plan li.is-done > i { color: #C9A27E; }
.cv-plan li.is-today { font-weight: 700; }
.cv-plan-remove > i, .cv-plan-taste > i, .cv-plan-filter > i { color: #8B4513; }
.cv-plan-filter .cv-plan-title, .cv-plan-rest .cv-plan-title { font-weight: 600; }
.cv-plan-state { font-size: 0.78rem; font-weight: 600; white-space: nowrap; padding: 0.1rem 0.5rem; border-radius: 999px; }
.cv-plan-state.is-done { color: #2E7D4F; background: #E8F4EC; }
.cv-plan-state.is-today { color: #FFFFFF; background: #D2691E; }
.cv-plan-state.is-missed { color: #8A7565; background: #F3ECE4; }
@media (max-width: 480px) {
    .cv-plan li { grid-template-columns: 4.6rem 1.2rem 1fr; }
    .cv-plan-state { grid-column: 3; justify-self: start; }
}

/* Mes étiquettes (favoris et personnalisées), avant la collection de cartes */
.cv-label-list { display: grid; grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); gap: 0.75rem; }
.cv-label { display: flex; flex-direction: column; gap: 0.15rem; padding: 0 0 0.7rem; border: 1px solid var(--border-color); border-radius: 14px; background: #FFFFFF; color: var(--text-dark); text-decoration: none; overflow: hidden; transition: border-color 0.2s, transform 0.2s; }
.cv-label:hover { border-color: var(--primary-color); transform: translateY(-2px); }
.cv-label-thumb { position: relative; display: flex; align-items: center; justify-content: center; height: 130px; margin-bottom: 0.45rem; background: radial-gradient(circle at 50% 35%, #FFFFFF 0%, #F3EBE1 100%); }
.cv-label-thumb canvas { box-shadow: 0 4px 12px rgba(44, 24, 16, 0.15); }
.cv-label-thumb i { position: absolute; top: 0.5rem; right: 0.55rem; color: #C0392B; font-size: 0.85rem; }
.cv-label strong, .cv-label small { padding: 0 0.7rem; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.cv-label strong { font-size: 0.88rem; }
.cv-label small { font-size: 0.76rem; color: var(--text-muted); }
.coll-intro { margin: -0.6rem 0 0.9rem; font-size: 0.88rem; color: var(--text-muted); }
