/* Festival Calendar Tool Styles */

/* Calendar Container */
.festival-calendar-app {
    font-family: var(--font-family-base);
    max-width: 1000px;
    margin: 0 auto;
}

/* Controls */
.calendar-controls {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: #fff;
    padding: var(--space-md);
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-sm);
    margin-bottom: var(--space-lg);
    border: 1px solid var(--color-border);
    flex-wrap: wrap;
    gap: var(--space-md);
}

.year-selector-group {
    display: flex;
    align-items: center;
    gap: var(--space-sm);
}

.year-btn {
    background: transparent;
    border: 1px solid var(--color-border);
    padding: 5px 10px;
    border-radius: var(--radius-sm);
    cursor: pointer;
    font-weight: 600;
    color: var(--color-text-muted);
    transition: all 0.2s;
}

.year-btn:hover {
    border-color: var(--color-primary);
    color: var(--color-primary);
}

.year-btn.active {
    background: var(--color-primary);
    color: white;
    border-color: var(--color-primary);
}

.view-controls button {
    background: transparent;
    border: none;
    color: var(--color-text-muted);
    cursor: pointer;
    font-size: 1.1rem;
}

.view-controls button:hover {
    color: var(--color-primary);
}

/* Main Calendar View (Yearly/List style for festivals) */
.calendar-view-year {
    display: flex;
    flex-direction: column;
    gap: var(--space-lg);
}

/* Month Group */
.cal-month-group {
    background: white;
    border-radius: var(--radius-lg);
    border: 1px solid var(--color-border);
    overflow: hidden;
}

.cal-month-header {
    background: #FFF8E1;
    padding: var(--space-sm) var(--space-md);
    font-weight: 700;
    color: var(--color-text-main);
    border-bottom: 1px solid var(--color-border);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

/* Festival Date Card */
.cal-date-row {
    display: flex;
    padding: var(--space-md);
    border-bottom: 1px solid var(--color-border);
    transition: background 0.1s;
}

.cal-date-row:last-child {
    border-bottom: none;
}

.cal-date-row:hover {
    background: #FFFCF5;
}

.cal-date-box {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-width: 80px;
    padding-right: var(--space-md);
    border-right: 1px solid var(--color-border);
    margin-right: var(--space-md);
    color: var(--color-primary-dark);
}

.cal-day-num {
    font-size: 1.8rem;
    font-weight: 700;
    line-height: 1;
}

.cal-day-name {
    font-size: 0.8rem;
    text-transform: uppercase;
    font-weight: 600;
    opacity: 0.8;
}

.cal-info-box {
    flex: 1;
}

.cal-festival-name {
    font-size: 1.2rem;
    font-weight: 700;
    color: var(--color-text-main);
    margin-bottom: 5px;
}

.cal-festival-tithi {
    font-size: 0.9rem;
    color: var(--color-text-muted);
    margin-bottom: 8px;
    display: inline-block;
    background: #F5F5F5;
    padding: 2px 8px;
    border-radius: 4px;
}

.cal-festival-ritual {
    font-size: 0.95rem;
    color: var(--color-text-main);
    line-height: 1.4;
}

/* List View (Directory) */
.festival-directory-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: var(--space-md);
}

.festival-dir-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    background: white;
    padding: var(--space-lg);
    border-radius: var(--radius-md);
    border: 1px solid var(--color-border);
    border-top: 4px solid var(--color-primary);
    /* Default fallback */
    text-align: center;
    transition: transform 0.2s, box-shadow 0.2s;
    position: relative;
    height: 100%;
}

.festival-dir-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-md);
    text-decoration: none;
}

.festival-dir-icon {
    font-size: 2.5rem;
    margin-bottom: var(--space-md);
    transition: transform 0.2s;
}

.festival-dir-card:hover .festival-dir-icon {
    transform: scale(1.1);
}

.festival-dir-name {
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--color-text-main);
}

.festival-dir-arrow {
    margin-top: var(--space-md);
    font-size: 0.9rem;
    color: var(--color-text-muted);
    opacity: 0;
    transition: opacity 0.2s, transform 0.2s;
}

.festival-dir-card:hover .festival-dir-arrow {
    opacity: 1;
    transform: translateX(5px);
}

/* Empty State */
.no-data-state {
    text-align: center;
    padding: var(--space-xl);
    background: white;
    border-radius: var(--radius-md);
    border: 1px dashed var(--color-text-muted);
    color: var(--color-text-muted);
}

@media print {

    .site-header,
    .site-footer,
    .breadcrumbs,
    .calendar-controls {
        display: none !important;
    }

    .tool-layout-wrapper {
        display: block;
    }

    .main-content {
        padding: 0;
    }

    .cal-month-group {
        break-inside: avoid;
        border: 1px solid #ccc;
    }

    body {
        background: white;
    }
}

@media (max-width: 600px) {
    .cal-date-row {
        flex-direction: column;
        align-items: flex-start;
    }

    .cal-date-box {
        flex-direction: row;
        border-right: none;
        border-bottom: 1px solid var(--color-border);
        margin-right: 0;
        margin-bottom: var(--space-sm);
        padding-bottom: var(--space-sm);
        width: 100%;
        justify-content: flex-start;
        gap: var(--space-sm);
        padding-right: 0;
    }

    .cal-day-num {
        font-size: 1.2rem;
    }
}

/* SEO Content Block */
.seo-content-block {
    background: white;
    padding: var(--space-xl);
    border-radius: var(--radius-lg);
    border: 1px solid var(--color-border);
    margin-top: var(--space-xl);
}

.seo-content-block h2 {
    color: var(--color-primary-dark);
    margin-bottom: var(--space-md);
    margin-top: var(--space-lg);
    font-size: 1.6rem;
}

.seo-content-block h2:first-child {
    margin-top: 0;
}

.seo-content-block p {
    line-height: 1.7;
    color: var(--color-text-main);
    margin-bottom: var(--space-md);
    font-size: 1.05rem;
}

.seo-content-block ul {
    margin-bottom: var(--space-md);
    padding-left: var(--space-xl);
}

.seo-content-block li {
    margin-bottom: var(--space-xs);
    line-height: 1.6;
}

.seo-content-block strong {
    color: var(--color-primary);
}