/**
 * Weinbegleiter - Home v7 Styles
 * Redesign: Welcome + Flaschen-Hero + Restaurant/Supermarkt + Geschmacksprofil CTA
 */

/* ==================== HOME MAIN ==================== */
.home-main {
    padding: 0 1rem;
    padding-top: calc(var(--safe-area-top) + 1rem);
}

/* ==================== HOME HEADER OVERRIDES ==================== */
.home-header {
    padding-right: 0 !important;
}

.home-headline {
    font-size: clamp(0.9375rem, 4vw, 1.1875rem);
    white-space: nowrap;
}

.home-subline {
    font-size: clamp(0.6875rem, 2.8vw, 0.75rem);
    color: var(--text-secondary, var(--gray-600));
    margin: 0.25rem 0 0 0;
    line-height: 1.4;
    white-space: nowrap;
}

/* Profil-Ring: natürliche Position via flex space-between */


/* ==================== ZONE SCANNER v7 ==================== */
.zone-scanner-v7 {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    margin-bottom: 0;
}

/* ==================== Animations für neue Zonen ==================== */
.zone-scanner-v7 { animation: homeEntryFadeUp 0.5s ease 0.1s both; }
.zone-engage-v7  { animation: homeEntryFadeUp 0.5s ease 0.3s both; }


/* ==================== HERO CARD: Weinflasche scannen ==================== */
.scan-hero-v7 {
    /* Weinrot-Gradient (CI-konform, wie .scan-hero in themes.css) */
    background: linear-gradient(135deg, #722F37 0%, #8c2942 40%, #4B0D18 100%);
    border-radius: var(--radius-lg, 1rem);
    padding: 1.5rem;
    color: #fff;
    cursor: pointer;
    transition: all 0.2s ease;
    position: relative;
    overflow: hidden;
}

.scan-hero-v7:hover {
    box-shadow: 0 8px 30px rgba(114, 47, 55, 0.35);
    transform: translateY(-1px);
}

.scan-hero-v7:active {
    transform: translateY(0) scale(0.99);
}

/* Dekorative Kreise (wie .scan-hero) */
.scan-hero-v7::before {
    content: '';
    position: absolute;
    top: -40%;
    right: -15%;
    width: 200px;
    height: 200px;
    border-radius: 50%;
    background: rgba(197, 160, 89, 0.08);
    pointer-events: none;
}

.scan-hero-v7::after {
    content: '';
    position: absolute;
    bottom: -35%;
    left: -10%;
    width: 150px;
    height: 150px;
    border-radius: 50%;
    background: rgba(197, 160, 89, 0.05);
    pointer-events: none;
}

/* Icon + Titel nebeneinander */
.scan-hero-v7-top {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: 0.75rem;
    position: relative;
    z-index: 1;
}

.scan-hero-v7-icon {
    width: 48px;
    height: 48px;
    background: linear-gradient(135deg, rgba(197, 160, 89, 0.28) 0%, rgba(255, 255, 255, 0.15) 100%);
    border: 1px solid rgba(197, 160, 89, 0.25);
    border-radius: 13px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    flex-shrink: 0;
}

.scan-hero-v7-title {
    font-family: 'Playfair Display', Georgia, serif;
    font-size: 1.375rem;
    font-weight: 700;
    margin: 0;
    color: #fff;
    line-height: 1.2;
}

.scan-hero-v7-desc {
    font-size: 0.875rem;
    color: rgba(255, 255, 255, 0.88);
    margin: 0 0 1rem 0;
    line-height: 1.5;
    position: relative;
    z-index: 1;
}

.scan-hero-v7-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    /* Solid Gold – konsistent mit allen anderen CTAs der App */
    background: var(--gold-gradient, linear-gradient(135deg, #C5A059 0%, #D4AF37 50%, #B8860B 100%));
    border: none;
    color: #fff;
    font-size: 0.9375rem;
    font-weight: 600;
    padding: 0.75rem 1.375rem;
    border-radius: var(--radius-full, 9999px);
    box-shadow: var(--shadow-gold, 0 4px 15px rgba(197, 160, 89, 0.4));
    transition: all 0.2s ease;
    position: relative;
    z-index: 1;
}

.scan-hero-v7:hover .scan-hero-v7-btn {
    box-shadow: 0 6px 20px rgba(197, 160, 89, 0.55);
    transform: translateY(-1px);
}


/* ==================== SECONDARY SCAN ROW ==================== */
.scan-secondary-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0.75rem;
}

.scan-secondary-card {
    background: var(--bg-secondary, #fff);
    border: 1px solid var(--border-color, var(--gray-200));
    border-radius: var(--radius-lg, 1rem);
    padding: 1.125rem 1rem;
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    flex-direction: column;
    position: relative;
}

.scan-secondary-card:hover {
    border-color: var(--wine-corporate, #722F37);
    box-shadow: 0 4px 20px rgba(114, 47, 55, 0.1);
}

.scan-secondary-card:active {
    transform: scale(0.98);
}

.scan-secondary-icon {
    display: none;
}

.scan-secondary-emoji {
    font-size: 1.75rem;
    line-height: 1;
    margin-bottom: 0.625rem;
}

.scan-secondary-label {
    font-size: 1rem;
    font-weight: 600;
    color: var(--text-primary, var(--gray-900));
    margin-bottom: 0.25rem;
    line-height: 1.3;
}

.scan-secondary-desc {
    font-size: 0.8125rem;
    color: var(--text-secondary, var(--gray-600));
    line-height: 1.4;
    margin-bottom: 0.375rem;
}

.scan-secondary-hint {
    font-size: 0.75rem;
    color: var(--text-tertiary, var(--gray-400));
    line-height: 1.3;
    font-style: italic;
}


/* ==================== ZONE ENGAGE v7: Geschmacksprofil CTA ==================== */
.zone-engage-v7 {
    margin-top: 0.75rem;
    margin-bottom: 1rem;
}

.taste-profile-cta {
    background: var(--wine-tint-subtle, rgba(114, 47, 55, 0.06));
    border: 1.5px solid var(--border-color, var(--gray-200));
    border-radius: var(--radius-lg, 1rem);
    padding: 1.25rem 1.25rem 1.5rem;
    cursor: pointer;
    transition: all 0.2s ease;
    text-align: center;
}

.taste-profile-cta:hover {
    border-color: var(--wine-corporate, #722F37);
    box-shadow: 0 4px 16px rgba(114, 47, 55, 0.12);
}

.taste-profile-cta:active {
    transform: scale(0.99);
}

.taste-profile-cta-icon {
    display: none;
}

.taste-profile-cta-title {
    font-family: 'Playfair Display', Georgia, serif;
    font-size: 1.125rem;
    font-weight: 600;
    color: var(--text-primary, var(--gray-900));
    margin: 0 0 0.375rem 0;
    line-height: 1.3;
}

.taste-profile-cta-desc {
    font-size: 0.8125rem;
    color: var(--text-secondary, var(--gray-600));
    line-height: 1.5;
    margin: 0 0 1rem 0;
}

.taste-profile-cta-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.375rem;
    background: var(--gold-gradient, linear-gradient(135deg, #C5A059 0%, #D4AF37 50%, #B8860B 100%));
    color: #fff;
    font-size: 0.9375rem;
    font-weight: 600;
    padding: 0.75rem 1.5rem;
    border-radius: var(--radius-full, 9999px);
    transition: all 0.2s ease;
    box-shadow: var(--shadow-gold, 0 4px 15px rgba(197, 160, 89, 0.4));
}

.taste-profile-cta:hover .taste-profile-cta-btn {
    box-shadow: 0 6px 20px rgba(197, 160, 89, 0.55);
    transform: translateY(-1px);
}

/* Text und Icon im Button müssen weiß sein (überschreibt .micro-task-title Farbe) */
.taste-profile-cta-btn .micro-task-title,
.taste-profile-cta-btn span,
.taste-profile-cta-btn svg {
    color: #fff !important;
}


/* ==================== ZONE TASTE ==================== */
.zone-taste {
    margin-top: 0.75rem;
    margin-bottom: 0;
}

.zone-taste-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 0.75rem;
}

.zone-taste-title {
    font-family: 'Playfair Display', Georgia, serif;
    font-size: 1.125rem;
    font-weight: 600;
    color: var(--text-primary, var(--gray-900));
    margin: 0;
}

.zone-taste-link {
    font-size: 0.8125rem;
    font-weight: 500;
    color: var(--gold);
}

.taste-carousel {
    display: flex;
    gap: 0.75rem;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    -webkit-overflow-scrolling: touch;
    padding-bottom: 0.5rem;
    scrollbar-width: none;
}

.taste-carousel::-webkit-scrollbar {
    display: none;
}


/* ==================================================================
   DARK MODE
   ================================================================== */

/* --- data-theme="dark" --- */
[data-theme="dark"] .scan-secondary-card {
    background: var(--bg-secondary);
    border-color: var(--border-color);
}

[data-theme="dark"] .scan-secondary-card:hover {
    border-color: var(--wine-corporate-light, #8c2942);
    box-shadow: 0 4px 20px rgba(140, 41, 66, 0.2);
}

[data-theme="dark"] .taste-profile-cta {
    background: var(--wine-tint-subtle);
    border-color: var(--border-color);
}

[data-theme="dark"] .taste-profile-cta:hover {
    border-color: var(--wine-corporate-light, #8c2942);
    box-shadow: 0 4px 16px rgba(140, 41, 66, 0.2);
}

[data-theme="dark"] .taste-profile-cta-btn {
    box-shadow: 0 4px 15px rgba(197, 160, 89, 0.4);
}

/* --- prefers-color-scheme: dark (Auto-Modus) --- */
@media (prefers-color-scheme: dark) {
    :root:not([data-theme="light"]) .scan-secondary-card {
        background: var(--bg-secondary);
        border-color: var(--border-color);
    }

    :root:not([data-theme="light"]) .scan-secondary-card:hover {
        border-color: var(--wine-corporate-light, #8c2942);
        box-shadow: 0 4px 20px rgba(140, 41, 66, 0.2);
    }

    :root:not([data-theme="light"]) .taste-profile-cta {
        background: var(--wine-tint-subtle);
        border-color: var(--border-color);
    }

    :root:not([data-theme="light"]) .taste-profile-cta:hover {
        border-color: var(--wine-corporate-light, #8c2942);
        box-shadow: 0 4px 16px rgba(140, 41, 66, 0.2);
    }

    :root:not([data-theme="light"]) .taste-profile-cta-btn {
        box-shadow: 0 4px 15px rgba(197, 160, 89, 0.4);
    }
}


/* ==================================================================
   RESPONSIVE
   ================================================================== */

@media (max-height: 680px) {
    .home-headline { font-size: clamp(1rem, 4.5vw, 1.375rem); }
}

@media (max-width: 340px) {
    .home-headline { font-size: clamp(0.875rem, 4.2vw, 1.125rem); }
    .home-subline { font-size: clamp(0.6875rem, 3vw, 0.75rem); }
}

@media (max-width: 320px) {
    .scan-hero-v7 {
        padding: 1.25rem;
    }
    
    .scan-hero-v7-title {
        font-size: 1.125rem;
    }
    
    .scan-secondary-card {
        padding: 0.875rem 0.75rem;
    }
    
    .scan-secondary-emoji {
        font-size: 1.5rem;
    }
}
