/* Google Fonts Import */
@import url('https://fonts.googleapis.com/css2?family=Nunito:ital,wght@0,400;0,600;0,700;0,800;1,400;1,600&display=swap');

/* =========================================
   1. 全局变量与基础样式
   ========================================= */
:root {
    /* Core */
    --primary:      #1C3D2E;   /* deep forest — authoritative botanical green */
    --primary-dark: #102318;   /* darkest — overlays, fun fact bg */
    --secondary:    #1C3D2E;

    /* Surfaces */
    --bg:           #f2efdc;   /* warm cream background */
    --card-bg:      #FFFFFF;
    --border:       #E0D9CF;   /* warm grey — subtle, not cold */

    /* Text */
    --text-primary: #1A1A18;   /* near-black warm — easier on eyes than #000 */
    --sage:         #6A7C6F;   /* muted sage — secondary text */

    /* Semantic badges — solid filled, white text */
    --badge-green-bg:  #2D6A4F; /* confident forest green — edible / safe */
    --badge-green-text: #fff;
    --badge-amber-bg:  #B5691E; /* burnt sienna amber — partial / caution */
    --badge-amber-text: #fff;
    --badge-red-bg:    #C0392B; /* deep botanical red — danger / not edible */
    --badge-red-text:  #fff;

    /* Accents */
    --accent-coral:  #D4694A;  /* terracotta — quote border, highlights */
    --accent-green:  #52A676;  /* mid green — active dots, chips */
    --quote-bg:      #EDF4EA;  /* very pale sage — quote card */
    --story-bg:      #EDF4EA;  /* story cards */
    --fun-fact-bg:   var(--story-bg);  /* fun fact box — matches story card bg */

    --safe-bottom: env(safe-area-inset-bottom, 20px);
}

* { margin: 0; padding: 0; box-sizing: border-box; }

body {
    font-family: 'Nunito', sans-serif;
    background: var(--bg);
    min-height: 100vh;
    color: #333;
    overflow-x: hidden;
}

.container {
    max-width: 520px;
    margin: 0 auto;
    min-height: 100vh;
    position: relative;
    padding: 64px 24px 28px;
    padding-bottom: calc(28px + var(--safe-bottom));
}

@media (min-width: 768px) {
    .container {
        max-width: 640px;
        padding: 72px 32px 40px;
    }
}

.beta-notice {
    position: fixed;
    bottom: calc(10px + var(--safe-bottom));
    left: 10px; font-size: 12px; color: #666;
    z-index: 9999; background: rgba(245, 245, 220, 0.9);
    padding: 5px 10px; border-radius: 5px; pointer-events: none;
}

h1 {
    color: var(--secondary);
    text-align: center; font-size: 28px; margin-bottom: 20px;
    display: flex; align-items: center; justify-content: center; gap: 10px;
}

/* =========================================
   2. 上传区域 (Upload Area)
   ========================================= */
.upload-card {
    background: var(--card-bg);
    border-radius: 20px;
    padding: 20px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.05);
    margin-bottom: 20px;
    position: relative;
    overflow: hidden;
}

.upload-area {
    display: flex; flex-direction: column; align-items: center; justify-content: center;
    border: 3px dashed #d3d3d3; border-radius: 15px;
    width: 100%; min-height: 200px; padding: 30px 20px;
    box-sizing: border-box; cursor: pointer;
    background: #fafafa; transition: all 0.3s;
}

.upload-area:hover { border-color: var(--primary); background: #fdfdf9; }
.camera-icon { width: 64px; height: 64px; margin-bottom: 15px; display: block; }
.upload-hint { color: #666; font-size: 18px; font-weight: 600; margin-bottom: 5px; }
.sub-hint { font-size: 13px; color: #999; }
#fileInput { display: none; }

.preview-container { display: none; width: 100%; margin-top: 10px; }
.preview-img {
    width: 100%; max-height: 350px; object-fit: contain;
    border-radius: 15px; box-shadow: 0 4px 10px rgba(0,0,0,0.1); display: block;
}

/* =========================================
   3. 结果卡片样式 (Result Cards)
   ========================================= */
.id-result-screen { display: none; animation: slideUp 0.5s ease; }

.result-container { text-align: center; }

.result-user-img {
    width: 100%; height: 250px; object-fit: cover;
    border-radius: 20px; margin-bottom: 15px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
}

.plant-header {
    margin-bottom: 20px;
    text-align: center;
    padding: 0 8px;
}
.plant-name-display {
    font-size: 28px; font-weight: 800; color: var(--primary);
    line-height: 1.2; margin-bottom: 4px;
    font-family: 'Nunito', sans-serif;
}
.scientific-name {
    font-size: 14px; font-style: italic; color: var(--sage);
    margin-bottom: 8px;
}
.confidence-pill {
    display: inline-block; background: var(--badge-green-bg); color: var(--badge-green-text);
    padding: 6px 14px; border-radius: 20px; font-size: 12px; font-weight: bold;
    margin-bottom: 12px;
}

.feature-list {
    display: flex; flex-direction: column; gap: 12px; margin-bottom: 25px;
}

.feature-card {
    background: #fff;
    border-radius: 12px;
    padding: 15px 20px;
    text-align: left;
    box-shadow: 0 2px 8px rgba(0,0,0,0.05);
    border: 1px solid rgba(0,0,0,0.05);
}

.feature-title {
    font-size: 14px; font-weight: 700; color: var(--secondary);
    text-transform: uppercase; letter-spacing: 0.5px;
    margin-bottom: 6px; display: block;
}

.feature-content {
    font-size: 15px; color: #444; line-height: 1.6;
}

.read-more-link {
    color: var(--primary);
    font-weight: bold;
    cursor: pointer;
    margin-left: 5px;
    text-decoration: underline;
}

.error-card {
    background: #fff5f5; border: 1px solid #ffcdd2;
    border-radius: 15px; padding: 25px; text-align: center;
    margin-top: 20px; display: none;
}
.error-title { color: #c62828; font-weight: bold; margin-bottom: 10px; font-size: 18px; }
.error-text { color: #555; font-size: 14px; margin-bottom: 15px; }

.action-buttons { display: flex; flex-direction: column; gap: 10px; margin-top: 20px; }
.btn-primary, .btn-secondary, .btn-retry {
    border: none; padding: 16px; border-radius: 30px;
    font-size: 16px; font-weight: 600; cursor: pointer;
    transition: transform 0.2s; width: 100%;
}
.btn-primary { background: var(--primary); color: white; box-shadow: 0 4px 10px rgba(139, 149, 86, 0.3); }
.btn-secondary { background: #e0e0e0; color: #555; }
.btn-retry { background: var(--secondary); color: white; }
.btn-primary:hover, .btn-secondary:hover { transform: translateY(-2px); }

/* =========================================
   4. 测验样式 (Quiz Styles)
   ========================================= */
.quiz-screen { display: none; }
.quiz-screen.active { display: block; }
/* ── Quiz appbar with title ── */
.quiz-appbar {
    display: flex; align-items: center; justify-content: center;
    position: relative;
    padding: 12px 0 8px;
    margin-bottom: 6px;
}
.quiz-appbar-title {
    text-align: center;
    font-family: 'Nunito', sans-serif !important;
    font-size: 18px; font-weight: 800;
    color: var(--primary);
    letter-spacing: 0.3px;
    pointer-events: none;
}
.quiz-appbar .back-btn {
    position: absolute; left: 0;
}
.header { display: flex; align-items: center; margin-bottom: 20px; }
.back-btn {
    font-size: 14px; color: #666; cursor: pointer; padding: 8px 15px;
    background: rgba(255,255,255,0.5); border-radius: 20px;
    display: flex; align-items: center; justify-content: center;
    min-width: 60px; border: 1px solid rgba(0,0,0,0.05); font-weight: 600;
}
.back-btn svg { width: 20px; height: 20px; stroke-width: 2.5; display: block; }
.progress-bar { flex: 1; height: 8px; background: #d3d3d3; border-radius: 10px; margin-left: 15px; overflow: hidden; }
.progress-fill { height: 100%; background: var(--primary); width: 0%; border-radius: 10px; transition: width 0.5s ease; }

.question-card { background: #808a4d; border-radius: 20px; padding: 30px 25px; margin-bottom: 30px; box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1); }
.question-title { font-size: 16px; font-weight: 600; color: rgba(255,255,255,0.8); margin-bottom: 10px; }
.question-text { font-size: 18px; color: #fff; line-height: 1.5; }

.options-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 15px; }
.option-card {
    background: white; border: 2px solid #333; border-radius: 15px; padding: 0;
    cursor: pointer; transition: all 0.3s; position: relative; min-height: 160px;
    display: flex; flex-direction: column; overflow: hidden;
}
.option-card-img { width: 100%; height: 110px; object-fit: cover; background-color: #f0f0f0; border-bottom: 1px solid #eee; }
.option-text { font-size: 15px; color: #333; text-align: center; font-weight: 500; padding: 10px; display: flex; align-items: center; justify-content: center; flex-grow: 1; }
.option-number { position: absolute; top: 10px; left: 10px; font-size: 20px; font-weight: bold; color: var(--primary); background: rgba(255, 255, 255, 0.9); padding: 2px 8px; border-radius: 8px; z-index: 5; }

/* =========================================
   5. Fullscreen Overlay
   ========================================= */
.fullscreen-overlay { position: fixed; top: 0; left: 0; width: 100vw; height: 100vh; background: #808a4d; z-index: 1000; display: none; perspective: 1000px; }
.fullscreen-overlay.active { display: block; }
.fullscreen-overlay.expanding { animation: expandFromCard 0.4s ease-out; }
.fullscreen-overlay.cannot-tell { background: #d9d9d9; }
.flip-container { width: 100%; height: 100%; transform-style: preserve-3d; transition: transform 0.8s cubic-bezier(0.4, 0.0, 0.2, 1); }
.flip-container.flipped { transform: rotateY(180deg); }

.flip-front {
    position: absolute;
    width: 100%;
    height: 100%;
    backface-visibility: hidden;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 30px;
    background: #808a4d;
}

.flip-back {
    position: absolute;
    width: 100%;
    height: 100%;
    backface-visibility: hidden;
    transform: rotateY(180deg);
    background: #808a4d;
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
    padding: 0;
}

.flip-back-content {
    width: 100%;
    padding: 30px;
    margin: auto 0;
    flex-shrink: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.fullscreen-option { font-size: 32px; color: white; font-weight: 600; text-align: center; margin-bottom: 20px; }

.fullscreen-img {
    width: auto;
    max-width: 100%;
    height: auto;
    max-height: 220px;
    object-fit: contain;
    background: rgba(255, 255, 255, 0.2);
    display: none;
    border-radius: 24px;
    box-shadow: 0 8px 20px rgba(0,0,0,0.15);
    margin-bottom: 20px;
    border: 4px solid white;
}

.explanation { font-size: 18px; color: white; text-align: center; line-height: 1.6; margin-bottom: 30px; }
.result-status { font-size: 24px; font-weight: bold; margin-bottom: 15px; padding: 10px 20px; border-radius: 10px; display: none; }
.result-status.correct { background: #d4edda; color: #155724; }
.result-status.wrong { background: #f8d7da; color: #721c24; }

.overlay-btn { padding: 12px 30px; font-size: 16px; border-radius: 30px; border: none; cursor: pointer; font-weight: 600; margin: 10px; transition: transform 0.2s; }
.overlay-btn:hover { transform: scale(1.05); }
.btn-white { background: white; color: var(--primary); }
.btn-dark { background: var(--secondary); color: white; }

.loading-overlay { position: absolute; top: 0; left: 0; right: 0; bottom: 0; background: rgba(255,255,255,0.9); display: none; flex-direction: column; align-items: center; justify-content: center; z-index: 10; }
.spinner { width: 40px; height: 40px; border: 4px solid #f3f3f3; border-top: 4px solid var(--primary); border-radius: 50%; animation: spin 1s linear infinite; }
.loading-inline { display: inline-block; width: 16px; height: 16px; border: 2px solid rgba(255,255,255,0.3); border-radius: 50%; border-top-color: white; animation: spin 1s infinite linear; }
@keyframes spin { 100% { transform: rotate(360deg); } }
@keyframes slideUp { from { transform: translateY(20px); opacity: 0; } to { transform: translateY(0); opacity: 1; } }
@keyframes expandFromCard { from { transform: scale(0.1); opacity: 0; } to { transform: scale(1); opacity: 1; } }

/* =========================================
   6. 总结页样式 (Summary Page)
   ========================================= */
.summary-wrapper {
    padding: 10px 5px 30px 5px;
    animation: slideUp 0.6s ease-out;
}
.summary-skeleton {
    opacity: 0.4;
    animation: skeletonPulse 1.4s ease-in-out infinite;
}
@keyframes skeletonPulse { 0%, 100% { opacity: 0.4; } 50% { opacity: 0.7; } }

.summary-hero {
    text-align: center;
    margin-bottom: 30px;
}

.hero-icon-circle {
    width: 60px; height: 60px;
    background: #e8f5e9;
    border-radius: 50%;
    display: inline-flex; align-items: center; justify-content: center;
    margin-bottom: 15px;
    box-shadow: 0 4px 10px rgba(139, 149, 86, 0.2);
}

.hero-icon-circle svg {
    width: 32px; height: 32px;
    stroke: var(--primary);
    stroke-width: 3;
}

.hero-title {
    font-size: 22px; font-weight: 800;
    color: var(--secondary);
    margin-bottom: 20px;
    letter-spacing: -0.5px;
}

.hero-plant-img {
    width: 120px; height: 120px;
    object-fit: cover;
    border-radius: 24px;
    box-shadow: 0 8px 20px rgba(0,0,0,0.15);
    margin-bottom: 15px;
    border: 4px solid white;
}

.hero-plant-name {
    font-size: 24px; font-weight: 800;
    color: #333;
    margin-bottom: 5px;
}

.section-label {
    font-size: 14px; font-weight: 700;
    color: #888;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 15px;
    margin-left: 5px;
}

.takeaway-card-styled {
    background: white;
    border-radius: 16px;
    padding: 18px;
    margin-bottom: 12px;
    display: flex;
    align-items: flex-start;
    gap: 15px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.03);
    border: 1px solid rgba(0,0,0,0.02);
    transition: transform 0.2s;
}

.takeaway-num {
    background: var(--primary);
    color: white;
    width: 28px; height: 28px;
    border-radius: 8px;
    display: flex; align-items: center; justify-content: center;
    font-size: 14px; font-weight: bold;
    flex-shrink: 0;
    margin-top: 2px;
}

.takeaway-content {
    font-size: 15px;
    color: #444;
    line-height: 1.5;
    font-weight: 500;
}

.fun-fact-box {
    background: var(--story-bg);
    border: 1.5px solid var(--border);
    border-radius: 16px;
    padding: 20px;
    position: relative;
    margin-top: 10px;
    margin-bottom: 40px;
}

.fun-fact-icon {
    position: absolute;
    top: -15px; left: 20px;
    background: var(--primary);
    color: white;
    padding: 4px 12px;
    border-radius: 12px;
    font-size: 12px; font-weight: 800;
    text-transform: uppercase;
}

.fun-fact-text {
    color: var(--sage);
    font-size: 15px;
    line-height: 1.6;
    font-weight: 500;
}

.summary-actions {
    display: flex; flex-direction: column; gap: 12px;
}

.btn-ghost {
    background: transparent;
    color: #999;
    font-size: 14px;
    border: none;
    padding: 10px;
    cursor: pointer;
    text-decoration: underline;
}

.bottom-safe-spacer {
    width: 100%;
    height: 60px;
    min-height: calc(60px + env(safe-area-inset-bottom, 20px));
    background: transparent;
    flex-shrink: 0;
    pointer-events: none;
    display: block;
}

/* =========================================
   7. Description Modal Styles
   ========================================= */
.modal-overlay {
    position: fixed;
    top: 0; left: 0; width: 100%; height: 100%;
    background: rgba(0, 0, 0, 0.6);
    z-index: 2000;
    display: none;
    align-items: center;
    justify-content: center;
    padding: 20px;
    backdrop-filter: blur(5px);
    animation: fadeIn 0.3s ease;
}

.modal-box {
    background: white;
    width: 100%;
    max-width: 500px;
    max-height: 80vh;
    border-radius: 20px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.2);
    display: flex;
    flex-direction: column;
    overflow: hidden;
    animation: scaleIn 0.3s ease;
}

.modal-header {
    padding: 15px 20px;
    border-bottom: 1px solid #eee;
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: #fafafa;
}

.modal-header h3 { margin: 0; color: var(--secondary); font-size: 18px; }

.close-modal-btn {
    background: none; border: none; font-size: 24px; color: #999;
    cursor: pointer; line-height: 1;
}

.modal-body {
    padding: 20px;
    overflow-y: auto;
    font-size: 16px; line-height: 1.6; color: #444;
}

@keyframes fadeIn { from { opacity: 0; } to { opacity: 1; } }
@keyframes scaleIn { from { transform: scale(0.9); opacity: 0; } to { transform: scale(1); opacity: 1; } }

/* =========================================
   8. Auth & History Styles
   ========================================= */
.app-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 20px;
}

.app-header h1 {
    margin-bottom: 0;
}

.btn-icon {
    background: rgba(255, 255, 255, 0.7);
    border: 1px solid rgba(0, 0, 0, 0.08);
    border-radius: 20px;
    padding: 7px 14px;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    color: var(--secondary);
    transition: all 0.2s;
}

.btn-icon:hover {
    background: rgba(255, 255, 255, 0.9);
}

#userMenu {
    display: flex;
    gap: 8px;
    align-items: center;
}

#usernameDisplay {
    font-size: 13px;
    color: #666;
    max-width: 100px;
    overflow: hidden;
    text-overflow: ellipsis;
}

.auth-modal {
    position: fixed;
    top: 0; left: 0; width: 100%; height: 100%;
    background: rgba(0, 0, 0, 0.6);
    z-index: 3000;
    display: none;
    align-items: center;
    justify-content: center;
    padding: 20px;
    backdrop-filter: blur(5px);
}

.auth-modal.active {
    display: flex;
}

.auth-box {
    background: white;
    border-radius: 20px;
    padding: 30px;
    max-width: 400px;
    width: 100%;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.2);
}

.auth-box h2 {
    font-size: 24px;
    font-weight: 800;
    color: var(--secondary);
    margin-bottom: 20px;
    text-align: center;
}

.auth-input-group {
    margin-bottom: 15px;
}

.auth-input-group label {
    display: block;
    font-size: 13px;
    font-weight: 600;
    color: #666;
    margin-bottom: 6px;
}

.auth-input-group input {
    width: 100%;
    padding: 12px 15px;
    border: 1px solid #ddd;
    border-radius: 10px;
    font-size: 14px;
    box-sizing: border-box;
    transition: border-color 0.3s;
}

.auth-input-group input:focus {
    outline: none;
    border-color: var(--primary);
}

.auth-buttons {
    display: flex;
    gap: 10px;
    margin-top: 20px;
}

.auth-btn {
    flex: 1;
    padding: 12px;
    border: none;
    border-radius: 10px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: transform 0.2s;
}

.auth-btn:hover {
    transform: translateY(-2px);
}

.auth-btn-submit {
    background: var(--primary);
    color: white;
}

.auth-btn-cancel {
    background: #e0e0e0;
    color: #555;
}

.auth-toggle {
    text-align: center;
    font-size: 13px;
    color: #999;
    margin-top: 15px;
}

.auth-toggle a {
    color: var(--primary);
    font-weight: 600;
    cursor: pointer;
    text-decoration: underline;
}

.auth-error {
    background: #ffebee;
    color: #c62828;
    padding: 10px 12px;
    border-radius: 8px;
    font-size: 12px;
    margin-bottom: 15px;
    display: none;
}

.history-drawer {
    position: fixed;
    top: 0;
    right: -100%;
    width: 100%;
    max-width: 400px;
    height: 100%;
    background: white;
    z-index: 2500;
    box-shadow: -4px 0 20px rgba(0, 0, 0, 0.15);
    transition: right 0.3s ease;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
}

.history-drawer.active {
    right: 0;
}

.history-drawer-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px;
    border-bottom: 1px solid #eee;
    position: sticky;
    top: 0;
    background: white;
    z-index: 10;
}

.history-drawer-header h3 {
    margin: 0;
    font-size: 18px;
    font-weight: 700;
    color: var(--secondary);
}

.close-drawer-btn {
    background: none;
    border: none;
    font-size: 24px;
    color: #999;
    cursor: pointer;
    padding: 0;
}

.history-list {
    padding: 10px;
}

.history-item {
    padding: 15px;
    margin-bottom: 10px;
    background: #fafafa;
    border-radius: 12px;
    cursor: pointer;
    transition: all 0.2s;
    border: 1px solid #eee;
}

.history-item:hover {
    background: #f0f0f0;
    transform: translateX(-4px);
}

.history-item-name {
    font-weight: 600;
    color: var(--secondary);
    margin-bottom: 4px;
}

.history-item-date {
    font-size: 12px;
    color: #999;
}

.history-empty {
    padding: 40px 20px;
    text-align: center;
    color: #999;
}

.history-backdrop {
    position: fixed;
    top: 0; left: 0; width: 100%; height: 100%;
    background: rgba(0, 0, 0, 0);
    z-index: 2400;
    pointer-events: none;
    transition: background 0.3s ease;
}

.history-backdrop.active {
    background: rgba(0, 0, 0, 0.5);
    pointer-events: auto;
}

/* =========================================
   9. New ID Result Screen Styles
   ========================================= */

.result-hero-img {
    width: 100%;
    height: 280px;
    object-fit: cover;
    border-radius: 20px;
    margin-bottom: 20px;
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.12);
    display: block;
}

.plant-identity {
    padding: 0 4px;
    margin-bottom: 14px;
}

.plant-name-display {
    font-size: 30px;
    font-weight: 800;
    color: #111;
    line-height: 1.15;
    margin-bottom: 4px;
    margin: 0 0 4px 0;
}

.plant-sci-name {
    font-size: 15px;
    font-style: italic;
    color: #777;
    margin-bottom: 4px;
    margin: 0 0 4px 0;
}

.plant-origin {
    font-size: 14px;
    color: #888;
    font-weight: 500;
    margin: 0;
}

.plant-quote {
    background: var(--quote-bg);
    border-left: 4px solid var(--primary);
    border-radius: 0 12px 12px 0;
    padding: 14px 18px;
    margin: 0 0 18px 0;
    font-style: italic;
    font-size: 15px;
    color: #555;
    line-height: 1.6;
}

.badges-row {
    display: flex;
    gap: 10px;
    margin-bottom: 20px;
    flex-wrap: wrap;
}

.badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 7px 14px;
    border-radius: 30px;
    font-size: 13px;
    font-weight: 600;
}

.badge-red {
    background: var(--badge-red-bg);
    color: var(--badge-red-text);
}

.badge-green {
    background: var(--badge-green-bg);
    color: var(--badge-green-text);
}

.badge-icon {
    font-size: 14px;
}

.info-section {
    background: var(--card-bg);
    border-radius: 16px;
    padding: 20px;
    margin-bottom: 16px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04);
}

.section-heading {
    font-size: 14px;
    font-weight: 700;
    color: var(--secondary);
    margin-bottom: 10px;
    margin: 0 0 10px 0;
    text-transform: capitalize;
    letter-spacing: 0.3px;
}

.section-body {
    font-size: 14px;
    color: #555;
    line-height: 1.65;
}

.lookalike-list {
    list-style: none;
    padding: 0;
    margin: 0 0 10px 0;
}

.lookalike-list li {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 7px 0;
    border-bottom: 1px solid #f0f0f0;
    font-size: 14px;
    color: #444;
}

.lookalike-list li:last-child {
    border-bottom: none;
}

.lookalike-bullet {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--primary);
    flex-shrink: 0;
}

.not-poisonous-note {
    margin: 0;
}

.looks-desc {
    font-size: 14px;
    color: #555;
    line-height: 1.65;
    margin-bottom: 14px;
}

/* ── horizontal photo gallery ── */
.gallery-outer {
    overflow-x: auto;
    overflow-y: hidden;
    margin: 0 -20px;          /* bleed to card edge */
    padding: 0 20px 4px;
    scroll-snap-type: x mandatory;
    -webkit-overflow-scrolling: touch;
}
.gallery-outer::-webkit-scrollbar { height: 0; }

.gallery-row {
    display: flex;
    gap: 10px;
    width: max-content;
}

.g-item {
    width: 120px;
    height: 120px;
    border-radius: 14px;
    overflow: hidden;
    flex-shrink: 0;
    position: relative;
    scroll-snap-align: start;
    box-shadow: 0 3px 12px rgba(0,0,0,.12);
    background: #e0e8e0;
}
.g-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}
.g-label {
    position: absolute;
    bottom: 0; left: 0; right: 0;
    background: rgba(26,58,42,.72);
    color: #fff;
    font-size: 9px;
    font-weight: 700;
    letter-spacing: .8px;
    text-transform: uppercase;
    text-align: center;
    padding: 5px 4px;
}

/* sliding progress bar */
.gallery-scroll-track {
    height: 2px;
    background: var(--border, #D9D4C7);
    border-radius: 1px;
    margin-top: 12px;
    position: relative;
    overflow: hidden;
}
.gallery-scroll-thumb {
    position: absolute;
    top: 0; left: 0;
    height: 100%;
    background: var(--primary);
    border-radius: 1px;
    transition: left .12s ease, width .12s ease;
}

.fun-fact-section {
    background: var(--fun-fact-bg);
    border: 2px solid #ffe58f;
}

.fun-fact-text {
    font-size: 14px;
    color: #5d4037;
    line-height: 1.6;
    margin: 0;
}

.btn-dark-green {
    background: var(--primary-dark);
    color: white;
    border: none;
    padding: 16px;
    border-radius: 30px;
    font-size: 16px;
    font-weight: 700;
    cursor: pointer;
    width: 100%;
    box-shadow: 0 4px 12px rgba(90, 107, 46, 0.35);
    transition: transform 0.2s;
}

.btn-dark-green:hover {
    transform: translateY(-2px);
}

.btn-ghost-outline {
    background: transparent;
    color: var(--secondary);
    border: 2px solid var(--secondary);
    padding: 14px;
    border-radius: 30px;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    width: 100%;
    transition: all 0.2s;
}

.btn-ghost-outline:hover {
    background: rgba(44, 62, 80, 0.05);
}
