        :root {
    --bg: #f9fafb;
    --primary: #1e40af;
    --primary-light: #3b82f6;
    --accent: #10b981;
    --accent-light: #34d399;
    --text: #1f2937;
    --text-light: #6b7280;
    --card-bg: #ffffff;
    --card-border: #e5e7eb;
    --weekend: #f3f4f6;
    --today: #dbeafe;
    --event-list-bg: #f8fafc;
    --holiday-color: #ef4444;
    --personal-event: #10b981;
    --work-event: #3b82f6;
    --health-event: #f59e0b;
    --leisure-event: #8b5cf6;
    --facultative-color: #f59e0b;
    --religious-color: #6366f1;
    --local-color: #ec4899;
    --spring: #10b981;
    --summer: #f59e0b;
    --autumn: #ef4444;
    --winter: #3b82f6;
    --season-bg: rgba(16, 185, 129, 0.08);
    --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
    --shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.1), 0 1px 2px 0 rgba(0, 0, 0, 0.06);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
}

[data-theme="dark"] {
    --bg: #111827;
    --primary: #60a5fa;
    --primary-light: #93c5fd;
    --accent: #34d399;
    --accent-light: #6ee7b7;
    --text: #f9fafb;
    --text-light: #d1d5db;
    --card-bg: #1f2937;
    --card-border: #374151;
    --weekend: #2d3748;
    --today: #1e3a8a;
    --event-list-bg: #111827;
    --holiday-color: #f87171;
    --personal-event: #34d399;
    --work-event: #60a5fa;
    --health-event: #fbbf24;
    --leisure-event: #a78bfa;
    --facultative-color: #fbbf24;
    --religious-color: #818cf8;
    --local-color: #f472b6;
    --spring: #34d399;
    --summer: #fbbf24;
    --autumn: #f87171;
    --winter: #60a5fa;
    --season-bg: rgba(52, 211, 153, 0.15);
    --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.3);
    --shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.4), 0 1px 2px 0 rgba(0, 0, 0, 0.3);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.4), 0 4px 6px -2px rgba(0, 0, 0, 0.3);
}
    * {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
    font-family: 'Inter', 'Segoe UI', system-ui, -apple-system, sans-serif;
}

html {
  scroll-behavior: smooth;
}


body {
    background: var(--bg);
    color: var(--text);
    padding-top: 70px;
    min-height: 100vh;
    transition: background 0.3s, color 0.3s;
}

    body::-webkit-scrollbar {
                width: 4px;
                
            }

    body::-webkit-scrollbar-thumb {
                background: rgba(0,0,0,0.2);            
            }

            .modal-body::-webkit-scrollbar{
                width: 4px;
            }

            .modal-body::-webkit-scrollbar-thumb{
                background: rgba(0,0,0,0.2);            

            }



.container {
    display: flex;
    flex-direction: column;
    gap: 24px;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

.app-header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    background: var(--card-bg);
    border-bottom: 1px solid var(--card-border);
    padding: 16px 0;
    box-shadow: var(--shadow);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    background-color: rgba(var(--card-bg-rgb, 255, 255, 255), 0.95);
}

[data-theme="dark"] .app-header {
    background-color: rgba(var(--card-bg-rgb, 31, 41, 55), 0.95);
}

.header-content {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 20px;
}

.header-left {
    display: flex;
    align-items: center;
    gap: 100px;
    flex: 1;
}

.header-current-date {
    font-size: 0.875rem;
    color: var(--text-light);
    font-weight: 500;
    margin-top: 4px;
}

.app-title {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.app-title h1 {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--primary);
    margin: 0;
    line-height: 1.2;
}

.app-title #current-year {
    color: var(--accent);
    font-weight: 600;
}

.clock-container {
    display: flex;
    align-items: center;
    gap: 20px;
    flex-wrap: wrap;
}

#live-clock-container {
    display: flex;
    align-items: center;
    gap: 12px;
    background: var(--bg);
    padding: 10px 16px;
    border-radius: 12px;
    border: 1px solid var(--card-border);
    min-width: 280px;
    transition: all 0.3s ease;
}

#live-clock-container:hover {
    border-color: var(--primary-light);
    box-shadow: var(--shadow-sm);
}

.live-clock {
    font-size: 1.5rem;
    font-weight: 600;
    color: var(--primary);
    font-family: 'JetBrains Mono', 'Cascadia Code', monospace;
    letter-spacing: 0.5px;
    min-width: 95px;
}

.live-date {
    font-size: 0.875rem;
    color: var(--text-light);
    font-weight: 500;
    white-space: nowrap;
}

.timezone-select {
    padding: 6px 12px;
    border: 1px solid var(--card-border);
    border-radius: 6px;
    background: var(--bg);
    color: var(--text);
    font-size: 0.813rem;
    cursor: pointer;
    transition: all 0.2s;
    min-width: 160px;
    font-weight: 500;
}

.timezone-select:hover {
    border-color: var(--primary-light);
}

.timezone-select:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.2);
}

.header-actions {
    display: flex;
    align-items: center;
    gap: 12px;
}

.header-actions .theme-toggle {
    background: var(--bg);
    border: 1px solid var(--card-border);
    color: var(--text);
    padding: 8px 12px;
    border-radius: 6px;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 0.875rem;
    font-weight: 500;
    transition: all 0.2s;
}

.header-actions .theme-toggle:hover {
    background: var(--weekend);
    border-color: var(--primary-light);
}

.current-date {
    font-size: 0.875rem;
    color: var(--text-light);
    font-weight: 500;
}
.controls {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
    padding: 20px 0;
    border-bottom: 1px solid var(--card-border);
    margin-bottom: 20px;
}

.controls button {
    background: var(--bg);
    color: var(--text) !important;
    border: 1px solid var(--card-border);
    padding: 10px 20px;
    border-radius: 8px;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 10px;
    transition: all 0.2s;
    font-weight: 500;
    font-size: 0.875rem;
}

.controls button:hover {
    background: var(--weekend);
    border-color: var(--primary-light);
    transform: translateY(-1px);
    box-shadow: var(--shadow-sm);
}

.controls button:active {
    transform: translateY(0);
}

.controls .theme-toggle {
    background: var(--primary);
    color: white !important;
    border-color: var(--primary);
}

.controls .theme-toggle:hover {
    background: var(--primary-light);
    border-color: var(--primary-light);
}

/* Campo de pesquisa mês/ano */
.month-year-search {
    display: flex;
    align-items: center;
}

.search-input-group {
    display: flex;
    gap: 8px;
    align-items: center;
    background: var(--bg);
    border: 1px solid var(--card-border);
    border-radius: 8px;
    padding: 5px;
    transition: all 0.2s;
}

.search-input-group:hover {
    border-color: var(--primary-light);
    box-shadow: var(--shadow-sm);
}

.search-select {
    padding: 8px 12px;
    border: none;
    background: transparent;
    color: var(--text);
    font-size: 0.875rem;
    font-weight: 500;
    cursor: pointer;
    min-width: 100px;
    border-radius: 6px;
    transition: background 0.2s;
}

.search-select:focus {
    outline: none;
    background: var(--weekend);
}

.search-select option {
    background: var(--card-bg);
    color: var(--text);
}

.search-btn {
    background: var(--primary);
    color: white;
    position: relative;
    border: none;
    width: 36px;
    height: 36px;
    border-radius: 6px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s;
    flex-shrink: 0;
}

.search-btn::after {
    content: 'Ir para mês/ano';
    position: absolute;
    bottom: 100%;
    left: 50%;
    transform: translateX(-50%);
    background: rgba(0, 0, 0, 0.9);
    color: white;
    padding: 6px 10px;
    border-radius: 6px;
    font-size: 0.75rem;
    white-space: nowrap;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s;
    pointer-events: none;
    z-index: 10;
}

.search-btn:hover::after {
    opacity: 1;
    visibility: visible;
}

.search-btn:hover {
    background: var(--primary-light);
    transform: translateY(-1px);
}

.search-btn:active {
    transform: translateY(0);
}


#today-btn {
    background: var(--accent);
    color: white !important;
    border-color: var(--accent);
}

#today-btn:hover {
    background: var(--accent-light);
    border-color: var(--accent-light);
}

#season-toggle.active {
    background: var(--accent);
    color: white !important;
    border-color: var(--accent);
}

#season-toggle.active:hover {
    background: var(--accent-light);
    border-color: var(--accent-light);
}
        .theme-toggle {
            background: var(--accent) !important;
            color: #ffffff !important;
        }

        #event-list-toggle {
            display: none;
        }

/* Cards Informativos */
.info-cards {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 20px;
    margin: 8% 0 0;
}

.info-card {
    background: var(--card-bg);
    border-radius: 12px;
    padding: 24px;
    box-shadow: var(--shadow);
    transition: all 0.3s ease;
    display: flex;
    align-items: flex-start;
    gap: 20px;
    border: 1px solid var(--card-border);
    position: relative;
    overflow: hidden;
}

.info-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-lg);
    border-color: var(--primary-light);
}

.info-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 4px;
    height: 100%;
    background: var(--accent);
    border-radius: 4px 0 0 4px;
}

.holiday-card::before {
    background: var(--holiday-color);
}

.info-card-icon {
    width: 56px;
    height: 56px;
    border-radius: 12px;
    background: linear-gradient(135deg, var(--accent), var(--accent-light));
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 1.5rem;
    flex-shrink: 0;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
}

.holiday-card .info-card-icon {
    background: linear-gradient(135deg, var(--holiday-color), #f87171);
}

.info-card-content {
    flex: 1;
    min-width: 0;
}

.info-card-title {
    font-size: 0.875rem;
    color: var(--text-light);
    margin-bottom: 8px;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.info-card-value {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--text);
    line-height: 1.3;
    margin-bottom: 8px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.info-card-subtitle {
    font-size: 0.875rem;
    color: var(--text-light);
    display: flex;
    align-items: center;
    gap: 6px;
}

.info-card-subtitle i {
    font-size: 0.75rem;
}

.info-card:nth-child(3) .info-card-icon {
    background: linear-gradient(135deg, var(--primary), var(--primary-light));
}

.year-progress {
    height: 6px;
    background: var(--weekend);
    border-radius: 3px;
    margin-top: 12px;
    overflow: hidden;
}

.year-progress-fill {
    height: 100%;
    background: linear-gradient(90deg, var(--primary), var(--primary-light));
    border-radius: 3px;
    transition: width 0.5s ease;
}

        .holiday-card .info-card-value {
            color: var(--holiday-color);
        }

        .main-content {
            display: flex;
            flex-direction: column;
            gap: 24px;
            margin-bottom: 30px;
        }


    .calendar-container {
        background: var(--card-bg);
        border-radius: 16px;
        box-shadow: var(--shadow);
        overflow: hidden;
        transition: all 0.3s ease;
        border: 1px solid var(--card-border);
        display: flex;
        flex-direction: column;
        position: relative; 
    }
        .calendar-container:hover {
            box-shadow: var(--shadow-lg);
            border-color: var(--primary-light);
        }

.calendar-header {
    background: linear-gradient(135deg, var(--primary), var(--primary-light));
    color: white;
    padding: 20px 24px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    position: relative;
    z-index: 2;
    border-radius: 16px 16px 0 0;
}

.calendar-header::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 1px;
    background: rgba(255, 255, 255, 0.1);
}

.calendar-header h1 {
    font-size: 1.5rem;
    font-weight: 700;
    margin: 0;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    flex: 1;
    text-align: center;
    letter-spacing: 0.5px;
}

.calendar-nav {
    display: flex;
    align-items: center;
    gap: 8px;
}

.calendar-header button {
    background: rgba(255, 255, 255, 0.15);
    border: none;
    color: white;
    font-size: 18px;
    cursor: pointer;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 8px;
    transition: all 0.2s;
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
}

.calendar-header button:hover {
    background: rgba(255, 255, 255, 0.25);
    transform: translateY(-1px);
}

.calendar-header button:active {
    transform: translateY(0);
}

.calendar-header button:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    pointer-events: none;
}

.calendar-header button:disabled:hover {
    background: rgba(255, 255, 255, 0.15);
    transform: none;
}

.calendar-content {
    flex: 1;
    overflow: visible;
    position: relative;
    min-height: 400px;
    height: auto !important; 
}
.calendar-month {
    height: auto !important; 
    min-height: 400px;
}


        .weekdays {
            display: grid;
            grid-template-columns: repeat(7, 1fr);
            background: var(--weekend);
            border-bottom: 1px solid var(--card-border);
        }

        .weekdays div {
            text-align: center;
            padding: 16px 8px;
            font-weight: 600;
            color: var(--text-light);
            font-size: 0.875rem;
            text-transform: uppercase;
            letter-spacing: 0.5px;
            border-right: 1px solid var(--card-border);
        }

        .weekdays div:last-child {
            border-right: none;
        }

        
        .days {
            display: grid;
            grid-template-columns: repeat(7, 1fr);
            background: var(--card-bg);
            grid-auto-rows: minmax(80px, auto); 

        }

        
        .days div {
                height: auto; 
                padding: 8px;
                transition: min-height 0.3s ease;           
                border: 1px solid rgba(0,0,0,0.05);
            cursor: pointer;
            position: relative;
            display: flex;
            flex-direction: column;
            overflow: hidden !important;
        }

        .days div.with-many-events {
            min-height: 100px;
        }

        .days div:hover {
            background: rgba(0,0,0,0.03);
        }

        .days div.weekend {
            background: var(--weekend);
        }

        .days div.today {
            background: var(--today);
            font-weight: bold;
            border: 2px solid var(--primary);
        }

.day-number {
    display: flex !important;
    align-items: center !important;
    justify-content: space-between !important;
    width: 100% !important;
    font-weight: 600;
    font-size: 1rem;
    padding: 4px 0;
    position: relative;
}

.day-number .date-text {
    color: var(--text);
    font-size: 1.1rem;
    min-width: 24px;
    text-align: center;
}

        .day-number:not(.with-season) {
            justify-content: flex-start !important;
        }

        .day-number:not(.with-season) span {
            display: none;
        }

        .day-number.with-season {
            justify-content: space-between !important;
        }

        .day-number.with-season > :first-child:not(.season-indicator) {
            display: none;
        }

        .day-number:not(.with-season) > :first-child:not(.season-indicator) {
            display: inline !important;
        }

.days div.today .day-number .date-text {
    background: var(--primary);
    color: white;
    width: 28px;
    height: 28px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    font-weight: 700;
}

.days div:hover .day-number .date-text {
    color: var(--primary);
}

.days div.today:hover .day-number .date-text {
    background: white;
    color: var(--primary);
}

        .day-indicators {
            display: flex;
            flex-wrap: wrap;
            gap: 10px;
            margin-top: 10px;
            align-items: center;
            justify-content: center;
            min-height: 24px;
            padding: 2px 0;
            max-height: 60px;
            overflow-y: auto;
            overflow-x: hidden;
        }

        .day-indicators::-webkit-scrollbar {
            width: 4px;
        }

        .day-indicators::-webkit-scrollbar-thumb {
            background: rgba(0,0,0,0.2);
            border-radius: 2px;
        }

        .compact-indicators {
            gap: 2px;
            justify-content: center;
        }

        .compact-indicators .indicator {
            width: 14px;
            height: 14px;
        }

        .compact-indicators .indicator i {
            font-size: 0.5em;
        }

        .indicator {
            width: 16px;
            height: 16px;
            border-radius: 50%;
            display: flex;
            align-items: center;
            justify-content: center;
            position: relative;
            transition: transform 0.2s;
            flex-shrink: 0;
            border: 2px solid var(--card-bg);
            box-shadow: 0 1px 3px rgba(0,0,0,0.2);
            cursor: pointer;
            z-index: 10;
        }

        .indicator:hover {
            transform: scale(1.1);
            z-index: 100;
        }

        .indicator.holiday {
            background: linear-gradient(135deg, var(--holiday-color), #ff6b6b);
        }

        .indicator.personal {
            background: linear-gradient(135deg, var(--personal-event), #26de81);
        }

        .indicator.work {
            background: linear-gradient(135deg, var(--work-event), #3498db);
        }

        .indicator.health {
            background: linear-gradient(135deg, var(--health-event), #e74c3c);
        }

        .indicator.leisure {
            background: linear-gradient(135deg, var(--leisure-event), #f39c12);
        }

        .indicator.facultative {
            background: linear-gradient(135deg, var(--facultative-color), #f1c40f);
        }

        .indicator.religious {
            background: linear-gradient(135deg, var(--religious-color), #3498db);
            border: 1.99px dotted var(--card-bg) !important;
        }

        .indicator.local {
            background: linear-gradient(135deg, var(--local-color), #9b59b6);
        }

        .indicator i {
            color: white;
            font-size: 0.7em;
            text-shadow: 0 1px 2px rgba(0,0,0,0.3);
            position: absolute;
            top: 50%;
            left: 50%;
            transform: translate(-50%, -50%);
            z-index: 11;
            pointer-events: none;
        }

        .indicator .tooltip {
            visibility: hidden;
            opacity: 0;
            position: absolute;
            bottom: 100%;
            left: 50%;
            transform: translateX(-50%);
            background: rgba(0, 0, 0, 0.95);
            color: white;
            padding: 6px 10px;
            border-radius: 6px;
            font-size: 0.75em;
            white-space: nowrap;
            z-index: 1000;
            margin-bottom: 8px;
            transition: opacity 0.3s ease, visibility 0.3s ease;
            pointer-events: none;
            font-weight: 500;
            box-shadow: 0 4px 8px rgba(0,0,0,0.3);
            text-align: center;
            min-width: 120px;
            max-width: 200px;
            overflow: hidden;
            text-overflow: ellipsis;
        }

        .indicator .tooltip::after {
            content: '';
            position: absolute;
            top: 100%;
            left: 50%;
            transform: translateX(-50%);
            border-width: 5px;
            border-style: solid;
            border-color: rgba(0, 0, 0, 0.95) transparent transparent transparent;
        }

        .indicator:hover .tooltip {
            visibility: visible;
            opacity: 1;
        }

.event-list-container {
    background: var(--card-bg);
    border-radius: 16px;
    padding: 24px;
    box-shadow: var(--shadow);
    transition: all 0.3s ease;
    border: 1px solid var(--card-border);
    height: fit-content;
    display: flex;
    flex-direction: column;
    height: calc(87vh - 200px);
    min-height: 600px;
}

.event-list-container:hover {
    box-shadow: var(--shadow-lg);
    border-color: var(--primary-light);
}


.event-list-container h3 {
    margin-bottom: 20px;
    padding-bottom: 16px;
    border-bottom: 2px solid var(--primary);
    color: var(--primary);
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 1.25rem;
    font-weight: 700;
}

.event-list-container h3 i {
    font-size: 1.2em;
    color: var(--accent);
}

        .event-list-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    padding-bottom: 16px;
    border-bottom: 1px solid var(--card-border);
}

.event-stats {
    display: flex;
    gap: 16px;
    font-size: 0.875rem;
}

.stat {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 6px 12px;
    background: var(--weekend);
    border-radius: 8px;
    border: 1px solid var(--card-border);
}

.stat-dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    border: 2px solid var(--card-bg);
}


.stat.holiday-stat {
    background: rgba(var(--holiday-color-rgb, 239, 68, 68), 0.1);
    border-color: rgba(var(--holiday-color-rgb, 239, 68, 68), 0.2);
}

.stat.event-stat {
    background: rgba(var(--personal-event-rgb, 16, 185, 129), 0.1);
    border-color: rgba(var(--personal-event-rgb, 16, 185, 129), 0.2);
}

/* Lista de Eventos */
#event-list {
    list-style: none;
    flex: 1;
    overflow-y: auto;
    padding-right: 8px;
    margin: 0 -8px 0 0;
}

     #event-list::-webkit-scrollbar {
    width: 6px;
}

#event-list::-webkit-scrollbar-track {
    background: var(--weekend);
    border-radius: 3px;
}

#event-list::-webkit-scrollbar-thumb {
    background: var(--text-light);
    border-radius: 3px;
    opacity: 0.3;
}

#event-list::-webkit-scrollbar-thumb:hover {
    opacity: 0.5;
}

        .event-list-item {
    padding: 16px;
    margin-bottom: 12px;
    background: var(--event-list-bg);
    border-radius: 12px;
    border-left: 4px solid var(--personal-event);
    display: flex;
    align-items: center;
    gap: 16px;
    transition: all 0.3s ease;
    border: 1px solid var(--card-border);
    cursor: pointer;
}

.event-list-item:hover {
    transform: translateX(8px);
    box-shadow: var(--shadow);
    border-left-width: 6px;
}

.event-list-item:active {
    transform: translateX(4px);
}

.event-date {
    font-weight: 700;
    font-size: 0.8rem;
    color: var(--primary);
    min-width: 80px;
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 2px;
}

      .event-date .weekday {
    font-size: 0.75rem;
    color: var(--text-light);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.event-date .day {
    font-size: 1.25rem;
    font-weight: 800;
}

.event-text {
    flex: 1;
    font-weight: 500;
    font-size: 14px;
    color: var(--text);
    line-height: 1.4;
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
}

.event-type-badge {
    padding: 6px 12px;
    border-radius: 20px;
    font-size: 0.7rem;
    font-weight: 700;
    min-width: 80px;
    text-align: center;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    white-space: nowrap;
    flex-shrink: 0;
}

.holiday-item {
    border-left-color: var(--holiday-color) !important;
    background: rgba(var(--holiday-color-rgb, 239, 68, 68), 0.05);
}

.facultative-item {
    border-left-color: var(--facultative-color) !important;
    background: rgba(var(--facultative-color-rgb, 245, 158, 11), 0.05);
}

.religious-item {
    border-left-color: var(--religious-color) !important;
    background: rgba(var(--religious-color-rgb, 99, 102, 241), 0.05);
}

.local-item {
    border-left-color: var(--local-color) !important;
    background: rgba(var(--local-color-rgb, 236, 72, 153), 0.05);
}

.personal-item {
    background: rgba(var(--personal-event-rgb, 16, 185, 129), 0.05);
}

.work-item {
    background: rgba(var(--work-event-rgb, 59, 130, 246), 0.05);
}

.health-item {
    background: rgba(var(--health-event-rgb, 245, 158, 11), 0.05);
}

.leisure-item {
    background: rgba(var(--leisure-event-rgb, 139, 92, 246), 0.05);
}

.holiday-badge {
    background: linear-gradient(135deg, var(--holiday-color), #f87171);
    color: white;
}

.facultative-badge {
    background: linear-gradient(135deg, var(--facultative-color), #fbbf24);
    color: white;
}

.religious-badge {
    background: linear-gradient(135deg, var(--religious-color), #818cf8);
    color: white;
}

.local-badge {
    background: linear-gradient(135deg, var(--local-color), #f472b6);
    color: white;
}

.personal-badge {
    background: linear-gradient(135deg, var(--personal-event), var(--accent-light));
    color: white;
}

.work-badge {
    background: linear-gradient(135deg, var(--work-event), #93c5fd);
    color: white;
}

.health-badge {
    background: linear-gradient(135deg, var(--health-event), #fcd34d);
    color: white;
}

.leisure-badge {
    background: linear-gradient(135deg, var(--leisure-event), #c4b5fd);
    color: white;
}

.modal {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.7);
    justify-content: center;
    align-items: center;
    z-index: 2000;
    padding: 20px;
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
}

.modal-content {
    background: var(--card-bg);
    padding: 32px;
    border-radius: 20px;
    width: 100%;
    max-width: 500px;
    color: var(--text);
    box-shadow: var(--shadow-lg);
    border: 1px solid var(--card-border);
    animation: modalSlideIn 0.3s ease-out;
    position: relative;
    max-height: 90vh;
    overflow-y: auto;
}

.modal-content::-webkit-scrollbar {
    display: none !important;

}

@keyframes modalSlideIn {
    from {
        opacity: 0;
        transform: translateY(-20px) scale(0.95);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

.modal-content h2 {
    margin-bottom: 24px;
    color: var(--primary);
    font-size: 1.5rem;
    font-weight: 700;
    display: flex;
    align-items: center;
    gap: 12px;
    padding-bottom: 16px;
    border-bottom: 2px solid var(--primary);
}


    .modal-content h2 i {
    color: var(--accent);
}

.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
    color: var(--text);
    font-size: 0.875rem;
    display: flex;
    align-items: center;
    gap: 8px;
}

.modal-content input,
.modal-content select,
.modal-content textarea {
    width: 100%;
    padding: 14px 16px;
    border: 2px solid var(--card-border);
    border-radius: 10px;
    background: var(--bg);
    color: var(--text);
    font-size: 1rem;
    transition: all 0.2s;
    font-family: 'Inter', sans-serif;
}

.modal-content input:hover,
.modal-content select:hover {
    border-color: var(--primary-light);
}

.modal-content input:focus,
.modal-content select:focus,
.modal-content textarea:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(var(--primary-rgb, 30, 64, 175), 0.2);
}

.modal-content textarea {
    min-height: 100px;
    resize: vertical;
}

    .checkbox-group {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 20px;
    padding: 12px;
    background: var(--weekend);
    border-radius: 10px;
    border: 1px solid var(--card-border);
}

.checkbox-group input[type="checkbox"] {
    width: 20px;
    height: 20px;
    margin: 0;
    cursor: pointer;
    accent-color: var(--primary);
    border-radius: 4px;
}

.checkbox-group label {
    display: flex;
    align-items: center;
    gap: 10px;
    cursor: pointer;
    font-weight: 600;
    margin: 0;
    color: var(--text);
    flex: 1;
}

.event-category-selector {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
    margin-top: 12px;
}

.category-option {
    position: relative;
}

.category-option input[type="radio"] {
    display: none;
}

    .category-option label {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 16px 12px;
    border-radius: 12px;
    cursor: pointer;
    transition: all 0.2s;
    text-align: center;
    border: 2px solid transparent;
    background: var(--weekend);
    height: 100%;
    justify-content: center;
}

.category-option label:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow);
    border-color: var(--primary-light);
}

.category-option input[type="radio"]:checked + label {
    border-color: var(--primary);
    background: rgba(var(--primary-rgb, 30, 64, 175), 0.1);
    box-shadow: 0 4px 12px rgba(var(--primary-rgb, 30, 64, 175), 0.15);
}

.category-color {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    margin-bottom: 10px;
    border: 2px solid var(--card-bg);
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.category-name {
    font-weight: 600;
    font-size: 0.875rem;
    color: var(--text);
}

.category-option[data-category="personal"] .category-color {
    background: linear-gradient(135deg, var(--personal-event), var(--accent-light));
}

.category-option[data-category="work"] .category-color {
    background: linear-gradient(135deg, var(--work-event), #93c5fd);
}

.category-option[data-category="health"] .category-color {
    background: linear-gradient(135deg, var(--health-event), #fcd34d);
}

.category-option[data-category="leisure"] .category-color {
    background: linear-gradient(135deg, var(--leisure-event), #c4b5fd);
}

      .recurrence-options {
    display: none;
    margin-top: 20px;
    padding: 20px;
    background: var(--weekend);
    border-radius: 12px;
    border-left: 4px solid var(--accent);
    border: 1px solid var(--card-border);
}

.recurrence-options.show {
    display: block;
}

.recurrence-options label {
    color: var(--text);
    font-weight: 600;
    margin-bottom: 12px;
    display: block;
}

.recurrence-type-selector {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 10px;
    margin-top: 12px;
}

.recurrence-option {
    position: relative;
}

.recurrence-option input[type="radio"] {
    display: none;
}

.recurrence-option label {
    display: block;
    padding: 14px 12px;
    border-radius: 10px;
    cursor: pointer;
    text-align: center;
    background: var(--bg);
    border: 2px solid transparent;
    transition: all 0.2s;
    font-weight: 500;
    color: var(--text);
    margin: 0;
}

      .recurrence-option label:hover {
    background: rgba(var(--primary-rgb, 30, 64, 175), 0.1);
    border-color: var(--primary-light);
}

.recurrence-option input[type="radio"]:checked + label {
    border-color: var(--primary);
    background: rgba(var(--primary-rgb, 30, 64, 175), 0.15);
    font-weight: 600;
    color: var(--primary);
}

.weekly-options,
.monthly-options {
    display: none;
    margin-top: 16px;
    padding: 16px;
    background: var(--bg);
    border-radius: 10px;
    border: 1px solid var(--card-border);
}

.weekly-options.show,
.monthly-options.show {
    display: block;
}

.days-of-week {
    display: flex;
    gap: 8px;
    margin-top: 12px;
    flex-wrap: wrap;
}

.day-of-week-option input[type="checkbox"] {
    display: none;
        }

      .day-of-week-option label {
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 10px;
    cursor: pointer;
    background: var(--weekend);
    border: 2px solid transparent;
    transition: all 0.2s;
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--text);
}

.day-of-week-option label:hover {
    transform: scale(1.1);
    background: rgba(var(--primary-rgb, 30, 64, 175), 0.1);
}

.day-of-week-option input[type="checkbox"]:checked + label {
    background: var(--primary);
    color: white;
    border-color: var(--primary);
}

.monthly-options select {
    margin-top: 8px;
}
     .modal-actions {
    display: flex;
    justify-content: flex-end;
    gap: 12px;
    margin-top: 32px;
    padding-top: 24px;
    border-top: 1px solid var(--card-border);
}

.modal-actions button {
    padding: 12px 24px;
    border: none;
    cursor: pointer;
    border-radius: 10px;
    font-weight: 600;
    font-size: 0.875rem;
    transition: all 0.2s;
    min-width: 100px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    letter-spacing: 0.5px;
}

.modal-actions button:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow);
}

.modal-actions button:active {
    transform: translateY(0);
}

#save {
    background: linear-gradient(135deg, var(--primary), var(--primary-light));
    color: white;
}

#save:hover {
    background: linear-gradient(135deg, var(--primary-light), var(--primary));
}

#delete {
    background: linear-gradient(135deg, #ef4444, #f87171);
    color: white;
    display: none;
}

#delete:hover {
    background: linear-gradient(135deg, #f87171, #ef4444);
}

#close {
    background: var(--weekend);
    color: var(--text);
    border: 1px solid var(--card-border);
}

#close:hover {
    background: var(--bg);
    border-color: var(--primary-light);
}

      .holiday-modal-content {
    background: var(--card-bg);
    padding: 32px;
    border-radius: 20px;
    width: 100%;
    max-width: 450px;
    color: var(--text);
    box-shadow: var(--shadow-lg);
    border: 1px solid var(--card-border);
    animation: modalSlideIn 0.3s ease-out;
}

.holiday-modal-content h2 {
    margin-bottom: 24px;
    color: var(--primary);
    font-size: 1.5rem;
    font-weight: 700;
    display: flex;
    align-items: center;
    gap: 12px;
    padding-bottom: 16px;
    border-bottom: 2px solid var(--primary);
}

.holiday-modal-content h2 i {
    color: var(--accent);
}

.holiday-info {
    display: flex;
    align-items: center;
    gap: 20px;
    margin-bottom: 24px;
    padding: 24px;
    background: rgba(var(--holiday-color-rgb, 239, 68, 68), 0.08);
    border-radius: 16px;
    border-left: 4px solid var(--holiday-color);
    transition: all 0.3s ease;
}

.holiday-info:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow);
}

.holiday-info.facultative {
    background: rgba(var(--facultative-color-rgb, 245, 158, 11), 0.08);
    border-left-color: var(--facultative-color);
}

.holiday-info.religious {
    background: rgba(var(--religious-color-rgb, 99, 102, 241), 0.08);
    border-left-color: var(--religious-color);
}

.holiday-info.local {
    background: rgba(var(--local-color-rgb, 236, 72, 153), 0.08);
    border-left-color: var(--local-color);
}

.holiday-icon {
    width: 60px;
    height: 60px;
    border-radius: 16px;
    background: linear-gradient(135deg, var(--holiday-color), #f87171);
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 1.8em;
    flex-shrink: 0;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
}

.holiday-icon.facultative {
    background: linear-gradient(135deg, var(--facultative-color), #fbbf24);
}

.holiday-icon.religious {
    background: linear-gradient(135deg, var(--religious-color), #818cf8);
}

.holiday-icon.local {
    background: linear-gradient(135deg, var(--local-color), #f472b6);
}

.holiday-details {
    flex: 1;
}

.holiday-name {
    font-size: 1.3rem;
    font-weight: 700;
    margin-bottom: 8px;
    color: var(--holiday-color);
    line-height: 1.3;
}

.holiday-name.facultative {
    color: var(--facultative-color);
}

.holiday-name.religious {
    color: var(--religious-color);
}

.holiday-name.local {
    color: var(--local-color);
}

.holiday-date {
    font-size: 0.95rem;
    color: var(--text);
    opacity: 0.8;
    display: flex;
    align-items: center;
    gap: 8px;
}

.holiday-note {
    font-style: italic;
    margin-top: 20px;
    padding: 16px;
    background: var(--weekend);
    border-radius: 12px;
    text-align: center;
    font-size: 0.875rem;
    color: var(--text-light);
    border: 1px solid var(--card-border);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
}

.holiday-modal-content .modal-actions {
    margin-top: 24px;
}

.holiday-modal-content .add-event-btn {
    background: linear-gradient(135deg, var(--personal-event), var(--accent-light)) !important;
    color: white !important;
    flex: 1;
}

        .add-event-btn {
            background: var(--personal-event) !important;
            color: white !important;
            display: flex;
            align-items: center;
            justify-content: center;
            gap: 8px;
        }

        .add-event-btn:hover {
            background: #27ae60 !important;
        }

.loading {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 40px;
    color: var(--text);
    gap: 16px;
}

.loading i {
    font-size: 28px;
    color: var(--primary);
    animation: spin 1s linear infinite;
}

.loading p {
    font-weight: 600;
    color: var(--text-light);
    font-size: 0.95rem;
}

.loading-spinner {
    width: 40px;
    height: 40px;
    border: 3px solid rgba(var(--primary-rgb, 30, 64, 175), 0.1);
    border-radius: 50%;
    border-top-color: var(--primary);
    animation: spin 1s ease-in-out infinite;
}

.indicators-legend {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 16px;
    padding: 20px 24px;
    background: var(--weekend);
    border-top: 1px solid var(--card-border);
    border-radius: 0 0 16px 16px;
}

.legend-item {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.875rem;
    color: var(--text);
    padding: 6px 12px;
    background: var(--card-bg);
    border-radius: 8px;
    border: 1px solid var(--card-border);
    transition: all 0.2s ease;
    cursor: default;
}

.legend-item:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-sm);
}

.legend-dot {
    width: 14px;
    height: 14px;
    border-radius: 4px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}


        .legend-dot.holiday {
            background: linear-gradient(135deg, var(--holiday-color), #ff6b6b);
        }

        .legend-dot.personal {
            background: linear-gradient(135deg, var(--personal-event), #26de81);
        }

        .legend-dot.work {
            background: linear-gradient(135deg, var(--work-event), #3498db);
        }

        .legend-dot.health {
            background: linear-gradient(135deg, var(--health-event), #e74c3c);
        }

        .legend-dot.leisure {
            background: linear-gradient(135deg, var(--leisure-event), #f39c12);
        }

        .legend-dot.facultative {
            background: linear-gradient(135deg, var(--facultative-color), #f1c40f);
        }

        .legend-dot.religious {
            background: linear-gradient(135deg, var(--religious-color), #3498db);
            border: 2px dotted var(--card-bg);
        }

        .legend-dot.local {
            background: linear-gradient(135deg, var(--local-color), #9b59b6);
        }

        .day-indicators {
            overflow: visible !important;
            position: relative;
        }

    .recurring-badge {
        display: inline-flex;
        align-items: center;
        gap: 4px;
        background: var(--accent);
        color: var(--text);
        padding: 4px 8px;
        border-radius: 10px;
        font-size: 0.65rem;
        font-weight: 600;
        vertical-align: middle;
    }

    .recurring-badge i {
        font-size: 0.8em;
    }

    .btn-limpar-mobile {
    display: none;
    position: absolute;
    top: 20px;
    right: 20px;
    width: 44px;
    height: 44px;
    padding: 0;
    background: linear-gradient(135deg, #ef4444, #f87171);
    color: white;
    border: none;
    border-radius: 12px;
    cursor: pointer;
    font-size: 16px;
    transition: all 0.3s ease;
    z-index: 10;
    box-shadow: var(--shadow);
    display: flex;
    align-items: center;
    justify-content: center;
}

.btn-limpar-mobile:hover {
    background: linear-gradient(135deg, #f87171, #ef4444);
    transform: scale(1.1);
    box-shadow: 0 6px 16px rgba(239, 68, 68, 0.3);
}

.btn-limpar-mobile::after {
    content: 'Limpar dados salvos';
    position: absolute;
    top: 100%;
    right: 0;
    margin-top: 10px;
    padding: 8px 12px;
    background: rgba(0, 0, 0, 0.95);
    color: white;
    border-radius: 8px;
    font-size: 0.75rem;
    white-space: nowrap;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, visibility 0.3s ease;
    pointer-events: none;
    z-index: 11;
    backdrop-filter: blur(4px);
}

.btn-limpar-mobile:hover::after {
    opacity: 1;
    visibility: visible;
}

        .btn-limpar {
            position: fixed;
            bottom: 24px;
            right: 24px;
            padding: 12px 20px;
            background: linear-gradient(135deg, #ef4444, #f87171);
            color: white;
            border: none;
            border-radius: 12px;
            cursor: pointer;
            font-size: 0.875rem;
            font-weight: 600;
            transition: all 0.3s ease;
            z-index: 100;
            box-shadow: var(--shadow-lg);
            display: flex;
            align-items: center;
            gap: 8px;
            letter-spacing: 0.5px;
        }

        .btn-limpar:hover {
            background: linear-gradient(135deg, #f87171, #ef4444);
            transform: translateY(-2px);
            box-shadow: 0 8px 20px rgba(239, 68, 68, 0.3);
        }

        .btn-limpar:active {
                transform: translateY(0);
            }


        #confirm-modal .modal-content {
            max-width: 400px;
        }

        #confirm-title {
            display: flex;
            align-items: center;
            gap: 10px;
            color: var(--accent);
        }

        #confirm-title i {
            font-size: 1.2em;
        }

        #confirm-message {
            font-size: 1.1em;
            line-height: 1.5;
            text-align: center;
            padding: 10px 0;
        }

        .confirm-btn {
            padding: 10px 20px;
            border: none;
            border-radius: 6px;
            cursor: pointer;
            font-weight: 500;
            transition: opacity 0.2s;
            flex: 1;
        }

        .confirm-btn:hover {
            opacity: 0.9;
        }

.calendar-loading {
    display: none;
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(var(--card-bg-rgb, 255, 255, 255), 0.95);
    z-index: 100;
    border-radius: 16px;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 20px;
    backdrop-filter: blur(4px);
    border-radius: 0 0 16px 16px;
}

.calendar-loading.active {
    display: flex;
}


.calendar-loading-spinner {
    width: 60px;
    height: 60px;
    border: 4px solid rgba(var(--primary-rgb, 30, 64, 175), 0.1);
    border-radius: 50%;
    border-top-color: var(--primary);
    animation: spin 1s ease-in-out infinite;
}

.calendar-loading-text {
    color: var(--text);
    font-weight: 600;
    font-size: 1.1rem;
    letter-spacing: 0.5px;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}
     .date-consultant {
    background: var(--card-bg);
    border-radius: 20px;
    padding: 32px 0 32px;
    margin-top: 30px;
    box-shadow: var(--shadow);
    border: 1px solid var(--card-border);
    transition: all 0.3s ease;
}

.date-consultant:hover {
    box-shadow: var(--shadow-lg);
    border-color: var(--primary-light);
}

.consultant-header {
    margin-bottom: 32px;
    text-align: center;
}

.consultant-header h3 {
    color: var(--primary);
    margin-bottom: 12px;
    font-size: 1.5rem;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
}

.consultant-header p {
    color: var(--text-light);
    font-size: 1rem;
    max-width: 600px;
    margin: 0 auto;
    line-height: 1.6;
}

.consultant-content {
    max-width: 600px;
    margin: 0 auto;
}

       .input-group {
    margin-bottom: 24px;
}

.input-group label {
    display: block;
    margin-bottom: 12px;
    color: var(--text);
    font-weight: 600;
    font-size: 0.875rem;
    display: flex;
    align-items: center;
    gap: 10px;
}

.input-with-button {
    display: flex;
    gap: 12px;
}

#consultant-date {
    flex: 1;
    padding: 12px 20px;
    border: 2px solid var(--card-border);
    border-radius: 12px;
    background: var(--bg);
    color: var(--text);
    font-size: 1rem;
    transition: all 0.2s;
    font-family: 'Inter', sans-serif;
}

#consultant-date:hover {
    border-color: var(--primary-light);
}

#consultant-date:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(var(--primary-rgb, 30, 64, 175), 0.2);
}

#consultant-check {
    padding: 14px 24px;
    background: linear-gradient(135deg, var(--primary), var(--primary-light));
    color: white;
    border: none;
    border-radius: 12px;
    cursor: pointer;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 10px;
    transition: all 0.3s;
    white-space: nowrap;
}

#consultant-check:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow);
    background: linear-gradient(135deg, var(--primary-light), var(--primary));
}

    .consultant-result {
    background: var(--weekend);
    border-radius: 16px;
    padding: 32px;
    margin-bottom: 24px;
    min-height: 160px;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    border: 2px dashed var(--card-border);
    transition: all 0.3s ease;
}

.consultant-result.active {
    border: 2px solid var(--primary);
    background: rgba(var(--primary-rgb, 30, 64, 175), 0.05);
    box-shadow: 0 4px 12px rgba(var(--primary-rgb, 30, 64, 175), 0.1);
}

.result-placeholder {
    color: var(--text-light);
    opacity: 0.8;
}

.result-placeholder i {
    font-size: 2.5rem;
    margin-bottom: 16px;
    display: block;
    color: var(--primary-light);
    opacity: 0.5;
}

.result-content {
    width: 100%;
}

       .result-date {
    font-size: 2rem;
    font-weight: 800;
    color: var(--primary);
    margin-bottom: 8px;
    letter-spacing: 0.5px;
}

.result-weekday {
    font-size: 1.3rem;
    color: var(--text);
    margin-bottom: 12px;
    font-weight: 600;
}

.result-details {
    color: var(--text);
    opacity: 0.9;
    font-size: 0.95rem;
    margin-top: 20px;
    padding-top: 20px;
    border-top: 1px solid var(--card-border);
    display: flex;
    flex-direction: column;
    gap: 12px;
}

    .result-details div {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
}

.quick-dates {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    justify-content: center;
}

.quick-date-btn {
    padding: 12px 15px;
    background: var(--weekend);
    color: var(--text);
    border: 1px solid var(--card-border);
    border-radius: 10px;
    cursor: pointer;
    font-weight: 600;
    transition: all 0.3s;
    flex: 1;
    min-width: 140px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    font-size: 0.85rem;
}

.quick-date-btn:hover {
    background: var(--primary);
    color: white;
    transform: translateY(-2px);
    box-shadow: var(--shadow);
    border-color: var(--primary);
}

        .day-number .season-indicator {
            width: 22px;
            height: 22px;
            border-radius: 50%;
            display: flex;
            align-items: center;
            justify-content: center;
            font-size: 0.7em;
            color: white;
            font-weight: bold;
            box-shadow: 0 1px 3px rgba(0,0,0,0.2);
            opacity: 0.9;
            margin-left: auto;
        }

        .days div.today .day-number .season-indicator {
            width: 22px;
            height: 22px;
            font-size: 0.7em;
        }

        .day-number .season-indicator .season-tooltip {
            visibility: hidden;
            opacity: 0;
            position: absolute;
            bottom: 100%;
            left: 50%;
            transform: translateX(-50%);
            background: rgba(0, 0, 0, 0.9);
            color: white;
            padding: 6px 10px;
            border-radius: 6px;
            font-size: 0.75em;
            white-space: nowrap;
            z-index: 1000;
            margin-bottom: 8px;
            transition: opacity 0.3s ease, visibility 0.3s ease;
            pointer-events: none;
            font-weight: 500;
            min-width: 120px;
            text-align: center;
        }

        .day-number .season-indicator:hover .season-tooltip {
            visibility: visible;
            opacity: 1;
        }

        .season-spring { background: var(--spring); }
        .season-summer { background: var(--summer); }
        .season-autumn { background: var(--autumn); }
        .season-winter { background: var(--winter); }

        .season-indicator i {
            font-size: 1.2em;
        }

        .season-indicator .season-tooltip {
            visibility: hidden;
            opacity: 0;
            position: absolute;
            bottom: 100%;
            left: 50%;
            transform: translateX(-50%);
            background: rgba(0, 0, 0, 0.9);
            color: white;
            padding: 6px 10px;
            border-radius: 6px;
            font-size: 0.75em;
            white-space: nowrap;
            z-index: 1000;
            margin-bottom: 8px;
            transition: opacity 0.3s ease, visibility 0.3s ease;
            pointer-events: none;
            font-weight: 500;
            min-width: 120px;
            text-align: center;
        }

        .season-indicator:hover .season-tooltip {
            visibility: visible;
            opacity: 1;
        }

      .season-legend {
    display: none;
    justify-content: center;
    gap: 24px;
    flex-wrap: wrap;
    padding: 16px 24px;
    background: var(--season-bg);
    border-bottom: 1px solid rgba(0,0,0,0.1);
    border-top: 1px solid var(--card-border);
}

.season-legend.show {
    display: flex;
}

.season-legend,
.indicators-legend {
    flex-shrink: 0; 
    position: relative;
    z-index: 2;
}


.legend-season-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px 16px;
    background: var(--card-bg);
    border-radius: 8px;
    border: 1px solid var(--card-border);
    transition: all 0.2s ease;
}

.legend-season-item:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-sm);
}

.legend-season-dot {
    width: 18px;
    height: 18px;
    border-radius: 50%;
    border: 2px solid var(--card-bg);
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.legend-season-dot.spring { background: var(--spring); }
.legend-season-dot.summer { background: var(--summer); }
.legend-season-dot.autumn { background: var(--autumn); }
.legend-season-dot.winter { background: var(--winter); }



        .mobile-toggle-btn {
            background: var(--primary);
            color: white;
            border: none;
            padding: 8px 16px;
            border-radius: 6px;
            cursor: pointer;
            display: flex;
            align-items: center;
            gap: 6px;
            font-size: 0.9em;
            transition: all 0.2s;
        }

        .mobile-toggle-btn:hover {
            opacity: 0.9;
            transform: translateY(-1px);
        }

        .mobile-toggle-btn.active {
            background: var(--accent);
            color: var(--text);
        }

        @media (min-width: 1024px) {
            .main-content {
                flex-direction: row;
                align-items: flex-start;
            }
            
            .calendar-section {
                flex: 2;
                min-width: 0;
            }
            
            .event-list-section {
                flex: 1;
                min-width: 0;
                position: sticky;
                top: 120px;
                max-width: 400px;
            }
        }

        @media (max-width: 1024px) {
                .footer-content {
        grid-template-columns: repeat(2, 1fr);
        gap: 30px;
    }
    
    .footer-bottom-content {
        flex-direction: column;
        text-align: center;
        gap: 30px;
    }
    
    .footer-copyright {
        min-width: 100%;
    }
    
    .footer-stats {
        justify-content: center;
    }

        .month-year-search {
                flex: 1;
                min-width: 200px;
            }
            
            .search-input-group {
                width: 100%;
            }

              .main-content {
        flex-direction: column;
            }
            
            .calendar-section {
                width: 100%;
            }
            
            .event-list-section {
                width: 100%;
                max-width: none;
                position: static;
                top: auto;
            }
            
            .event-list-container {
                height: auto;
                min-height: auto;
                max-height: 600px;
            }
            .header-content {
                flex-direction: column;
                gap: 5px;
            }
            
            .header-left {
                width: 100%;
                justify-content: space-between;
                gap: 0;
            }
            
            .clock-container {
                width: 100%;
                justify-content: center;
            }
            
            #live-clock-container {
                min-width: 100%;
                justify-content: space-between;
            }

               .info-cards {
                grid-template-columns: repeat(2, 1fr);
                margin: 17% 20px 0;
            }
            
            .controls {
                justify-content: center;
            }

              .indicators-legend {
        gap: 12px;
        padding: 16px 20px;
    }
    
    .legend-item {
        font-size: 0.8125rem;
        padding: 5px 10px;
    }
    
    .season-legend {
        gap: 16px;
        padding: 12px 20px;
    }
    
    .legend-season-item {
        font-size: 0.8125rem;
        padding: 6px 12px;
    }
        }
        
        @media (max-width: 768px) {

                #recurring-event-modal .modal-actions {
        flex-direction: column;
    }
    
    #recurring-event-modal .confirm-btn {
        min-width: 100%;
    }
            .how-to-use-modal-content,
    .contact-modal-content {
        max-width: 95%;
        max-height: 90vh;
        margin: 5px;
    }

    .modal{
        padding: 5px;
    }
    
    .modal-header {
        padding: 20px;
    }
    
    .modal-header h2 {
        font-size: 1.3rem;
    }
    
    .modal-body {
        padding: 10px;
    }
    
    .modal-tabs {
        overflow-x: auto;
        flex-wrap: nowrap;
        padding-bottom: 12px;
        margin-bottom: 24px;
    }
    
    .tab-btn {
        padding: 10px 16px !important;
        font-size: 0.8rem !important;
        white-space: nowrap;
    }
    
    .feature-item {
        flex-direction: column;
        align-items: flex-start;
        gap: 15px;
        padding: 14px !important;
    }
    
    .feature-icon {
        width: 40px;
        height: 40px;
        font-size: 1.1rem;
    }
    
    .faq-question {
        padding: 16px;
    }
    
    .faq-question h3 {
        font-size: 0.95rem;
    }
    
    .contact-info-grid {
        grid-template-columns: 1fr;
    }
    
    .contact-card {
        padding: 20px;
    }
    
    .contact-hero {
        padding: 15px 0;
    }
    
    .contact-avatar {
        width: 80px;
        height: 80px;
        font-size: 2.5rem;
    }
    
    .contact-hours {
        flex-direction: column;
        align-items: flex-start;
        gap: 15px;
    }
    
    .modal-footer {
        padding: 20px;
        flex-direction: column;
        gap: 15px;
        text-align: center;
    }
    
    .quick-tips {
        text-align: center;
    }
    .day-modal-content {
        max-width: 95%;
        padding: 20px;
    }
    
    .day-event-item {
        padding: 16px;
    }
    
    .day-event-icon {
        width: 40px;
        height: 40px;
        font-size: 1rem;
    }
    .site-footer {
        padding-top: 60px;
    }
    
    .footer-content {
        grid-template-columns: 1fr;
        gap: 30px;
        text-align: center;
    }
    
    .footer-logo {
        justify-content: center;
    }
    
    .footer-description {
        max-width: 100%;
        margin: 0 auto 25px;
    }
    
    .footer-title::after {
        left: 50%;
        transform: translateX(-50%);
    }
    
    .footer-links a:hover {
        transform: translateX(0);
        padding-left: 6px;
    }
    
    .footer-stats {
        align-items: center;
        gap: 15px;
    }
    
    .stat-item {
        width: 100%;
        max-width: 250px;
        justify-content: center;
    }
    
    .footer-wave svg {
        height: 60px;
    }
            .header-actions {

                margin-left: 60px;
            }


    .month-year-search {
        margin: 10px 0;
    }
    
    .search-input-group {
        background: var(--weekend);
        border: 1px solid var(--card-border);
    }
    
        .mobile-toggle-btn{
                padding: 6px 12px;
                font-size: 0.9em;
            }
    .container {
        padding: 0 8px;
        gap: 10px;
    }
    
    .info-cards {
        grid-template-columns: 1fr;
        gap: 16px;
        margin: 15% 20px 0;
    }
    
    .info-card {
        padding: 20px;
    }
    
    .info-card-icon {
        width: 50px;
        height: 50px;
        font-size: 1.3rem;
    }
    
    .info-card-value {
        font-size: 1.3rem;
    }
    
    .controls {
        padding: 16px 0;
        margin-bottom: 16px;
        gap: 10px;
    }
    
    .controls button {
        padding: 10px 16px;
        font-size: 0.8125rem;
        flex: 1;
        min-width: 120px;
        justify-content: center;
    }

     .calendar-header {
        padding: 16px 20px;
    }
    
    .calendar-header h1 {
        font-size: 1.2rem;
    }
    
    .calendar-header button {
        width: 36px;
        height: 36px;
        font-size: 16px;
    }
    
    .weekdays div {
        padding: 12px 4px;
        font-size: 0.8125rem;
    }
    
    .days div {
        min-height: 80px;
        padding: 8px 4px;
    }
    
    .day-number {
        font-size: 0.9rem;
        margin-bottom: 6px;
    }
    
    .day-number .date-text {
        font-size: 1rem;
    }
    
    .days div.today .day-number .date-text {
        width: 24px;
        height: 24px;
        font-size: 0.9rem;
    }
    
    .season-indicator {
        width: 20px;
        height: 20px;
        font-size: 0.7rem;
    }
    
    .indicator {
        width: 18px;
        height: 18px;
    }
    
    .compact-indicators .indicator {
        width: 14px;
        height: 14px;
    }
    
    .indicator i {
        font-size: 0.6em;
    }
    
    .day-indicators {
        gap: 4px;
        max-height: 50px;
    }

      .indicators-legend {
        flex-wrap: wrap;
        justify-content: center;
        gap: 10px;
        padding: 12px 16px;
    }
    
    .legend-item {
        flex: 1;
        min-width: calc(50% - 10px);
        justify-content: center;
        font-size: 0.75rem;
    }
    
    .legend-dot {
        width: 12px;
        height: 12px;
    }
    
    .season-legend {
        gap: 12px;
        padding: 10px 16px;
    }
    
    .legend-season-item {
        flex: 1;
        min-width: calc(50% - 12px);
        justify-content: center;
        font-size: 0.75rem;
        padding: 6px 10px;
    }
    
    .legend-season-dot {
        width: 16px;
        height: 16px;
    }

      .mobile-event-list-header {
        display: flex;
        justify-content: space-between;
        align-items: center;
        margin-bottom: 20px;
        padding-bottom: 16px;
        border-bottom: 2px solid var(--primary);
    }
    
    .mobile-event-list-header h3 {
        margin: 0;
        padding: 0;
        border: none;
        font-size: 1rem;
    }
    
    .desktop-title {
        display: none !important;
    }
    
    .event-list-item {
        flex-direction: column;
        align-items: flex-start;
        gap: 8px;
        padding: 15px;
    }
    
    .event-date {
        flex-direction: row;
        align-items: center;
        gap: 12px;
        width: 100%;
        justify-content: space-between;
        text-align: left;
    }
    
    .event-date .weekday {
        font-size: 0.875rem;
    }
    
    .event-date .day {
        font-size: 1.5rem;
    }
    
    .event-text {
        width: 100%;
        margin: 0;
    }
    
    .event-type-badge {
        align-self: flex-start;
    }
    
}

        @media (min-width: 768px) {



            .btn-limpar-mobile {
                display: none;
            }
            
            .btn-limpar {
                display: flex;
            }
            
            .calendar-header h1 {
                padding-right: 0;
            }
            .main-content {
                flex-direction: row;
            }
            
            .calendar-section {
                flex: 2;
            }
            
            .event-list-section {
                flex: 1;
                max-width: 400px;
                display: block !important;
            }

            .mobile-event-list-header {
                display: none !important;
            }
            
            .desktop-title {
                display: flex !important;
                align-items: center;
                gap: 10px;
                margin-bottom: 15px;
                padding-bottom: 10px;
                border-bottom: 2px solid var(--primary);
                color: var(--primary);
            }
            
            #event-list-toggle {
                display: none;
            }
        }
        

        @media (max-width: 767px) {
            .day-number .season-indicator {
                position: static !important;
                margin-left: 0 !important;
                margin-top: 2px;
                width: 16px !important;
                height: 16px !important;
                font-size: 0.6em !important;
                order: 1;
            }

            .day-number.with-season > :first-child:not(.season-indicator) {
                display: block !important;
                font-size: 1em;
                font-weight: bold;
                line-height: 1;
            }

             .days {
                    grid-auto-rows: minmax(70px, auto);
                }
                
                .days div {
                    min-height: 70px;
                }
                
                .days div.with-many-events {
                    min-height: 90px;
                }
            
            .day-indicators {
                flex: 1;
                margin-top: auto;
                min-height: 20px;
                max-height: none;
            }
            
            .days div.today .day-number {
                padding: 2px 4px !important;
                width: fit-content;
            }
            
            .day-number.with-season {
                flex-direction: row !important;
                justify-content: space-between !important;
                align-items: center !important;
                margin-bottom: 4px;
            }
            
            .day-number .season-indicator {
                width: 18px !important;
                height: 18px !important;
                font-size: 0.6em !important;
                margin-left: 4px !important;
            }
            
            .calendar-content {
                min-height: 400px !important;
                height: auto !important;
            }
                .calendar-loading {
                border-radius: 0 0 12px 12px;
            }
                    
            .calendar-month {
                height: auto !important;
            }
            
            .days div.today .day-number.with-season > :first-child:not(.season-indicator) {
                background: var(--primary);
                color: white;
                padding: 2px 4px;
                border-radius: 2px;
            }

            .season-legend {
                border-radius: 0;
            }
            
            .desktop-title {
                display: none !important;
            }
            
            .calendar-content {
                min-height: 10px;
            }
            
            .mobile-event-list-header {
                display: flex;
                justify-content: space-between;
                align-items: center;
                margin-bottom: 15px;
                padding-bottom: 10px;
                border-bottom: 2px solid var(--primary);
            }
            
            .mobile-event-list-header h3 {
                margin: 0;
                padding: 0;
                border: none;
            }
            
            #event-list-toggle {
                margin-top: 0;
                width: auto;
                padding: 8px 12px;
                font-size: 0.9em;
            }
            
            .event-list-container > h3 {
                display: none;
            }
            
            .event-list-section {
                display: block;
            }
            
            .info-cards {
                grid-template-columns: 1fr;
                margin: 30% 20px 0;
            }
            
            .info-card {
                padding: 15px;
            }
            
            .info-card-icon {
                width: 50px;
                height: 50px;
                font-size: 1.5em;
            }
            
            .info-card-value {
                font-size: 1.2em;
            }
            
            .btn-limpar {
                display: none;
            }
            
            .btn-limpar-mobile {
                display: flex;
            }
            
            .calendar-header h1 {
                padding-right: 50px;
            }

            body {
                padding: 0px 0px 0 0px;
            }
            
            .calendar-container {
                border-radius: 12px;
            }
            
            .days div {
                min-height: auto !important;
                height: auto !important;
                padding: 9px 3px !important;
                display: flex;
                flex-direction: column;
                justify-content: space-between;
            }
            
            .day-number {
                margin-bottom: 4px;
                font-size: 1em !important;
            }
            
            .controls {
                width: 100%;
                justify-content: center;
            }
            
    .app-header {
        padding: 12px 0;
    }
    
    .header-left {
        align-items: center;
        text-align: center;
        gap: 10px;
    }
    
#live-clock-container {
        padding: 8px 20px;
        min-width: auto;
        flex-wrap: wrap;
        gap: 8px;
    }
    
    .live-clock {
        font-size: 1.2rem;
        min-width: 80px;
    }
    
    .live-date {
        font-size: 0.8rem;
    }

       .timezone-select {
        min-width: 140px;
        font-size: 0.75rem;
        padding: 5px 8px;
    }
            
            .app-header h1 {
                text-align: center;
                margin-bottom: 10px;
            }
            
                .app-title h1 {
                font-size: 1.25rem;
            }
    
            
            .calendar-header {
                justify-content: initial;
            }
            
            
            .indicator .tooltip {
                font-size: 0.7em;
                padding: 5px 8px;
                white-space: normal;
                width: 140px;
                word-wrap: break-word;
            }
            
            .category-option {
                min-width: 70px;
            }
            
            .recurrence-type-selector {
                grid-template-columns: 1fr;
            }
            
            .day-of-week-option label {
                width: 32px;
                height: 32px;
                font-size: 0.8em;
            }
            
            .modal-content {
                max-width: 95%;
                padding: 20px;
            }

            .holiday-modal-content{
                padding: 20px;
            }
            
            .holiday-info {
                flex-direction: column;
                text-align: center;
                padding: 16px;
                gap: 10px;
            }
            
            .holiday-icon {
                width: 60px;
                height: 60px;
                font-size: 1.8em;
            }
            
            
            .modal-actions button {
                min-width: 120px;
                padding: 6px 24px;
            }

            .consultant-header p{
                font-size:  0.9rem;
            }

            .date-consultant {
                padding: 20px;
            }
            
            .input-with-button {
                flex-direction: column;
            }
            
            .quick-dates {
                flex-direction: column;
            }
            
            .quick-date-btn {
                min-width: 100%;
            }
            
            .result-date {
                font-size: 1.5em;
            }
            
            .result-weekday {
                font-size: 1.1em;
            }
        }


        @media (max-width: 480px) {

            .consultant-result {
                    padding: 25px;
            }


        .modal-header {
        gap: 17px;
    }
    
    .modal-header h2 {
        font-size: 1.1rem !important;
    }
    
    .header-actions .help-btn,
    .header-actions {
        padding: 11px 15px !important;
        font-size: 1rem !important;
    }
    
    .header-actions .help-btn i,
    .header-actions .contact-header-btn i {
        font-size: 1rem;
    }
    .footer-container {
        padding: 0 15px 30px;
    }
    
    .footer-logo {
        font-size: 1.5rem;
    }
    
    .footer-logo i {
        font-size: 1.8rem;
    }
    
    .footer-back-to-top {
        padding: 10px 20px;
        font-size: 0.85rem;
    }
    

  .search-input-group {
        flex-wrap: wrap;
        padding: 5px;
    }
    
    .search-select {
        min-width: calc(40% - 2px);
    }
    
    .search-btn {
        width: 100%;
    }

  .app-header {
        padding: 15px 0;
    }
    
    .header-content {
        padding: 0 12px;
    }
    
    .app-title h1 {
        font-size: 1.1rem;
    }
    
    #live-clock-container {
        flex-direction: column;
        align-items: stretch;
        gap: 8px;
    }
    
    .live-clock {
        text-align: center;
        font-size: 1.3rem;
    }
    
    .live-date {
        text-align: center;
        font-size: 0.75rem;
    }
    
    .timezone-select {
        width: 100%;
        min-width: auto;
    }
    .btn-limpar-mobile {
        top: 14px;
        right: 62px;
        width: 36px;
        height: 36px;
        font-size: 14px;
        border-radius: 10px;
    }
            
            .calendar-header h1 {
                padding-right: 10px;
                font-size: 1.2em;
            }

             .controls {
        flex-direction: row;
    }
    
    .controls button {
        width: 100%;
        min-width: auto;
    }
    
            .info-cards {
                grid-template-columns: 1fr;
                margin: 59% 0 0;
            }
    
    .info-card-content {
        width: 100%;
    }
    
    .info-card::before {
        width: 100%;
        height: 4px;
        top: 0;
        left: 0;
        border-radius: 4px 4px 0 0;
    }

    .calendar-header {
        padding: 14px 16px;
    }
    
    .calendar-header h1 {
        font-size: 1.1rem;
    }
    
    .weekdays div {
        padding: 10px 2px;
        font-size: 0.75rem;
    }
    
    .days div {
        min-height: 70px;
        padding: 8px 3px !important;
        font-size: 15px;
    }
    
    .day-number {
        flex-direction: column;
        align-items: center !important;
        gap: 4px;
        margin-bottom: 4px;
    }

    .event-stats{
            gap: 10px;
            font-size: 0.8rem;
    }
    
    .day-number .date-text {
        font-size: 0.9rem;
    }
    
    .season-indicator {
        width: 18px;
        height: 18px;
        margin-left: 0;
        order: -1;
        margin-bottom: 4px;
    }
    
    .day-indicators {
        justify-content: center;
    }
    
    .indicator {
        width: 16px;
        height: 16px;
    }
    
    .compact-indicators .indicator {
        width: 12px;
        height: 12px;
    }
    
    .indicator .tooltip {
        font-size: 0.7rem;
        min-width: 100px;
        max-width: 150px;
    }

      .indicators-legend {
        flex-direction: column;
        align-items: stretch;
        gap: 8px;
    }
    
    .legend-item {
        min-width: 100%;
    }
    
    .season-legend {
        flex-direction: column;
        gap: 8px;
    }
    
    .legend-season-item {
        min-width: 100%;
    }

    
        }

        .holiday-type-badge {
            display: inline-block;
            padding: 2px 8px;
            border-radius: 12px;
            font-size: 0.7em;
            font-weight: bold;
            vertical-align: middle;
            margin-left: 8px;
        }

        .holiday-type-national {
            background: var(--holiday-color);
            color: white;
        }

        .holiday-type-facultative {
            background: var(--facultative-color);
            color: white;
        }

        .holiday-type-religious {
            background: var(--religious-color);
            color: white;
        }

        .holiday-type-local {
            background: var(--local-color);
            color: white;
        }

#recurring-event-modal .modal-content {
    animation: modalSlideIn 0.3s ease-out;
}

#recurring-event-modal .modal-actions {
    flex-wrap: wrap;
    gap: 10px;
}

#recurring-event-modal .confirm-btn {
    flex: 1;
    min-width: 120px;
    padding: 12px 16px;
    border: none;
    border-radius: 10px;
    cursor: pointer;
    font-weight: 600;
    transition: all 0.2s;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

#recurring-event-modal .confirm-btn:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow);
}

#recurring-event-modal .confirm-btn:active {
    transform: translateY(0);
}


.day-modal-content {
    background: var(--card-bg);
    padding: 32px;
    border-radius: 20px;
    width: 100%;
    max-width: 500px;
    color: var(--text);
    box-shadow: var(--shadow-lg);
    border: 1px solid var(--card-border);
    animation: modalSlideIn 0.3s ease-out;
}

.day-modal-content h2 {
    margin-bottom: 24px;
    color: var(--primary);
    font-size: 1.5rem;
    font-weight: 700;
    display: flex;
    align-items: center;
    gap: 12px;
    padding-bottom: 16px;
    border-bottom: 2px solid var(--primary);
}

.day-events-container {
    max-height: 400px;
    overflow-y: auto;
    margin-bottom: 24px;
    padding-right: 8px;
}

.day-events-container::-webkit-scrollbar {
    width: 6px;
}

.day-events-container::-webkit-scrollbar-track {
    background: var(--weekend);
    border-radius: 3px;
}

.day-events-container::-webkit-scrollbar-thumb {
    background: var(--text-light);
    border-radius: 3px;
    opacity: 0.3;
}

.day-event-item {
    padding: 20px;
    margin-bottom: 16px;
    background: var(--event-list-bg);
    border-radius: 16px;
    border-left: 4px solid var(--personal-event);
    transition: all 0.3s ease;
    border: 1px solid var(--card-border);
    cursor: pointer;
    position: relative;
}

.day-event-item:hover {
    transform: translateX(8px);
    box-shadow: var(--shadow);
    border-left-width: 6px;
}

.day-event-item.holiday-item {
    border-left-color: var(--holiday-color);
    background: rgba(var(--holiday-color-rgb, 239, 68, 68), 0.05);
}

.day-event-item.facultative-item {
    border-left-color: var(--facultative-color);
    background: rgba(var(--facultative-color-rgb, 245, 158, 11), 0.05);
}

.day-event-item.religious-item {
    border-left-color: var(--religious-color);
    background: rgba(var(--religious-color-rgb, 99, 102, 241), 0.05);
}

.day-event-item.local-item {
    border-left-color: var(--local-color);
    background: rgba(var(--local-color-rgb, 236, 72, 153), 0.05);
}

.day-event-item.personal-item {
    background: rgba(var(--personal-event-rgb, 16, 185, 129), 0.05);
}

.day-event-item.work-item {
    background: rgba(var(--work-event-rgb, 59, 130, 246), 0.05);
}

.day-event-item.health-item {
    background: rgba(var(--health-event-rgb, 245, 158, 11), 0.05);
}

.day-event-item.leisure-item {
    background: rgba(var(--leisure-event-rgb, 139, 92, 246), 0.05);
}

.day-event-header {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 12px;
}

.day-event-icon {
    width: 48px;
    height: 48px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    flex-shrink: 0;
}

.day-event-icon.holiday {
    background: linear-gradient(135deg, var(--holiday-color), #f87171);
    color: white;
}

.day-event-icon.facultative {
    background: linear-gradient(135deg, var(--facultative-color), #fbbf24);
    color: white;
}

.day-event-icon.religious {
    background: linear-gradient(135deg, var(--religious-color), #818cf8);
    color: white;
}

.day-event-icon.local {
    background: linear-gradient(135deg, var(--local-color), #f472b6);
    color: white;
}

.day-event-icon.personal {
    background: linear-gradient(135deg, var(--personal-event), var(--accent-light));
    color: white;
}

.day-event-icon.work {
    background: linear-gradient(135deg, var(--work-event), #93c5fd);
    color: white;
}

.day-event-icon.health {
    background: linear-gradient(135deg, var(--health-event), #fcd34d);
    color: white;
}

.day-event-icon.leisure {
    background: linear-gradient(135deg, var(--leisure-event), #c4b5fd);
    color: white;
}

.day-event-info {
    flex: 1;
    min-width: 0;
}

.day-event-name {
    font-size: 1.1rem;
    font-weight: 700;
    margin-bottom: 4px;
    color: var(--text);
    line-height: 1.3;
}

.day-event-type {
    font-size: 0.75rem;
    font-weight: 600;
    padding: 4px 10px;
    border-radius: 12px;
    display: inline-block;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.day-event-type.holiday {
    background: rgba(var(--holiday-color-rgb, 239, 68, 68), 0.2);
    color: var(--holiday-color);
}

.day-event-type.facultative {
    background: rgba(var(--facultative-color-rgb, 245, 158, 11), 0.2);
    color: var(--facultative-color);
}

.day-event-type.religious {
    background: rgba(var(--religious-color-rgb, 99, 102, 241), 0.2);
    color: var(--religious-color);
}

.day-event-type.local {
    background: rgba(var(--local-color-rgb, 236, 72, 153), 0.2);
    color: var(--local-color);
}

.day-event-type.personal {
    background: rgba(var(--personal-event-rgb, 16, 185, 129), 0.2);
    color: var(--personal-event);
}

.day-event-type.work {
    background: rgba(var(--work-event-rgb, 59, 130, 246), 0.2);
    color: var(--work-event);
}

.day-event-type.health {
    background: rgba(var(--health-event-rgb, 245, 158, 11), 0.2);
    color: var(--health-event);
}

.day-event-type.leisure {
    background: rgba(var(--leisure-event-rgb, 139, 92, 246), 0.2);
    color: var(--leisure-event);
}

.day-event-recurring {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    background: var(--accent);
    color: var(--text);
    padding: 4px 8px;
    border-radius: 10px;
    font-size: 0.65rem;
    font-weight: 600;
    vertical-align: middle;
    margin-left: 8px;
}

.day-event-recurring i {
    font-size: 0.8em;
}

.day-modal-note {
    font-style: italic;
    margin-top: 20px;
    padding: 16px;
    background: var(--weekend);
    border-radius: 12px;
    text-align: center;
    font-size: 0.875rem;
    color: var(--text-light);
    border: 1px solid var(--card-border);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
}

/* ===== FOOTER ===== */
.site-footer {
    background: linear-gradient(135deg, var(--primary), var(--primary-light));
    color: white;
    margin-top: 60px;
    position: relative;
    overflow: hidden;
    padding-top: 80px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.footer-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px 40px;
    position: relative;
    z-index: 2;
}

.footer-content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 40px;
    margin-bottom: 50px;
}

.footer-section {
    animation: fadeInUp 0.6s ease-out;
}

.footer-logo {
    display: flex;
    align-items: center;
    gap: 18px;
    font-size: 1.8rem;
    font-weight: 700;
    margin-bottom: 20px;
    color: white;
}

.footer-logo i {
    font-size: 2.2rem;
    color: var(--accent-light);
    filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.2));
}

.footer-description {
    font-size: 0.95rem;
    line-height: 1.6;
    opacity: 0.9;
    margin-bottom: 25px;
    max-width: 300px;
}

.footer-title {
    font-size: 1.2rem;
    font-weight: 600;
    margin-bottom: 20px;
    color: white;
    position: relative;
    padding-bottom: 10px;
}

.footer-title::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 40px;
    height: 3px;
    background: var(--accent-light);
    border-radius: 2px;
}



.footer-links, .footer-links-0 {
    list-style: none;
}

.footer-links li, .footer-links-0 li {
    margin-bottom: 12px;
}

.footer-links a, .footer-links-0 a {
    color: rgba(255, 255, 255, 0.85);
    text-decoration: none;
    font-size: 0.95rem;
    display: flex;
    align-items: center;
    gap: 10px;
    transition: all 0.3s ease;
    padding: 6px 0;
    border-radius: 6px;
}

.footer-links a:hover {
    color: white;
    transform: translateX(8px);
    background: rgba(255, 255, 255, 0.1);
    padding-left: 10px;
}

.footer-links a i, .footer-links-0 a i {
    font-size: 0.9rem;
    color: var(--accent-light);
    width: 20px;
    text-align: center;
}

.footer-bottom {
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    padding-top: 30px;
    margin-top: 30px;
}

.footer-bottom-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 20px;
    margin-bottom: 25px;
}

.footer-copyright {
    flex: 1;
    min-width: 300px;
}

.footer-copyright p {
    margin-bottom: 8px;
    opacity: 0.9;
    font-size: 0.9rem;
}

.footer-version {
    font-size: 0.8rem !important;
    opacity: 0.7 !important;
    font-style: italic;
}

.footer-stats {
    display: flex;
    gap: 25px;
    flex-wrap: wrap;
}

.stat-item {
    display: flex;
    align-items: center;
    gap: 10px;
    background: rgba(255, 255, 255, 0.1);
    padding: 10px 18px;
    border-radius: 12px;
    border: 1px solid rgba(255, 255, 255, 0.15);
    transition: all 0.3s ease;
}

.stat-item:hover {
    background: rgba(255, 255, 255, 0.15);
    transform: translateY(-2px);
    border-color: var(--accent-light);
}

.stat-item i {
    color: var(--accent-light);
    font-size: 1.1rem;
}

.stat-item span {
    font-size: 0.9rem;
    font-weight: 500;
}

.footer-credits {
    text-align: center;
    padding-top: 25px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    position: relative;
}

.footer-credits p {
    margin-bottom: 20px;
    opacity: 0.9;
    font-size: 0.95rem;
}

.heart-beat {
    color: #ff6b6b;
    animation: heartbeat 1.5s ease-in-out infinite;
    display: inline-block;
    margin: 0 5px;
}

.developer-name a{
    color: var(--accent-light);
    font-weight: 600;
}

.footer-back-to-top {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    background: white;
    color: var(--primary);
    padding: 12px 24px;
    border-radius: 30px;
    font-weight: 600;
    font-size: 0.9rem;
    cursor: pointer;
    transition: all 0.3s ease;
    border: 2px solid transparent;
    text-decoration: none;
    margin-top: 10px;
}

.footer-back-to-top:hover {
    background: transparent;
    color: white;
    border-color: white;
    transform: translateY(-3px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.2);
}

.footer-back-to-top:active {
    transform: translateY(-1px);
}



/* Onda decorativa */
.footer-wave {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    overflow: hidden;
    line-height: 0;
    transform: rotate(180deg);
}

.footer-wave svg {
    position: relative;
    display: block;
    width: calc(100% + 1.3px);
    height: 80px;
}

.footer-wave .shape-fill {
    fill: rgba(255, 255, 255, 0.05);
}


/* ===== MODAL COMO USAR ===== */
.how-to-use-modal-content,
.contact-modal-content {
    background: var(--card-bg);
    border-radius: 12px;
    width: 100%;
    max-width: 800px;
    max-height: 85vh;
    color: var(--text);
    box-shadow: var(--shadow-lg);
    animation: modalSlideIn 0.3s ease-out;
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

.modal-header {
    padding: 24px 32px;
    border-bottom: 1px solid var(--card-border);
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: linear-gradient(135deg, var(--primary), var(--primary-light));
    color: white;
}

.modal-header h2 {
    margin: 0;
    color: white;
    font-size: 1.5rem;
    font-weight: 700;
    display: flex;
    align-items: center;
    gap: 12px;
}

.modal-close-btn {
    background: none;
    border: none;
    color: white;
    width: 40px;
    height: 40px;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.2s;
    font-size: 1.2rem;
}

.modal-close-btn:hover {
    transform: rotate(90deg);
}

.modal-body {
    padding: 32px;
    flex: 1;
    overflow-y: auto;
}

.modal-tabs {
    display: flex;
    gap: 8px;
    margin-bottom: 32px;
    flex-wrap: wrap;
    padding-bottom: 16px;
    border-bottom: 2px solid var(--card-border);
}

.tab-btn {
    padding: 12px 24px;
    background: var(--weekend);
    border: 2px solid transparent;
    border-radius: 10px;
    cursor: pointer;
    font-weight: 600;
    color: var(--text);
    transition: all 0.3s ease;
    font-size: 0.9rem;
    display: flex;
    align-items: center;
    gap: 8px;
}

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

.tab-btn:hover:not(.active) {
    background: var(--bg);
    border-color: var(--card-border);
    transform: translateY(-2px);
}

.tab-content {
    display: none;
    animation: fadeIn 0.3s ease-out;
}

.tab-content.active {
    display: block;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

.feature-item {
    display: flex;
    align-items: flex-start;
    gap: 20px;
    padding: 20px;
    margin-bottom: 16px;
    background: var(--weekend);
    border-radius: 16px;
    border-left: 4px solid var(--primary);
    transition: all 0.3s ease;
}

.feature-item:hover {
    transform: translateX(8px);
    box-shadow: var(--shadow);
    background: var(--bg);
}

.feature-icon {
    width: 50px;
    height: 50px;
    border-radius: 12px;
    background: linear-gradient(135deg, var(--primary), var(--primary-light));
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 1.3rem;
    flex-shrink: 0;
}

.feature-text h3 {
    margin: 0 0 8px 0;
    color: var(--text);
    font-size: 1.1rem;
}

.feature-text p {
    margin: 0;
    color: var(--text-light);
    font-size: 0.95rem;
    line-height: 1.6;
}

.faq-item {
    margin-bottom: 16px;
    border: 1px solid var(--card-border);
    border-radius: 12px;
    overflow: hidden;
    transition: all 0.3s ease;
}

.faq-item:hover {
    border-color: var(--primary-light);
    box-shadow: var(--shadow-sm);
}

.faq-question {
    padding: 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    cursor: pointer;
    background: var(--weekend);
    transition: all 0.3s ease;
}

.faq-question:hover {
    background: var(--bg);
}

.faq-question h3 {
    margin: 0;
    font-size: 1rem;
    color: var(--text);
    font-weight: 600;
}

.faq-question i {
    color: var(--text-light);
    transition: transform 0.3s ease;
}

.faq-item.active .faq-question i {
    transform: rotate(180deg);
}

.faq-answer {
    padding: 0 20px;
    max-height: 0;
    overflow: hidden;
    transition: all 0.3s ease;
    background: var(--bg);
}

.faq-item.active .faq-answer {
    padding: 20px;
    max-height: 500px;
}

.faq-answer p {
    margin: 0;
    color: var(--text);
    line-height: 1.6;
    font-size: 0.95rem;
}

.modal-footer {
    padding: 24px 32px;
    border-top: 1px solid var(--card-border);
    background: var(--weekend);
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 20px;
}

.quick-tips {
    flex: 1;
}

.quick-tips h4 {
    margin: 0 0 8px 0;
    color: var(--text);
    font-size: 0.95rem;
    display: flex;
    align-items: center;
    gap: 8px;
}

.quick-tips h4 i {
    color: var(--accent);
}

.quick-tips p {
    margin: 0;
    color: var(--text-light);
    font-size: 0.9rem;
    font-style: italic;
}

.modal-close-btn.large {
    padding: 12px 32px;
    background: var(--primary);
    color: white;
    border: none;
    border-radius: 10px;
    cursor: pointer;
    font-weight: 600;
    font-size: 1rem;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 10px;
    min-width: 140px;
    justify-content: center;
}

.modal-close-btn.large:hover {
    background: var(--primary-light);
    transform: translateY(-2px);
    box-shadow: var(--shadow);
}

/* ===== MODAL CONTATO ===== */
.contact-hero {
    text-align: center;
    padding: 0 0 20px;
    margin-bottom: 32px;
    border-bottom: 1px solid var(--card-border);
}

.contact-avatar {
    width: 100px;
    height: 100px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--primary), var(--primary-light));
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 20px;
    font-size: 3.5rem;
    color: white;
    box-shadow: var(--shadow-lg);
}

.contact-hero h3 {
    margin: 0 0 10px 0;
    color: var(--text);
    font-size: 1.5rem;
}

.contact-hero p {
    margin: 0;
    color: var(--text-light);
    max-width: 600px;
    margin: 0 auto;
    line-height: 1.6;
}

.contact-info-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
    margin-bottom: 32px;
}

.contact-card {
    padding: 24px;
    border-radius: 16px;
    border: 2px solid transparent;
    transition: all 0.3s ease;
    background: var(--weekend);
    position: relative;
    overflow: hidden;
}

.contact-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-lg);
    border-color: var(--primary-light);
}

.contact-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 4px;
}

.contact-card.email::before { background: var(--primary); }
.contact-card.phone::before { background: var(--accent); }
.contact-card.github::before { background: #333; }
.contact-card.linkedin::before { background: #0077b5; }

.contact-icon {
    width: 50px;
    height: 50px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    margin-bottom: 16px;
    color: white;
}

.contact-card.email .contact-icon { background: var(--primary); }
.contact-card.phone .contact-icon { background: var(--accent); }
.contact-card.github .contact-icon { background: #333; }
.contact-card.linkedin .contact-icon { background: #0077b5; }

.contact-details h4 {
    margin: 0 0 8px 0;
    color: var(--text);
    font-size: 1rem;
}

.contact-value {
    margin: 0 0 16px 0;
    color: var(--text);
    font-weight: 500;
    font-size: 1.1rem;
    word-break: break-all;
}

.copy-btn,
.contact-link {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 16px;
    border-radius: 8px;
    font-size: 0.9rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    text-decoration: none;
    border: 2px solid transparent;
}

.copy-btn {
    background: var(--bg);
    color: var(--text);
    border: 2px solid var(--card-border);
}

.copy-btn:hover {
    background: var(--primary);
    color: white;
    border-color: var(--primary);
    transform: translateY(-2px);
}

.copy-btn.copied {
    background: var(--accent);
    color: white;
    border-color: var(--accent);
}

.contact-link {
    background: var(--primary);
    color: white;
}

.contact-link:hover {
    background: var(--primary-light);
    transform: translateY(-2px);
    box-shadow: var(--shadow);
}

.contact-hours {
    display: flex;
    align-items: center;
    gap: 20px;
    padding: 24px;
    background: var(--weekend);
    border-radius: 16px;
    margin-bottom: 24px;
    border-left: 4px solid var(--accent);
}

.hours-icon {
    width: 50px;
    height: 50px;
    border-radius: 12px;
    background: var(--accent);
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 1.5rem;
    flex-shrink: 0;
}

.hours-info h4 {
    margin: 0 0 12px 0;
    color: var(--text);
    font-size: 1.1rem;
}

.hours-info p {
    margin: 4px 0;
    color: var(--text-light);
    font-size: 0.95rem;
}

.timezone-info {
    margin-top: 12px !important;
    padding-top: 12px;
    border-top: 1px solid var(--card-border);
    font-size: 0.9rem !important;
    color: var(--text-light) !important;
    display: flex;
    align-items: center;
    gap: 8px;
}

.contact-disclaimer {
    padding: 20px;
    background: rgba(var(--accent-rgb, 16, 185, 129), 0.1);
    border-radius: 12px;
    border-left: 4px solid var(--accent);
    display: flex;
    align-items: flex-start;
    gap: 15px;
}

.contact-disclaimer i {
    color: var(--accent);
    font-size: 1.2rem;
    margin-top: 2px;
}

.contact-disclaimer p {
    margin: 0;
    color: var(--text);
    font-size: 0.95rem;
    line-height: 1.6;
}

/* ===== HEADER BUTTONS ===== */
.header-actions .help-btn,
.header-actions .contact-header-btn {
    background: var(--bg);
    border: 1px solid var(--card-border);
    color: var(--text);
    padding: 8px 16px;
    border-radius: 8px;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.875rem;
    font-weight: 500;
    transition: all 0.2s;
    text-decoration: none;
}

.header-actions .help-btn:hover,
.header-actions .contact-header-btn:hover {
    background: var(--weekend);
    border-color: var(--primary-light);
    transform: translateY(-1px);
}

.header-actions .help-btn i,
.header-actions .contact-header-btn i {
    font-size: 0.9em;
}
