:root {
    --bg-primary: #0d1117;
    --bg-secondary: #131920;
    --card-bg: rgba(20, 28, 36, 0.78);
    --card-hover: rgba(28, 38, 48, 0.92);
    --text-primary: #edf0f2;
    --text-secondary: #7a8a96;
    --accent: #1e2e3a;
    --accent-light: #a0b4c0;
    --accent-hot: #c8d8e0;
    --border: rgba(140, 160, 175, 0.18);
    --wiki-bg: #0d1117;
    --wiki-bg-soft: #141c24;
    --wiki-panel: rgba(20, 28, 36, 0.78);
    --wiki-panel-hot: rgba(28, 38, 48, 0.92);
    --wiki-line: rgba(140, 160, 175, 0.14);
    --wiki-line-hot: rgba(160, 180, 192, 0.32);
    --wiki-text: #edf0f2;
    --wiki-muted: #7a8a96;
    --wiki-green: #2ecc8a;
    --wiki-green-soft: #1fa870;
    --wiki-blue: #4ab0e0;
    --wiki-orange: #e08840;
    color-scheme: dark;
}

* {
    letter-spacing: 0;
}

html {
    scroll-behavior: smooth;
}

body {
    min-width: 320px;
    background-color: var(--wiki-bg);
    background-image:
        linear-gradient(rgba(160, 180, 192, 0.03) 1px, transparent 1px),
        linear-gradient(90deg, rgba(160, 180, 192, 0.03) 1px, transparent 1px),
        radial-gradient(circle at 18% 10%, rgba(120, 150, 170, 0.10), transparent 34rem),
        radial-gradient(circle at 86% 16%, rgba(100, 130, 150, 0.07), transparent 30rem);
    background-size: 42px 42px, 42px 42px, auto, auto;
    color: var(--wiki-text);
    line-height: 1.62;
}

body::before {
    content: "";
    position: fixed;
    inset: 0;
    z-index: -2;
    pointer-events: none;
    background:
        radial-gradient(circle at center, transparent 0, transparent 58%, rgba(0, 0, 0, 0.44) 100%),
        linear-gradient(rgba(255, 255, 255, 0.014) 50%, transparent 50%);
    background-size: auto, 100% 4px;
}

a {
    color: inherit;
}

code,
pre {
    font-family: "Cascadia Code", Consolas, monospace;
}

.nav {
    background: rgba(10, 14, 18, 0.82);
    border-bottom: 1px solid var(--border);
    backdrop-filter: blur(16px);
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.35);
}

.nav .nav-links {
    color: var(--wiki-text);
}

.logo {
    text-shadow: 0 0 18px rgba(160, 180, 192, 0.3);
}

.guide-meta,
.milestone-grid div {
    display: flex;
    align-items: center;
}

.rail-link,
.guide-callout a {
    border: 1px solid var(--wiki-line);
    border-radius: 7px;
    text-decoration: none;
    transition: border-color 180ms ease, background 180ms ease, transform 180ms ease;
}

.rail-link:hover,
.guide-callout a:hover {
    border-color: var(--wiki-line-hot);
    background: rgba(160, 180, 192, 0.08);
    transform: translateY(-1px);
}

.wiki-shell {
    display: grid;
    grid-template-columns: minmax(220px, 292px) minmax(0, 920px);
    justify-content: center;
    gap: clamp(1rem, 3vw, 3rem);
    width: min(100%, 1420px);
    margin: 0 auto;
    padding: clamp(8.2rem, 10vw, 9rem) clamp(1rem, 4vw, 3rem) 4rem;
}

.wiki-home {
    width: min(100%, 1120px);
    margin: 0 auto;
    padding: clamp(8.6rem, 12vw, 11rem) clamp(1rem, 4vw, 3rem) clamp(3rem, 7vw, 6rem);
}

.wiki-home-head {
    max-width: 760px;
    padding: clamp(1rem, 3vw, 2.25rem);
    border: 1px solid var(--wiki-line);
    border-radius: 8px;
    background:
        linear-gradient(135deg, rgba(120, 150, 170, 0.10), transparent 42%),
        linear-gradient(120deg, rgba(80, 110, 130, 0.08), transparent 58%),
        var(--wiki-panel);
}

.wiki-home-head h1 {
    margin-bottom: 0.7rem;
}

.wiki-home-head p:last-child {
    max-width: 580px;
    margin-bottom: 0;
    color: var(--wiki-muted);
    font-size: clamp(1rem, 2vw, 1.2rem);
}

.wiki-home-list {
    display: grid;
    gap: 0.9rem;
    margin-top: clamp(1rem, 3vw, 2rem);
}

.wiki-home-entry,
.wiki-home-empty {
    border: 1px solid var(--wiki-line);
    border-radius: 8px;
    background: var(--wiki-panel);
}

.wiki-home-entry {
    display: grid;
    gap: 0.35rem;
    padding: clamp(1rem, 2.5vw, 1.5rem);
    color: var(--wiki-text);
    text-decoration: none;
    transition: border-color 180ms ease, background 180ms ease, transform 180ms ease;
}

.wiki-home-entry:hover {
    border-color: var(--wiki-line-hot);
    background: var(--wiki-panel-hot);
    transform: translateY(-2px);
}

.wiki-home-entry span {
    color: var(--wiki-green);
    font-size: 0.78rem;
    font-weight: 950;
    text-transform: uppercase;
}

.wiki-home-entry strong {
    font-size: clamp(1.2rem, 2.2vw, 1.8rem);
    line-height: 1.15;
}

.wiki-home-entry small,
.wiki-home-empty {
    color: var(--wiki-muted);
}

.wiki-home-empty {
    padding: 1rem;
}

.wiki-rail {
    position: sticky;
    top: 104px;
    align-self: start;
    display: grid;
    gap: 1rem;
}

.rail-block,
.guide-callout,
.phase-grid > div,
.roadmap > section,
.mistake-list > div,
.reset-grid > div {
    border: 1px solid var(--wiki-line);
    border-radius: 8px;
    background: var(--wiki-panel);
}

.rail-block {
    display: grid;
    gap: 0.62rem;
    padding: 1rem;
}

.rail-label,
.guide-path {
    margin: 0;
    color: var(--wiki-green);
    font-size: 0.76rem;
    font-weight: 950;
    text-transform: uppercase;
}

.rail-link {
    padding: 0.72rem;
    font-weight: 900;
}

.rail-link.is-active {
    border-color: var(--wiki-line-hot);
    background: rgba(56, 255, 127, 0.12);
}

.rail-note {
    margin: 0;
    color: var(--wiki-muted);
    font-size: 0.88rem;
}

.toc a {
    color: var(--wiki-muted);
    text-decoration: none;
    font-weight: 750;
}

.toc a:hover {
    color: var(--wiki-green-soft);
}

.wiki-guide {
    min-width: 0;
    padding-bottom: 2rem;
}

.guide-head {
    padding: clamp(1rem, 3vw, 2.25rem);
    border: 1px solid var(--wiki-line);
    border-radius: 8px;
    background:
        linear-gradient(135deg, rgba(120, 150, 170, 0.08), transparent 42%),
        linear-gradient(120deg, rgba(80, 110, 130, 0.08), transparent 58%),
        var(--wiki-panel);
}

h1,
h2,
h3,
h4,
p,
ul,
ol {
    margin-top: 0;
}

h1 {
    max-width: 760px;
    margin-bottom: 0.95rem;
    color: var(--wiki-text);
    font-size: clamp(2rem, 5vw, 4.6rem);
    line-height: 0.98;
}

h2 {
    margin-bottom: 0.85rem;
    color: var(--wiki-green-soft);
    font-size: clamp(1.35rem, 2.3vw, 2.12rem);
    line-height: 1.16;
}

h3 {
    margin: 1.35rem 0 0.55rem;
    color: var(--wiki-text);
    font-size: 1.13rem;
    line-height: 1.24;
}

h4 {
    margin-bottom: 0.35rem;
    color: var(--wiki-orange);
    font-size: 1rem;
}

.guide-lead {
    max-width: 670px;
    color: var(--wiki-text);
    font-size: clamp(1rem, 2vw, 1.24rem);
}

.guide-meta {
    flex-wrap: wrap;
    gap: 0.55rem;
}

.guide-meta span {
    padding: 0.34rem 0.58rem;
    border: 1px solid var(--wiki-line);
    border-radius: 6px;
    color: var(--wiki-muted);
    background: rgba(0, 0, 0, 0.24);
    font-size: 0.84rem;
    font-weight: 800;
}

.wiki-guide > section {
    scroll-margin-top: 104px;
    margin-top: clamp(1rem, 3vw, 2.4rem);
}

.wiki-guide > section:not(.guide-callout) {
    padding: clamp(0.4rem, 1vw, 0.8rem) clamp(0rem, 2vw, 0.4rem);
}

.wiki-guide p,
.wiki-guide li {
    color: var(--wiki-muted);
}

.wiki-guide strong {
    color: var(--wiki-text);
}

.wiki-guide ul,
.wiki-guide ol {
    padding-left: 1.25rem;
}

.wiki-guide li + li {
    margin-top: 0.35rem;
}

code {
    color: var(--wiki-blue);
}

pre {
    overflow-x: auto;
    padding: 0.95rem;
    border: 1px solid var(--wiki-line);
    border-radius: 8px;
    background: rgba(0, 0, 0, 0.45);
    color: var(--wiki-blue);
    line-height: 1.5;
}

/* ── Callout: grün ── */
.guide-callout {
    padding: clamp(1rem, 2.5vw, 1.5rem);
    background:
        linear-gradient(110deg, rgba(56, 255, 127, 0.13), transparent 58%),
        var(--wiki-panel-hot);
}

.guide-callout ol {
    margin-bottom: 0;
}

.phase-grid,
.upgrade-list,
.roadmap,
.mistake-list,
.reset-grid {
    display: grid;
    gap: 0.8rem;
}

.phase-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
}

.phase-grid > div,
.roadmap > section,
.mistake-list > div,
.reset-grid > div {
    padding: 0.95rem;
}

.phase-grid p,
.roadmap p,
.roadmap ul,
.roadmap ol,
.mistake-list p,
.reset-grid ul,
.upgrade-list p {
    margin-bottom: 0;
}

.table-wrap {
    overflow-x: auto;
    border: 1px solid var(--wiki-line);
    border-radius: 8px;
    background: rgba(0, 0, 0, 0.34);
}

table {
    width: 100%;
    min-width: 560px;
    border-collapse: collapse;
}

th,
td {
    padding: 0.72rem 0.82rem;
    border-bottom: 1px solid var(--wiki-line);
    text-align: left;
}

th {
    color: var(--wiki-green-soft);
    font-size: 0.8rem;
    text-transform: uppercase;
}

td {
    color: var(--wiki-muted);
}

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

/* ── Rule: orange ── */
.wiki-rule {
    padding: 0.95rem;
    border-left: 3px solid var(--wiki-orange);
    background: rgba(255, 176, 82, 0.09);
    color: var(--wiki-muted);
}

/* ── Upgrade-Liste: blau ── */
.upgrade-list {
    grid-template-columns: repeat(3, minmax(0, 1fr));
}

.upgrade-list > div {
    padding: 0.9rem;
    border-top: 1px solid rgba(98, 217, 255, 0.28);
    background: linear-gradient(180deg, rgba(98, 217, 255, 0.08), transparent);
}

.roadmap,
.mistake-list,
.reset-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

/* ── Milestone-Grid: lila ── */
.milestone-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 0.7rem;
}

.milestone-grid div {
    flex-direction: column;
    align-items: flex-start;
    min-height: 118px;
    padding: 0.85rem;
    border: 1px solid rgba(193, 111, 255, 0.42);
    border-radius: 8px;
    background:
        linear-gradient(145deg, rgba(193, 111, 255, 0.18), transparent 62%),
        #1a0f26;
}

.milestone-grid strong {
    color: #e2b3ff;
    font-size: 1.05rem;
}

.milestone-grid span {
    color: var(--wiki-muted);
    font-size: 0.9rem;
}

.milestone-grid em {
    margin-top: auto;
    color: #c874ff;
    font-style: normal;
    font-weight: 950;
}

/* ── End-Card: grün ── */
.end-card a {
    display: inline-flex;
    margin-top: 0.45rem;
    padding: 0.72rem 0.85rem;
    color: var(--wiki-text);
    background: rgba(56, 255, 127, 0.14);
    font-weight: 950;
}

.wiki-footer {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 1rem;
    padding: 1.5rem 1rem 3rem;
    border-top: 1px solid var(--wiki-line);
    color: var(--wiki-muted);
}

.wiki-footer a {
    text-decoration: none;
}

.wiki-footer a:hover {
    color: var(--wiki-green-soft);
}

@media (max-width: 960px) {
    .wiki-shell {
        grid-template-columns: 1fr;
    }

    .wiki-rail {
        position: static;
    }

    .toc {
        display: flex;
        flex-wrap: wrap;
    }

    .toc .rail-label {
        flex-basis: 100%;
    }

    .phase-grid,
    .upgrade-list,
    .milestone-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 620px) {
    .wiki-shell {
        padding-inline: 0.8rem;
    }

    .phase-grid,
    .upgrade-list,
    .roadmap,
    .mistake-list,
    .reset-grid,
    .milestone-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 760px) {
    .nav .nav-links {
        border-color: rgba(140, 160, 175, 0.22);
        background:
            linear-gradient(rgba(160, 180, 192, 0.04) 1px, transparent 1px),
            linear-gradient(90deg, rgba(160, 180, 192, 0.035) 1px, transparent 1px),
            rgba(8, 12, 16, 0.97);
        box-shadow:
            0 28px 72px rgba(0, 0, 0, 0.52),
            0 0 44px rgba(140, 165, 185, 0.08);
    }
}

/* ============================================================
   Wiki-Suche + Tabellen
   ============================================================ */

.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

.wiki-search {
    position: sticky;
    top: 0.5rem;
    z-index: 10;
    margin: 0 0 1.5rem;
    display: flex;
    align-items: center;
    gap: 0.7rem;
    padding: 0.65rem 0.85rem;
    border: 1px solid rgba(160, 180, 192, 0.32);
    border-radius: 12px;
    background: rgba(10, 14, 20, 0.96);
    box-shadow: 0 6px 22px rgba(0, 0, 0, 0.4), inset 0 1px rgba(255, 255, 255, 0.04);
    backdrop-filter: blur(12px);
}

.wiki-search input {
    flex: 1;
    min-width: 0;
    padding: 0.5rem 0.7rem;
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 8px;
    background: rgba(0, 0, 0, 0.4);
    color: var(--text-primary);
    font: inherit;
    font-size: 0.95rem;
}

.wiki-search input:focus {
    outline: none;
    border-color: rgba(105, 240, 174, 0.55);
    box-shadow: 0 0 0 3px rgba(105, 240, 174, 0.18);
}

.wiki-search-info {
    flex-shrink: 0;
    color: var(--text-secondary);
    font-size: 0.78rem;
    font-weight: 700;
    letter-spacing: 0.04em;
    text-transform: uppercase;
}

.wiki-highlight {
    background: rgba(255, 224, 102, 0.28);
    color: inherit;
    padding: 0 0.15em;
    border-radius: 3px;
    box-shadow: 0 0 0 1px rgba(255, 224, 102, 0.42);
}

[data-searchable][hidden] {
    display: none !important;
}

.wiki-table {
    width: 100%;
    border-collapse: collapse;
    margin: 0.75rem 0;
    font-size: 0.88rem;
}

.wiki-table th,
.wiki-table td {
    padding: 0.55rem 0.7rem;
    border-bottom: 1px solid rgba(160, 180, 192, 0.14);
    text-align: left;
    vertical-align: top;
}

.wiki-table th {
    background: rgba(160, 180, 192, 0.08);
    color: var(--text-secondary);
    font-weight: 800;
    font-size: 0.74rem;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.wiki-table tr:hover td {
    background: rgba(160, 180, 192, 0.04);
}

.wiki-table code {
    font-size: 0.82rem;
    padding: 0.1rem 0.32rem;
    border-radius: 4px;
    background: rgba(255, 255, 255, 0.06);
}

.table-wrap {
    overflow-x: auto;
    margin: 0.5rem 0 1rem;
}

/* ============================================================
   KaktusClicker Kauf-Optimizer
   ============================================================ */

.wiki-optimizer {
    margin-top: 3rem;
    padding: 1.6rem clamp(1.2rem, 3vw, 2.2rem) 1.8rem;
    border: 1px solid rgba(105, 240, 174, 0.32);
    border-radius: 14px;
    background:
        radial-gradient(ellipse 80% 50% at 20% 0%, rgba(105, 240, 174, 0.14), transparent 60%),
        radial-gradient(ellipse 70% 50% at 90% 100%, rgba(99, 216, 255, 0.1), transparent 60%),
        linear-gradient(180deg, rgba(8, 28, 14, 0.92), rgba(2, 14, 8, 0.96));
    box-shadow: 0 0 36px rgba(105, 240, 174, 0.12), inset 0 1px rgba(255, 255, 255, 0.04);
}

.opt-head { display: grid; gap: 0.4rem; margin-bottom: 1rem; }
.opt-kicker {
    margin: 0;
    font-size: 0.74rem;
    font-weight: 800;
    letter-spacing: 0.22em;
    text-transform: uppercase;
    color: #b8ffd6;
}
.wiki-optimizer h2 {
    margin: 0;
    font-size: clamp(1.5rem, 3.5vw, 2.2rem);
    font-weight: 950;
    background: linear-gradient(90deg, #b8ffd6, #6ee7ff);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}
.opt-sub {
    margin: 0;
    color: var(--text-secondary);
    line-height: 1.55;
    font-size: 0.96rem;
}

.opt-status {
    margin: 0 0 0.8rem;
    padding: 0.6rem 0.85rem;
    border-radius: 8px;
    font-size: 0.86rem;
    font-weight: 700;
    border: 1px solid rgba(255, 255, 255, 0.08);
    background: rgba(255, 255, 255, 0.04);
}
.opt-status[data-type="info"] { color: var(--text-secondary); }
.opt-status[data-type="ok"] {
    color: #6ee7ff;
    border-color: rgba(110, 231, 255, 0.34);
    background: rgba(110, 231, 255, 0.08);
}
.opt-status[data-type="warn"] {
    color: #ffe066;
    border-color: rgba(255, 224, 102, 0.34);
    background: rgba(255, 224, 102, 0.08);
}

.opt-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-bottom: 1rem;
}
.opt-actions button {
    padding: 0.55rem 0.95rem;
    border: 1px solid rgba(105, 240, 174, 0.4);
    border-radius: 999px;
    background: rgba(105, 240, 174, 0.12);
    color: #b8ffd6;
    cursor: pointer;
    font: inherit;
    font-size: 0.84rem;
    font-weight: 850;
    letter-spacing: 0.02em;
    transition: background 160ms ease, transform 160ms ease, border-color 160ms ease;
}
.opt-actions button:hover {
    background: rgba(105, 240, 174, 0.22);
    transform: translateY(-1px);
    border-color: #a8ffd6;
}

.opt-result-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem;
    flex-wrap: wrap;
    margin: 0.4rem 0 0.85rem;
}
.opt-result-head h3 {
    margin: 0;
    font-size: 1.2rem;
    font-weight: 900;
    color: #f0fff5;
}
.opt-source-pill {
    padding: 0.32rem 0.7rem;
    border-radius: 999px;
    font-size: 0.7rem;
    font-weight: 800;
    letter-spacing: 0.1em;
    text-transform: uppercase;
}
.opt-source-cloud {
    background: rgba(110, 231, 255, 0.16);
    color: #9ef0ff;
    border: 1px solid rgba(110, 231, 255, 0.4);
}
.opt-source-manual {
    background: rgba(255, 224, 102, 0.16);
    color: #ffe066;
    border: 1px solid rgba(255, 224, 102, 0.4);
}

.opt-empty {
    margin: 0;
    padding: 1.4rem;
    border: 1px dashed rgba(255, 255, 255, 0.18);
    border-radius: 10px;
    color: var(--text-secondary);
    text-align: center;
}

.opt-plan {
    list-style: none;
    margin: 0;
    padding: 0;
    display: grid;
    gap: 0.5rem;
}

.opt-plan-row {
    display: grid;
    grid-template-columns: auto auto 1fr auto auto;
    align-items: center;
    gap: 0.85rem;
    padding: 0.75rem 0.95rem;
    border: 1px solid rgba(105, 240, 174, 0.18);
    border-radius: 10px;
    background:
        linear-gradient(90deg,
            rgba(105, 240, 174, calc(0.18 - var(--opt-step) * 0.012)) 0%,
            rgba(110, 231, 255, 0.04) 100%);
    transition: transform 160ms ease, border-color 160ms ease;
}
.opt-plan-row:hover {
    transform: translateX(2px);
    border-color: rgba(110, 231, 255, 0.55);
}

.opt-step-num {
    min-width: 2.5rem;
    font-size: 0.95rem;
    font-weight: 900;
    color: #b8ffd6;
    letter-spacing: 0.02em;
}
.opt-step-icon {
    width: 2rem;
    height: 2rem;
    display: grid;
    place-items: center;
    border: 1px solid rgba(105, 240, 174, 0.4);
    border-radius: 8px;
    background: rgba(8, 28, 14, 0.82);
    color: #b8ffd6;
    font-weight: 900;
    font-size: 1rem;
}
.opt-step-main { min-width: 0; display: grid; gap: 0.18rem; line-height: 1.25; }
.opt-step-main strong {
    color: #f0fff5;
    font-size: 0.98rem;
    font-weight: 900;
}
.opt-step-main small {
    color: var(--text-secondary);
    font-size: 0.78rem;
}
.opt-step-main small em {
    color: #ffe066;
    font-style: normal;
    font-weight: 700;
}

.opt-step-cost, .opt-step-roi {
    text-align: right;
    display: grid;
    line-height: 1.1;
}
.opt-step-cost b {
    color: #ffe066;
    font-size: 0.96rem;
    font-weight: 950;
}
.opt-step-cost small,
.opt-step-roi small {
    color: var(--text-secondary);
    font-size: 0.7rem;
}
.opt-step-roi b {
    color: #9ef0ff;
    font-size: 0.96rem;
    font-weight: 950;
}

.opt-disclaimer {
    margin: 1rem 0 0;
    padding: 0.7rem 0.9rem;
    border-left: 3px solid rgba(105, 240, 174, 0.4);
    background: rgba(8, 28, 14, 0.4);
    border-radius: 4px;
    color: var(--text-secondary);
    font-size: 0.8rem;
    line-height: 1.55;
}
.opt-disclaimer strong { color: #b8ffd6; font-weight: 850; }

/* --- Manueller Modus --- */

.opt-manual {
    margin-top: 1.2rem;
    padding: 1.1rem;
    border: 1px solid rgba(255, 224, 102, 0.28);
    border-radius: 12px;
    background: rgba(28, 22, 4, 0.42);
}
.opt-manual-intro {
    margin: 0 0 0.85rem;
    color: var(--text-secondary);
    font-size: 0.88rem;
}
.opt-manual-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(min(14rem, 100%), 1fr));
    gap: 0.5rem;
}
.opt-manual-field {
    display: grid;
    grid-template-columns: auto 1fr auto;
    align-items: center;
    gap: 0.55rem;
    padding: 0.5rem 0.7rem;
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 8px;
    background: rgba(0, 0, 0, 0.32);
}
.opt-manual-icon {
    width: 1.6rem;
    height: 1.6rem;
    display: grid;
    place-items: center;
    border: 1px solid rgba(255, 224, 102, 0.36);
    border-radius: 6px;
    background: rgba(28, 22, 4, 0.82);
    color: #ffe066;
    font-weight: 900;
}
.opt-manual-name {
    font-weight: 800;
    font-size: 0.86rem;
    color: #f0fff5;
}
.opt-manual-input {
    width: 4.5rem;
    padding: 0.32rem 0.5rem;
    border: 1px solid rgba(255, 255, 255, 0.18);
    border-radius: 6px;
    background: rgba(0, 0, 0, 0.42);
    color: #f0fff5;
    font: inherit;
    font-weight: 800;
    text-align: right;
}

.opt-manual-upgrades {
    margin-top: 0.85rem;
    padding: 0.5rem 0.7rem;
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 8px;
    background: rgba(0, 0, 0, 0.22);
}
.opt-manual-upgrades summary {
    cursor: pointer;
    font-weight: 800;
    color: #b8ffd6;
    font-size: 0.86rem;
}
.opt-manual-upgrade-grid {
    margin-top: 0.6rem;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(min(14rem, 100%), 1fr));
    gap: 0.3rem;
}
.opt-manual-upgrade-row {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: var(--text-secondary);
    font-size: 0.82rem;
}
.opt-manual-upgrade-row em {
    color: #ffe066;
    font-style: normal;
    font-weight: 700;
}

.opt-manual-run {
    margin-top: 1rem;
    padding: 0.7rem 1.2rem;
    border: 0;
    border-radius: 999px;
    background: linear-gradient(90deg, #b8ffd6, #6ee7ff);
    color: #062014;
    cursor: pointer;
    font: inherit;
    font-size: 0.95rem;
    font-weight: 950;
    letter-spacing: 0.02em;
    box-shadow: 0 0 1rem rgba(110, 231, 255, 0.35);
    transition: transform 160ms ease, box-shadow 160ms ease;
}
.opt-manual-run:hover {
    transform: translateY(-1px) scale(1.02);
    box-shadow: 0 0 1.6rem rgba(110, 231, 255, 0.55);
}

@media (max-width: 600px) {
    .opt-plan-row {
        grid-template-columns: auto 1fr auto;
        grid-template-areas:
            "num main main"
            "icon cost roi";
        row-gap: 0.4rem;
    }
    .opt-step-num { grid-area: num; }
    .opt-step-icon { grid-area: icon; }
    .opt-step-main { grid-area: main; }
    .opt-step-cost { grid-area: cost; text-align: left; }
    .opt-step-roi { grid-area: roi; }
}