:root {
    --primary: #2ecc71;
    --primary-dark: #27ae60;
    --secondary: #3498db;
    --danger: #e74c3c;
    --warning: #f39c12;
    --info: #9b59b6;
    --dark: #1a1a2e;
    --darker: #16213e;
    --card-bg: #1e2a4a;
    --card-border: #2a3a5c;
    --text: #e0e6ed;
    --text-muted: #8b9bb4;
    --success-glow: rgba(46, 204, 113, 0.3);
    --danger-glow: rgba(231, 76, 60, 0.3);
}

* { margin: 0; padding: 0; box-sizing: border-box; }

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background: var(--dark);
    color: var(--text);
    min-height: 100vh;
    overflow-x: hidden;
}

/* Sidebar */
.sidebar {
    position: fixed;
    left: 0; top: 0;
    width: 260px;
    height: 100vh;
    background: var(--darker);
    border-right: 1px solid var(--card-border);
    z-index: 1000;
    overflow-y: auto;
}

.sidebar-header {
    padding: 25px 20px;
    border-bottom: 1px solid var(--card-border);
    text-align: center;
}

.logo {
    font-size: 24px;
    font-weight: 700;
    color: var(--primary);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
}

.logo i { font-size: 28px; }

.subtitle {
    font-size: 11px;
    color: var(--text-muted);
    margin-top: 5px;
    letter-spacing: 2px;
    text-transform: uppercase;
}

.nav-section { padding: 15px 0; }

.nav-section-title {
    padding: 0 25px;
    font-size: 10px;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    color: var(--text-muted);
    margin-bottom: 10px;
}

.nav-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 25px;
    color: var(--text-muted);
    text-decoration: none;
    transition: all 0.2s;
    cursor: pointer;
    border-left: 3px solid transparent;
}

.nav-item:hover, .nav-item.active {
    background: rgba(46, 204, 113, 0.08);
    color: var(--primary);
    border-left-color: var(--primary);
}

.nav-item i { width: 20px; text-align: center; font-size: 16px; }

.badge {
    margin-left: auto;
    background: var(--danger);
    color: white;
    font-size: 10px;
    padding: 2px 8px;
    border-radius: 10px;
}

/* Main Content */
.main-content {
    margin-left: 260px;
    padding: 25px;
    min-height: 100vh;
}

/* Top Bar */
.top-bar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 25px;
    padding-bottom: 20px;
    border-bottom: 1px solid var(--card-border);
}

.top-bar-left h1 { font-size: 24px; font-weight: 600; }

.breadcrumb {
    font-size: 13px;
    color: var(--text-muted);
    margin-top: 5px;
}

.top-bar-right {
    display: flex;
    align-items: center;
    gap: 15px;
}

.status-indicator {
    display: flex;
    align-items: center;
    gap: 8px;
    background: var(--card-bg);
    padding: 8px 16px;
    border-radius: 25px;
    border: 1px solid var(--card-border);
    font-size: 13px;
}

.status-dot {
    width: 8px; height: 8px;
    border-radius: 50%;
    background: var(--primary);
    box-shadow: 0 0 8px var(--primary);
    animation: pulse 2s infinite;
}

.status-dot.active { background: var(--primary); }
.status-dot.warning { background: var(--warning); }
.status-dot.danger { background: var(--danger); }

@keyframes pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.5; }
}

.last-update {
    font-size: 12px;
    color: var(--text-muted);
}

/* Buttons */
.btn-primary, .btn-export, .btn-irrigate, .btn-mix, .btn-temp {
    background: var(--primary);
    color: white;
    border: none;
    padding: 10px 20px;
    border-radius: 8px;
    cursor: pointer;
    font-size: 14px;
    transition: all 0.2s;
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.btn-primary:hover, .btn-export:hover, .btn-irrigate:hover, .btn-mix:hover {
    background: var(--primary-dark);
    transform: translateY(-2px);
}

.btn-export { background: var(--secondary); }
.btn-export:hover { background: #2980b9; }

.btn-irrigate { width: 100%; justify-content: center; margin-bottom: 10px; }
.btn-irrigate.active { background: var(--warning); }
.btn-irrigate.active:hover { background: #e67e22; }

.btn-mix { width: 100%; margin-top: 15px; background: var(--info); }
.btn-mix:hover { background: #8e44ad; }

.btn-temp {
    width: 36px; height: 36px;
    padding: 0;
    justify-content: center;
    background: var(--card-bg);
    border: 1px solid var(--card-border);
}

.btn-temp:hover { background: var(--card-border); }

/* Stats Grid */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
    margin-bottom: 25px;
}

.stat-card {
    background: var(--card-bg);
    border: 1px solid var(--card-border);
    border-radius: 16px;
    padding: 20px;
    position: relative;
    overflow: hidden;
    transition: transform 0.2s;
}

.stat-card:hover { transform: translateY(-3px); }

.stat-card::before {
    content: '';
    position: absolute;
    top: 0; left: 0; right: 0;
    height: 3px;
}

.stat-card.temp::before { background: var(--warning); }
.stat-card.humidity::before { background: var(--secondary); }
.stat-card.soil::before { background: var(--primary); }
.stat-card.light::before { background: #f1c40f; }
.stat-card.ph::before { background: var(--info); }
.stat-card.ec::before { background: #e67e22; }
.stat-card.co2::before { background: #95a5a6; }
.stat-card.pest::before { background: var(--danger); }
.stat-card.pressure::before { background: #1abc9c; }
.stat-card.water::before { background: var(--secondary); }
.stat-card.fertilizer::before { background: var(--info); }
.stat-card.pump::before { background: var(--primary); }
.stat-card.schedule::before { background: var(--warning); }
.stat-card.wind::before { background: #1abc9c; }

.stat-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 15px;
}

.stat-icon {
    width: 45px; height: 45px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
}

.stat-card.temp .stat-icon { background: rgba(243, 156, 18, 0.15); color: var(--warning); }
.stat-card.humidity .stat-icon { background: rgba(52, 152, 219, 0.15); color: var(--secondary); }
.stat-card.soil .stat-icon { background: rgba(46, 204, 113, 0.15); color: var(--primary); }
.stat-card.light .stat-icon { background: rgba(241, 196, 15, 0.15); color: #f1c40f; }
.stat-card.ph .stat-icon { background: rgba(155, 89, 182, 0.15); color: var(--info); }
.stat-card.ec .stat-icon { background: rgba(230, 126, 34, 0.15); color: #e67e22; }
.stat-card.co2 .stat-icon { background: rgba(149, 165, 166, 0.15); color: #95a5a6; }
.stat-card.pest .stat-icon { background: rgba(231, 76, 60, 0.15); color: var(--danger); }
.stat-card.pressure .stat-icon { background: rgba(26, 188, 156, 0.15); color: #1abc9c; }
.stat-card.water .stat-icon { background: rgba(52, 152, 219, 0.15); color: var(--secondary); }
.stat-card.fertilizer .stat-icon { background: rgba(155, 89, 182, 0.15); color: var(--info); }
.stat-card.pump .stat-icon { background: rgba(46, 204, 113, 0.15); color: var(--primary); }
.stat-card.schedule .stat-icon { background: rgba(243, 156, 18, 0.15); color: var(--warning); }
.stat-card.wind .stat-icon { background: rgba(26, 188, 156, 0.15); color: #1abc9c; }

.stat-trend {
    font-size: 11px;
    padding: 3px 8px;
    border-radius: 6px;
    font-weight: 500;
}

.trend-up { background: rgba(46, 204, 113, 0.15); color: var(--primary); }
.trend-down { background: rgba(231, 76, 60, 0.15); color: var(--danger); }

.stat-value {
    font-size: 32px;
    font-weight: 700;
    margin-bottom: 5px;
}

.stat-label {
    font-size: 13px;
    color: var(--text-muted);
}

.stat-detail {
    margin-top: 12px;
    padding-top: 12px;
    border-top: 1px solid var(--card-border);
}

.detail-row {
    display: flex;
    justify-content: space-between;
    font-size: 12px;
    margin: 4px 0;
    color: var(--text-muted);
}

.detail-row .value { color: var(--text); font-weight: 500; }
.detail-row .value.warn { color: var(--warning); }
.detail-row .value.danger { color: var(--danger); }

.stat-range {
    font-size: 11px;
    color: var(--text-muted);
    margin-top: 8px;
    padding-top: 8px;
    border-top: 1px solid var(--card-border);
}

/* Charts */
.charts-row {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 20px;
    margin-bottom: 25px;
}

.chart-card {
    background: var(--card-bg);
    border: 1px solid var(--card-border);
    border-radius: 16px;
    padding: 20px;
}

.chart-card.wide { grid-column: span 2; }

.chart-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
}

.chart-title {
    font-size: 16px;
    font-weight: 600;
}

.chart-title i { margin-right: 8px; }

.chart-filters { display: flex; gap: 8px; }

.chart-filter {
    padding: 5px 12px;
    border-radius: 6px;
    border: 1px solid var(--card-border);
    background: transparent;
    color: var(--text-muted);
    font-size: 12px;
    cursor: pointer;
    transition: all 0.2s;
}

.chart-filter.active, .chart-filter:hover {
    background: var(--primary);
    color: white;
    border-color: var(--primary);
}

/* Toggle Switch */
.toggle-switch {
    position: relative;
    width: 50px;
    height: 26px;
    display: inline-block;
}

.toggle-switch.large { width: 60px; height: 32px; }

.toggle-switch input {
    opacity: 0;
    width: 0; height: 0;
}

.toggle-slider {
    position: absolute;
    cursor: pointer;
    top: 0; left: 0; right: 0; bottom: 0;
    background: var(--card-border);
    border-radius: 26px;
    transition: 0.3s;
}

.toggle-slider::before {
    content: '';
    position: absolute;
    height: 20px; width: 20px;
    left: 3px; bottom: 3px;
    background: white;
    border-radius: 50%;
    transition: 0.3s;
}

.toggle-switch.large .toggle-slider::before {
    height: 24px; width: 24px;
    left: 4px; bottom: 4px;
}

.toggle-switch input:checked + .toggle-slider { background: var(--primary); }

.toggle-switch input:checked + .toggle-slider::before {
    transform: translateX(24px);
}

.toggle-switch.large input:checked + .toggle-slider::before {
    transform: translateX(28px);
}

/* Range Slider */
.range-control, .duration-control, .fan-speed, .co2-rate {
    width: 100%;
    margin-top: 10px;
}

.range-value, .duration-value {
    display: flex;
    justify-content: space-between;
    font-size: 12px;
    color: var(--text-muted);
    margin-bottom: 5px;
}

input[type="range"] {
    -webkit-appearance: none;
    width: 100%;
    height: 6px;
    border-radius: 3px;
    background: var(--card-border);
    outline: none;
}

input[type="range"]::-webkit-slider-thumb {
    -webkit-appearance: none;
    width: 18px; height: 18px;
    border-radius: 50%;
    background: var(--primary);
    cursor: pointer;
    box-shadow: 0 0 10px var(--success-glow);
}

/* Tables */
.table-card {
    background: var(--card-bg);
    border: 1px solid var(--card-border);
    border-radius: 16px;
    padding: 20px;
    margin-bottom: 25px;
}

.data-table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 15px;
}

.data-table th {
    text-align: left;
    padding: 12px 15px;
    font-size: 12px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: var(--text-muted);
    border-bottom: 1px solid var(--card-border);
}

.data-table td {
    padding: 12px 15px;
    font-size: 13px;
    border-bottom: 1px solid var(--card-border);
}

.data-table tr:hover td {
    background: rgba(46, 204, 113, 0.03);
}

.data-table td.warn { color: var(--warning); }
.data-table td.danger { color: var(--danger); }

.status-pill {
    display: inline-block;
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 11px;
    font-weight: 500;
}

.status-pill.success { background: rgba(46, 204, 113, 0.15); color: var(--primary); }
.status-pill.warning { background: rgba(243, 156, 18, 0.15); color: var(--warning); }
.status-pill.danger { background: rgba(231, 76, 60, 0.15); color: var(--danger); }
.status-pill.info { background: rgba(52, 152, 219, 0.15); color: var(--secondary); }

/* Control Panel */
.control-panel {
    background: var(--card-bg);
    border: 1px solid var(--card-border);
    border-radius: 16px;
    padding: 20px;
    margin-bottom: 25px;
}

.control-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
    margin-top: 20px;
}

.control-group {
    background: var(--darker);
    border-radius: 12px;
    padding: 20px;
}

.control-group-title {
    font-size: 14px;
    font-weight: 600;
    margin-bottom: 15px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.control-group-title i { color: var(--primary); }

.control-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 0;
    border-bottom: 1px solid var(--card-border);
}

.control-item:last-child { border-bottom: none; }

.control-label {
    font-size: 13px;
    color: var(--text-muted);
}

.mode-toggle {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 14px;
}

/* Irrigation Page */
.irrigation-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
    margin-top: 20px;
}

.irrigation-zone {
    background: var(--darker);
    border: 2px solid var(--card-border);
    border-radius: 12px;
    padding: 20px;
    transition: all 0.3s;
}

.irrigation-zone:hover {
    border-color: var(--primary);
    transform: translateY(-2px);
}

.irrigation-zone.warning {
    border-color: var(--warning);
    box-shadow: 0 0 15px rgba(243, 156, 18, 0.2);
}

.zone-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 15px;
}

.zone-header h3 { font-size: 16px; }

.zone-crop {
    font-size: 11px;
    padding: 3px 10px;
    background: rgba(46, 204, 113, 0.15);
    color: var(--primary);
    border-radius: 10px;
}

.alert-badge {
    font-size: 11px;
    padding: 3px 8px;
    background: rgba(231, 76, 60, 0.15);
    color: var(--danger);
    border-radius: 10px;
    margin-left: 8px;
}

.zone-metrics {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
    margin-bottom: 15px;
}

.metric {
    text-align: center;
    padding: 10px;
    background: var(--card-bg);
    border-radius: 8px;
}

.metric i {
    font-size: 18px;
    color: var(--primary);
    margin-bottom: 5px;
    display: block;
}

.metric-value {
    font-size: 18px;
    font-weight: 700;
    display: block;
}

.metric-value.warn { color: var(--warning); }
.metric-value.danger { color: var(--danger); }

.metric-label {
    font-size: 11px;
    color: var(--text-muted);
}

.zone-controls { margin-bottom: 15px; }

.duration-control {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 12px;
}

.duration-control label { color: var(--text-muted); }

.duration-slider { flex: 1; }

.zone-status-bar { margin-top: 10px; }

.progress-bar {
    width: 100%;
    height: 6px;
    background: var(--card-border);
    border-radius: 3px;
    overflow: hidden;
    margin-bottom: 5px;
}

.progress-fill {
    height: 100%;
    background: var(--primary);
    border-radius: 3px;
    transition: width 0.3s;
}

.progress-fill.active {
    background: var(--warning);
    animation: progress-pulse 1.5s infinite;
}

@keyframes progress-pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.6; }
}

.next-irrigation {
    font-size: 11px;
    color: var(--text-muted);
}

/* Schedule Timeline */
.schedule-timeline {
    position: relative;
    padding-left: 30px;
    margin-top: 20px;
}

.schedule-timeline::before {
    content: '';
    position: absolute;
    left: 8px;
    top: 0; bottom: 0;
    width: 2px;
    background: var(--card-border);
}

.schedule-item {
    position: relative;
    padding-bottom: 25px;
}

.schedule-item::before {
    content: '';
    position: absolute;
    left: -26px;
    top: 2px;
    width: 12px; height: 12px;
    border-radius: 50%;
    background: var(--primary);
    border: 2px solid var(--card-bg);
}

.schedule-item.completed::before { background: var(--primary); }
.schedule-item.pending::before { background: var(--warning); }
.schedule-item.active::before {
    background: var(--secondary);
    box-shadow: 0 0 10px var(--secondary);
    animation: pulse 2s infinite;
}

.schedule-time {
    font-size: 12px;
    color: var(--text-muted);
    margin-bottom: 3px;
}

.schedule-action {
    font-size: 14px;
    font-weight: 600;
}

.schedule-detail {
    font-size: 12px;
    color: var(--text-muted);
    margin-top: 3px;
}

/* Fertilizer */
.fertilizer-controls {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 30px;
    margin-top: 20px;
}

.fertilizer-tank h4, .fertilizer-mix h4 {
    font-size: 14px;
    margin-bottom: 15px;
    color: var(--text-muted);
}

.tank-visual {
    position: relative;
    width: 100%;
    height: 150px;
    background: var(--darker);
    border-radius: 12px;
    overflow: hidden;
    border: 2px solid var(--card-border);
}

.tank-level {
    position: absolute;
    bottom: 0;
    left: 0; right: 0;
    background: linear-gradient(to top, var(--secondary), rgba(52, 152, 219, 0.6));
    transition: height 0.3s;
}

.tank-info {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    text-align: center;
}

.tank-percent {
    font-size: 28px;
    font-weight: 700;
    display: block;
}

.tank-volume {
    font-size: 12px;
    color: var(--text-muted);
}

.tank-metrics {
    display: flex;
    justify-content: space-around;
    margin-top: 15px;
    padding: 10px;
    background: var(--darker);
    border-radius: 8px;
}

.tank-metrics div { text-align: center; }
.tank-metrics span { font-size: 12px; color: var(--text-muted); }
.tank-metrics strong { font-size: 16px; color: var(--text); }

.mix-item {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 12px;
    font-size: 13px;
}

.mix-item span:first-child { width: 120px; color: var(--text-muted); }
.mix-item span:last-child { width: 40px; text-align: right; }

.mix-bar {
    flex: 1;
    height: 8px;
    background: var(--card-border);
    border-radius: 4px;
    overflow: hidden;
}

.mix-fill {
    height: 100%;
    background: var(--primary);
    border-radius: 4px;
    transition: width 0.3s;
}

/* Ventilation Page */
.fan-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
    margin-top: 20px;
}

.fan-card {
    background: var(--darker);
    border: 1px solid var(--card-border);
    border-radius: 12px;
    padding: 20px;
    display: flex;
    align-items: center;
    gap: 15px;
    transition: all 0.3s;
}

.fan-card:hover {
    border-color: var(--primary);
}

.fan-card.warning {
    border-color: var(--warning);
    box-shadow: 0 0 15px rgba(243, 156, 18, 0.2);
}

.fan-visual {
    width: 60px; height: 60px;
    border-radius: 50%;
    background: var(--card-bg);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
    color: var(--text-muted);
}

.fan-card.active .fan-visual {
    background: rgba(46, 204, 113, 0.15);
    color: var(--primary);
}

.fan-card.warning .fan-visual {
    background: rgba(243, 156, 18, 0.15);
    color: var(--warning);
}

.fa-spin {
    animation: fa-spin 2s linear infinite;
}

@keyframes fa-spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

.fan-info { flex: 1; }

.fan-info h4 { font-size: 14px; margin-bottom: 8px; }

.fan-speed {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 8px;
}

.fan-speed span { font-size: 12px; color: var(--text-muted); width: 60px; }

.fan-slider { flex: 1; }

.fan-stats {
    display: flex;
    gap: 15px;
    font-size: 12px;
    color: var(--text-muted);
}

.fan-stats i { margin-right: 4px; }

/* Heating */
.heating-controls {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 15px;
    margin-bottom: 20px;
}

.heater-card {
    background: var(--darker);
    border: 1px solid var(--card-border);
    border-radius: 12px;
    padding: 15px;
    text-align: center;
}

.heater-card i {
    font-size: 28px;
    color: var(--text-muted);
    margin-bottom: 10px;
    display: block;
}

.heater-card h4 { font-size: 13px; margin-bottom: 8px; }

.heater-temp {
    font-size: 18px;
    font-weight: 700;
    color: var(--text-muted);
    margin-bottom: 10px;
}

.heater-card.active {
    border-color: var(--danger);
    box-shadow: 0 0 15px rgba(231, 76, 60, 0.2);
}

.heater-card.active i { color: var(--danger); }
.heater-card.active .heater-temp { color: var(--danger); }

.target-temp {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 15px;
    background: var(--darker);
    border-radius: 12px;
}

.target-temp label { font-size: 14px; color: var(--text-muted); }

.temp-input {
    display: flex;
    align-items: center;
    gap: 15px;
}

.temp-display {
    font-size: 24px;
    font-weight: 700;
    min-width: 60px;
    text-align: center;
}

/* CO2 */
.co2-controls {
    display: grid;
    grid-template-columns: 1fr 1fr 1fr;
    gap: 30px;
    align-items: center;
    padding: 20px;
}

.co2-status { text-align: center; }

.co2-value {
    font-size: 48px;
    font-weight: 700;
    color: var(--text);
}

.co2-unit {
    font-size: 18px;
    color: var(--text-muted);
}

.co2-target {
    font-size: 13px;
    color: var(--text-muted);
    margin-top: 5px;
}

.co2-injection {
    display: flex;
    align-items: center;
    gap: 15px;
    justify-content: center;
}

.co2-rate {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.co2-rate label { font-size: 13px; color: var(--text-muted); }

.co2-slider { width: 100%; }

/* Responsive */
@media (max-width: 1400px) {
    .stats-grid { grid-template-columns: repeat(4, 1fr); }
    .control-grid { grid-template-columns: repeat(2, 1fr); }
    .irrigation-grid { grid-template-columns: repeat(2, 1fr); }
    .fan-grid { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 1200px) {
    .stats-grid { grid-template-columns: repeat(2, 1fr); }
    .charts-row { grid-template-columns: 1fr; }
    .chart-card.wide { grid-column: span 1; }
    .control-grid { grid-template-columns: 1fr; }
    .irrigation-grid { grid-template-columns: 1fr; }
    .fan-grid { grid-template-columns: 1fr; }
    .fertilizer-controls { grid-template-columns: 1fr; }
    .heating-controls { grid-template-columns: repeat(2, 1fr); }
    .co2-controls { grid-template-columns: 1fr; }
}

@media (max-width: 768px) {
    .sidebar { transform: translateX(-100%); }
    .main-content { margin-left: 0; }
    .stats-grid { grid-template-columns: 1fr; }
    .heating-controls { grid-template-columns: 1fr; }
}

/* ============================================
   EK STILLER - Settings, Nodes, Drainage, vb.
   ============================================ */

/* Settings Page */
.settings-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
}

.settings-card {
    background: var(--card-bg);
    border: 1px solid var(--card-border);
    border-radius: 16px;
    overflow: hidden;
}

.settings-header {
    padding: 20px;
    background: var(--darker);
    border-bottom: 1px solid var(--card-border);
    display: flex;
    align-items: center;
    gap: 12px;
}

.settings-header i {
    font-size: 20px;
    color: var(--primary);
}

.settings-header h3 {
    font-size: 16px;
    font-weight: 600;
}

.settings-body {
    padding: 20px;
}

.form-group {
    margin-bottom: 15px;
}

.form-group label {
    display: block;
    font-size: 13px;
    color: var(--text-muted);
    margin-bottom: 6px;
}

.form-input {
    width: 100%;
    padding: 10px 14px;
    background: var(--darker);
    border: 1px solid var(--card-border);
    border-radius: 8px;
    color: var(--text);
    font-size: 14px;
    outline: none;
    transition: border-color 0.2s;
}

.form-input:focus {
    border-color: var(--primary);
}

.form-input.small {
    width: 80px;
    text-align: center;
}

.form-range {
    width: 100%;
    margin: 10px 0;
}

.range-labels {
    display: flex;
    justify-content: space-between;
    font-size: 11px;
    color: var(--text-muted);
}

.checkbox-group {
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
}

.checkbox-group label {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 13px;
    color: var(--text);
    cursor: pointer;
}

.checkbox-group input[type="checkbox"] {
    width: 16px;
    height: 16px;
    accent-color: var(--primary);
}

/* Threshold Items */
.threshold-item {
    margin-bottom: 15px;
    padding-bottom: 15px;
    border-bottom: 1px solid var(--card-border);
}

.threshold-item:last-child {
    border-bottom: none;
    margin-bottom: 0;
    padding-bottom: 0;
}

.threshold-label {
    display: flex;
    justify-content: space-between;
    margin-bottom: 8px;
    font-size: 13px;
}

.threshold-range {
    color: var(--primary);
    font-weight: 500;
}

.threshold-inputs {
    display: flex;
    align-items: center;
    gap: 10px;
}

.threshold-inputs span {
    color: var(--text-muted);
}

/* Schedule Settings */
.schedule-setting {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.schedule-row {
    display: flex;
    align-items: center;
    gap: 15px;
    padding: 10px;
    background: var(--darker);
    border-radius: 8px;
}

.schedule-info {
    flex: 1;
}

.schedule-info strong {
    display: block;
    font-size: 14px;
}

.schedule-info span {
    font-size: 12px;
    color: var(--text-muted);
}

/* Notification Items */
.notification-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 0;
    border-bottom: 1px solid var(--card-border);
}

.notification-item:last-child {
    border-bottom: none;
}

.notif-info strong {
    display: block;
    font-size: 14px;
}

.notif-info span {
    font-size: 12px;
    color: var(--text-muted);
}

/* Backup */
.backup-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 15px;
}

.backup-info strong {
    display: block;
    font-size: 14px;
}

.backup-info span {
    font-size: 12px;
    color: var(--text-muted);
}

.backup-actions {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.system-info {
    background: var(--darker);
    border-radius: 8px;
    padding: 15px;
}

.info-row {
    display: flex;
    justify-content: space-between;
    padding: 6px 0;
    font-size: 13px;
    border-bottom: 1px solid var(--card-border);
}

.info-row:last-child {
    border-bottom: none;
}

.info-row span {
    color: var(--text-muted);
}

/* Node Cards */
.node-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
}

.node-card {
    background: var(--card-bg);
    border: 1px solid var(--card-border);
    border-radius: 16px;
    padding: 20px;
    text-align: center;
    transition: all 0.3s;
}

.node-card:hover {
    transform: translateY(-3px);
    border-color: var(--primary);
}

.node-card.warning {
    border-color: var(--warning);
}

.node-card.offline {
    border-color: var(--danger);
    opacity: 0.7;
}

.node-icon {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    background: var(--darker);
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 12px;
    font-size: 24px;
    color: var(--primary);
}

.node-name {
    font-size: 16px;
    font-weight: 700;
    margin-bottom: 5px;
}

.node-ip {
    font-size: 12px;
    color: var(--text-muted);
    font-family: monospace;
    margin-bottom: 10px;
}

.node-meta {
    display: flex;
    justify-content: center;
    gap: 15px;
    font-size: 11px;
    color: var(--text-muted);
    margin-bottom: 12px;
}

.node-meta i {
    margin-right: 4px;
}

.node-sensors {
    display: flex;
    justify-content: center;
    gap: 8px;
    margin-bottom: 12px;
}

.sensor-tag {
    width: 32px;
    height: 32px;
    border-radius: 8px;
    background: var(--darker);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    color: var(--text-muted);
    cursor: help;
    transition: all 0.2s;
}

.sensor-tag:hover {
    background: var(--primary);
    color: white;
}

.node-uptime {
    font-size: 11px;
    color: var(--text-muted);
    margin-bottom: 10px;
}

.node-signal {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    margin-bottom: 12px;
}

.signal-label {
    font-size: 11px;
    color: var(--text-muted);
}

.signal-bars {
    display: flex;
    gap: 2px;
    align-items: flex-end;
}

.signal-bar {
    width: 4px;
    background: var(--primary);
    border-radius: 1px;
}

.signal-bar:nth-child(1) { height: 4px; }
.signal-bar:nth-child(2) { height: 8px; }
.signal-bar:nth-child(3) { height: 12px; }
.signal-bar:nth-child(4) { height: 16px; }

.signal-bar.weak { background: var(--warning); }
.signal-bar.off { background: var(--card-border); }

.node-actions {
    display: flex;
    justify-content: center;
    gap: 8px;
}

/* Drainage Tanks */
.drainage-tanks {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
    margin-top: 20px;
}

.tank-card {
    background: var(--darker);
    border-radius: 12px;
    padding: 20px;
}

.tank-card h4 {
    font-size: 14px;
    margin-bottom: 15px;
    color: var(--text-muted);
}

.tank-metrics {
    display: flex;
    justify-content: space-around;
    margin-top: 15px;
    padding: 10px;
    background: var(--card-bg);
    border-radius: 8px;
}

.tank-metrics div {
    text-align: center;
}

.tank-metrics span {
    font-size: 11px;
    color: var(--text-muted);
}

.tank-metrics strong {
    font-size: 14px;
    color: var(--text);
}

.tank-metrics strong.warn {
    color: var(--warning);
}

/* Camera Grid */
.camera-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 15px;
    margin-top: 20px;
}

.camera-feed {
    background: var(--darker);
    border-radius: 12px;
    overflow: hidden;
    position: relative;
    aspect-ratio: 16/9;
}

.camera-feed img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.camera-overlay {
    position: absolute;
    top: 10px;
    left: 10px;
    background: rgba(0,0,0,0.7);
    padding: 5px 10px;
    border-radius: 6px;
    font-size: 11px;
    display: flex;
    align-items: center;
    gap: 5px;
}

.live-dot {
    width: 6px;
    height: 6px;
    background: var(--danger);
    border-radius: 50%;
    animation: blink 1s infinite;
}

@keyframes blink {
    0%, 100% { opacity: 1; }
    50% { opacity: 0; }
}

.pest-count {
    position: absolute;
    top: 10px;
    right: 10px;
    background: var(--danger);
    color: white;
    padding: 5px 12px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 600;
}

.camera-info {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: linear-gradient(transparent, rgba(0,0,0,0.8));
    padding: 15px;
    font-size: 12px;
}

/* Disease Cards */
.disease-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-top: 20px;
}

.disease-card {
    display: flex;
    gap: 15px;
    background: var(--darker);
    border-radius: 12px;
    padding: 15px;
    border-left: 3px solid var(--danger);
    transition: all 0.2s;
}

.disease-card:hover {
    background: var(--card-bg);
}

.disease-img {
    width: 80px;
    height: 80px;
    border-radius: 8px;
    object-fit: cover;
}

.disease-info {
    flex: 1;
}

.disease-info h4 {
    font-size: 14px;
    margin-bottom: 5px;
}

.disease-info p {
    font-size: 12px;
    color: var(--text-muted);
    margin-bottom: 8px;
}

.disease-confidence {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 12px;
}

.confidence-bar {
    width: 100px;
    height: 6px;
    background: var(--card-border);
    border-radius: 3px;
    overflow: hidden;
}

.confidence-fill {
    height: 100%;
    background: var(--danger);
    border-radius: 3px;
}

.disease-date {
    font-size: 12px;
    color: var(--text-muted);
    text-align: right;
}

/* Disease Alert */
.disease-alert {
    display: grid;
    grid-template-columns: auto 1fr auto;
    gap: 20px;
    padding: 20px;
}

.disease-image img {
    width: 200px;
    height: 200px;
    border-radius: 12px;
    object-fit: cover;
}

.disease-details h3 {
    font-size: 18px;
    margin-bottom: 10px;
    color: var(--danger);
}

.disease-meta {
    display: flex;
    gap: 20px;
    font-size: 13px;
    color: var(--text-muted);
    margin-bottom: 10px;
}

.disease-meta i {
    margin-right: 5px;
}

.disease-actions {
    display: flex;
    gap: 10px;
    margin-top: 15px;
}

.disease-timeline h4 {
    font-size: 14px;
    margin-bottom: 15px;
    color: var(--text-muted);
}

.mini-timeline {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.mini-item {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 12px;
}

.mini-dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: var(--card-border);
    border: 2px solid var(--card-bg);
}

.mini-item.active .mini-dot {
    background: var(--danger);
    box-shadow: 0 0 10px var(--danger-glow);
}

.mini-time {
    width: 40px;
    color: var(--text-muted);
}

.mini-text {
    color: var(--text);
}

/* AI Status */
.ai-status {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 20px;
    padding: 20px;
}

.ai-metric {
    text-align: center;
}

.ai-label {
    display: block;
    font-size: 11px;
    color: var(--text-muted);
    margin-bottom: 5px;
}

.ai-value {
    font-size: 18px;
    font-weight: 700;
}

/* Responsive Updates */
@media (max-width: 1400px) {
    .settings-grid { grid-template-columns: 1fr; }
    .node-grid { grid-template-columns: repeat(2, 1fr); }
    .drainage-tanks { grid-template-columns: repeat(2, 1fr); }
    .camera-grid { grid-template-columns: repeat(2, 1fr); }
    .disease-alert { grid-template-columns: 1fr; }
    .ai-status { grid-template-columns: repeat(3, 1fr); }
}

@media (max-width: 768px) {
    .node-grid { grid-template-columns: 1fr; }
    .drainage-tanks { grid-template-columns: 1fr; }
    .camera-grid { grid-template-columns: 1fr; }
    .ai-status { grid-template-columns: repeat(2, 1fr); }
}

/* ============================================
   METEOROLOJİ İSTASYONU STILLERİ
   ============================================ */

/* AI Tahmin Banner */
.ai-prediction-banner {
    background: linear-gradient(135deg, rgba(155, 89, 182, 0.15), rgba(52, 152, 219, 0.15));
    border: 1px solid var(--info);
    border-radius: 16px;
    padding: 20px 25px;
    display: flex;
    align-items: center;
    gap: 20px;
    margin-bottom: 25px;
    position: relative;
    overflow: hidden;
}

.ai-prediction-banner::before {
    content: '';
    position: absolute;
    top: 0; left: 0; right: 0;
    height: 3px;
    background: linear-gradient(90deg, var(--info), var(--secondary));
}

.ai-icon {
    position: relative;
    width: 60px; height: 60px;
    border-radius: 50%;
    background: rgba(155, 89, 182, 0.2);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 28px;
    color: var(--info);
    flex-shrink: 0;
}

.ai-pulse {
    position: absolute;
    width: 100%; height: 100%;
    border-radius: 50%;
    border: 2px solid var(--info);
    animation: ai-pulse-ring 2s infinite;
}

@keyframes ai-pulse-ring {
    0% { transform: scale(1); opacity: 1; }
    100% { transform: scale(1.5); opacity: 0; }
}

.ai-content { flex: 1; }

.ai-content h3 {
    font-size: 16px;
    margin-bottom: 5px;
    color: var(--info);
}

.ai-content p {
    font-size: 13px;
    color: var(--text-muted);
    line-height: 1.5;
}

.ai-confidence {
    color: var(--primary);
    font-weight: 600;
}

.ai-actions { flex-shrink: 0; }

/* Weather Hero */
.weather-hero {
    background: linear-gradient(135deg, var(--card-bg), var(--darker));
    border: 1px solid var(--card-border);
    border-radius: 20px;
    padding: 30px;
    margin-bottom: 25px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 30px;
}

.weather-main {
    display: flex;
    align-items: center;
    gap: 20px;
}

.weather-icon-large {
    width: 100px; height: 100px;
    border-radius: 50%;
    background: linear-gradient(135deg, rgba(52, 152, 219, 0.2), rgba(155, 89, 182, 0.2));
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 48px;
    color: var(--secondary);
    animation: float 3s ease-in-out infinite;
}

@keyframes float {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-10px); }
}

.weather-temp {
    display: flex;
    align-items: flex-start;
}

.temp-big {
    font-size: 72px;
    font-weight: 700;
    line-height: 1;
}

.temp-unit {
    font-size: 24px;
    font-weight: 300;
    margin-top: 8px;
}

.weather-desc h2 {
    font-size: 20px;
    font-weight: 600;
    margin-bottom: 5px;
}

.weather-desc p {
    font-size: 14px;
    color: var(--text-muted);
}

.weather-highlow {
    display: flex;
    gap: 25px;
}

.highlow-item {
    text-align: center;
    padding: 15px 20px;
    background: var(--darker);
    border-radius: 12px;
    min-width: 80px;
}

.highlow-item i {
    font-size: 20px;
    margin-bottom: 8px;
    display: block;
}

.highlow-label {
    display: block;
    font-size: 11px;
    color: var(--text-muted);
    margin-bottom: 4px;
}

.highlow-value {
    display: block;
    font-size: 18px;
    font-weight: 700;
}

/* AI Model Info */
.ai-model-info {
    display: flex;
    gap: 20px;
    font-size: 12px;
    color: var(--text-muted);
}

.ai-model-info span {
    padding: 4px 12px;
    background: var(--darker);
    border-radius: 20px;
}

/* Forecast Grid */
.forecast-grid {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 12px;
    margin-top: 20px;
}

.forecast-day {
    background: var(--darker);
    border: 1px solid var(--card-border);
    border-radius: 12px;
    padding: 15px 10px;
    text-align: center;
    transition: all 0.3s;
}

.forecast-day:hover {
    transform: translateY(-5px);
    border-color: var(--primary);
}

.forecast-day.today {
    border-color: var(--info);
    background: rgba(155, 89, 182, 0.1);
}

.forecast-date {
    font-size: 12px;
    color: var(--text-muted);
    margin-bottom: 10px;
}

.forecast-date small {
    font-size: 11px;
}

.forecast-icon {
    font-size: 28px;
    margin: 10px 0;
    color: var(--secondary);
}

.forecast-day.today .forecast-icon {
    color: var(--info);
}

.forecast-temps {
    display: flex;
    justify-content: center;
    gap: 8px;
    margin-bottom: 8px;
}

.forecast-temps .max {
    font-size: 16px;
    font-weight: 700;
}

.forecast-temps .min {
    font-size: 14px;
    color: var(--text-muted);
}

.forecast-rain {
    font-size: 11px;
    color: var(--secondary);
    margin-bottom: 10px;
}

.forecast-ai {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 10px;
    color: var(--text-muted);
}

.ai-bar {
    flex: 1;
    height: 4px;
    background: var(--card-border);
    border-radius: 2px;
    overflow: hidden;
}

.ai-fill {
    height: 100%;
    background: linear-gradient(90deg, var(--primary), var(--info));
    border-radius: 2px;
}

/* AI Recommendations */
.ai-recommendations {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.rec-item {
    display: flex;
    align-items: flex-start;
    gap: 15px;
    padding: 15px;
    background: var(--darker);
    border-radius: 12px;
    border-left: 3px solid var(--primary);
    transition: all 0.2s;
}

.rec-item:hover {
    background: var(--card-bg);
}

.rec-item.high { border-left-color: var(--danger); }
.rec-item.medium { border-left-color: var(--warning); }
.rec-item.low { border-left-color: var(--primary); }

.rec-icon {
    width: 40px; height: 40px;
    border-radius: 10px;
    background: var(--card-bg);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
    color: var(--primary);
    flex-shrink: 0;
}

.rec-item.high .rec-icon { color: var(--danger); }
.rec-item.medium .rec-icon { color: var(--warning); }

.rec-content { flex: 1; }

.rec-content h4 {
    font-size: 14px;
    margin-bottom: 5px;
}

.rec-content p {
    font-size: 12px;
    color: var(--text-muted);
    line-height: 1.5;
    margin-bottom: 5px;
}

.rec-time {
    font-size: 11px;
    color: var(--info);
}

.rec-priority {
    padding: 4px 10px;
    border-radius: 20px;
    font-size: 10px;
    font-weight: 600;
    text-transform: uppercase;
    flex-shrink: 0;
}

.rec-priority.high {
    background: rgba(231, 76, 60, 0.15);
    color: var(--danger);
}

.rec-priority.medium {
    background: rgba(243, 156, 18, 0.15);
    color: var(--warning);
}

.rec-priority.low {
    background: rgba(46, 204, 113, 0.15);
    color: var(--primary);
}

/* Wind Analysis */
.wind-analysis {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 30px;
    padding: 20px;
}

.wind-rose {
    display: flex;
    align-items: center;
    justify-content: center;
}

.wind-stats h4 {
    font-size: 14px;
    margin-bottom: 15px;
    color: var(--text-muted);
}

.wind-stat-row {
    display: flex;
    justify-content: space-between;
    padding: 10px 0;
    border-bottom: 1px solid var(--card-border);
    font-size: 13px;
}

.wind-stat-row:last-child {
    border-bottom: none;
}

.wind-stat-row span {
    color: var(--text-muted);
}

.wind-stat-row strong {
    color: var(--text);
}

/* Responsive Weather */
@media (max-width: 1400px) {
    .forecast-grid { grid-template-columns: repeat(4, 1fr); }
    .weather-hero { flex-direction: column; text-align: center; }
    .weather-main { flex-direction: column; }
    .weather-highlow { width: 100%; justify-content: center; }
    .wind-analysis { grid-template-columns: 1fr; }
}

@media (max-width: 768px) {
    .forecast-grid { grid-template-columns: repeat(2, 1fr); }
    .ai-prediction-banner { flex-direction: column; text-align: center; }
    .temp-big { font-size: 48px; }
    .weather-icon-large { width: 70px; height: 70px; font-size: 32px; }
    .weather-highlow { flex-wrap: wrap; }
}
/* ============================================
   BURGER MENU & MOBİL SİDEBAR
   ============================================ */

/* Sidebar footer */
.sidebar-footer {
    padding: 12px 16px;
    border-top: 1px solid var(--card-border);
    margin-top: auto;
}

/* Sidebar kapatma butonu (mobil) */
.sidebar-close {
    display: none;
    background: none;
    border: none;
    color: var(--text-muted);
    font-size: 18px;
    cursor: pointer;
    padding: 4px;
    margin-left: auto;
}

/* Burger butonu */
.burger-btn {
    display: none;
    position: fixed;
    top: 14px;
    left: 14px;
    z-index: 1100;
    width: 40px;
    height: 40px;
    background: var(--card-bg);
    border: 1px solid var(--card-border);
    border-radius: 10px;
    cursor: pointer;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 5px;
    padding: 8px;
    box-shadow: 0 2px 12px rgba(0,0,0,.3);
    transition: background .2s;
}
.burger-btn span {
    display: block;
    width: 20px;
    height: 2px;
    background: var(--text-primary);
    border-radius: 2px;
    transition: all .3s ease;
    transform-origin: center;
}
.burger-btn.open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.burger-btn.open span:nth-child(2) { opacity: 0; }
.burger-btn.open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* Karartma overlay */
.sidebar-overlay {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,.5);
    z-index: 999;
    backdrop-filter: blur(2px);
}
.sidebar-overlay.open { display: block; }

/* Sidebar nav scroll */
.sidebar-nav {
    flex: 1;
    overflow-y: auto;
    overflow-x: hidden;
}
.sidebar-nav::-webkit-scrollbar { width: 4px; }
.sidebar-nav::-webkit-scrollbar-track { background: transparent; }
.sidebar-nav::-webkit-scrollbar-thumb { background: var(--card-border); border-radius: 2px; }

/* ============================================
   MOBİL (max 768px)
   ============================================ */
@media (max-width: 768px) {
    /* Burger göster */
    .burger-btn { display: flex; }

    /* Sidebar gizle — slide animasyonu */
    .sidebar {
        transform: translateX(-100%);
        transition: transform .3s cubic-bezier(.4,0,.2,1);
        z-index: 1000;
        box-shadow: none;
    }
    .sidebar.open {
        transform: translateX(0);
        box-shadow: 4px 0 24px rgba(0,0,0,.4);
    }
    .sidebar-close { display: block; }
    .sidebar-header {
        display: flex;
        align-items: center;
        flex-direction: row;
        flex-wrap: wrap;
    }
    .sidebar-header .logo { margin-right: auto; }
    .sidebar-header .subtitle { display: none; }

    /* İçerik sidebar'sız başlasın */
    .main-content {
        margin-left: 0 !important;
        padding: 16px;
        padding-top: 64px; /* burger buton yüksekliği kadar */
    }

    /* Top bar */
    .top-bar {
        flex-direction: column;
        align-items: flex-start;
        gap: 10px;
        padding-top: 0;
    }
    .top-bar h1 { font-size: 18px; }
    .top-bar-right { flex-wrap: wrap; gap: 8px; }

    /* Grid 1 sütun */
    .stats-grid    { grid-template-columns: 1fr 1fr; gap: 10px; }
    .charts-row    { flex-direction: column; }
    .two-col       { grid-template-columns: 1fr !important; }
    .settings-grid { grid-template-columns: 1fr !important; }
    .fan-grid      { grid-template-columns: 1fr !important; }
    .zone-sensor-grid { grid-template-columns: 1fr 1fr; gap: 10px; }
    .screen-grid   { grid-template-columns: 1fr !important; }
    .recipe-grid   { grid-template-columns: 1fr !important; }
    .report-type-grid { grid-template-columns: 1fr 1fr; }

    /* Tablo scroll */
    .data-table { font-size: 11px; }
    table { display: block; overflow-x: auto; }
    .period-table { font-size: 10px; }

    /* Kartlar */
    .control-panel { padding: 14px; }
    .chart-card    { padding: 14px; }
    .stat-card     { padding: 14px; }
    .stat-value    { font-size: 28px; }

    /* Butonlar */
    .btn-primary, .btn-export { padding: 7px 12px; font-size: 12px; }

    /* Modal tam ekran */
    .modal-overlay { align-items: flex-end; }
    .modal-box     { max-width: 100% !important; width: 100% !important; border-radius: 16px 16px 0 0 !important; max-height: 90vh !important; }
}

/* Küçük telefon */
@media (max-width: 420px) {
    .stats-grid       { grid-template-columns: 1fr; }
    .zone-sensor-grid { grid-template-columns: 1fr; }
    .report-type-grid { grid-template-columns: 1fr; }
    .stat-value       { font-size: 24px; }
    .main-content     { padding: 12px; padding-top: 60px; }
}
