﻿:root {
    --bg: #f3f6f8;
    --panel: #ffffff;
    --sidebar: #0a1016;
    --sidebar-2: #111a23;
    --text: #101828;
    --muted: #667085;
    --line: #e4e9ee;
    --green: #16a163;
    --green-soft: #eaf8f1;
    --orange: #d99016;
    --orange-soft: #fff5df;
    --red: #d64b43;
    --red-soft: #fff0ef;
    --radius: 16px;
}

* {
    box-sizing: border-box;
}

html,
body {
    margin: 0;
    min-height: 100%;
    font-family: "Segoe UI", Arial, sans-serif;
    color: var(--text);
    background: var(--bg);
}

body {
    min-height: 100vh;
}

a {
    color: inherit;
    text-decoration: none;
}

/* ANA YAPI */

.shell {
    min-height: 100vh;
    display: grid;
    grid-template-columns: 260px minmax(0, 1fr);
}

/* SOL MENÃœ */

.sidebar {
    position: sticky;
    top: 0;
    height: 100vh;
    padding: 25px 18px 18px;
    background:
        radial-gradient(circle at 10% 0%, #172532 0, transparent 32%),
        linear-gradient(180deg, #0a1016 0%, #080d12 100%);
    color: white;
    display: flex;
    flex-direction: column;
    border-right: 1px solid #17212b;
}

.brand {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 0 7px 25px;
    border-bottom: 1px solid #1c2731;
}

.brandmark {
    width: 43px;
    height: 43px;
    display: grid;
    place-items: center;
    border-radius: 12px;
    background: white;
    color: #0a1016;
    font-size: 23px;
    font-weight: 900;
    box-shadow: 0 7px 25px rgba(0,0,0,.25);
}

.brand b {
    display: block;
    font-size: 14px;
    letter-spacing: .09em;
}

.brand span {
    display: block;
    margin-top: 4px;
    color: #8493a1;
    font-size: 10px;
}

.sidebar nav {
    display: flex;
    flex-direction: column;
    gap: 5px;
    margin-top: 25px;
}

.sidebar nav a {
    position: relative;
    padding: 12px 13px;
    border-radius: 10px;
    color: #8f9ca9;
    font-size: 12px;
    font-weight: 600;
    transition: .2s ease;
}

.sidebar nav a:hover {
    color: white;
    background: #131d26;
    transform: translateX(2px);
}

.sidebar nav a:first-child {
    color: white;
    background: #18232d;
}

.sidebar nav a:first-child::before {
    content: "";
    position: absolute;
    left: 0;
    top: 10px;
    bottom: 10px;
    width: 3px;
    border-radius: 4px;
    background: var(--green);
}

.sidebar-bottom {
    margin-top: auto;
    padding: 17px 6px 3px;
    border-top: 1px solid #1c2731;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.sidebar-bottom small {
    display: block;
    color: #6f7e8b;
    font-size: 9px;
    margin-bottom: 3px;
}

.sidebar-bottom b {
    font-size: 11px;
}

.sidebar-bottom button {
    padding: 8px 11px;
    border: 1px solid #273541;
    border-radius: 8px;
    color: #aab4be;
    background: #111922;
    cursor: pointer;
}

/* SAÄ TARAF */

.content {
    min-width: 0;
}

.topbar {
    height: 82px;
    padding: 0 30px;
    background: rgba(255,255,255,.94);
    border-bottom: 1px solid var(--line);
    display: flex;
    align-items: center;
    justify-content: space-between;
    position: sticky;
    top: 0;
    z-index: 20;
    backdrop-filter: blur(12px);
}

.topbar small {
    color: #98a2b3;
    font-size: 9px;
    font-weight: 800;
    letter-spacing: .13em;
}

.topbar h1 {
    margin: 4px 0 0;
    font-size: 18px;
    font-weight: 750;
}

.live {
    padding: 7px 11px;
    border-radius: 30px;
    background: var(--green-soft);
    color: var(--green);
    font-size: 9px;
    font-weight: 900;
    letter-spacing: .05em;
}

.page {
    width: 100%;
    max-width: 1600px;
    margin: auto;
    padding: 30px;
}

/* BAÅLIK */

.hero {
    position: relative;
    overflow: hidden;
    min-height: 150px;
    display: flex;
    align-items: center;
    padding: 28px 30px;
    margin-bottom: 15px;
    border-radius: 20px;
    color: white;
    background:
        radial-gradient(circle at 85% 20%, rgba(32,179,111,.23), transparent 28%),
        linear-gradient(120deg, #0b1218 0%, #111c25 65%, #14262a 100%);
    box-shadow: 0 10px 30px rgba(16,24,40,.08);
}

.hero::after {
    content: "";
    position: absolute;
    width: 310px;
    height: 310px;
    right: -100px;
    top: -180px;
    border: 1px solid rgba(255,255,255,.08);
    border-radius: 50%;
}

.hero .kicker {
    color: #62d49b;
}

.hero h2 {
    margin: 7px 0 7px;
    font-size: 29px;
    letter-spacing: -.025em;
}

.hero p {
    max-width: 720px;
    margin: 0;
    color: #9facb8;
    line-height: 1.6;
    font-size: 12px;
}

.kicker {
    color: #8b96a3;
    font-size: 9px;
    font-weight: 900;
    letter-spacing: .14em;
}

/* KPI KARTLARI */

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

.stat {
    position: relative;
    overflow: hidden;
    padding: 19px;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    background: var(--panel);
    box-shadow: 0 3px 14px rgba(16,24,40,.035);
}

.stat::after {
    content: "";
    position: absolute;
    right: 0;
    top: 0;
    width: 4px;
    height: 100%;
    background: #e8ecef;
}

.stat:nth-child(2)::after {
    background: var(--green);
}

.stat small,
.metric small {
    display: block;
    color: #8b96a3;
    font-size: 9px;
    font-weight: 900;
    letter-spacing: .06em;
}

.stat strong {
    display: block;
    margin: 8px 0 4px;
    font-size: 24px;
    font-weight: 750;
    letter-spacing: -.02em;
}

.stat span {
    color: #8b96a3;
    font-size: 10px;
}

/* PANELLER */

.grid2 {
    display: grid;
    grid-template-columns: minmax(0,1.7fr) minmax(300px,.7fr);
    gap: 12px;
}

.panel {
    overflow: hidden;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    background: var(--panel);
    box-shadow: 0 3px 14px rgba(16,24,40,.035);
}

.panel-head {
    min-height: 72px;
    padding: 17px 19px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.panel-head h3 {
    margin: 5px 0 0;
    font-size: 15px;
}

.panel-head a {
    padding: 7px 10px;
    border: 1px solid var(--line);
    border-radius: 8px;
    color: #475467;
    font-size: 10px;
    font-weight: 700;
    transition: .15s;
}

.panel-head a:hover {
    background: #f7f9fa;
}

/* TABLO */

table {
    width: 100%;
    border-collapse: collapse;
}

thead {
    background: #f8fafb;
}

th {
    padding: 10px 13px;
    color: #8994a1;
    border-top: 1px solid #edf0f2;
    border-bottom: 1px solid #edf0f2;
    text-align: left;
    font-size: 8px;
    font-weight: 900;
    letter-spacing: .07em;
}

td {
    padding: 14px 13px;
    border-bottom: 1px solid #eef1f3;
    color: #475467;
    font-size: 10px;
}

tbody tr {
    transition: .15s;
}

tbody tr:hover {
    background: #fafcfd;
}

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

.pump-link {
    display: flex;
    flex-direction: column;
}

.pump-link b {
    color: #1d2939;
    font-size: 11px;
}

.pump-link span {
    margin-top: 3px;
    color: #98a2b3;
    font-size: 8px;
}

/* DURUMLAR */

.status {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 5px 8px;
    border-radius: 30px;
    background: #f1f3f5;
    color: #667085;
    font-size: 8px;
    font-weight: 900;
}

.status::before {
    content: "";
    width: 5px;
    height: 5px;
    border-radius: 50%;
    background: currentColor;
}

.status.running {
    background: var(--green-soft);
    color: var(--green);
}

.status.warning {
    background: var(--orange-soft);
    color: var(--orange);
}

.status.offline {
    background: var(--red-soft);
    color: var(--red);
}

.status.big {
    padding: 8px 12px;
    font-size: 10px;
}

/* SÄ°STEM SAÄLIÄI */

.health {
    min-height: 47px;
    padding: 13px 18px;
    border-top: 1px solid #eef1f3;
    display: flex;
    align-items: center;
    justify-content: space-between;
    font-size: 10px;
}

.health span {
    color: #667085;
}

.health b {
    font-size: 9px;
}

.green {
    color: var(--green);
}

.amber {
    color: var(--orange);
}

/* METRÄ°KLER */

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

.metric {
    min-height: 105px;
    padding: 20px;
    border-right: 1px solid #edf0f2;
}

.metric:last-child {
    border-right: none;
}

.metric strong {
    display: block;
    margin-top: 9px;
    font-size: 20px;
    letter-spacing: -.02em;
}

/* DETAY */

.detail-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 18px;
}

.detail-header h2 {
    margin: 5px 0;
    font-size: 28px;
}

.detail-header p {
    margin: 0;
    color: var(--muted);
    font-size: 11px;
}

/* FORM */

.form-panel {
    margin-top: 12px;
}

.form-grid {
    padding: 0 18px 18px;
    display: grid;
    grid-template-columns: repeat(4,1fr);
    gap: 10px;
}

.form-grid input,
.form-grid select,
.stack-form input,
.login-card input {
    width: 100%;
    padding: 11px 12px;
    outline: none;
    border: 1px solid #dbe1e7;
    border-radius: 9px;
    background: white;
    color: #344054;
}

.form-grid input:focus,
.stack-form input:focus,
.login-card input:focus {
    border-color: #91a1ae;
    box-shadow: 0 0 0 3px rgba(71,84,103,.07);
}

.primary {
    padding: 11px 15px !important;
    border: 0 !important;
    border-radius: 9px !important;
    background: #0b1218 !important;
    color: white !important;
    font-weight: 800;
    cursor: pointer;
}

.stack-form {
    padding: 0 18px 18px;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

/* KOMUTLAR */

.command-panel {
    padding-bottom: 18px;
}

.warning-text {
    margin: 0 18px 14px;
    padding: 11px;
    border: 1px solid #f0d9a6;
    border-radius: 9px;
    background: #fff8e8;
    color: #8c5a00;
    font-size: 10px;
}

.commands {
    display: flex;
    gap: 10px;
    padding: 0 18px;
}

.commands button {
    min-width: 100px;
    padding: 11px 18px;
    border: 1px solid #dce2e8;
    border-radius: 9px;
    background: white;
    font-weight: 900;
    cursor: pointer;
}

.commands .start {
    border-color: var(--green);
    background: var(--green);
    color: white;
}

.commands .stop {
    border-color: var(--red);
    background: var(--red);
    color: white;
}

/* MESAJ */

.notice,
.error {
    margin-bottom: 14px;
    padding: 11px 13px;
    border: 1px solid #f0d89a;
    border-radius: 10px;
    background: #fff6e5;
    color: #8c5a00;
    font-size: 11px;
}

/* LOGIN */

.login-body {
    min-height: 100vh;
    display: grid;
    place-items: center;
    padding: 20px;
    background:
        radial-gradient(circle at 20% 20%, #183026, transparent 30%),
        radial-gradient(circle at 80% 70%, #142633, transparent 30%),
        #080d12;
}

.login-card {
    width: min(420px,100%);
    padding: 30px;
    border: 1px solid #e5e9ed;
    border-radius: 20px;
    background: white;
    box-shadow: 0 30px 100px rgba(0,0,0,.4);
}

.login-card .brandmark {
    background: #0b1218;
    color: white;
}

.login-brand span {
    display: block;
    margin-top: 3px;
    color: #8b96a3;
    font-size: 10px;
}

.login-card h1 {
    margin: 30px 0 6px;
    font-size: 25px;
}

.login-card p {
    margin-bottom: 20px;
    color: #667085;
    font-size: 12px;
}

.login-card form {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.login-card label {
    margin-top: 5px;
    font-size: 10px;
    font-weight: 800;
}

.login-card .primary {
    margin-top: 10px;
}

.demo {
    margin-top: 18px;
    padding: 11px;
    border-radius: 10px;
    background: #f5f7f9;
    color: #667085;
    font-size: 10px;
}

/* MOBÄ°L */

@media (max-width: 1100px) {
    .stats,
    .metrics {
        grid-template-columns: repeat(2,1fr);
    }

    .grid2 {
        grid-template-columns: 1fr;
    }

    .form-grid {
        grid-template-columns: repeat(2,1fr);
    }
}

@media (max-width: 760px) {
    .shell {
        display: block;
    }

    .sidebar {
        display: none;
    }

    .page {
        padding: 16px;
    }

    .topbar {
        padding: 0 16px;
    }

    .stats,
    .metrics,
    .form-grid {
        grid-template-columns: 1fr;
    }

    .hero {
        padding: 23px;
    }

    .hero h2 {
        font-size: 24px;
    }

    .panel {
        overflow-x: auto;
    }

    table {
        min-width: 700px;
    }
}


.theme-toggle:hover {
    border-color: var(--green);
    color: var(--green);
    transform: translateY(-1px);
}


.leaflet-container { border: 1px solid #ffffff !important; }

/* Harita başlık alanını açık tona çek */
.map-header,
.panel-head,
.panel-header,
.live-map-header {
    background: #f8fafc !important;
    color: #101828 !important;
    border-bottom: 1px solid #e5e7eb !important;
}

/* Başlık içindeki ana yazılar */
.map-header h1,
.map-header h2,
.map-header h3,
.panel-head h1,
.panel-head h2,
.panel-head h3,
.panel-header h1,
.panel-header h2,
.panel-header h3,
.live-map-header h1,
.live-map-header h2,
.live-map-header h3 {
    color: #101828 !important;
}

/* Başlık altındaki küçük açıklama yazıları */
.map-header small,
.map-header span,
.map-header p,
.panel-head small,
.panel-head span,
.panel-head p,
.panel-header small,
.panel-header span,
.panel-header p,
.live-map-header small,
.live-map-header span,
.live-map-header p {
    color: #667085 !important;
}


