/* === PAGE D'ACCUEIL SIMUBEE.COM === */

body.homepage {
    background: linear-gradient(135deg, #ffeb3b 0%, #fbc02d 50%, #f57c00 100%);
    min-height: 100vh;
    margin: 0;
    padding: 0;
    font-family: 'Segoe UI', system-ui, -apple-system, sans-serif;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-start;      /* Commence en haut */
    padding-top: 10vh;                /* Espace raisonnable en haut (10% de la hauteur) */
    color: #1b5e20;
}

@media (max-width: 768px) {
    body.homepage {
        padding-top: 8vh;             /* Encore moins sur mobile */
    }
}

@media (max-height: 600px) {
    body.homepage {
        padding-top: 5vh;             /* Pour les très petits écrans */
    }
}

.home-container {
    text-align: center;
    max-width: 520px;
    width: 90%;
    padding: 20px 15px;
    margin-top: 10px;                 /* Petite marge supplémentaire */
    animation: slideUp 0.9s ease-out;
}

@keyframes slideUp {
    from { opacity: 0; transform: translateY(30px); }
    to   { opacity: 1; transform: translateY(0); }
}

/* Titre principal */
.site-title {
    display: block;
    margin: 0 0 18px 0;
}

.title-main {
    font-size: clamp(3.2rem, 10vw, 6.5rem);
    font-weight: 900;
    background: linear-gradient(45deg, #1b5e20, #2e7d32, #4caf50);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    text-shadow: 0 4px 15px rgba(0,0,0,0.25);
    letter-spacing: -3px;
    line-height: 0.9;
}

.title-sub {
    font-size: clamp(2rem, 7vw, 4rem);
    color: #c62828;
    font-weight: 800;
    text-shadow: 0 3px 12px rgba(200,40,40,0.4);
    display: block;
    letter-spacing: -1px;
}

/* Description */
.home-description {
    color: #1b5e20;
    font-size: clamp(1.1rem, 3.5vw, 1.4rem);
    font-weight: 500;
    margin: 0 0 30px 0;
    line-height: 1.45;
    text-shadow: 0 1px 4px rgba(255,255,255,0.7);
}

.home-description small {
    font-size: 0.82em;
    opacity: 0.92;
    font-weight: 400;
}

/* Bouton principal */
.enter-btn {
    display: inline-flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #4caf50, #2e7d32, #1b5e20);
    color: white;
    padding: 18px 40px;
    border-radius: 50px;
    text-decoration: none;
    font-size: clamp(1.15rem, 4.2vw, 1.45rem);
    font-weight: 700;
    box-shadow: 0 12px 35px rgba(46,125,50,0.55);
    transition: all 0.3s cubic-bezier(0.4,0,0.2,1);
    position: relative;
    overflow: hidden;
    min-height: 70px;
    margin: 0 auto 30px auto;
}

.enter-btn::before {
    content: '';
    position: absolute;
    top: 0; left: -100%;
    width: 100%; height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.25), transparent);
    transition: left 0.6s;
}

.enter-btn:hover::before {
    left: 100%;
}

.enter-btn:hover {
    transform: translateY(-6px) scale(1.03);
    box-shadow: 0 20px 50px rgba(46,125,50,0.75);
    background: linear-gradient(135deg, #66bb6a, #4caf50, #43a047);
}

.enter-btn:active {
    transform: translateY(-2px) scale(1.01);
}

.enter-btn span {
    line-height: 1.1;
}

.enter-btn small {
    font-size: 0.72em;
    opacity: 0.94;
    font-weight: 500;
    margin-top: 4px;
    letter-spacing: 0.6px;
}

/* Badge version */
.version-badge {
    margin-top: 20px;
    padding: 8px 18px;
    background: rgba(255,255,255,0.88);
    border-radius: 30px;
    font-size: 0.9rem;
    color: #444;
    font-weight: 500;
    box-shadow: 0 4px 15px rgba(0,0,0,0.12);
    animation: pulse 2.5s infinite;
}

@keyframes pulse {
    0%, 100% { opacity: 0.85; }
    50%      { opacity: 1; }
}

/* Responsive très petits écrans */
@media (max-width: 480px) {
    .home-container {
        padding: 15px 10px;
    }
    
    .enter-btn {
        padding: 16px 35px;
        min-height: 65px;
    }
    
    .site-title {
        margin-bottom: 15px;
    }
    
    .home-description {
        margin-bottom: 25px;
    }
}



        body {
            font-family: 'Segoe UI', sans-serif;
            background: linear-gradient(135deg, #f5f7fa 0%, #c3cfe2 100%);
            margin: 0;
            padding: 15px;
        }
        .container {
            max-width: 620px;
            margin: 0 auto;
            background: white;
            border-radius: 14px;
            box-shadow: 0 8px 25px rgba(0,0,0,0.15);
            padding: 20px 25px;
        }
        h1 {
            text-align: center;
            color: #2c3e50;
            font-size: 1.8em;
            margin: 0 0 12px 0;
        }
        .poches {
            display: flex;
            justify-content: center;
            gap: 60px;
            margin: 8px 0 10px;
        }
        .poche-container {
            width: 90px;
            height: 90px;
            position: relative;
            cursor: pointer;
            background: transparent;
        }
        .poche-color {
            position: absolute;
            width: 60px;
            height: 60px;
            border-radius: 50%;
            border: 4px solid #fff;
            box-shadow: 0 4px 12px rgba(0,0,0,0.25);
            top: 15px;
            left: 15px;
            z-index: 1;
            transition: all 0.3s ease;
        }
        .poche-color:hover {
            transform: scale(1.08);
        }
        .poche-size {
            position: absolute;
            inset: 0;
            border-radius: 50%;
            display: flex;
            justify-content: space-between;
            align-items: center;
            padding: 0 12px;
            pointer-events: none;
            z-index: 2;
        }
        .size-arrow {
            width: 0;
            height: 0;
            border-style: solid;
            pointer-events: auto;
            user-select: none;
            cursor: pointer;
            filter: drop-shadow(0 2px 4px rgba(0,0,0,0.4));
            position: relative;
            top: 2px;
            transition: opacity 0.3s ease, filter 0.3s ease;
        }
        .size-arrow.minus {
            border-width: 12px 18px 12px 0;
            border-color: transparent #ffffff transparent transparent;
            transform: translateX(-12px);
        }
        .size-arrow.plus {
            border-width: 12px 0 12px 18px;
            border-color: transparent transparent transparent #ffffff;
            transform: translateX(20px);
        }
        .poche-color.gray ~ .poche-size .size-arrow {
            opacity: 0 !important;
            pointer-events: none !important;
        }
        .size-display {
            position: absolute;
            top: 50%;
            left: 50%;
            transform: translate(-50%, -50%);
            font-weight: bold;
            font-size: 1.15em;
            color: white;
            text-shadow: 1px 1px 4px rgba(0,0,0,0.9);
            pointer-events: none;
            z-index: 10;
        }
        .gray { background: #95a5a6; }
        .yellow { background: #f1c40f; }
        .blue { background: #3498db; }
        .red { background: #e74c3c; }
		.purple { background: #800080; }
        .emerald { background: #2ecc71; }
        .abeille-img {
            text-align: center;
            margin: 6px 0 10px;
        }
        .abeille-img img {
            max-width: 140px;
            height: auto;
            border-radius: 10px;
            box-shadow: 0 5px 15px rgba(0,0,0,0.2);
        }
        .select-btn {
            width: 110px;
            height: 40px;
            border-radius: 10px;
            border: 3px solid #fff;
            box-shadow: 0 3px 10px rgba(0,0,0,0.2);
            cursor: pointer;
            transition: all 0.3s ease;
            display: flex;
            align-items: center;
            justify-content: center;
            font-weight: bold;
            font-size: 0.9em;
            color: white;
            text-align: center;
        }
        .select-btn:hover {
            box-shadow: 0 5px 14px rgba(0,0,0,0.25);
        }
        .select-btn.small {
            width: 82px;
            height: 34px;
            font-size: 0.78em;
            padding: 0 3px;
            line-height: 1.1;
        }
        .t-forager { background: #e67e22; }
        .t-nurse { background: #27ae60; }
        .t-guardian { background: #c0392b; }
        .t-ventilator { background: #8e44ad; }
        .t-storer { background: #9b59b6; }
        .t-cleaner { background: #3498db; }
		.t-none { background: #9e9e9f; }
        .e-basic { background: #95a5a6; }
        .e-advanced { background: #27ae60; }
        .e-rare { background: #3498db; }
        .part-bouton {
            width: 35px;
            height: 35px;
            border-radius: 50%;
            border: 2px solid #fff;
            box-shadow: 0 2px 8px rgba(0,0,0,0.2);
            cursor: pointer;
            transition: all 0.3s ease;
            display: flex;
            align-items: center;
            justify-content: center;
            font-weight: bold;
            font-size: 0.75em;
            color: #fff;
        }
        .part-bouton:hover { transform: scale(1.3); }
        .part-normal { background: #bdc3c7; color: #888; }
        .part-og { background: #000000; color: #f1c40f; }
        .part-genesis { background: #27ae60; color: #000; }
        .form-grid {
            display: grid;
            grid-template-columns: 1fr 1fr;
            gap: 10px 20px;
        }
        .stat-row {
            grid-column: 1 / -1;
            display: flex;
            align-items: center;
            gap: 6px;
            justify-content: center;
            max-width: 420px;
            margin: 0 auto;
        }
        .stat-row label {
            width: 130px;
            text-align: right;
            font-size: 0.90em;
            white-space: nowrap;
        }
        .stat-row input {
            width: 40px;
            text-align: center;
            font-size: 1em;
        }
        .stat-row span.add-label {
            margin: 0 4px;                /* réduit l'espace à gauche et à droite du + */
			width: 8px;                  /* force une largeur fixe petite */
			font-size: 1.2em;
			line-height: 1;
			
            font-weight: bold;
            color: #9b59b6;
            text-align: center;
        }
        .top-row {
            grid-column: 1 / -1;
            display: flex;
            justify-content: center;
            align-items: flex-end;
            gap: 30px;
            margin-bottom: 8px;
        }
        .top-row input[type="text"] { width: 180px; text-align: center; }
        .top-row input[type="number"] { width: 100px; text-align: center; }
        .type-ex-row {
            grid-column: 1 / -1;
            display: flex;
            justify-content: center;
            gap: 30px;
            margin: 8px 0;
        }
        .level-row {
            grid-column: 1 / -1;
            text-align: center;
            margin: 6px 0 12px;
        }
        .level-control {
            display: flex;
            align-items: center;
            gap: 8px;
            justify-content: center;
        }
        .level-arrow {
            width: 32px;
            height: 32px;
            background: #9b59b6;
            color: white;
            border-radius: 50%;
            display: flex;
            align-items: center;
            justify-content: center;
            font-size: 1.4em;
            cursor: pointer;
            user-select: none;
            transition: all 0.2s;
        }
        .level-arrow:hover {
            background: #8e44ad;
            transform: scale(1.15);
        }
        .level-display {
            width: 80px;
            text-align: center;
            font-size: 1.1em;
            font-weight: bold;
            color: #2c3e50;
            border: 2px solid #9b59b6;
            border-radius: 6px;
            padding: 4px;
            background: #f9f9f9;
        }
        .level-display.small {
            width: 60px;
            font-size: 1em;
            padding: 3px;
        }
        .support-boxes {
            grid-column: 1 / -1;
            display: flex;
            justify-content: center;
            gap: 20px;
            margin: 15px auto 10px;
            max-width: 580px;
            flex-wrap: wrap;
        }
        .left-column, .right-column {
            display: flex;
            flex-direction: column;
            gap: 12px;
            min-width: 180px;
        }
        .support-frame {
            background: #f8f9fa;
            border: 2px solid #9b59b6;
            border-radius: 12px;
            padding: 10px 12px;
            text-align: center;
            min-width: 180px;
            display: flex;
            flex-direction: column;
            justify-content: center;
        }
        .support-frame.support-small { min-width: 180px; }
        .support-frame.endurance-max-frame { background: #fff3e0; border-color: #ef6c00; }
        .support-frame h3 { margin: 0 0 8px 0; font-size: 0.95em; color: #9b59b6; font-weight: bold; }
        .support-types.support-types-compact { display: flex; flex-direction: row; flex-wrap: nowrap; gap: 10px; justify-content: center; align-items: center; }
        .ventilators-control { display: flex; align-items: center; gap: 6px; justify-content: center; }
        .action-buttons { grid-column: 1 / -1; display: flex; justify-content: center; gap: 12px; margin-top: 15px; flex-wrap: wrap; max-width: 550px; margin-left: auto; margin-right: auto; }
        .action-btn { padding: 10px 18px; font-size: 1em; border: none; border-radius: 8px; cursor: pointer; transition: all 0.2s; min-width: 120px; color: white; text-align: center; }
        .action-btn.calculate { background: #27ae60; }
        .action-btn.calculate:hover { background: #219653; }
        .action-btn.simulate { background: #3498db; }
        .action-btn.simulate:hover { background: #2980b9; }
        .action-btn.share { background: #8e44ad; }
        .action-btn.share:hover { background: #7d3c98; }
        .action-btn.save { background: #e67e22; }
        .action-btn.save:hover { background: #d35400; }
        .share-link { margin-top: 10px; padding: 8px; background: #ecf0f1; border-radius: 7px; font-size: 0.85em; text-align: center; }
        #copy-notification { position: fixed; top: 50%; left: 50%; transform: translate(-50%, -50%); background: rgba(0,0,0,0.85); color: white; padding: 20px 40px; border-radius: 12px; font-size: 1.4em; font-weight: bold; box-shadow: 0 10px 30px rgba(0,0,0,0.6); z-index: 9999; opacity: 0; pointer-events: none; transition: opacity 0.4s ease; }
        #copy-notification.show { opacity: 1; }
        .popup-overlay { position: fixed; inset: 0; background: rgba(0,0,0,0.65); display: flex; justify-content: center; align-items: center; z-index: 2000; backdrop-filter: blur(3px); }
        .popup-content { background: linear-gradient(135deg, #e8f5e9, #c8e6c9); border: 5px solid #2e7d32; border-radius: 16px; width: 90%; max-width: 440px; padding: 25px 20px; position: relative; box-shadow: 0 15px 40px rgba(0,0,0,0.5); color: #1b5e20; text-align: left; }
        .popup-close { position: absolute; top: 12px; right: 18px; background: none; border: none; font-size: 2.4rem; color: #2e7d32; cursor: pointer; }
        .popup-close:hover { color: #d32f2f; transform: scale(1.2); }
        .popup-content h2 { margin: 0 0 16px 0; color: #1b5e20; font-size: 1.4rem; text-align: center; }
        .result-big { font-size: 1.4rem; font-weight: bold; color: #2e7d32; margin: 6px 0 2px 0; text-align: center; }
        .result-line { margin: 10px 0; font-size: 0.8rem; }
        .result-line strong { color: #1b5e20; font-size: 1.05rem; }
        .bonus-section { margin-top: 20px; padding-top: 16px; border-top: 1px solid #a5d6a7; }
		
		/* Styles pour le popup d'erreur */
.error-popup {
    background: linear-gradient(135deg, #fff5f5, #ffebee);
    border: 4px solid #e74c3c;
    color: #c0392b;
    max-width: 380px;
}

.error-popup h3 {
    color: #c0392b;
    margin: 0 0 16px 0;
    font-size: 1.4rem;
}

.error-popup p {
    margin: 8px 0;
    font-size: 1.05rem;
    line-height: 1.4;
}

/* Légère animation d'apparition */
.popup-overlay {
    opacity: 0;
    transition: opacity 0.3s ease;
}
.popup-overlay[style*="display: flex"] {
    opacity: 1;
}

/* Fond miel sur toutes les pages .homepage (accueil + simulateur) */
body.homepage {
    background: linear-gradient(135deg, #ffeb3b 0%, #fbc02d 50%, #f57c00 100%);
    color: #1b5e20;
    min-height: 100vh;
    margin: 0;
    padding: 20px;               /* ← petit padding pour ne pas coller les bords sur mobile */
}

/* On garde le container blanc avec ombre */
.container {
    background: white;
    border-radius: 14px;
    box-shadow: 0 8px 25px rgba(0,0,0,0.15);
    padding: 25px 20px;          /* ← tu peux ajuster */
    max-width: 620px;
    margin: 0 auto;
}

/* Optionnel : si tu veux que le titre h1 soit plus visible sur le fond miel */
.container h1 {
    color: #1b5e20;
    text-align: center;
    margin-bottom: 1.5em;
    text-shadow: 0 2px 8px rgba(255,255,255,0.9);
}

/* ────────────────────────────────────────────────
   Style spécifique pour les champs Base + Add (stats abeille)
   ──────────────────────────────────────────────── */

.stat-input-base,
.stat-input-add {
    width: 44px;                     /* encore plus compact (avant 48px) */
    height: 28px;                    /* hauteur réduite (avant 32px) */
    padding: 3px 4px;                /* padding plus fin pour gagner de la place */
    font-size: 0.95em;               /* un peu plus petit pour coller à la taille */
    font-weight: 500;
    text-align: center;
    
    border: 2px solid #9b59b6;
    border-radius: 8px;              /* coins arrondis un peu moins agressifs */
    
    background: #fdfaff;
    color: #2c3e50;
    
    transition: border-color 0.2s, box-shadow 0.2s, background 0.2s;
}

.stat-input-base:focus,
.stat-input-add:focus {
    outline: none;
    border-color: #8e44ad;
    background: #f8f4ff;
    box-shadow: 0 0 0 3px rgba(142, 68, 173, 0.28);
}

.stat-input-base:hover:not(:focus),
.stat-input-add:hover:not(:focus) {
    border-color: #a569bd;
    background: #fcfaff;
}

.stat-input-base::placeholder,
.stat-input-add::placeholder {
    color: #a569bd;
    opacity: 0.7;
    font-weight: normal;
}



/* Sur mobile : encore plus compact */
@media (max-width: 480px) {
    .stat-input-base,
    .stat-input-add {
        width: 42px;
        height: 18px;
        font-size: 0.92em;
        padding: 1px 2px;
        border-radius: 7px;
    }
}


/*  Authentification */
.auth-hint,
.save-invite {
    line-height: 1.45;
}

.auth-option-btn,
.small-auth-btn {
    display: inline-block;
    padding: 10px 20px;
    border: 1px solid #1b5e20;
    border-radius: 999px;
    color: #1b5e20;
    text-decoration: none;
    font-weight: 500;
    background: rgba(255,255,255,0.4);
    transition: all 0.2s ease;
}

.auth-option-btn:hover,
.small-auth-btn:hover {
    background: rgba(255,255,255,0.7);
    transform: translateY(-1px);
    box-shadow: 0 3px 10px rgba(27,94,32,0.15);
}

.auth-option-btn.google {
    border-color: #1a73e8;
    color: #1a73e8;
    background: rgba(26,115,232,0.08);
}

.auth-option-btn.google:hover {
    background: rgba(26,115,232,0.18);
}