* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    background: #191f59;
    color: white;
    font-family: 'Segoe UI', Arial, sans-serif;
    min-height: 100vh;
    margin-top: 60px;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
}

/* NAVIGATION BAR */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    height: 60px;
    background-color: white;
    box-shadow: 0 1px 3px rgba(0,0,0,0.1);
    z-index: 1000;
}

.nav-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 100%;
    padding: 0 24px;
}

.nav-logo {
    display: flex;
    align-items: center;
    gap: 10px;
}

.logo-img {
    height: 36px;
    width: auto;
}

.logo-text {
    font-size: 1.225rem;
    font-weight: 700;
    color: #111827;
}

.nav-links {
    display: flex;
    gap: 24px;
    align-items: center;
}

.nav-link {
    color: #0879d6;
    text-decoration: none;
    font-size: 1rem;
    font-weight: 600;
    transition: color 0.2s;
}

.nav-link:hover {
    color: #0056a3;
    text-decoration: underline;
}

/* HEADER */
.header {
    padding: 40px 48px 32px;
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.header h1 {
    font-size: 2.6rem;
    font-weight: 800;
    color: white;
    margin-bottom: 12px;
    line-height: 1.1;
}

.header p {
    font-size: 1.125rem;
    color: rgba(255,255,255,0.85);
    font-weight: 400;
    max-width: 900px;
    line-height: 1.6;
}

/* CHART CARD */
.card {
    background: white;
    color: black;
    border-radius: 12px;
    padding: 20px;
    margin: 0 24px 16px;
}

/* CONTROLS ROW */
.controls-row {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 16px;
    flex-wrap: wrap;
}

select {
    padding: 6px 10px;
    font-size: 1.025rem;
    border-radius: 8px;
    border: 1px solid #d1d5db;
    background: white;
    color: #111;
    cursor: pointer;
}

/* TIME/DATE TOGGLE */
.time-toggle {
    display: inline-flex;
    align-items: center;
    border-radius: 8px;
    border: 1px solid #e0e0e0;
    background: #f5f5f5;
    padding: 3px;
    gap: 2px;
}

.time-toggle button {
    height: 30px;
    padding: 0 14px;
    font-size: 0.975rem;
    font-weight: 600;
    border: none;
    background: transparent;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.2s;
    color: #555;
}

.time-toggle button:hover {
    background: #e0e0e0;
}

.time-toggle button.active {
    background: white;
    color: #111;
    box-shadow: 0 1px 3px rgba(0,0,0,0.15);
}

.nav-button {
    background: #0879d6;
    color: white;
    border: none;
    cursor: pointer;
    border-radius: 6px;
    padding: 6px 14px;
    font-size: 1.025rem;
    min-width: 36px;
}

.nav-button:disabled {
    background: #ccc;
    cursor: not-allowed;
}

/* CONNECTION STATUS */
.connection-status {
    display: inline-block;
    padding: 4px 10px;
    border-radius: 6px;
    font-size: 0.925rem;
    font-weight: bold;
}

.status-connected { background: #4caf50; color: white; }
.status-connecting { background: #ff9800; color: white; }
.status-disconnected { background: #f44336; color: white; }

/* DATA ANALYSIS CARD */
.stats-card {
    background: white;
    border-radius: 12px;
    padding: 20px 24px;
    margin: 0 24px 16px;
    color: black;
}

.stats-card-header {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 4px;
}

.stats-card-title {
    font-size: 1.325rem;
    font-weight: 700;
    color: black;
}

.stats-card-subtitle {
    font-size: 0.975rem;
    color: black;
    margin-bottom: 16px;
}

.stats-icon {
    color: black;
    display: flex;
    align-items: center;
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 0;
}

.stat-item {
    padding: 10px 16px 10px 0;
    border-right: 1px solid rgba(255,255,255,0.1);
}

.stat-item:last-child, .stat-item:nth-child(4n) {
    border-right: none;
}

.stat-label-row {
    display: flex;
    align-items: center;
    gap: 6px;
    color: black;
    font-size: 0.945rem;
    margin-bottom: 6px;
}

.stat-value {
    font-size: 1.175rem;
    font-weight: 700;
    color: black;
}

.stat-icon-sm {
    display: flex;
    align-items: center;
    opacity: 0.7;
    flex-shrink: 0;
}

/* ABOUT SECTION */
.about-section {
    background: white;
    color: #111;
    padding: 48px;
    margin: 0 24px 16px;
    border-radius: 12px;
}

.about-section h2 {
    font-size: 2.125rem;
    font-weight: 800;
    text-align: center;
    margin-bottom: 24px;
    color: #111;
}

.about-section p {
    font-size: 1.075rem;
    line-height: 1.7;
    color: #333;
    margin-bottom: 14px;
}

.image-placeholder {
    background: #f5f5f5;
    border-radius: 8px;
    min-height: 300px;
    margin: 20px 0;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
}

.bracket {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    font-size: 80px;
    font-weight: 300;
    color: rgba(0,0,0,0.15);
    user-select: none;
}

.bracket.left { left: 32px; }
.bracket.right { right: 32px; }

/* TEAM SECTION
.team-section {
    background: #e8e8e4;
    border-radius: 12px;
    padding: 32px 40px;
    margin: 0 24px 16px;
    color: #111;
}

.team-section h2 {
    font-size: 1.525rem;
    font-weight: 800;
    margin-bottom: 4px;
    color: #111;
}

.team-subtitle {
    font-size: 1.025rem;
    color: #555;
    margin-bottom: 24px;
}

.team-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
}

.team-member {
    display: flex;
    align-items: center;
    gap: 14px;
}

.team-avatar {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    background: #c8c8c4;
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.225rem;
    font-weight: 700;
    color: #888;
}

.team-info .name {
    font-weight: 700;
    font-size: 1.075rem;
    color: #111;
}

.team-info .role {
    font-size: 0.945rem;
    color: #555;
}

.team-info .email {
    font-size: 0.925rem;
    color: #888;
} */

/* FOOTER */
.footer {
    padding: 20px 24px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-top: 2px solid rgba(255,255,255,0.15);
    margin-top: 8px;
}

.footer-qr-codes {
    display: flex;
    gap: 12px;
    align-items: center;

}

.footer-qr-card {
    background: #d0d0cc;
    border-radius: 8px;
    width: 80px;
    height: 80px;
    overflow: hidden;
}

.footer-qr-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 8px;
}

.footer-content {
    flex: 1;
    padding-left: 24px;
}

.footer-title {
    font-size: 1.225rem;
    font-weight: 700;
    color: white;
    margin-bottom: 4px;
}

.footer-subtitle {
    font-size: 0.905rem;
    color: rgba(255,255,255,0.65);
    line-height: 1.5;
    margin-bottom: 2px;
}

/* LOADING OVERLAY */
.loading-overlay {
    position: absolute;
    top: 0; left: 0; right: 0; bottom: 0;
    background: rgba(255,255,255,0.95);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    border-radius: 12px;
    z-index: 10;
}

.loading-spinner {
    width: 44px;
    height: 44px;
    border: 4px solid #e0e0e0;
    border-top: 4px solid #0879d6;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

.loading-text {
    margin-top: 14px;
    font-size: 1.075rem;
    color: #333;
    font-weight: 600;
}
/* ── CAROUSEL ──────────────────────────────────────────────── */
.carousel {
    position: relative;
    margin: 24px 0 4px;
    border-radius: 10px;
    overflow: hidden;
    background: #f0f0ee;
}

.carousel-track-wrapper {
    overflow: hidden;
    border-radius: 10px;
    width: 100%;
}

.carousel-track {
    display: flex;
    will-change: transform;
}

.carousel-slide {
    min-width: 100%;
    height: 340px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #e8e8e4;
    overflow: hidden;
}

.carousel-slide img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    padding: 24px;
    user-select: none;
    -webkit-user-drag: none;
}

.carousel-btn {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 42px;
    height: 42px;
    border-radius: 50%;
    border: none;
    background: rgba(25, 31, 89, 0.75);
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: background 0.2s, transform 0.15s;
    z-index: 10;
    backdrop-filter: blur(4px);
}

.carousel-btn:hover {
    background: rgba(25, 31, 89, 0.95);
    transform: translateY(-50%) scale(1.08);
}

.carousel-btn-prev { left: 12px; }
.carousel-btn-next { right: 12px; }

.carousel-dots {
    display: flex;
    justify-content: center;
    gap: 8px;
    padding: 12px 0 10px;
    background: #e8e8e4;
}

.carousel-dot {
    width: 9px;
    height: 9px;
    border-radius: 50%;
    border: none;
    background: rgba(25, 31, 89, 0.25);
    cursor: pointer;
    padding: 0;
    transition: background 0.2s, transform 0.2s;
}

.carousel-dot.active {
    background: #191f59;
    transform: scale(1.25);
}

.carousel-dot:hover:not(.active) {
    background: rgba(25, 31, 89, 0.5);
}