/* Diet Session Summary Page Styles */
:root {
    --ds-bg-color: #f4f7fa;
    --ds-card-bg: #ffffff;
    --ds-text-primary: #2b3a57;
    --ds-text-secondary: #506080;
    --ds-accent-color: #f59e0b;
    /* Amber/Gold for Kokumin */
    --ds-shadow-sm: 0 2px 4px rgba(0, 0, 0, 0.05);
    --ds-shadow-md: 0 4px 12px rgba(0, 0, 0, 0.08);
    --ds-radius: 16px;
}

.diet-summary-page {
    background-color: var(--ds-bg-color);
    min-height: 100vh;
    padding-bottom: 60px;
}

.ds-hero {
    background: linear-gradient(135deg, #2b3a57 0%, #1a253a 100%);
    color: white;
    padding: 60px 0;
    text-align: center;
    margin-bottom: 40px;
    position: relative;
    overflow: hidden;
}

.ds-hero::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(255, 255, 255, 0.05) 0%, transparent 60%);
    animation: rotate 60s linear infinite;
}

@keyframes rotate {
    from {
        transform: rotate(0deg);
    }

    to {
        transform: rotate(360deg);
    }
}

.ds-hero-content {
    position: relative;
    z-index: 1;
}

.ds-title {
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 10px;
    letter-spacing: 0.05em;
}

.ds-subtitle {
    font-size: 1.1rem;
    opacity: 0.8;
}

/* Filter/Search Bar */
.ds-controls-wrapper {
    max-width: 1000px;
    margin: 0 auto 30px;
}

.ds-controls {
    background: white;
    padding: 20px;
    border-radius: var(--ds-radius);
    box-shadow: var(--ds-shadow-sm);
    margin-bottom: 15px;
}

.ds-search-group {
    position: relative;
    margin-bottom: 15px;
}

.ds-search-group i {
    position: absolute;
    left: 12px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--ds-text-secondary);
}

.ds-search-input {
    width: 100%;
    padding: 12px 12px 12px 40px;
    border: 1px solid #ddd;
    border-radius: 8px;
    font-size: 1rem;
    background-color: #f9f9f9;
    transition: all 0.2s;
}

.ds-search-input:focus {
    outline: none;
    border-color: var(--ds-accent-color);
    background-color: white;
    box-shadow: 0 0 0 3px rgba(245, 158, 11, 0.1);
}

.ds-filter-row {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
}

.ds-filter-group {
    display: flex;
    align-items: center;
    gap: 8px;
    flex: 1 1 200px;
    /* Allow growing and shrinking, base 200px */
    min-width: 0;
    /* Allow shrinking below content size if needed */
}

/* Specific adjustment for date group to prevent overflow */
.ds-filter-group:last-child {
    flex: 2 1 300px;
    /* Give date group more space preference */
    min-width: 280px;
    /* Ensure date inputs don't get too squashed */
}

.ds-select,
.ds-date-input {
    width: 100%;
    min-width: 0;
    /* Important for flex items */
    padding: 10px 12px;
    /* Slightly reduced padding */
    border: 1px solid #ddd;
    border-radius: 8px;
    font-size: 0.9rem;
    color: var(--ds-text-primary);
    background-color: #f9f9f9;
    transition: all 0.2s;
}

.ds-select:focus,
.ds-date-input:focus {
    outline: none;
    border-color: var(--ds-accent-color);
    background-color: white;
    box-shadow: 0 0 0 3px rgba(245, 158, 11, 0.1);
}

.ds-date-sep {
    color: var(--ds-text-secondary);
    font-weight: bold;
}

.ds-disclaimer {
    font-size: 0.8rem;
    color: #666;
    line-height: 1.5;
    text-align: right;
    margin: 0 10px;
}

.ds-disclaimer a {
    color: var(--ds-text-secondary);
    text-decoration: underline;
}

/* Grid Layout */
.ds-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 24px;
    padding: 0 20px;
    max-width: 1200px;
    margin: 0 auto;
}

/* Card Styles */
.ds-card {
    background: var(--ds-card-bg);
    border-radius: var(--ds-radius);
    padding: 24px;
    box-shadow: var(--ds-shadow-sm);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    display: flex;
    flex-direction: column;
    border: 1px solid rgba(0, 0, 0, 0.03);
    position: relative;
    overflow: hidden;
}

.ds-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--ds-shadow-md);
}

.ds-card-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 16px;
}

.ds-date {
    font-size: 0.85rem;
    color: var(--ds-text-secondary);
    background: #f0f2f5;
    padding: 4px 10px;
    border-radius: 20px;
    font-weight: 600;
}

.ds-house-badge {
    font-size: 0.75rem;
    padding: 4px 8px;
    border-radius: 4px;
    font-weight: bold;
    color: white;
}

.ds-house-sangiin {
    background-color: #673ab7;
    /* Deep Purple */
}

.ds-house-shugiin {
    background-color: #2196f3;
    /* Blue */
}

.ds-speaker {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 16px;
}

.ds-speaker-avatar {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    background: #e0e0e0;
    object-fit: cover;
    border: 2px solid white;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.ds-speaker-info h3 {
    font-size: 1.1rem;
    font-weight: 700;
    margin: 0;
    color: var(--ds-text-primary);
}

.ds-party {
    font-size: 0.8rem;
    color: var(--ds-text-secondary);
}

.ds-meeting {
    font-size: 0.9rem;
    color: var(--ds-text-secondary);
    margin-bottom: 12px;
    font-weight: 600;
    border-bottom: 1px solid #eee;
    padding-bottom: 8px;
}

.ds-summary {
    font-size: 0.95rem;
    line-height: 1.7;
    color: #444;
    margin-bottom: 20px;
    flex-grow: 1;
}

.ds-footer {
    margin-top: auto;
    display: flex;
    justify-content: flex-end;
}

.ds-link {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    color: var(--ds-accent-color);
    text-decoration: none;
    font-weight: 600;
    font-size: 0.9rem;
    transition: color 0.2s;
}

.ds-link:hover {
    color: #d97706;
}

/* Responsive */
@media (max-width: 768px) {
    .ds-title {
        font-size: 1.8rem;
    }

    .ds-grid {
        grid-template-columns: 1fr;
    }
}