/* Dark Theme Overrides */
[data-theme="dark"] body {
    background-color: #121212 !important;
}
/* Global Text Colors & Variables */
[data-theme="dark"] {
    --color-default: #e0e0e0;
    --color-secondary: #cccccc;
}

[data-theme="dark"] body,
[data-theme="dark"] div,
[data-theme="dark"] h1,
[data-theme="dark"] h2,
[data-theme="dark"] h3,
[data-theme="dark"] h4,
[data-theme="dark"] h5,
[data-theme="dark"] h6,
[data-theme="dark"] p,
[data-theme="dark"] span:not(.theme-option span):not(.navbar span):not(.header span),
[data-theme="dark"] li,
[data-theme="dark"] td,
[data-theme="dark"] th,
[data-theme="dark"] label,
[data-theme="dark"] strong,
[data-theme="dark"] b,
[data-theme="dark"] small,
[data-theme="dark"] article,
[data-theme="dark"] section,
[data-theme="dark"] .text-muted,
[data-theme="dark"] .text-dark {
    color: #e0e0e0 !important;
}

[data-theme="dark"] a:not(.btn):not(.theme-option):not(.navbar a):not(.header a) {
    color: #66b2ff !important;
}
[data-theme="dark"] a:not(.btn):not(.theme-option):not(.navbar a):not(.header a):hover {
    color: #ffc732 !important;
}


[data-theme="dark"] section.announcement,
[data-theme="dark"] .announcement-update {
    background-color: #1e1e1e !important;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.4) !important;
}

[data-theme="dark"] .announcement-item,
[data-theme="dark"] .announcement-item-update {
    background-color: #2a2a2a !important;
    color: #e0e0e0 !important;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.3) !important;
}

[data-theme="dark"] h1.announcement-text,
[data-theme="dark"] .announcement-text-update,
[data-theme="dark"] .heading-update,
[data-theme="dark"] .main-title {
    color: #ffffff !important;
    border-color: #444 !important;
}

[data-theme="dark"] .content,
[data-theme="dark"] .announcement-content-text-update {
    color: #cccccc !important;
}

[data-theme="dark"] .sub-title,
[data-theme="dark"] .time,
[data-theme="dark"] h1.announcement-text .clock,
[data-theme="dark"] .clock,
[data-theme="dark"] .time-update {
    color: #aaa !important;
}

/* Calendar & Cards */
[data-theme="dark"] .company-calendar-section {
    background: #121212 !important;
}

[data-theme="dark"] .glass-card {
    background: #1e1e1e !important;
    border-color: #333 !important;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.4) !important;
}

[data-theme="dark"] .company-calendar-section .section-header h2,
[data-theme="dark"] .calendar-header h3,
[data-theme="dark"] .holiday-list-card h3 {
    color: #ffffff !important;
    border-color: #444 !important;
}

[data-theme="dark"] .calendar-nav-btn {
    background: #2a2a2a !important;
    color: #fff !important;
}
[data-theme="dark"] .calendar-nav-btn:hover {
    background: #3498db !important;
}

[data-theme="dark"] .calendar-day {
    background: #222 !important;
    border-color: #333 !important;
    color: #ddd !important;
}

[data-theme="dark"] .calendar-day:hover:not(.empty) {
    background: #333 !important;
}

[data-theme="dark"] .calendar-day.empty {
    background: transparent !important;
}

[data-theme="dark"] .calendar-day.today {
    background: rgba(52, 152, 219, 0.2) !important;
    border-color: #3498db !important;
}

[data-theme="dark"] .holiday-item {
    background: #2a2a2a !important;
    border-color: #444 !important;
}
[data-theme="dark"] .holiday-item:hover {
    background: #333 !important;
}
[data-theme="dark"] .holiday-name {
    color: #fff !important;
}
[data-theme="dark"] .holiday-date {
    color: #bbb !important;
}

/* Base components */
[data-theme="dark"] .section-bg {
    background-color: #1a1a1a !important;
}
[data-theme="dark"] .section-header h2 {
    color: #fff !important;
}
[data-theme="dark"] .breadcrumbs {
    background-color: #1a1a1a !important;
}

[data-theme="dark"] .popup-content,
[data-theme="dark"] .popup_img-content {
    background: #1e1e1e !important;
    color: #eee !important;
}

/* Fix inline white/light backgrounds and specific containers */
[data-theme="dark"] [style*="background-color: #f8f9fa"],
[data-theme="dark"] [style*="background-color:#f8f9fa"],
[data-theme="dark"] [style*="background-color: #fff"],
[data-theme="dark"] [style*="background-color:#fff"],
[data-theme="dark"] [style*="background-color: white"],
[data-theme="dark"] [style*="background: #fff"],
[data-theme="dark"] [style*="background:#fff"],
[data-theme="dark"] [style*="background: white"],
[data-theme="dark"] .bg-white,
[data-theme="dark"] .bg-light,
[data-theme="dark"] .subscribe-container,
[data-theme="dark"] .our-story,
[data-theme="dark"] .card,
[data-theme="dark"] .glass-card,
[data-theme="dark"] .company-calendar-section,
[data-theme="dark"] .holiday-item,
[data-theme="dark"] .navbar .dropdown ul,
[data-theme="dark"] .swal2-popup {
    background-color: #1e1e1e !important;
    border-color: #333 !important;
}
[data-theme="dark"] .holiday-item:hover {
    background-color: #2c1a1a !important;
}

/* Theme Switcher Button & Popup UI */
#theme-switcher-btn {
    position: fixed;
    bottom: 80px;
    right: 15px;
    z-index: 99999;
    background: #3498db;
    color: #fff;
    width: 45px;
    height: 45px;
    border-radius: 50%;
    border: none;
    cursor: pointer;
    box-shadow: 0 4px 10px rgba(0,0,0,0.3);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    transition: all 0.3s ease;
}

#theme-switcher-btn:hover {
    transform: scale(1.1);
    background: #2980b9;
}

#theme-popup {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    -webkit-backdrop-filter: blur(5px);
    backdrop-filter: blur(5px);
    display: flex;
    justify-content: center;
    align-items: center;
    visibility: hidden;
    opacity: 0;
    transition: visibility 0s, opacity 0.3s ease;
    z-index: 100000;
}

#theme-popup.show {
    visibility: visible;
    opacity: 1;
}

.theme-popup-inner {
    background: #fff;
    width: 90%;
    max-width: 400px;
    border-radius: 20px;
    padding: 30px;
    box-shadow: 0 15px 35px rgba(0,0,0,0.2);
    position: relative;
    transform: translateY(20px);
    transition: transform 0.3s ease;
}
#theme-popup.show .theme-popup-inner {
    transform: translateY(0);
}

[data-theme="dark"] .theme-popup-inner {
    background: #1e1e1e;
    color: #fff;
    box-shadow: 0 15px 35px rgba(0,0,0,0.6);
}

.theme-popup-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 25px;
}
.theme-popup-header h3 {
    margin: 0;
    font-size: 22px;
    font-weight: 700;
    color: #333;
}
[data-theme="dark"] .theme-popup-header h3 {
    color: #fff;
}

.theme-popup-close {
    background: none;
    border: none;
    font-size: 24px;
    color: #999;
    cursor: pointer;
    transition: color 0.2s;
}
.theme-popup-close:hover {
    color: #e74c3c;
}

.theme-options-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 15px;
}

.theme-option {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 15px;
    border-radius: 15px;
    border: 2px solid #edf2f7;
    cursor: pointer;
    transition: all 0.2s ease;
    background: #f8f9fa;
    color: #555;
}

[data-theme="dark"] .theme-option {
    background: #2a2a2a;
    border-color: #444;
    color: #bbb;
}

.theme-option:hover {
    transform: translateY(-3px);
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
}
[data-theme="dark"] .theme-option:hover {
    box-shadow: 0 5px 15px rgba(0,0,0,0.4);
}

.theme-option.active {
    border-color: #3498db;
    background: rgba(52, 152, 219, 0.1);
    color: #3498db;
}

.theme-option i {
    font-size: 28px;
    margin-bottom: 10px;
}
.theme-option span {
    font-size: 14px;
    font-weight: 600;
}
