/*
 * site.css — the whole design layer of rogr.cz.
 * ROGR design language (logomanual): blue #008cd2 as the accent, dark grey
 * #3c4141, mono grey #9b9b9b, Open Sans, negative logotype on dark surfaces.
 * Dark only. No framework, no JavaScript, no inline styles (strict CSP).
 * Copied from the Smart Mirror product web and owned by this repo — every
 * ROGR project carries its own copy of the design, nothing is shared.
 *
 * Contrast bar: text ≥ 4.5:1, UI edges and focus ≥ 3:1 against the surface
 * they sit on (WCAG 2.2 AA). Buttons rest on #0079b8 (4.74:1 with white);
 * the brand blue #008cd2 is kept for large marks and hover states only.
 */

@font-face {
  font-family: "Open Sans";
  font-style: normal;
  font-weight: 300 800;
  font-display: swap;
  src: url("../fonts/open-sans-latin-ext.woff2") format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: "Open Sans";
  font-style: normal;
  font-weight: 300 800;
  font-display: swap;
  src: url("../fonts/open-sans-latin.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

:root {
  color-scheme: dark;
  --blue: #008cd2;
  --blue-btn: #0079b8;
  --blue-hover: #006fa6;
  --blue-active: #00618f;
  --blue-light: #3fa9e0;
  --grey: #3c4141;
  --grey-light: #9b9b9b;
  --line: #4a5050;
  --ctrl-line: #767c7c;
  --bg: #1f2324;
  --surface: #2a2f30;
  --surface-2: #262b2c;
  --field: #1a1e1f;
  --ink: #eceeee;
  --ink-strong: #ffffff;
  --ink-soft: #c4c7c7;
  --muted: var(--grey-light);
  --focus: #6cc4f0;
  --ok: #75b798;
  --ok-bg: #0f2a1c;
  --err: #ea868f;
  --err-bg: #2c0b0e;
  --radius: 6px;
  --gutter: clamp(16px, 4vw, 40px);
  --nav-h: 3.75rem;
  --block-y: clamp(3rem, 7vw, 5.5rem);
  --font: "Open Sans", system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}

/* ---------- base ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-padding-top: calc(var(--nav-h) + 1rem); }
@media (prefers-reduced-motion: no-preference) { html { scroll-behavior: smooth; } }
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font);
  font-size: 1rem;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}
main { flex: 1 0 auto; }
main:focus { outline: none; }
h1, h2, h3 { color: var(--ink-strong); line-height: 1.2; margin: 0; text-wrap: balance; }
h1 { font-size: clamp(2.1rem, 5vw, 3.4rem); font-weight: 300; letter-spacing: .01em; }
h1 b { font-weight: 700; }
h2 { font-size: clamp(1.6rem, 3vw, 2rem); font-weight: 300; letter-spacing: .01em; margin-bottom: 1.75rem; }
h3 { font-size: 1.05rem; font-weight: 600; }
p { margin: 0 0 1rem; }
/* Fewer orphaned last words in running text (progressive enhancement). */
p, li, .lead { text-wrap: pretty; }
a { color: var(--blue-light); text-decoration: none; }
a:hover { text-decoration: underline; }
img { max-width: 100%; height: auto; }
.icon { width: 24px; height: 24px; flex: none; }
.muted { color: var(--muted); }
.visually-hidden { position: absolute !important; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }

/* One focus treatment for everything interactive. */
a:focus-visible, button:focus-visible, input:focus-visible, textarea:focus-visible, [tabindex]:focus-visible {
  outline: 2px solid var(--focus);
  outline-offset: 2px;
  box-shadow: none;
}

/* ---------- skip link ---------- */
.skip { position: absolute; left: -9999px; top: 0; z-index: 100; background: var(--blue-btn); color: #fff; font-weight: 600; font-size: .875rem; padding: .625rem 1.125rem; border-radius: var(--radius); }
.skip:focus { left: var(--gutter); top: .75rem; }

/* ---------- header / navigation (no JS: wraps on phones) ---------- */
.site-head {
  background: var(--surface);
  border-bottom: 1px solid var(--grey);
  position: sticky;
  top: 0;
  z-index: 50;
}
.nav {
  max-width: 72rem;
  margin: 0 auto;
  padding: .625rem var(--gutter);
  display: flex;
  align-items: center;
  gap: 1.5rem;
  min-height: var(--nav-h);
}
.brand { display: flex; align-items: center; color: var(--ink); text-decoration: none; padding: .25rem 0; }
.brand:hover { text-decoration: none; }
.brand-mark { display: block; height: 26px; width: auto; }
.nav-links { list-style: none; margin: 0; padding: 0; display: flex; gap: .25rem; flex: 1 1 auto; }
.nav-links a { display: inline-block; color: var(--ink-soft); padding: .5rem .75rem; border-radius: var(--radius); font-size: .9375rem; white-space: nowrap; }
.nav-links a:hover { background: rgba(255, 255, 255, .06); color: #fff; text-decoration: none; }
.nav-actions { display: flex; align-items: center; gap: .5rem; }
.lang { display: inline-flex; align-items: center; justify-content: center; min-width: 2.5rem; min-height: 36px; padding: .5rem .625rem; border: 1px solid var(--ctrl-line); border-radius: var(--radius); color: var(--ink-soft); font-size: .875rem; font-weight: 600; letter-spacing: .04em; }
.lang:hover { border-color: var(--blue); color: #fff; text-decoration: none; }

@media (max-width: 959.98px) {
  .site-head { position: static; }
  html { scroll-padding-top: 1rem; }
  .nav { flex-wrap: wrap; gap: .5rem .75rem; padding-block: .75rem; }
  .brand { flex: 1 1 auto; }
  .nav-actions { order: 2; }
  .nav-links { order: 3; flex-basis: 100%; flex-wrap: wrap; gap: 0; margin-top: .25rem; border-top: 1px solid var(--grey); padding-top: .25rem; }
  .nav-links a { padding: .75rem .75rem; min-height: 44px; }
  .btn-sm, .lang { min-height: 44px; }
}

/* ---------- buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: .5rem;
  font: inherit;
  font-weight: 600;
  line-height: 1.2;
  padding: .75rem 1.25rem;
  min-height: 44px;
  border-radius: var(--radius);
  border: 1px solid transparent;
  cursor: pointer;
  text-decoration: none;
  white-space: nowrap;
}
.btn:hover { text-decoration: none; }
.btn-primary { background: var(--blue-btn); border-color: var(--blue-btn); color: #fff; }
.btn-primary:hover { background: var(--blue-hover); border-color: var(--blue-hover); }
.btn-primary:active { background: var(--blue-active); border-color: var(--blue-active); }
.btn-ghost { background: transparent; border-color: var(--ctrl-line); color: var(--ink-soft); }
.btn-ghost:hover { background: var(--grey); border-color: var(--grey); color: #fff; }
.btn-lg { font-size: 1.125rem; padding: .875rem 1.75rem; min-height: 52px; }
.btn-sm { font-size: .875rem; padding: .5rem .875rem; min-height: 36px; }

/* ---------- page containers ---------- */
.block { max-width: 72rem; margin: 0 auto; padding: var(--block-y) var(--gutter); border-top: 1px solid var(--grey); }
.section-lead { color: var(--muted); font-size: 1.05rem; max-width: 46em; margin: -1rem 0 2rem; }
.page-head { max-width: 72rem; margin: 0 auto; padding: clamp(2.5rem, 6vw, 4rem) var(--gutter) 1.5rem; }
.page-head h1 { font-size: clamp(1.9rem, 4vw, 2.6rem); }
.page-head .lead { margin-top: .75rem; }

/* ---------- hero ---------- */
.hero {
  max-width: 72rem;
  margin: 0 auto;
  padding: clamp(3.5rem, 9vw, 7rem) var(--gutter) clamp(2.5rem, 6vw, 4rem);
}
.hero-text { max-width: 44rem; }
.lead { font-size: 1.2rem; color: var(--ink-soft); max-width: 34em; margin: 1.5rem 0 0; font-weight: 300; }
.cta-row { display: flex; flex-wrap: wrap; gap: .75rem; margin-top: 2rem; }
.facts {
  list-style: none;
  margin: clamp(2.5rem, 6vw, 4rem) 0 0;
  padding: 1.25rem 0 0;
  border-top: 1px solid var(--grey);
  display: flex;
  flex-wrap: wrap;
  gap: .5rem 2.5rem;
  color: var(--muted);
  font-size: .9375rem;
}
.facts li { display: flex; align-items: center; gap: .625rem; }
.facts li::before { content: ""; width: .5rem; height: .5rem; border-radius: 50%; background: var(--blue); flex: none; }
@media (max-width: 575.98px) {
  .cta-row .btn { flex: 1 1 100%; }
}

/* ---------- cards ---------- */
.cards { display: grid; gap: 1rem; }
.cards-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 1.5rem 1.5rem 1.375rem; min-width: 0; display: flex; flex-direction: column; }
.card h3 { margin-bottom: .5rem; font-size: 1.125rem; }
.card p { color: var(--muted); font-size: .9375rem; margin: 0; }
.card-icon { display: inline-flex; color: var(--blue-light); margin-bottom: 1rem; }
.card-icon .icon { width: 28px; height: 28px; }
.card-list { list-style: none; margin: 1rem 0 0; padding: 0; }
.card-list li { position: relative; padding-left: 1.125rem; color: var(--ink-soft); font-size: .9375rem; margin-bottom: .4rem; }
.card-list li::before { content: ""; position: absolute; left: 0; top: .6em; width: .375rem; height: .375rem; border-radius: 50%; background: var(--blue); }
.card-link { display: inline-flex; align-items: center; gap: .375rem; margin-top: auto; padding-top: 1.25rem; font-weight: 600; }
.card-link .icon { width: 18px; height: 18px; }
@media (max-width: 991.98px) { .cards-3 { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 639.98px) { .cards-3 { grid-template-columns: 1fr; } }

/* ---------- steps (a real sequence, so the numbers carry meaning) ---------- */
.steps { list-style: none; counter-reset: step; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 1rem; }
.steps li { counter-increment: step; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 1.25rem 1.375rem; min-width: 0; }
.steps li::before { content: counter(step); display: block; font-size: 2.25rem; font-weight: 200; color: var(--blue); line-height: 1; margin-bottom: .75rem; }
.steps h3 { margin-bottom: .5rem; }
.steps p { color: var(--muted); font-size: .9375rem; margin: 0; }
@media (max-width: 991.98px) { .steps { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 639.98px) { .steps { grid-template-columns: 1fr; } }

.collab { margin-top: 2rem; padding: 1.25rem 1.5rem; background: var(--surface-2); border: 1px solid var(--line); border-radius: var(--radius); display: flex; flex-wrap: wrap; gap: .75rem 2rem; align-items: center; }
.collab h3 { font-size: .8125rem; text-transform: uppercase; letter-spacing: .12em; color: var(--muted); margin: 0; }
.collab ul { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: .5rem 2rem; color: var(--ink-soft); }
.collab li { display: flex; align-items: center; gap: .625rem; }
.collab li::before { content: ""; width: .375rem; height: .375rem; border-radius: 50%; background: var(--blue); flex: none; }

/* ---------- technologies ---------- */
.tech { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: .625rem; }
.tech li { padding: .5rem .875rem; border: 1px solid var(--line); border-radius: 999px; background: var(--surface); color: var(--ink-soft); font-size: .9375rem; }

/* ---------- references ---------- */
.ref-period { display: block; color: var(--muted); font-size: .8125rem; letter-spacing: .06em; text-transform: uppercase; margin-bottom: .5rem; }

/* ---------- about ---------- */
.about { display: grid; grid-template-columns: minmax(0, 2fr) minmax(0, 3fr); gap: 2.5rem 4rem; align-items: start; }
.monogram { aspect-ratio: 4 / 5; max-width: 20rem; background: var(--surface-2); border: 1px solid var(--line); border-radius: var(--radius); display: grid; place-items: center; font-size: 3.5rem; font-weight: 200; letter-spacing: .06em; color: var(--blue-light); }
.about-photo { display: block; width: 100%; max-width: 20rem; aspect-ratio: 4 / 5; object-fit: cover; border-radius: var(--radius); border: 1px solid var(--line); }
.about-name { font-size: 1.25rem; font-weight: 600; color: var(--ink-strong); margin: 0; }
.about-role { color: var(--muted); margin: 0 0 1rem; }
.about-text { color: var(--ink-soft); max-width: 40em; }
.principles { list-style: none; margin: 1.5rem 0 0; padding: 0; display: grid; gap: .75rem; }
.principles li { display: flex; gap: .75rem; align-items: flex-start; color: var(--ink-soft); }
.principles .icon { color: var(--blue-light); width: 20px; height: 20px; margin-top: .2rem; }
@media (max-width: 767.98px) {
  .about { grid-template-columns: 1fr; }
  .monogram, .about-photo { max-width: 14rem; }
}

/* ---------- contact band ---------- */
.cta-band { max-width: 72rem; margin: 0 auto; padding: 0 var(--gutter) var(--block-y); }
.cta-inner { background: var(--surface-2); border: 1px solid var(--line); border-radius: var(--radius); padding: clamp(1.5rem, 4vw, 2.5rem); display: grid; grid-template-columns: minmax(0, 3fr) minmax(0, 2fr); gap: 1.5rem 3rem; align-items: center; }
.cta-inner h2 { margin-bottom: .5rem; }
.cta-inner p { color: var(--ink-soft); margin: 0; max-width: 36em; }
.cta-actions { display: flex; flex-direction: column; gap: .75rem; align-items: flex-start; }
.cta-actions .contact-line { display: inline-flex; align-items: center; gap: .5rem; color: var(--ink); padding: .25rem 0; }
.cta-actions .contact-line .icon { color: var(--blue-light); width: 20px; height: 20px; }
@media (max-width: 767.98px) { .cta-inner { grid-template-columns: 1fr; } }

/* ---------- contact page ---------- */
.contact { max-width: 72rem; margin: 0 auto; padding: 0 var(--gutter) var(--block-y); display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); gap: 2.5rem 4rem; align-items: start; }
.form { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 1.5rem; }
.form-required { color: var(--muted); font-size: .8125rem; margin-bottom: 1rem; }
.field { margin-bottom: 1.125rem; }
.field label { display: block; color: var(--muted); font-size: .8125rem; margin-bottom: .3rem; }
.field label span[aria-hidden] { color: var(--blue-light); }
input[type="text"], input[type="email"], input[type="tel"], textarea {
  display: block;
  width: 100%;
  font: inherit;
  color: var(--ink);
  background: var(--field);
  border: 1px solid var(--ctrl-line);
  border-radius: var(--radius);
  padding: .625rem .75rem;
  min-height: 44px;
}
textarea { resize: vertical; min-height: 8rem; }
input::placeholder, textarea::placeholder { color: #8a8f8f; }
input:focus, textarea:focus { border-color: var(--blue); }
.is-invalid { border-color: var(--err); }
.invalid-feedback { color: var(--err); font-size: .875rem; margin: .35rem 0 0; }
.form-text { color: var(--muted); font-size: .8125rem; margin-top: .35rem; }
.form-privacy { color: var(--muted); font-size: .8125rem; margin: 1rem 0 0; }
.hp { position: absolute !important; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.flash { background: var(--ok-bg); color: var(--ok); border-left: 4px solid var(--ok); border-radius: var(--radius); padding: .75rem 1rem; margin-bottom: 1rem; }
.flash a { color: inherit; text-decoration: underline; }
.alert { background: var(--err-bg); color: var(--err); border-left: 4px solid var(--err); border-radius: var(--radius); padding: .75rem 1rem; margin-bottom: 1rem; }
.aside-title { font-size: 1.05rem; font-weight: 600; margin-bottom: 1rem; } /* h2 for the outline, h3 look */
.contact-direct { line-height: 1.7; }
.contact-direct p { margin: 0 0 .5rem; }
.contact-direct a, .contact-direct .contact-line { display: inline-flex; align-items: center; gap: .5rem; padding: .15rem 0; min-height: 44px; }
.contact-direct .contact-line { color: var(--ink-soft); }
.contact-direct .icon { color: var(--blue-light); width: 20px; height: 20px; }
.contact-company { margin-top: 1.75rem; padding-top: 1.25rem; border-top: 1px solid var(--grey); color: var(--muted); font-size: .9375rem; }
.contact-company p { margin: 0 0 .35rem; }
.next-title { margin-top: 1.75rem; padding-top: 1.25rem; border-top: 1px solid var(--grey); }
.next-steps { list-style: none; counter-reset: next; margin: 1rem 0 0; padding: 0; display: grid; gap: .625rem; }
.next-steps li { counter-increment: next; display: flex; gap: .75rem; color: var(--ink-soft); }
.next-steps li::before { content: counter(next); flex: none; width: 1.5rem; height: 1.5rem; border-radius: 50%; border: 1px solid var(--blue); color: var(--blue-light); font-size: .8125rem; display: grid; place-items: center; }
@media (max-width: 991.98px) { .contact { grid-template-columns: 1fr; } }

/* ---------- not found ---------- */
.notfound { max-width: 72rem; margin: 0 auto; padding: clamp(3rem, 8vw, 6rem) var(--gutter); }
.notfound p { color: var(--ink-soft); max-width: 40em; }
.notfound .cta-row { margin-top: 1.5rem; }

/* ---------- footer ---------- */
.site-foot { border-top: 1px solid var(--grey); color: var(--muted); font-size: .875rem; margin-top: 2rem; }
.foot-grid { max-width: 72rem; margin: 0 auto; padding: 2rem var(--gutter) 2.5rem; display: flex; flex-wrap: wrap; justify-content: space-between; gap: 1.5rem 3rem; }
.foot-brand { display: flex; align-items: center; gap: .625rem; color: var(--ink); margin-bottom: .5rem; }
.foot-brand img { height: 18px; width: auto; opacity: .85; }
.foot-company p, .foot-contact p { margin: 0 0 .5rem; max-width: 40em; }
.foot-contact { text-align: right; }
.foot-contact a { display: inline-flex; align-items: center; min-height: 44px; }
.foot-copy { margin-top: .75rem; }
@media (max-width: 639.98px) { .foot-contact { text-align: left; } }

/* ---------- legal pages ---------- */
.prose { max-width: 70ch; margin: 0 auto; padding: 3rem var(--gutter) 4rem; }
.prose h1 { font-size: clamp(1.8rem, 4vw, 2.4rem); margin-bottom: .5rem; }
.prose h2 { font-size: 1.25rem; font-weight: 600; margin: 2.25rem 0 .75rem; }
.prose p, .prose li { color: #d5d9d9; }
.prose ol, .prose ul { padding-left: 1.4rem; }
.prose li { margin-bottom: .5rem; }
.prose .updated { color: var(--muted); font-size: .875rem; margin-bottom: 2rem; }

/* ---------- phone/tablet tap targets (after the button rules so they win) ---------- */
@media (max-width: 959.98px) {
  .nav-actions .btn-sm { min-height: 44px; padding-block: .625rem; }
}
@media (max-width: 575.98px) {
  .nav-links { gap: 0; justify-content: space-between; }
  .nav-links a { font-size: .875rem; padding: .7rem .45rem; }
}
