/* WeCRM tanıtım sitesi: tema seçici ve koyu tema elle ayarları.
   Renk eşlemesinin büyük kısmı marketing-dark.css (tools/build_marketing_dark.mjs) içindedir. */
html { color-scheme: light; }
html[data-theme="dark"] {
    color-scheme: dark;
    --paper: #0c1410;
    --ink: #e7eeeb;
    --forest: #8fc3ab;
    --sage: #1b2621;
    --muted: #9aa8a1;
    --line: #2b3832;
}

/* ---- Tema seçici: masaüstünde tek düğme + açılır liste, mobil menüde satır içi ---- */
.theme-switch { position: relative; display: inline-flex; align-items: center; }
.theme-switch svg { width: 17px; height: 17px; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; flex-shrink: 0; }
.theme-switch-toggle { display: grid; place-items: center; width: 38px; height: 38px; padding: 0; border: 1px solid var(--line); border-radius: 50%; background: transparent; color: var(--ink); transition: background .2s, border-color .2s; }
.theme-switch-toggle:hover, .theme-switch-toggle[aria-expanded="true"] { background: var(--sage); border-color: transparent; }
.theme-glyph { display: none; }
html:not([data-theme-pref]) .theme-glyph-system,
html[data-theme-pref="system"] .theme-glyph-system,
html[data-theme-pref="light"] .theme-glyph-light,
html[data-theme-pref="dark"] .theme-glyph-dark { display: block; }
.theme-options { position: absolute; z-index: 70; top: calc(100% + 10px); right: 0; min-width: 158px; display: none; flex-direction: column; gap: 2px; padding: 6px; background: var(--paper); border: 1px solid var(--line); border-radius: 16px; box-shadow: 0 16px 40px rgb(25 45 37 / 14%); }
.theme-switch.is-open .theme-options { display: flex; }
.theme-switch-label { display: none; }
.theme-options button { display: flex; align-items: center; gap: 11px; width: 100%; min-height: 40px; padding: 0 12px; border: 0; border-radius: 10px; background: transparent; color: var(--ink); font-size: 14px; font-weight: 600; text-align: left; }
.theme-options button:hover { background: var(--sage); }
.theme-options button[aria-pressed="true"] { background: var(--ink); color: var(--paper); }
.theme-options button:focus-visible, .theme-switch-toggle:focus-visible { outline-offset: 2px; }
html[data-theme="dark"] .theme-options { box-shadow: 0 16px 40px rgb(0 0 0 / 45%); }
@media (max-width: 1200px) {
    .theme-switch-toggle { width: 34px; height: 34px; }
}
@media (max-width: 700px) {
    .theme-switch { display: block; margin-top: 10px; padding-top: 14px; border-top: 1px solid var(--line); }
    .theme-switch-toggle { display: none; }
    .theme-options { position: static; display: flex; flex-direction: row; flex-wrap: wrap; align-items: center; gap: 8px; min-width: 0; padding: 0; background: none; border: 0; border-radius: 0; box-shadow: none; }
    html[data-theme="dark"] .theme-options { box-shadow: none; }
    .theme-switch-label { display: inline; margin-right: auto; font-size: 16px; }
    .theme-options button { width: auto; min-height: 40px; padding: 0 14px; gap: 7px; border: 1px solid var(--line); border-radius: 999px; }
    .theme-options button[aria-pressed="true"] { border-color: var(--ink); }
}

/* ---- Koyu tema elle ayarları ---- */
html[data-theme="dark"] .button-coral,
html[data-theme="dark"] .button-coral:hover { color: #182b23; }
html[data-theme="dark"] .button-dark { background: var(--ink); color: var(--paper); }
html[data-theme="dark"] .button-dark:hover { background: #cfe3d8; }
html[data-theme="dark"] ::selection { color: #182b23; }

/* Mercan kapanış bandı açık temadaki gibi koyu yazıyla kalır. */
html[data-theme="dark"] .closing { color: #192d25; }
/* Ana sayfa akışında kapanış, açık temada kremden mercana açılır; koyu temada koyu yazı her
   karede okunabilsin diye zemin baştan mercandır. */
html[data-theme="dark"] .flow-ready .closing { background: var(--coral); }
html[data-theme="dark"] .closing a:focus-visible { outline-color: #192d25; }
html[data-theme="dark"] .closing .button-dark { background: #192d25; color: #f7f5ef; }
html[data-theme="dark"] .closing .button-dark:hover { background: #204b3b; }
html[data-theme="dark"] .closing-orbit span { border-color: rgb(25 45 37 / 14%); }
