/* ========================================
   ChillCheck Design System
   Apple-Inspired Clean & Modern Theme
   ======================================== */

/* ========================================
   Blazor Error UI (lives in index.html)
   ======================================== */

#blazor-error-ui {
    color-scheme: light only;
    background: #FEF2F2;
    border-top: 3px solid #FF3B30;
    bottom: 0;
    box-shadow: 0 -4px 6px -1px rgba(0, 0, 0, 0.1);
    box-sizing: border-box;
    display: none;
    left: 0;
    padding: 1rem 1.5rem;
    position: fixed;
    width: 100%;
    z-index: 1000;
    color: #D70015;
    font-weight: 500;
}

#blazor-error-ui .dismiss {
    cursor: pointer;
    position: absolute;
    right: 1rem;
    top: 0.75rem;
    font-size: 1.25rem;
    opacity: 0.7;
    transition: opacity 0.15s ease;
}

#blazor-error-ui .dismiss:hover {
    opacity: 1;
}

#blazor-error-ui .reload {
    color: #0EA5E9;
    font-weight: 600;
    margin-left: 0.5rem;
}

:root {
    /* ChillCheck Brand Colours */
    --cc-sidebar: #0F172A;      /* Deep Blue/Black */
    --cc-bg: #F5F5F7;           /* Apple-style light grey */
    --cc-primary: #0EA5E9;      /* Ice Blue Action Colour */
    --cc-white: #FFFFFF;        /* Snow White */
    --cc-success: #34C759;      /* Apple Green */
    --cc-danger: #FF3B30;       /* Apple Red */
    --cc-warning: #FF9500;      /* Apple Orange */
    
    /* Extended Palette - Apple inspired */
    --cc-text: #1D1D1F;         /* Apple dark text */
    --cc-text-secondary: #86868B; /* Apple secondary text */
    --cc-text-muted: #6E6E73;   /* Muted text */
    --cc-border: #D2D2D7;       /* Apple border */
    --cc-card-bg: #FFFFFF;
    --cc-card-shadow: 0 2px 8px rgba(0, 0, 0, 0.04), 0 1px 2px rgba(0, 0, 0, 0.06);
    --cc-card-shadow-hover: 0 8px 24px rgba(0, 0, 0, 0.08), 0 2px 8px rgba(0, 0, 0, 0.04);
    
    /* Typography */
    --cc-font: -apple-system, BlinkMacSystemFont, 'SF Pro Display', 'SF Pro Text', 'Helvetica Neue', Helvetica, Arial, sans-serif;
    --cc-font-mono: 'SF Mono', SFMono-Regular, ui-monospace, Menlo, Monaco, monospace;
    
    /* Spacing */
    --cc-radius: 12px;
    --cc-radius-lg: 16px;
    --cc-radius-sm: 8px;
}

html, body {
    font-family: var(--cc-font);
    background-color: var(--cc-bg);
    color: var(--cc-text);
    font-size: 17px;
    line-height: 1.47059;
    font-weight: 400;
    letter-spacing: -0.022em;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* ========================================
   Typography - Apple Style
   ======================================== */

h1, h2, h3, h4, h5, h6 {
    font-weight: 600;
    color: var(--cc-text);
    letter-spacing: -0.025em;
}

h1 {
    font-size: 2rem;
    font-weight: 700;
    margin-bottom: 2rem;
    letter-spacing: -0.03em;
}

h3 {
    font-size: 1.375rem;
    font-weight: 600;
    margin-top: 2.5rem;
    margin-bottom: 1.25rem;
}

p {
    color: var(--cc-text-secondary);
}

/* ========================================
   Links & Buttons - Apple Style
   ======================================== */

a, .btn-link {
    color: var(--cc-primary);
    text-decoration: none;
    transition: opacity 0.2s ease;
}

a:hover, .btn-link:hover {
    opacity: 0.7;
    color: var(--cc-primary);
}

.btn {
    font-weight: 500;
    border-radius: var(--cc-radius);
    padding: 0.75rem 1.5rem;
    font-size: 0.9375rem;
    letter-spacing: -0.01em;
    transition: all 0.2s cubic-bezier(0.25, 0.1, 0.25, 1);
    border: none;
}

.btn-primary {
    color: var(--cc-white);
    background-color: var(--cc-primary);
    border: none;
}

.btn-primary:hover {
    background-color: var(--cc-primary);
    opacity: 0.85;
    transform: scale(1.02);
}

.btn-primary:active {
    transform: scale(0.98);
}

.btn-outline-secondary {
    background: var(--cc-white);
    border: 1px solid var(--cc-border);
    color: var(--cc-text);
}

.btn-outline-secondary:hover {
    background: var(--cc-bg);
    border-color: var(--cc-border);
    color: var(--cc-text);
}

.btn:focus, .btn:active:focus, .btn-link.nav-link:focus, .form-control:focus, .form-check-input:focus {
    box-shadow: 0 0 0 4px rgba(14, 165, 233, 0.2);
    outline: none;
}

/* ========================================
   Cards - Apple Style Glass Cards
   ======================================== */

.card {
    border: none;
    border-radius: var(--cc-radius-lg);
    box-shadow: var(--cc-card-shadow);
    transition: all 0.3s cubic-bezier(0.25, 0.1, 0.25, 1);
    overflow: hidden;
    background: var(--cc-card-bg);
}

.card:hover {
    box-shadow: var(--cc-card-shadow-hover);
    transform: translateY(-4px);
}

.card-body {
    padding: 1.75rem;
}

.card-title {
    font-size: 0.8125rem;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    opacity: 0.85;
    margin-bottom: 0.75rem;
}

.card h2 {
    font-size: 2.75rem;
    font-weight: 700;
    margin: 0;
    letter-spacing: -0.03em;
}

/* Card colour overrides for dashboard stats - Apple gradients */
.card.bg-primary {
    background: linear-gradient(145deg, #0EA5E9 0%, #0284C7 100%) !important;
}

.card.bg-success {
    background: linear-gradient(145deg, #34C759 0%, #28A745 100%) !important;
}

.card.bg-danger {
    background: linear-gradient(145deg, #FF3B30 0%, #E02D1B 100%) !important;
}

.card.bg-secondary {
    background: linear-gradient(145deg, #8E8E93 0%, #636366 100%) !important;
}

.card.text-white .card-title,
.card.text-white h2 {
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.1);
}

/* ========================================
   Tables - Apple Clean Style
   ======================================== */

.table {
    background: var(--cc-white);
    border-radius: var(--cc-radius-lg);
    overflow: hidden;
    box-shadow: var(--cc-card-shadow);
    border-collapse: separate;
    border-spacing: 0;
    font-size: 0.9375rem;
}

.table thead th {
    background-color: var(--cc-white);
    border-bottom: 1px solid var(--cc-border);
    font-weight: 600;
    font-size: 0.8125rem;
    text-transform: none;
    letter-spacing: normal;
    color: var(--cc-text-secondary);
    padding: 1rem 1.5rem;
}

.table tbody td {
    padding: 1.125rem 1.5rem;
    border-bottom: 1px solid rgba(0, 0, 0, 0.04);
    vertical-align: middle;
    color: var(--cc-text);
}

.table tbody tr:last-child td {
    border-bottom: none;
}

.table-striped > tbody > tr:nth-of-type(odd) > * {
    background-color: transparent;
}

.table tbody tr {
    transition: background-color 0.15s ease;
}

.table tbody tr:hover {
    background-color: rgba(0, 0, 0, 0.02) !important;
}

/* ========================================
   Badges - Apple Pill Style
   ======================================== */

.badge {
    font-weight: 500;
    font-size: 0.75rem;
    padding: 0.375rem 0.875rem;
    border-radius: 100px;
    text-transform: none;
    letter-spacing: normal;
}

.badge.bg-success {
    background-color: rgba(52, 199, 89, 0.12) !important;
    color: #248A3D !important;
}

.badge.bg-danger {
    background-color: rgba(255, 59, 48, 0.12) !important;
    color: #D70015 !important;
}

.badge.bg-warning {
    background-color: rgba(255, 149, 0, 0.12) !important;
    color: #C93400 !important;
}

.badge.bg-secondary {
    background-color: rgba(142, 142, 147, 0.12) !important;
    color: var(--cc-text-muted) !important;
}

/* ========================================
   Alerts - Apple Style
   ======================================== */

.alert {
    border: none;
    border-radius: var(--cc-radius);
    padding: 1rem 1.25rem;
    font-size: 0.9375rem;
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.alert-danger {
    background-color: rgba(255, 59, 48, 0.08);
    color: #D70015;
}

.alert-info {
    background-color: rgba(14, 165, 233, 0.08);
    color: #0077CC;
}

.alert-success {
    background-color: rgba(52, 199, 89, 0.08);
    color: #248A3D;
}

.alert-warning {
    background-color: rgba(255, 149, 0, 0.08);
    color: #C93400;
}

/* ========================================
   Code & Device IDs
   ======================================== */

code {
    background-color: rgba(0, 0, 0, 0.04);
    color: var(--cc-text);
    padding: 0.25rem 0.5rem;
    border-radius: var(--cc-radius-sm);
    font-size: 0.875rem;
    font-family: var(--cc-font-mono);
}

/* ========================================
   Content Area
   ======================================== */

.content {
    padding-top: 2rem;
    padding-bottom: 3rem;
}

h1:focus {
    outline: none;
}

/* ========================================
   Forms - Apple Style
   ======================================== */

.form-control {
    border: 1px solid var(--cc-border);
    border-radius: var(--cc-radius);
    padding: 0.75rem 1rem;
    font-size: 1rem;
    transition: all 0.2s ease;
    background-color: var(--cc-white);
}

.form-control:focus {
    border-color: var(--cc-primary);
    box-shadow: 0 0 0 4px rgba(14, 165, 233, 0.15);
}

.form-control::placeholder {
    color: var(--cc-text-muted);
}

.valid.modified:not([type=checkbox]) {
    outline: none;
    border-color: var(--cc-success);
}

.invalid {
    outline: none;
    border-color: var(--cc-danger);
}

.validation-message {
    color: var(--cc-danger);
    font-size: 0.875rem;
    margin-top: 0.375rem;
}

/* ========================================
   Loading State
   ======================================== */

em {
    color: var(--cc-text-muted);
    font-style: normal;
}

/* ========================================
   Error Boundaries
   ======================================== */

.blazor-error-boundary {
    background: rgba(255, 59, 48, 0.08);
    padding: 1.25rem 1.5rem;
    color: #D70015;
    border-radius: var(--cc-radius);
    margin: 1rem 0;
}

.blazor-error-boundary::after {
    content: "An error has occurred. Please refresh the page.";
}

.darker-border-checkbox.form-check-input {
    border-color: var(--cc-border);
}

.form-floating > .form-control-plaintext::placeholder, .form-floating > .form-control::placeholder {
    color: var(--cc-text-muted);
    text-align: end;
}

.form-floating > .form-control-plaintext:focus::placeholder, .form-floating > .form-control:focus::placeholder {
    text-align: start;
}

/* ========================================
   Dashboard Layout Spacing
   ======================================== */

.row.mb-4 {
    margin-bottom: 2.5rem !important;
}

.row .col-md-3 {
    margin-bottom: 1.25rem;
}

/* ========================================
   Smooth Scrolling & Selection
   ======================================== */

html {
    scroll-behavior: smooth;
}

::selection {
    background-color: rgba(14, 165, 233, 0.2);
}

/* ========================================
   Utility Classes
   ======================================== */

.text-muted {
    color: var(--cc-text-muted) !important;
}

/* ========================================
   Dashboard - TempGuard Style
   ======================================== */

/* Stats Row */
.stats-row {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1.25rem;
    margin-bottom: 2rem;
}

.stat-card {
    background: var(--cc-white);
    border-radius: var(--cc-radius-lg);
    padding: 1.5rem;
    box-shadow: var(--cc-card-shadow);
}

.stat-label {
    font-size: 0.875rem;
    color: var(--cc-text-muted);
    margin-bottom: 0.5rem;
    font-weight: 500;
}

.stat-value {
    font-size: 2.25rem;
    font-weight: 700;
    color: var(--cc-text);
    letter-spacing: -0.02em;
}

.stat-value.stat-alert {
    color: var(--cc-danger);
}

.stat-value.stat-success {
    color: var(--cc-success);
}

.stat-status {
    font-size: 1.25rem;
}

.status-ok {
    color: var(--cc-success);
    font-weight: 600;
}

.status-warning {
    color: var(--cc-warning);
    font-weight: 600;
}

/* Dashboard Grid */
.dashboard-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    grid-template-rows: auto auto;
    gap: 1.5rem;
}

.dashboard-section {
    background: var(--cc-white);
    border-radius: var(--cc-radius-lg);
    padding: 1.5rem;
    box-shadow: var(--cc-card-shadow);
}

.section-title {
    font-size: 1.125rem;
    font-weight: 600;
    color: var(--cc-text);
    margin: 0 0 1.25rem 0;
    letter-spacing: -0.01em;
}

.section-header-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
}

.section-header-row .section-title {
    margin: 0;
}

.section-updated {
    font-size: 0.75rem;
    color: #94a3b8;
}

/* Temperatures Section */
.temperatures-section {
    grid-column: 1;
    grid-row: 1 / 3;
}

.device-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1rem;
}

.device-card {
    display: block;
    background: #FAFAFA;
    border-radius: var(--cc-radius);
    padding: 1.25rem;
    border: 1px solid #F0F0F0;
    transition: all 0.2s ease;
    text-decoration: none;
    color: inherit;
    cursor: pointer;
}

.device-card:hover {
    border-color: var(--cc-primary);
    background: #F5F5F5;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
}

.device-card.has-alert {
    border-color: rgba(255, 59, 48, 0.3);
    background: rgba(255, 59, 48, 0.03);
}

.device-name {
    font-size: 0.9375rem;
    font-weight: 500;
    color: var(--cc-text-muted);
    margin-bottom: 0.5rem;
}

.device-temp {
    margin-bottom: 0.5rem;
}

.temp-value {
    font-size: 1.75rem;
    font-weight: 700;
    color: var(--cc-text);
    letter-spacing: -0.02em;
}

.temp-value.temp-alert {
    color: var(--cc-danger);
}

.temp-value.temp-na {
    color: var(--cc-text-muted);
}

.device-status {
    display: flex;
    align-items: center;
}

.status-badge {
    font-size: 0.8125rem;
    font-weight: 500;
    padding: 0.125rem 0;
}

.status-badge.status-normal {
    color: var(--cc-success);
}

.status-badge.status-alert {
    color: var(--cc-danger);
}

.status-badge.status-offline {
    color: var(--cc-text-muted);
}

/* Alerts Section */
.alerts-section {
    grid-column: 2;
    grid-row: 1;
}

.alerts-list {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.alert-item {
    display: flex;
    align-items: flex-start;
    gap: 0.875rem;
    padding: 0.75rem;
    background: rgba(255, 59, 48, 0.04);
    border-radius: var(--cc-radius-sm);
    border-left: 3px solid var(--cc-danger);
}

.alert-icon {
    font-size: 1.25rem;
    line-height: 1;
    color: var(--cc-danger);
}

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

.alert-title {
    font-size: 0.9375rem;
    font-weight: 500;
    color: var(--cc-danger);
    margin-bottom: 0.25rem;
}

.alert-time {
    font-size: 0.8125rem;
    color: var(--cc-text-muted);
}

/* Stats/Overview Section */
.stats-section {
    grid-column: 2;
    grid-row: 2;
}

.overview-stats {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1rem;
}

.overview-stat {
    text-align: center;
    padding: 1rem;
    background: #FAFAFA;
    border-radius: var(--cc-radius);
}

.overview-value {
    font-size: 1.75rem;
    font-weight: 700;
    color: var(--cc-text);
    letter-spacing: -0.02em;
}

.overview-label {
    font-size: 0.8125rem;
    color: var(--cc-text-muted);
    margin-top: 0.25rem;
}

/* Section Footer */
.section-footer {
    margin-top: 1.25rem;
    padding-top: 1rem;
    border-top: 1px solid #F0F0F0;
    text-align: center;
}

.view-all-link {
    font-size: 0.875rem;
    font-weight: 500;
    color: var(--cc-primary);
}

.view-all-btn {
    display: inline-block;
    padding: 0.5rem 1.25rem;
    background: #FAFAFA;
    color: var(--cc-text);
    font-size: 0.875rem;
    font-weight: 500;
    border-radius: var(--cc-radius-sm);
    text-decoration: none;
    border: 1px solid #E5E5E5;
    transition: all 0.2s ease;
}

.view-all-btn:hover {
    background: #F0F0F0;
    color: var(--cc-text);
}

/* Empty States */
.empty-state {
    text-align: center;
    padding: 3rem 2rem;
    grid-column: 1 / -1;
}

.empty-state p {
    color: var(--cc-text-muted);
    margin-bottom: 1rem;
}

.empty-state-small {
    text-align: center;
    padding: 2rem 1rem;
    color: var(--cc-text-muted);
}

.empty-state-small .status-ok {
    font-size: 1.5rem;
    display: block;
    margin-bottom: 0.5rem;
}

.loading-state {
    text-align: center;
    padding: 3rem;
    color: var(--cc-text-muted);
}

/* Responsive */
@media (max-width: 1024px) {
    .stats-row {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .dashboard-grid {
        grid-template-columns: 1fr;
    }
    
    .temperatures-section {
        grid-column: 1;
        grid-row: auto;
    }
    
    .alerts-section {
        grid-column: 1;
        grid-row: auto;
    }
    
    .stats-section {
        grid-column: 1;
        grid-row: auto;
    }
}

@media (max-width: 640px) {
    .stats-row {
        grid-template-columns: 1fr;
    }
    
    .device-grid {
        grid-template-columns: 1fr;
    }
    
    .overview-stats {
        grid-template-columns: 1fr;
    }
}

/* ========================================
   Mobile Navigation Menu
   ======================================== */

.mobile-menu-toggle {
    display: none;
    width: 44px;
    height: 44px;
    padding: 10px;
    background: transparent;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    color: #1D1D1F;
    transition: background-color 0.2s ease;
    align-items: center;
    justify-content: center;
}

.mobile-menu-toggle:hover {
    background-color: rgba(0, 0, 0, 0.06);
}

.mobile-menu-toggle svg {
    width: 24px;
    height: 24px;
    display: block;
}

@media (max-width: 768px) {
    /* Show hamburger menu on mobile */
    .mobile-menu-toggle {
        display: flex !important;
    }
    
    /* Hide main nav by default on mobile */
    .main-nav {
        display: none !important;
        position: absolute;
        top: 3.5rem;
        left: 0;
        right: 0;
        background: #FFFFFF;
        flex-direction: column;
        padding: 1rem;
        border-bottom: 1px solid #E5E5E7;
        box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
        z-index: 99;
        margin-left: 0;
        gap: 0.25rem;
    }
    
    /* Show nav when mobile-open class is added */
    .main-nav.mobile-open {
        display: flex !important;
    }
    
    .main-nav .nav-link {
        width: 100%;
        padding: 0.875rem 1rem;
        text-align: left;
        font-size: 1rem;
    }
    
    /* Hide user name and badge on mobile */
    .user-nav .user-name,
    .user-nav .badge {
        display: none;
    }
    
    /* Adjust nav container for mobile */
    .nav-container {
        position: relative;
    }
}

/* ========================================
   Active Navigation Link Styling
   ======================================== */

.main-nav .nav-link.active,
.main-nav a.nav-link.active,
nav.main-nav .nav-link.active,
nav.main-nav a.nav-link.active {
    color: var(--cc-primary) !important;
    background-color: rgba(14, 165, 233, 0.12) !important;
    font-weight: 700 !important;
    text-decoration: underline !important;
    text-decoration-color: var(--cc-primary) !important;
    text-decoration-thickness: 2px !important;
    text-underline-offset: 4px !important;
}

/* ========================================
   Grouped Device Card - Multi-Sensor View
   ======================================== */

.grouped-device-card {
    display: block;
    background: var(--cc-white);
    border-radius: var(--cc-radius-lg);
    border: 1.5px solid #e5e7eb;
    overflow: hidden;
    cursor: pointer;
    transition: box-shadow 0.15s ease, transform 0.15s ease;
    text-decoration: none;
    color: inherit;
}

.grouped-device-card:hover {
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.08);
    transform: translateY(-2px);
    text-decoration: none;
    color: inherit;
}

.grouped-device-card.has-alert {
    border-color: rgba(239, 68, 68, 0.4);
}

.grouped-device-card.has-warning {
    border-color: rgba(245, 158, 11, 0.4);
}

/* Card Header */
.grouped-card-header {
    padding: 14px 18px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid #f1f5f9;
}

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

.card-device-name {
    font-weight: 700;
    font-size: 0.9375rem;
    color: #0f172a;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.card-device-meta {
    font-size: 0.75rem;
    color: #94a3b8;
    margin-top: 2px;
}

/* Status Badge Pill */
.status-badge-pill {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 4px 10px;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 600;
    flex-shrink: 0;
}

.status-badge-pill.status-normal {
    background: #f0fdf4;
    color: #22c55e;
}

.status-badge-pill.status-warning {
    background: #fffbeb;
    color: #f59e0b;
}

.status-badge-pill.status-critical {
    background: #fef2f2;
    color: #ef4444;
}

.status-badge-pill .status-dot-small {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: currentColor;
}

/* Sensor Rows Container */
.sensor-rows {
    padding: 4px 0;
}

/* Individual Sensor Row */
.sensor-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 10px 18px;
    border-bottom: 1px solid #f8fafc;
    transition: background-color 0.15s ease;
}

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

.sensor-row.row-warning {
    background: #fffbeb;
}

.sensor-row.row-critical {
    background: #fef2f2;
}

.sensor-row.no-sensors {
    justify-content: center;
    padding: 16px;
}

/* Sensor Left (Status + Info) */
.sensor-left {
    display: flex;
    align-items: center;
    gap: 8px;
    flex: 1;
    min-width: 0;
}

/* Status Dot */
.status-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    flex-shrink: 0;
}

.status-dot.normal {
    background: #22c55e;
}

.status-dot.warning {
    background: #f59e0b;
}

.status-dot.critical {
    background: #ef4444;
}

/* Sensor Info */
.sensor-info {
    display: flex;
    flex-direction: column;
    min-width: 0;
}

.sensor-name {
    font-size: 0.8125rem;
    font-weight: 500;
    color: #334155;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.sensor-type {
    font-size: 0.6875rem;
    color: #94a3b8;
    display: flex;
    align-items: center;
    gap: 4px;
}

.wireless-indicator {
    display: inline-flex;
    align-items: center;
    gap: 2px;
}

.wireless-indicator i {
    font-size: 0.625rem;
}

/* Sensor Temperature */
.sensor-temp {
    font-size: 1.25rem;
    font-weight: 700;
    font-family: var(--cc-font);
    letter-spacing: -0.01em;
    flex-shrink: 0;
    margin-left: 12px;
}

.sensor-temp.normal {
    color: #0f172a;
}

.sensor-temp.warning {
    color: #92400e;
}

.sensor-temp.critical {
    color: #991b1b;
}

/* Dashboard Grid Update - Full Width Cards */
.device-grid.grouped-view {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1rem;
}

@media (max-width: 992px) {
    .device-grid.grouped-view {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 768px) {
    .grouped-card-header {
        padding: 12px 14px;
    }
    
    .sensor-row {
        padding: 8px 14px;
    }
    
    .sensor-temp {
        font-size: 1.125rem;
    }
}