/* bewertung.css – Kommentare, Statistik, Zutaten-Auswahl (aus style.css ausgelagert, unveraendert) */

/* --- Kommentare View Styling --- */
.kommentare-filter {
    display: flex;
    gap: 10px;
    margin-bottom: 20px;
    flex-wrap: wrap;
}

.kommentare-filter select {
    flex: 1 1 160px;
    min-width: 0;
    padding: 12px 15px;
    border: 2px solid #e9ecef;
    border-radius: 25px;
    font-size: 14px;
    outline: none;
    background: white;
    cursor: pointer;
    transition: border-color 0.3s ease;
}

.kommentare-filter select:focus {
    border-color: #667eea;
}

#kommentare-liste {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.comment-item {
    display: flex;
    align-items: flex-start;
    gap: 14px;
    background: #f8f9fa;
    border: 1px solid #e9ecef;
    padding: 16px 18px;
    border-radius: 14px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.06);
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.comment-item:hover {
    border-color: #667eea;
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.15);
}

.comment-avatar {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: linear-gradient(135deg, #667eea, #764ba2);
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 1.15rem;
    flex-shrink: 0;
}

.comment-body {
    flex: 1;
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.comment-head {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
}

.comment-head strong {
    font-weight: 700;
    color: #333;
    font-size: 1.05rem;
}

.comment-stars {
    color: #e6a800;
    letter-spacing: 1px;
    white-space: nowrap;
}

.comment-meta {
    font-size: 0.85rem;
    color: #6c757d;
}

.comment-text {
    font-style: italic;
    border-left: 3px solid #764ba2;
    padding-left: 10px;
    margin: 6px 0 0;
    color: #555;
    word-break: break-word;
}

.comment-actions {
    flex-shrink: 0;
    align-self: center;
}

.comment-actions .btn-small {
    border-radius: 20px;
}

/* --- Statistik View Styling --- */
.statistics-year-selector {
    display: flex;
    align-items: center;
    gap: 10px;
}

.statistics-year-selector select {
    padding: 8px 15px;
    border-radius: 10px;
    font-size: 1rem;
    font-weight: bold;
}

.statistics-year-selector button {
    /* Reuse btn-secondary style but adjust size */
    padding: 8px 12px;
    border-radius: 50%;
    width: 35px;
    height: 35px;
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 1.2rem;
}

.statistics-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
    margin-top: 20px;
}

.statistic-card {
    background: linear-gradient(145deg, #f0f4ff, #ffffff);
    padding: 20px;
    border-radius: 15px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
    border-left: 5px solid #667eea;
    transition: transform 0.3s ease;
}

.statistic-card:hover {
    transform: translateY(-3px);
}

.statistic-card h3 {
    color: #764ba2;
    font-size: 1.1rem;
    margin-bottom: 15px;
    border-bottom: 1px dashed #e9ecef;
    padding-bottom: 5px;
}

.statistic-card .value {
    font-size: 2.5rem;
    font-weight: bold;
    color: #667eea;
    text-align: center;
    margin: 10px 0;
}

/* Specific styling for list-based stats (Top 3) */
.statistic-card ul {
    list-style: none;
    padding: 0;
}

.statistic-card li {
    display: flex;
    justify-content: space-between;
    padding: 8px 0;
    border-bottom: 1px dotted #ccc;
    font-size: 1rem;
}

.statistic-card li:last-child {
    border-bottom: none;
}

.statistic-card .recipe-name,
.statistic-card .person-name {
    font-weight: 600;
    color: #333;
}

/* Shopping List Controls */
.shopping-list-controls {
    display: flex;
    gap: 10px;
    margin-bottom: 20px;
    flex-wrap: wrap;
}

/* TOP Raters List */
.top-raters-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.top-raters-list li {
    display: flex;
    align-items: center;
    padding: 8px 0;
    border-bottom: 1px solid #e9ecef;
}

.top-raters-list li:last-child {
    border-bottom: none;
}

.top-raters-list .rank {
    font-weight: bold;
    color: #667eea;
    margin-right: 10px;
}

/* Zutaten Auswahl Modal */
.zutaten-auswahl-content {
    max-width: 500px;
    max-height: 600px;
    width: 90%;
}

.zutaten-auswahl-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
}

.zutaten-auswahl-header h3 {
    margin: 0;
}

.zutaten-auswahl-search {
    margin-bottom: 15px;
}

.zutaten-auswahl-search input {
    width: 100%;
    padding: 10px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 14px;
}

.zutaten-auswahl-list {
    max-height: 300px;
    overflow-y: auto;
    border: 1px solid #ddd;
    border-radius: 4px;
    margin-bottom: 20px;
}

.zutaten-auswahl-item {
    padding: 12px;
    border-bottom: 1px solid #eee;
    cursor: pointer;
    transition: background-color 0.2s;
}

.zutaten-auswahl-item:hover {
    background-color: #f8f9fa;
}

.zutaten-auswahl-item:last-child {
    border-bottom: none;
}

.zutaten-auswahl-item-name {
    font-weight: 600;
    margin-bottom: 4px;
}

.zutaten-auswahl-item-type {
    font-size: 12px;
    color: #666;
    background: #f0f0f0;
    padding: 2px 8px;
    border-radius: 12px;
    display: inline-block;
}

.zutaten-auswahl-actions {
    display: flex;
    justify-content: flex-end;
    gap: 10px;
}

.zutaten-einheit-selector {
    margin-top: 10px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.zutaten-einheit-selector select {
    flex: 1;
    padding: 8px;
    border: 1px solid #ddd;
    border-radius: 4px;
}

.zutaten-menge-input {
    width: 80px;
    padding: 8px;
    border: 1px solid #ddd;
    border-radius: 4px;
    text-align: center;
}

.zutaten-item-container {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 10px;
    padding: 10px;
    background: #f8f9fa;
    border-radius: 4px;
}

.zutaten-item-info {
    flex: 1;
    font-weight: 500;
}

.zutaten-item-remove {
    background: #dc3545;
    color: white;
    border: none;
    border-radius: 4px;
    padding: 5px 10px;
    cursor: pointer;
    font-size: 12px;
}

.zutaten-item-remove:hover {
    background: #c82333;
    min-width: 30px;
}

.top-raters-list .person-name {
    flex: 1;
    font-weight: 600;
    color: #333;
}

.top-raters-list .count {
    color: #666;
    font-size: 0.9em;
}

/* Responsive adjustments for mobile */
@media (max-width: 768px) {
    .statistics-year-selector {
        flex-wrap: wrap;
        justify-content: center;
    }

    .shopping-list-controls {
        flex-direction: column;
        align-items: stretch;
    }

    .shopping-list-controls .btn-primary,
    .shopping-list-controls .btn-danger {
        width: 100%;
    }

    .top-raters-list li {
        flex-direction: column;
        align-items: flex-start;
        gap: 4px;
    }

    .top-raters-list .rank {
        margin-right: 0;
        margin-bottom: 4px;
    }
}
