/**
 * Styles Pro pour le calculateur NoCarbono - FIX VISIBILITÉ
 */

:root {
    --cc-primary: #38b2ac;
    --cc-secondary: #4fd1c5;
    --cc-accent: #f6ad55;
    --cc-text: #2d3748;
    --cc-radius: 16px;
    --cc-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.1);
}

.carbon-calculator-wrapper { max-width: 850px; margin: 40px auto; font-family: 'Inter', system-ui, sans-serif; }
.carbon-calculator { background: #fff; border-radius: var(--cc-radius); box-shadow: var(--cc-shadow); padding: 40px; position: relative; }

/* FIX CRITIQUE : Masquage des étapes non actives */
.wizard-content { 
    display: none !important; 
    visibility: hidden;
}
.wizard-content.active { 
    display: block !important; 
    visibility: visible;
    animation: fadeIn 0.4s ease-out;
}

@keyframes fadeIn { from { opacity: 0; } to { opacity: 1; } }

/* Header & Progress */
.carbon-calculator-header-banner { width: 100%; border-radius: var(--cc-radius) var(--cc-radius) 0 0; margin-bottom: -1px; display: block; }
.wizard-progress { margin-bottom: 40px; }
.wizard-steps { display: flex; justify-content: space-between; gap: 10px; }
.wizard-step { flex: 1; text-align: center; opacity: 0.3; }
.wizard-step.active { opacity: 1; }
.step-icon { font-size: 20px; background: #f7fafc; width: 40px; height: 40px; line-height: 40px; border-radius: 50%; margin: 0 auto 5px; display: block; }
.wizard-step.active .step-icon { background: var(--cc-primary); color: white; }
.step-label { font-size: 11px; font-weight: 700; text-transform: uppercase; display: block; }

.wizard-progress-bar { height: 6px; background: #edf2f7; border-radius: 10px; margin-top: 15px; position: relative; }
.wizard-progress-fill { height: 100%; background: var(--cc-primary); border-radius: 10px; transition: width 0.5s ease; width: 20%; }

/* Hide theme headers/breadcrumbs on calculator page */
.page-title, 
.woodmart-breadcrumb, 
.breadcrumb-wrapper, 
.entry-title,
.title-design-default,
.page-title-default,
.main-page-wrapper .page-title,
.wd-breadcrumbs,
.entry-title.title,
.container .entry-title {
    display: none !important;
}

/* Forms Layout */
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; margin-bottom: 15px; }
.form-group { margin-bottom: 20px; }
label { display: block; font-weight: 700; margin-bottom: 8px; color: var(--cc-text); font-size: 15px; }
.big-select, .big-input { width: 100%; border: 2px solid #edf2f7; border-radius: 12px; padding: 12px; font-size: 16px; background: #fff; }
.big-select:focus, .big-input:focus { border-color: var(--cc-primary); outline: none; }

.input-hint { font-size: 12px; color: #718096; margin-top: -5px; margin-bottom: 10px; font-style: italic; }

/* Diet Cards */
.diet-selector { display: grid; grid-template-columns: repeat(auto-fit, minmax(120px, 1fr)); gap: 10px; }
.diet-card { border: 2px solid #edf2f7; padding: 15px; border-radius: 12px; cursor: pointer; text-align: center; transition: 0.2s; }
.diet-card input { display: none; }
.diet-card:has(input:checked) { border-color: var(--cc-primary); background: #f0fff4; }
.diet-icon { font-size: 24px; display: block; }

/* Buttons */
.wizard-navigation { display: flex; justify-content: space-between; margin-top: 30px; }
.btn-wizard { padding: 14px 30px; border-radius: 50px; font-weight: 700; border: none; cursor: pointer; transition: 0.2s; font-size: 16px; }
.btn-next, .btn-calculate { background: var(--cc-primary); color: white; margin-left: auto; }
.btn-prev { background: #edf2f7; color: #718096; }

/* Results */
.score-card-new { background: #f7fafc; padding: 40px; border-radius: 24px; text-align: center; margin: 30px 0; border: 2px solid var(--cc-primary); }
.total-score-big { font-size: 64px; font-weight: 900; }
.score-badge { display: inline-block; padding: 8px 25px; border-radius: 50px; color: white; font-weight: 800; margin-top: 15px; }

.local-equivalences { display: grid; grid-template-columns: 1fr 1fr; gap: 15px; margin: 20px 0; }
.eq-item { background: #fff; border: 1px solid #edf2f7; padding: 15px; border-radius: 16px; text-align: center; }

.breakdown-chart { text-align: left; margin-top: 20px; }
.breakdown-item { display: flex; align-items: center; margin-bottom: 10px; }
.breakdown-label { width: 100px; font-size: 13px; font-weight: 600; }
.breakdown-bar-container { flex: 1; height: 10px; background: #edf2f7; border-radius: 10px; margin: 0 10px; overflow: hidden; }
.breakdown-bar { height: 100%; background: var(--cc-primary); border-radius: 10px; }

/* Masquer le loader par défaut */
#bear-loader { display: none; text-align: center; padding: 50px; }

@media (max-width: 600px) {
    .form-row, .local-equivalences { grid-template-columns: 1fr; }
    .carbon-calculator { padding: 20px; }
    .wizard-steps .step-label { display: none; }
}