/* The original two-cube identity keeps its proportions in both palettes. */
:root { color-scheme: light; --brand-blue: #4a90e2; }
.brand-on-dark { display: none; }
:root[data-theme="dark"] .brand-on-light { display: none; }
:root[data-theme="dark"] .brand-on-dark { display: block; }
.site-brand img { width: 154px; height: auto; }
.connection-hub img { width: 144px; height: auto; }
.footer-intro img { width: 154px; height: auto; }
.header-inner { gap: 20px; }
.site-brand { order: 1; }
.site-nav { order: 2; margin-left: auto; gap: 18px; }
.header-controls { order: 3; display: flex; align-items: center; gap: 8px; flex-shrink: 0; }
.theme-toggle { display: none; place-items: center; width: 44px; height: 44px; padding: 10px; border: 1px solid var(--line); border-radius: 50%; background: transparent; color: var(--ink); }
.js .theme-toggle { display: grid; }
.theme-toggle:hover { background: var(--wash); border-color: var(--blue); }
.theme-toggle svg { width: 21px; height: 21px; }
:root:not([data-theme="dark"]) .theme-icon-sun,
:root[data-theme="dark"] .theme-icon-moon { display: none; }

@media (max-width: 1100px) {
  .header-inner { min-height: 80px; flex-wrap: wrap; }
  .site-brand img { width: 140px; }
  .header-controls { order: 2; margin-left: auto; }
  .js .menu-toggle { display: block; }
  .site-nav { order: 3; width: 100%; margin-left: 0; padding-bottom: 22px; flex-wrap: wrap; }
  .js .site-nav { display: none; }
  .js .site-nav.is-open { display: flex; }
}
@media (max-width: 760px) {
  .header-inner { min-height: 76px; gap: 12px; }
  .site-brand img { width: 124px; }
  .site-nav { gap: 0; }
}

/* Dark is the default; an explicit visitor choice restores the light palette. */
:root[data-theme="dark"] {
  color-scheme: dark;
  --ink: #e9f0f7;
  --muted: #adbed0;
  --blue: #86bffc;
  --blue-dark: #b4d8ff;
  --line: #2b4359;
  --wash: #0e1d2d;
  --canvas: #0a1421;
  --surface: #142638;
  --surface-raised: #1a334a;
  --primary-button: #2467a5;
  --primary-button-hover: #1c568c;
}
:root[data-theme="dark"] body.site-body { background: var(--canvas); }
:root[data-theme="dark"] .site-header { background: #0b1725f5; border-color: var(--line); }
:root[data-theme="dark"] .site-nav > a:not(.site-button) { color: #c5d5e5; }
:root[data-theme="dark"] .site-nav > a:hover:not(.site-button),
:root[data-theme="dark"] .site-nav > a[aria-current="page"] { color: var(--blue); }
:root[data-theme="dark"] .language-switch a[aria-current="true"] { background: #1b354d; }
:root[data-theme="dark"] .home-hero { background: radial-gradient(ellipse at 90% 25%, #1a354b 0, transparent 65%), linear-gradient(115deg, #0a1421, #102135); }
:root[data-theme="dark"] .site-button:not(.button-outline):not(.button-white) { color: #fff; background: var(--primary-button); border-color: var(--primary-button); }
:root[data-theme="dark"] .site-button:not(.button-outline):not(.button-white):hover { background: var(--primary-button-hover); border-color: var(--primary-button-hover); }
:root[data-theme="dark"] .button-outline { border-color: #58738c; color: var(--ink); }
:root[data-theme="dark"] .button-outline:hover { background: var(--surface-raised); border-color: var(--blue); }
:root[data-theme="dark"] .button-white { color: #122c42; }
:root[data-theme="dark"] .skip-link { background: var(--surface); }
:root[data-theme="dark"] :is(a, button, input, select, textarea, summary, [tabindex="0"]):focus-visible { outline-color: var(--blue); }

:root[data-theme="dark"] :is(.warehouse-visual, .visual-task, .product-card, .connection-node, .connection-hub, .android-card, .integration-flow, .demo-form, .success-panel, .scan-illustration) { background: var(--surface); border-color: var(--line); box-shadow: 0 18px 45px -28px #0008; }
:root[data-theme="dark"] .warehouse-visual { box-shadow: 0 24px 65px -25px #0009; }
:root[data-theme="dark"] .visual-tabs button { background: var(--wash); color: var(--muted); }
:root[data-theme="dark"] .visual-tabs button[aria-selected="true"] { background: #203f5c; color: #c0dfff; border-color: #4b7aa3; }
:root[data-theme="dark"] :is(.visual-badge, .task-check, .app-standalone .icon-tile, .success-panel .icon-tile) { background: #1b354d; }
:root[data-theme="dark"] :is(.icon-tile, .step-number) { background: #1b354d; }
:root[data-theme="dark"] .app-scanner .icon-tile { background: #302c49; color: #c5b4ef; }
:root[data-theme="dark"] :is(.check-list, .inline-facts) { color: #c0d0e0; }
:root[data-theme="dark"] .capability-strip .icon { color: #93b4d1; }
:root[data-theme="dark"] .product-section { border-color: var(--line); }
:root[data-theme="dark"] .integration-section { background: #11283b; }
:root[data-theme="dark"] .connected-workflow { background: linear-gradient(130deg, #102235, #172e43); }
:root[data-theme="dark"] .workflow-connector span { background: #3d5c77; }
:root[data-theme="dark"] .faq-list details { border-color: var(--line); }
:root[data-theme="dark"] .cta-section { background: #163a55; }

/* Adapt the conceptual diagrams themselves, without filters on brand assets. */
:root[data-theme="dark"] #floor-fill stop { stop-color: #12283d; }
:root[data-theme="dark"] #floor-fill stop[offset="1"] { stop-color: #1a344b; }
:root[data-theme="dark"] #warehouse-grid path { stroke: #456079; }
:root[data-theme="dark"] .aisle-label { fill: #c4d6e8; }
:root[data-theme="dark"] .map-route { stroke: var(--blue); }
:root[data-theme="dark"] .map-pin circle { fill: #2467a5; }
:root[data-theme="dark"] .map-dispatch-zone { fill: #183147; stroke: #49627a; }
:root[data-theme="dark"] .map-zone-label { fill: #cfdeec; }
:root[data-theme="dark"] .scan-illustration svg g { fill: #bdd7ee; }
:root[data-theme="dark"] .scan-illustration svg > path { stroke: var(--blue); }

:root[data-theme="dark"] .site-cookies { background: #162a3e; border-color: #45617b; box-shadow: 0 12px 65px #0007; }
:root[data-theme="dark"] :is(.field input, .field select, .field textarea) { background: #0c1b2b; border-color: #49627a; color: var(--ink); }
:root[data-theme="dark"] :is(.field input, .field textarea)::placeholder { color: #9aacbe; opacity: 1; }
:root[data-theme="dark"] :is(.field input, .field select, .field textarea)[aria-invalid="true"] { border-color: #f69393; }
:root[data-theme="dark"] .field-error { color: #ffaaaa; }
:root[data-theme="dark"] .form-message { background: #3a242e; border-color: #995863; color: #ffc4c4; }
:root[data-theme="dark"] .demo-verification .altcha-challenge > div:first-child > span { color: var(--ink) !important; }
:root[data-theme="dark"] .demo-verification .altcha-button { background: var(--primary-button) !important; }
:root[data-theme="dark"] .demo-verification [role="status"] { color: var(--muted) !important; }
:root[data-theme="dark"] .demo-verification [role="status"] span[style*="#16a34a"] { color: var(--blue) !important; }
:root[data-theme="dark"] .demo-verification [role="status"] span[style*="#4A90E2"] { color: var(--blue) !important; }
:root[data-theme="dark"] .demo-verification [role="status"] span[style*="#dc2626"] { color: #ffaaaa !important; }

/* A quiet navy footer continues the site's palette in both themes. */
.site-footer { --footer-ink: #e9f0f7; --footer-muted: #adbed0; --footer-line: #2b4359; background: #0a1421; color: var(--footer-ink); border-top: 1px solid var(--footer-line); }
.footer-brand { display: inline-block; }
.site-footer :is(.footer-intro p, .footer-language, .footer-top ul, .footer-social-link, .footer-bottom, .trademark-note, .partner-heading p) { color: var(--footer-muted); }
.site-footer .partner-network { border-color: var(--footer-line); }
.site-footer .partner-card { background: #101e2e; border-color: var(--footer-line); color: var(--footer-ink); }
.site-footer .partner-region { color: #86bffc; }
.site-footer :is(.partner-card address, .partner-hours) { color: var(--footer-muted); }
.site-footer .partner-card > a:not(.partner-logo) { color: var(--footer-ink); }
.site-footer .partner-logo[href="https://zeusrfid.gr"] { background: #10263a !important; border-radius: 5px; padding: 10px 12px; }
.site-footer a:hover, .site-footer .partner-card > a:not(.partner-logo):hover { color: #86bffc; }
:root[data-theme] .site-footer :is(a, button):focus-visible { outline-color: #86bffc; }
