:root {
    --bg: #0b0d10;
    --surface: #12151a;
    --surface-2: #181c23;
    --surface-3: #222831;
    --line: rgba(255, 255, 255, 0.08);
    --text: #f3f4f6;
    --muted: #9ca3af;
    --accent: #e5e7eb;
    --accent-2: #d1d5db;
    --ok: #34d399;
    --warn: #fbbf24;
    --danger: #f87171;
    --radius: 12px;
    --font: Inter, ui-sans-serif, system-ui, -apple-system, "Segoe UI", Arial, sans-serif;
}

* { box-sizing: border-box; }
html, body { margin: 0; min-height: 100%; }
body {
    font-family: var(--font);
    color: var(--text);
    background: var(--bg);
    line-height: 1.5;
    font-size: 15px;
}
a { color: inherit; text-decoration: none; }

.app-shell {
    display: grid;
    grid-template-columns: 240px 1fr;
    min-height: 100vh;
}

.sidebar {
    border-right: 1px solid var(--line);
    background: var(--surface);
    padding: 20px;
    position: sticky;
    top: 0;
    height: 100vh;
}

.brand {
    display: flex;
    gap: 12px;
    align-items: center;
    margin-bottom: 24px;
}
.brand-mark {
    width: 42px;
    height: 42px;
    border-radius: 12px;
    display: grid;
    place-items: center;
    background: var(--surface-3);
    border: 1px solid var(--line);
    color: var(--text);
    font-weight: 800;
}
.brand strong, .brand small { display: block; }
.brand small { color: var(--muted); font-size: 12px; }

.menu { display: grid; gap: 6px; }
.menu a {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 11px 12px;
    border-radius: 12px;
    color: var(--muted);
    border: 1px solid transparent;
}
.menu a:hover, .menu a.active {
    color: var(--text);
    background: var(--surface-2);
    border-color: var(--line);
}

.sidebar-card {
    margin-top: 24px;
    padding: 16px;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    background: var(--surface-2);
}
.sidebar-card span { color: var(--muted); font-size: 12px; display: block; }
.sidebar-card strong { display: block; margin: 6px 0; font-size: 22px; }
.sidebar-card p { margin: 0; color: var(--muted); font-size: 13px; }

.main { padding: 24px 28px 40px; max-width: none; width: 100%; min-width: 0; overflow-x: hidden; }

.menu svg,
.top-pill svg,
.btn svg,
.sidebar-card svg,
.panel-head svg,
.summary-card svg,
.feed-list svg {
    width: 18px;
    height: 18px;
    flex-shrink: 0;
}

/* Bakiye çekmecesi kapalıyken görünmesin */
.balance-drawer {
    display: none;
    position: fixed;
    inset: 0;
    z-index: 200;
}
.balance-drawer.open {
    display: block;
}

/* Grid taşmalarını önle */
.app-shell {
    min-width: 0;
}
.sidebar {
    min-width: 240px;
    overflow-y: auto;
}

.exchange-terminal {
    margin-bottom: 16px;
}

.institutional-grid {
    margin-bottom: 16px;
}

/* Gereksiz animasyonları kapat — daha sade görünüm */
.summary-card::before,
.terminal-panel::after,
.btn::before,
button::before {
    display: none !important;
}

.chip-btn,
.market-tabs button,
.chart-toolbar button,
.order-toggle button {
    border: 1px solid var(--line);
    background: var(--surface-2);
    color: var(--muted);
    border-radius: 999px;
    min-height: 34px;
    padding: 7px 12px;
    font-size: 12px;
    font-weight: 700;
    cursor: pointer;
    box-shadow: none;
}

.chip-btn.active,
.market-tabs button.active,
.chart-toolbar button.active,
.order-toggle button.active {
    color: var(--text);
    background: var(--surface-3);
    border-color: var(--muted);
}

.panel-head h2,
.stage-top h2 {
    font-size: 20px;
    margin-top: 4px;
}

.stage-top h2[data-selected-pair],
.stage-top h2 {
    font-size: clamp(22px, 2.5vw, 32px);
}

.feature-hero,
.app-page-hero {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
    align-items: center;
    padding: 24px;
    margin-bottom: 16px;
    background: var(--surface);
    border: 1px solid var(--line);
    border-radius: calc(var(--radius) + 4px);
}

.ultra-table .table-row {
    display: grid;
    grid-template-columns: repeat(6, minmax(0, 1fr));
    gap: 10px;
    padding: 12px;
    border-bottom: 1px solid var(--line);
}

.table-head {
    color: var(--muted);
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: 0.06em;
}

.empty-state {
    display: grid;
    gap: 12px;
}

@media (max-width: 1100px) {
    .feature-hero,
    .app-page-hero,
    .institutional-grid,
    .exchange-summary {
        grid-template-columns: 1fr;
    }

    .exchange-terminal {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 1100px) {
    .app-shell { grid-template-columns: 1fr; }
    .sidebar { position: static; height: auto; min-width: 0; }
    .mode-grid, .summary-row, .form-grid, .exchange-terminal, .dashboard-bottom { grid-template-columns: 1fr; }
}

/* Kâr paneli */
.profit-panel.terminal-panel {
    display: flex;
    flex-direction: column;
    background: var(--surface);
    border: 1px solid var(--line);
    border-radius: var(--radius);
    padding: 0;
    min-width: 0;
    overflow: hidden;
}
.profit-panel.terminal-panel::after {
    display: none !important;
}

.profit-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    padding: 14px 16px;
    border-bottom: 1px solid var(--line);
    background: rgba(255, 255, 255, 0.02);
}
.profit-header-text {
    display: flex;
    align-items: center;
    gap: 10px;
    min-width: 0;
}
.profit-header h2 {
    margin: 0;
    font-size: 17px;
    font-weight: 700;
    line-height: 1.2;
}
.profit-live-dot {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    flex-shrink: 0;
    font-size: 10px;
    font-weight: 700;
    color: #86efac;
    padding: 3px 8px;
    border-radius: 6px;
    background: rgba(52, 211, 153, 0.1);
    border: 1px solid rgba(52, 211, 153, 0.16);
}
.profit-live-pulse {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: #34d399;
}
.profit-updated {
    flex-shrink: 0;
    font-size: 11px;
    color: var(--muted);
    font-style: normal;
    white-space: nowrap;
    padding: 4px 8px;
    border-radius: 6px;
    background: var(--surface-2);
    border: 1px solid var(--line);
    font-variant-numeric: tabular-nums;
}

.profit-content {
    flex: 1;
    min-height: 0;
    padding: 12px 14px 14px;
    display: flex;
    flex-direction: column;
    gap: 14px;
    overflow: auto;
}

.profit-section {
    display: grid;
    gap: 8px;
}

.profit-period-tabs {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 6px;
    padding: 6px;
    border-radius: 10px;
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid var(--line);
}

.profit-period-tabs button {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    min-height: 36px;
    border: 1px solid transparent;
    background: rgba(255, 255, 255, 0.03);
    color: var(--muted);
    border-radius: 10px;
    padding: 8px 10px;
    font-size: 12px;
    font-weight: 600;
    line-height: 1;
    cursor: pointer;
    transition: 0.18s ease;
    white-space: nowrap;
}

.profit-period-tabs button:hover {
    color: #fff;
    border-color: rgba(255, 255, 255, 0.08);
    background: rgba(255, 255, 255, 0.05);
}

.profit-period-tabs button.active {
    color: var(--text);
    border-color: var(--muted);
    background: var(--surface-3);
}

.profit-block-label {
    margin: 0;
    font-size: 10px;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--muted);
}

.profit-rows {
    display: grid;
    gap: 8px;
}

.profit-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
    min-height: 50px;
    padding: 12px 14px;
    background: var(--surface-2);
    border: 1px solid var(--line);
    border-radius: 8px;
}

.profit-row-accent {
    min-height: 54px;
    border-color: rgba(52, 211, 153, 0.18);
    background: var(--surface-2);
}

.profit-row-accent.is-loss {
    border-color: rgba(248, 113, 113, 0.18);
    background: var(--surface-2);
}

.profit-row-label {
    flex: 1;
    min-width: 0;
    color: var(--muted);
    font-size: 12px;
    font-weight: 600;
    line-height: 1.35;
}

.profit-row-value {
    flex-shrink: 0;
    max-width: 58%;
    color: #fff;
    font-size: 14px;
    font-weight: 700;
    line-height: 1.3;
    text-align: right;
    font-variant-numeric: tabular-nums;
    word-break: break-word;
}

.profit-row-value-main {
    font-size: 16px;
    font-weight: 800;
    color: #6ee7b7;
}

.profit-row-value-main.down {
    color: #fca5a5;
}

.profit-panel .profit-cta {
    flex-shrink: 0;
    margin: 0 14px 14px;
    width: calc(100% - 28px);
    min-height: 42px;
    font-size: 13px;
    font-weight: 700;
    border-radius: 8px;
}

.profit-rows-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

.profit-rows-grid .profit-row {
    flex-direction: column;
    align-items: flex-start;
    justify-content: center;
    gap: 5px;
    min-height: 58px;
    padding: 10px 12px;
}

.profit-rows-grid .profit-row-value {
    max-width: 100%;
    text-align: left;
    font-size: 13px;
}

.budget-cell strong,
.balance-line strong {
    display: block;
    margin-top: 4px;
    font-size: 14px;
    line-height: 1.25;
    color: #fff;
    font-weight: 700;
    font-variant-numeric: tabular-nums;
}

.balance-list {
    display: grid;
    gap: 0;
    border: 1px solid var(--line);
    border-radius: 10px;
    overflow: hidden;
}
.balance-line {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    padding: 10px 12px;
    background: var(--surface-2);
    border-bottom: 1px solid var(--line);
    min-width: 0;
}
.balance-line:last-child {
    border-bottom: none;
}
.balance-line span {
    color: var(--muted);
    font-size: 11px;
    font-weight: 600;
    flex-shrink: 0;
}
.balance-line strong {
    margin-top: 0;
    text-align: right;
    flex: 1;
    min-width: 0;
}
.balance-line.highlight {
    background: rgba(52, 211, 153, 0.06);
}
.balance-line.highlight strong {
    color: #6ee7b7;
}

.profit-trades-wrap .profit-list {
    margin-top: 0;
}
.profit-list {
    display: grid;
    gap: 6px;
}
.profit-item {
    display: grid;
    gap: 2px;
    padding: 8px 10px;
    border-radius: 8px;
    background: var(--surface-2);
    font-size: 12px;
}
.profit-item b { color: #fff; font-size: 12px; }
.profit-item span { color: var(--muted); font-size: 11px; }
.empty-note {
    margin: 0;
    color: var(--muted);
    font-size: 12px;
    padding: 4px 0;
}

.bot-features {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 8px;
    margin: 16px 0;
}
.bot-features div {
    padding: 10px;
    border: 1px solid var(--line);
    border-radius: 10px;
    background: var(--surface-2);
    min-width: 0;
}
.bot-features span { display: block; color: var(--muted); font-size: 11px; font-weight: 600; }
.bot-features strong { display: block; margin-top: 4px; font-size: 14px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

.runtime-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 10px;
    margin: 14px 0;
}
.runtime-grid div,
.copy-box,
.backup-actions {
    border: 1px solid var(--line);
    border-radius: 12px;
    background: var(--surface-2);
}
.runtime-grid div {
    padding: 12px;
    min-width: 0;
}
.runtime-grid span {
    display: block;
    color: var(--muted);
    font-size: 11px;
    font-weight: 700;
}
.runtime-grid strong {
    display: block;
    margin-top: 5px;
    font-size: 13px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}
.copy-box {
    display: grid;
    gap: 10px;
    padding: 12px;
}
.copy-box label,
.restore-form label {
    display: grid;
    gap: 6px;
    color: var(--muted);
    font-size: 12px;
    font-weight: 700;
}
.copy-box input {
    width: 100%;
    min-width: 0;
}
.copy-box small {
    color: var(--muted);
    line-height: 1.45;
}
.backup-actions {
    display: grid;
    grid-template-columns: minmax(0, 220px) 1fr;
    gap: 12px;
    padding: 12px;
    align-items: end;
}
.restore-form {
    display: grid;
    grid-template-columns: 1fr auto;
    gap: 10px;
    align-items: end;
}

.profit-card { margin: 0 16px 12px; padding: 12px; border: 1px solid var(--line); border-radius: 12px; background: var(--surface-2); }
.profit-card span { display: block; color: var(--muted); font-size: 12px; margin-bottom: 6px; }
.profit-card p { margin: 0; color: var(--text); font-size: 13px; line-height: 1.45; }

.dashboard-bottom {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 14px;
    margin-bottom: 16px;
}
.status-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
    padding: 16px;
}
.status-grid div {
    padding: 12px;
    border: 1px solid var(--line);
    border-radius: 12px;
    background: var(--surface-2);
}
.status-grid span { display: block; color: var(--muted); font-size: 12px; }
.status-grid strong { display: block; margin-top: 4px; font-size: 16px; }

.profit-stats.compact { grid-template-columns: repeat(3, minmax(0, 1fr)); padding: 0; }
.profit-stats.compact .profit-stat strong { font-size: 18px; }

@media (max-width: 900px) {
    .bot-features { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .runtime-grid,
    .backup-actions,
    .restore-form { grid-template-columns: 1fr; }
    .profit-stats.compact { grid-template-columns: 1fr; }
}

.panel-head .inline-form { margin: 0; }
.panel-head .inline-form .btn { min-height: 36px; padding: 8px 12px; font-size: 12px; }

.log-list { padding: 12px 16px 16px; display: grid; gap: 8px; max-height: 260px; overflow: auto; }
.log-row {
    display: grid;
    grid-template-columns: 64px 1fr;
    gap: 10px;
    padding: 8px 0;
    border-bottom: 1px solid var(--line);
    font-size: 13px;
}
.log-row time { color: var(--muted); font-size: 12px; }
.log-body { display: grid; gap: 4px; min-width: 0; }
.log-row p { margin: 0; color: var(--text); line-height: 1.4; }
.log-detail {
    display: block;
    color: var(--muted);
    font-size: 11px;
    line-height: 1.35;
    font-variant-numeric: tabular-nums;
}
.activity-stack {
    display: grid;
    gap: 8px;
    margin-bottom: 12px;
}

.activity-toast {
    padding: 12px 14px;
    border-radius: 10px;
    border: 1px solid var(--line);
    background: var(--surface-2);
    color: var(--text);
    font-size: 13px;
    line-height: 1.45;
    animation: activityIn 0.25s ease;
}

.activity-toast.activity-order_placed {
    border-color: rgba(251, 191, 36, 0.35);
    background: rgba(251, 191, 36, 0.08);
}

.activity-toast.activity-order_filled {
    border-color: rgba(52, 211, 153, 0.35);
    background: rgba(52, 211, 153, 0.08);
}

.activity-toast.activity-order_cancelled,
.activity-toast.activity-order_cancel_requested {
    border-color: rgba(248, 113, 113, 0.28);
    background: rgba(248, 113, 113, 0.06);
}

.activity-toast.activity-order_waiting {
    border-color: rgba(156, 163, 175, 0.28);
}

.activity-toast.fade-out {
    opacity: 0;
    transform: translateY(-4px);
    transition: 0.35s ease;
}

@keyframes activityIn {
    from { opacity: 0; transform: translateY(-6px); }
    to { opacity: 1; transform: translateY(0); }
}

.open-orders-panel {
    margin-bottom: 12px;
}

.open-orders-panel .compact-head {
    padding: 12px 14px;
}

.open-orders-panel .compact-head h2 {
    font-size: 16px;
    margin-top: 4px;
}

.open-orders-list {
    display: grid;
    gap: 8px;
    padding: 0 14px 14px;
}

.open-order-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 10px 12px;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: var(--surface-2);
}

.open-order-row strong {
    display: block;
    font-size: 13px;
}

.open-order-row small {
    display: block;
    margin-top: 2px;
    color: var(--muted);
    font-size: 11px;
}

.open-order-meta {
    text-align: right;
    font-size: 12px;
    font-variant-numeric: tabular-nums;
}

.open-order-meta em {
    display: block;
    margin-top: 2px;
    font-style: normal;
    color: var(--warn);
    font-size: 11px;
}

.log-row.log-event-order_placed p { color: #fde68a; }
.log-row.log-event-order_filled p { color: #6ee7b7; }
.log-row.log-event-order_cancelled p,
.log-row.log-event-order_cancel_requested p { color: #fca5a5; }
.log-row.log-event-order_waiting p { color: var(--muted); }
.log-row.log-event-buy_confirm_wait p { color: #cbd5e1; }
.log-row.log-event-order_rebalance p { color: #fdba74; }

.activity-toast.activity-order_rebalance {
    border-color: rgba(251, 146, 60, 0.35);
    background: rgba(251, 146, 60, 0.08);
}

.profit-row-hint {
    display: inline;
    margin-left: 4px;
    color: var(--muted);
    font-size: 10px;
    font-weight: 500;
    letter-spacing: 0;
    text-transform: none;
}

.balance-hint {
    display: block;
    margin-top: 1px;
    color: var(--warn);
    font-size: 10px;
    font-weight: 600;
    line-height: 1.2;
}

.empty-note { margin: 0; color: var(--muted); font-size: 13px; }

/* Parlama ve animasyonları tamamen kapat */
*, *::before, *::after {
    animation: none !important;
}
.chart-line,
.chart-area,
.live-dot,
.buy-zone,
.target-line,
.radar-visual,
.radar-visual span,
.heat-grid span,
.panel-glow,
.balance-orb,
.summary-card,
.terminal-panel,
.btn,
.market-row,
.pro-chart,
.pro-chart::before,
.pro-chart::after {
    filter: none !important;
    box-shadow: none !important;
    text-shadow: none !important;
}
.pro-chart {
    background: var(--bg) !important;
}
.chart-line {
    stroke-width: 2 !important;
    stroke: var(--ok) !important;
}
.chart-area {
    fill: url(#chartFill) !important;
    opacity: 1 !important;
}
.buy-zone,
.target-line,
.live-dot,
.radar-visual,
.heat-grid,
.panel-glow,
.order-toggle,
.range-track,
.order-form-preview {
    display: none !important;
}
.feature-hero .radar-visual,
.institutional-grid,
.exchange-summary,
.liquidity-panel,
.activity-feed,
.portfolio-panel {
    display: none !important;
}


.topbar {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 16px;
    margin-bottom: 24px;
    flex-wrap: wrap;
}
.eyebrow {
    display: block;
    color: var(--muted);
    font-size: 12px;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    font-weight: 700;
}
h1, h2, h3 { margin: 0; line-height: 1.15; font-weight: 700; }
h1 { font-size: clamp(24px, 3vw, 34px); margin-top: 6px; }
h2 { font-size: clamp(20px, 2.4vw, 28px); }
p { color: var(--muted); margin: 0; }

.top-actions, .inline-form, .btn-row { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; }
.top-pill {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 12px;
    border-radius: 999px;
    border: 1px solid var(--line);
    background: var(--surface-2);
    color: var(--muted);
    font-size: 13px;
    font-weight: 700;
}
.top-pill.ok { color: #a7f3d0; border-color: rgba(52,211,153,.25); }
.top-pill.warn { color: #fde68a; border-color: rgba(251,191,36,.25); }

.btn, button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    min-height: 42px;
    padding: 10px 16px;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: var(--surface-3);
    color: var(--text);
    font: inherit;
    font-weight: 700;
    cursor: pointer;
}
.btn.ghost, button.ghost {
    background: var(--surface-2);
    color: var(--text);
    border: 1px solid var(--line);
}
.btn.danger { background: var(--danger); }
.btn.success { background: var(--ok); }
.btn.full { width: 100%; }

.panel {
    background: var(--surface);
    border: 1px solid var(--line);
    border-radius: calc(var(--radius) + 4px);
    padding: 20px;
    margin-bottom: 16px;
}
.section-title { margin-bottom: 16px; }
.section-title p { margin-top: 8px; max-width: 720px; }

label { display: grid; gap: 8px; color: var(--muted); font-weight: 600; font-size: 14px; }
input, select, textarea {
    width: 100%;
    min-height: 44px;
    padding: 10px 12px;
    border-radius: 10px;
    border: 1px solid var(--line);
    background: var(--bg);
    color: var(--text);
    font: inherit;
    outline: none;
    box-shadow: none !important;
    appearance: none;
}
select {
    padding-right: 36px;
    background-image: linear-gradient(45deg, transparent 50%, var(--muted) 50%), linear-gradient(135deg, var(--muted) 50%, transparent 50%);
    background-position: calc(100% - 18px) 18px, calc(100% - 12px) 18px;
    background-size: 6px 6px, 6px 6px;
    background-repeat: no-repeat;
}
input:focus, select:focus, textarea:focus {
    border-color: var(--accent);
    box-shadow: none !important;
}
label small { color: var(--muted); font-weight: 500; font-size: 12px; }

.clean-form label,
.form-grid label {
    gap: 6px;
    min-width: 0;
}
.clean-form input,
.clean-form select,
.form-grid input,
.form-grid select {
    min-height: 44px;
    border-radius: 10px;
    background: var(--bg) !important;
    border: 1px solid var(--line) !important;
    box-shadow: none !important;
}
.clean-form input:hover,
.clean-form select:hover,
.form-grid input:hover,
.form-grid select:hover {
    border-color: rgba(255,255,255,.16) !important;
}
.clean-form .secret-input-wrap,
.form-grid .secret-input-wrap {
    position: relative;
    width: 100%;
}
.clean-form .secret-input-wrap input,
.form-grid .secret-input-wrap input {
    padding-right: 78px;
}
.form-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; }
.form-grid .full { grid-column: 1 / -1; }

.clean-form .secret-toggle,
.form-grid .secret-toggle {
    position: absolute;
    right: 6px;
    top: 50%;
    transform: translateY(-50%);
    min-height: 32px;
    padding: 6px 10px;
    font-size: 12px;
    background: var(--surface-2);
    border: 1px solid var(--line);
    color: var(--text);
}

.alert {
    padding: 12px 14px;
    border-radius: 12px;
    margin-bottom: 16px;
    border: 1px solid var(--line);
}
.alert.success { border-color: rgba(52,211,153,.3); color: #a7f3d0; }
.alert.error { border-color: rgba(248,113,113,.3); color: #fecaca; }

/* Bot control */
.bot-hero {
    display: flex;
    justify-content: space-between;
    gap: 16px;
    flex-wrap: wrap;
    align-items: flex-start;
}

.bot-control-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin-top: 16px;
}

.bot-control-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    min-height: 46px;
    padding: 0 20px;
    border-radius: 10px;
    border: 1px solid transparent;
    font: inherit;
    font-size: 14px;
    font-weight: 700;
    cursor: pointer;
}

.bot-control-btn svg {
    width: 18px;
    height: 18px;
    flex-shrink: 0;
}

.bot-control-btn--start {
    background: rgba(52, 211, 153, 0.14);
    color: #bbf7d0;
    border-color: rgba(52, 211, 153, 0.35);
}

.bot-control-btn--stop {
    background: rgba(248, 113, 113, 0.12);
    color: #fecaca;
    border-color: rgba(248, 113, 113, 0.32);
}

.maintenance-note {
    margin-top: 16px;
    padding: 14px 16px;
    border: 1px solid var(--line);
    border-radius: 10px;
    background: var(--surface-2);
    color: var(--muted);
    font-size: 13px;
    line-height: 1.5;
}

.maintenance-note strong {
    display: block;
    margin-bottom: 6px;
    color: var(--text);
    font-size: 14px;
}

.maintenance-note ol {
    margin: 8px 0 0 18px;
    padding: 0;
    color: var(--text);
}

.maintenance-note code {
    color: #fde68a;
    font-size: 12px;
}

.maintenance-note-hint {
    margin: 10px 0 0;
    font-size: 12px;
}

.migration-zip-btn svg,
.btn svg,
button.btn svg {
    width: 18px;
    height: 18px;
    flex-shrink: 0;
}

.status-pill {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 14px;
    border-radius: 999px;
    border: 1px solid var(--line);
    font-weight: 700;
    font-size: 13px;
}
.status-pill.ok { color: #a7f3d0; border-color: rgba(52,211,153,.28); }
.status-pill.off { color: var(--muted); }
.status-pill.run { color: var(--warn); border-color: rgba(240, 185, 11, 0.28); }

.mode-grid {
    display: grid;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: 12px;
    margin: 16px 0;
}
.mode-card {
    padding: 16px;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    background: var(--surface-2);
    cursor: pointer;
    transition: border-color .15s ease;
}
.mode-card input { display: none; }
.mode-card.active { border-color: var(--muted); background: var(--surface-3); }
.mode-card strong { display: block; color: #fff; margin-bottom: 6px; }
.mode-card span { display: block; color: var(--muted); font-size: 12px; margin-bottom: 8px; }
.mode-card p { font-size: 13px; line-height: 1.45; margin: 0; }

@media (max-width: 1300px) {
    .mode-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}

@media (max-width: 900px) {
    .mode-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

.coin-table-wrap { overflow: auto; border: 1px solid var(--line); border-radius: var(--radius); }
.coin-table { width: 100%; border-collapse: collapse; font-size: 13px; }
.coin-table th, .coin-table td { padding: 11px 12px; border-bottom: 1px solid var(--line); text-align: left; }
.coin-table th { color: var(--muted); font-size: 11px; text-transform: uppercase; letter-spacing: .06em; }
.coin-table td small { display: block; color: var(--muted); font-size: 11px; margin-top: 2px; }
.analysis-pagination {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-top: 12px;
}
.analysis-pagination button {
    min-width: 34px;
    min-height: 32px;
    border: 1px solid var(--line);
    border-radius: 9px;
    background: var(--surface-2);
    color: var(--muted);
    font-weight: 700;
    cursor: pointer;
}
.analysis-pagination button.active {
    color: #fff;
    border-color: rgba(52, 211, 153, 0.4);
    background: rgba(52, 211, 153, 0.12);
}

.tag {
    display: inline-flex;
    padding: 4px 8px;
    border-radius: 999px;
    font-size: 11px;
    font-weight: 800;
    background: rgba(255,255,255,.06);
}
.tag.buy { color: #a7f3d0; }
.tag.watch { color: #fde68a; }
.tag.skip { color: #d1d5db; }

.summary-row {
    display: grid;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: 10px;
    margin-bottom: 14px;
}
.summary-row div {
    padding: 12px;
    border: 1px solid var(--line);
    border-radius: 12px;
    background: var(--surface-2);
}
.summary-row span { display: block; color: var(--muted); font-size: 12px; }
.summary-row strong { display: block; margin-top: 4px; font-size: 22px; }

/* Dashboard essentials */
.exchange-terminal {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1.12fr) minmax(0, 1fr);
    gap: 12px;
    align-items: stretch;
    min-width: 0;
}

.exchange-terminal > .market-board,
.exchange-terminal > .trade-stage {
    display: flex;
    flex-direction: column;
    min-height: 0;
    height: min(680px, calc(100vh - 168px));
    min-height: 520px;
}

.exchange-terminal > .profit-panel {
    display: flex;
    flex-direction: column;
    min-height: 0;
    align-self: stretch;
}
.terminal-panel {
    background: var(--surface);
    border: 1px solid var(--line);
    border-radius: var(--radius);
    overflow: hidden;
}
.panel-head {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    padding: 16px;
    border-bottom: 1px solid var(--line);
}
.market-board {
    display: flex;
    flex-direction: column;
    min-height: 0;
}

.market-list {
    flex: 1;
    min-height: 0;
    padding: 8px 10px 10px;
    display: grid;
    gap: 4px;
    overflow: auto;
    align-content: start;
}

.market-row {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto auto;
    gap: 8px;
    align-items: center;
    width: 100%;
    min-height: 52px;
    height: auto;
    padding: 9px 10px;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: var(--surface-2);
    color: inherit;
    font: inherit;
    text-align: left;
    cursor: pointer;
    line-height: 1.25;
    overflow: visible;
}

.market-row strong {
    font-size: 13px;
    font-variant-numeric: tabular-nums;
}

.market-row em {
    font-size: 12px;
    font-style: normal;
    font-variant-numeric: tabular-nums;
    min-width: 64px;
    text-align: right;
}

.trade-stage {
    display: flex;
    flex-direction: column;
    min-height: 0;
}

.chart-shell {
    flex: 1;
    min-height: 0;
    display: flex;
    flex-direction: column;
    padding: 10px 14px 0;
}

.pro-chart {
    flex: 1;
    min-height: 180px;
    height: auto !important;
}
.market-row.active { border-color: var(--line); background: var(--surface-2); }
.market-row span, .market-row small, .market-row b { display: block; }
.market-row small { color: var(--muted); font-size: 11px; }
.up { color: var(--ok) !important; }
.down { color: var(--danger) !important; }

.balance-pill {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 8px 12px;
    border-radius: 999px;
    border: 1px solid var(--line);
    background: var(--surface-2);
    color: #fff;
    cursor: pointer;
}
.balance-pill small, .balance-pill strong { display: block; text-align: left; }
.balance-pill small { color: var(--muted); font-size: 11px; }

.balance-orb {
    display: grid;
    place-items: center;
    width: 38px;
    height: 38px;
    border-radius: 50%;
    background: var(--surface-3);
    border: 1px solid var(--line);
}

@media (max-width: 1100px) {
    .app-shell { grid-template-columns: 1fr; }
    .sidebar { position: static; height: auto; }
    .mode-grid, .summary-row, .form-grid, .exchange-terminal { grid-template-columns: 1fr; }
}

/* Form elemanları — panel.css parlama/gradient override */
body input:not([type="checkbox"]):not([type="radio"]):not([type="hidden"]),
body select,
body textarea,
.clean-form input,
.clean-form select,
.form-grid input,
.form-grid select {
    width: 100% !important;
    max-width: 100% !important;
    min-width: 0 !important;
    min-height: 44px !important;
    padding: 10px 12px !important;
    border-radius: 10px !important;
    border: 1px solid var(--line) !important;
    background: var(--bg) !important;
    color: var(--text) !important;
    font: inherit !important;
    box-shadow: none !important;
    outline: none !important;
    appearance: none;
}
body input:focus,
body select:focus,
body textarea:focus,
.clean-form input:focus,
.form-grid input:focus,
.form-grid select:focus {
    border-color: var(--accent) !important;
    box-shadow: none !important;
}
body label,
.clean-form label,
.form-grid label {
    display: grid !important;
    gap: 6px !important;
    min-width: 0 !important;
    width: 100% !important;
}
