/* home/static/home/style.css */

@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700&family=DM+Sans:ital,opsz,wght@0,9..40,300;0,9..40,400;0,9..40,500;0,9..40,600;0,9..40,700;1,9..40,400&display=swap');

:root {
  /* existing */
  --bg: #0b0e14;
  --fg: #e6e8eb;
  --muted: #9aa4b2;

  --surface: rgba(255,255,255,0.03);
  --surface-border: rgba(255,255,255,0.08);

  --accent: #3b82f6;

  /* semantic statuses */
  --status-idle: #9aa4b2;
  --status-running: #60a5fa;
  --status-success: #34d399;
  --status-failed: #f87171;
}

* { box-sizing: border-box; }

html, body {
  height: 100%;
}

body {
  margin: 0;
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI",
               Roboto, Helvetica, Arial, sans-serif;
  color: var(--fg);
  background: var(--bg);
}

/* Top-right auth buttons */
.topbar {
  position: fixed;
  top: 0;
  right: 0;
  padding: 22px 26px;
  width: 100%;
  display: flex;
  justify-content: flex-end;
  pointer-events: none; /* keeps hero clickable; buttons re-enable */
}

.topbar__actions {
  display: flex;
  gap: 14px;
  pointer-events: auto;
}

/* Centered hero */
.hero {
  min-height: 100vh;
  display: grid;
  place-items: center;
  padding: 24px;
  text-align: center;
}

.hero__content {
  transform: translateY(10px); /* tiny optical adjustment */
}

.hero__logo {
  margin: 0;
  font-size: clamp(2.4rem, 5vw, 3.4rem);
  font-weight: 650;
  letter-spacing: 0.02em;
}

.hero__tagline {
  margin: 14px 0 0;
  font-size: clamp(1rem, 2vw, 1.15rem);
  color: var(--muted);
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 10px 18px;
  border-radius: 10px;
  text-decoration: none;
  color: var(--fg);
  font-size: 0.95rem;
  line-height: 1;
  border: 1px solid var(--btn-border);
  background: var(--btn-bg);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  transition: background 140ms ease, border-color 140ms ease, transform 140ms ease;
}

.btn:hover {
  background: var(--btn-hover);
  border-color: rgba(255,255,255,0.18);
  transform: translateY(-1px);
}

.btn:active {
  transform: translateY(0px);
}

/* Better keyboard accessibility */
.btn:focus-visible {
  outline: 2px solid rgba(255,255,255,0.35);
  outline-offset: 2px;
}

/* Auth pages */

.auth-container {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
}

.auth-title {
    font-size: 1.8rem;
    margin-bottom: 24px;
}

.auth-form {
    width: 100%;
    max-width: 340px;
    display: flex;
    flex-direction: column;
    gap: 16px;

    padding: 28px;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 12px;
    backdrop-filter: blur(6px);
}

.field {
    display: flex;
    flex-direction: column;
}

.field label {
    font-size: 0.85rem;
    color: #9aa4b2;
    margin-bottom: 6px;
}

.field input {
    font-family: inherit;
    font-size: 0.95rem;

    background: #020617;
    border: 1px solid #1e293b;
    color: #e6e8eb;

    padding: 10px 12px;
    border-radius: 6px;
}

.field input:focus {
    outline: none;
    border-color: #3b82f6;
}

.auth-title {
    font-size: 1.9rem;
    font-weight: 600;
    margin-bottom: 18px;
    text-align: center;
}

.auth-footer {
    margin-top: 18px;
    font-size: 0.85rem;
    color: #9aa4b2;
    text-align: center;
}

.auth-footer a {
    color: #e6e8eb;
    text-decoration: underline;
}

/* ===== App layout ===== */

.app-layout {
    display: flex;
    height: 100vh;
    background: #0b0e14;
    color: #e6e8eb;
}

/* ===== Sidebar ===== */

.sidebar {
    width: 260px;
    background: #0f131a;
    border-right: 1px solid #1e293b;
    display: flex;
    flex-direction: column;
}

.sidebar-header {
    padding: 20px;
    font-size: 0.95rem;
    font-weight: 600;
    color: #cbd5e1;
    border-bottom: 1px solid #1e293b;
}

.project-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.project-item {
    padding: 16px 22px;
    font-size: 0.95rem;
    font-weight: 500;
    letter-spacing: 0.01em;
    color: #9aa4b2;
    cursor: pointer;
}

.project-item:hover {
    background: rgba(255, 255, 255, 0.04);
    color: #e6e8eb;
}

.project-item.active {
    background: rgba(59, 130, 246, 0.18);
    color: #e6e8eb;
}

.project-item a {
    color: inherit;
    text-decoration: none;
    display: block;
    width: 100%;
    height: 100%;
}

.project-item + .project-item {
    border-top: 1px solid rgba(255, 255, 255, 0.04);
}

.project-item:hover {
    background: rgba(255, 255, 255, 0.06);
    color: #e6e8eb;
}

/* ===== Main content ===== */

.main-content {
    flex: 1;
    display: flex;
    flex-direction: column;
}

/* ===== Top bar ===== */

.top-bar {
  height: 56px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0 32px;
  border-bottom: 1px solid rgba(255,255,255,0.05);
  flex-shrink: 0;
}

.top-bar__title {
  font-size: 0.82rem;
  font-weight: 600;
  color: rgba(154,164,178,0.5);
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.top-bar__date {
  font-size: 0.8rem;
  color: rgba(154,164,178,0.4);
}

.sign-out {
  font-size: 0.85rem;
  color: #9aa4b2;
  text-decoration: none;
}

.sign-out:hover {
  color: #e6e8eb;
}

/* ===== Empty state ===== */

.empty-state {
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
}

.empty-state h1 {
    font-size: 2rem;
    margin-bottom: 8px;
}

.empty-state p {
    color: #9aa4b2;
    margin-bottom: 32px;
}

.empty-box {
    width: 180px;
    height: 120px;
    border: 2px dashed rgba(255, 255, 255, 0.15);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 3rem;
    color: rgba(255, 255, 255, 0.3);
}

/* ===== Upload card ===== */

.upload-card {
    max-width: 420px;
    padding: 28px;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 14px;
    backdrop-filter: blur(6px);
    text-align: center;
}

.upload-title {
    margin: 0 0 6px;
    font-size: 1.25rem;
    font-weight: 600;
}

.upload-subtitle {
    margin: 0 0 20px;
    font-size: 0.9rem;
    color: var(--muted);
}

/* ===== Upload form ===== */

.upload-form {
    display: flex;
    flex-direction: column;
    gap: 14px;
}

/* Custom file input */

.file-input {
    display: block;
}

.file-label {
    display: block;
    padding: 14px;
    border-radius: 10px;
    border: 1px dashed rgba(255, 255, 255, 0.18);
    background: rgba(255, 255, 255, 0.02);
    color: var(--fg);
    font-size: 0.9rem;
    cursor: pointer;
    transition: background 150ms ease, border-color 150ms ease;
}

.file-label:hover {
    background: rgba(255, 255, 255, 0.05);
    border-color: rgba(255, 255, 255, 0.3);
}

/* Primary button variant */

.btn.primary {
    background: rgba(59, 130, 246, 0.25);
    border-color: rgba(59, 130, 246, 0.45);
}

.btn.primary:hover {
    background: rgba(59, 130, 246, 0.35);
}

/* ===== Status & download ===== */

.upload-status {
    margin-top: 16px;
    font-size: 0.9rem;
    color: var(--muted);
}

.download-box {
    margin-top: 18px;
}

.content-center {
    flex: 1;
    display: flex;
    justify-content: center;
    align-items: center;
}

/* Tesco scraping */
.scraper-grid {
      display: grid;
      grid-template-columns: repeat(2, 320px);
      gap: 24px;
      justify-content: center;
      margin-top: 80px;
    }

.scraper-card {
  background: var(--surface);
  border: 1px solid var(--surface-border);
  border-radius: 14px;
  padding: 20px;
  backdrop-filter: blur(6px);
}
.scraper-card h3 {
  margin: 0 0 14px;
  font-size: 1.05rem;
  font-weight: 600;
}

.scraper-meta {
  display: flex;
  justify-content: space-between;
  font-size: 0.85rem;
  margin-bottom: 18px;
}

.label {
  color: var(--muted);
}

.status.idle    { color: var(--status-idle); }
.status.running { color: var(--status-running); }
.status.success { color: var(--status-success); }
.status.failed  { color: var(--status-failed); }

.scrape-btn {
  width: 100%;
}

.scrape-btn.btn.primary {
  width: 100%;
}

.scraper-card[data-status="running"] {
  box-shadow: 0 0 0 1px rgba(59,130,246,0.35);
}

.progress {
  margin: 14px 0;
}

.progress-bar {
  height: 6px;
  background: rgba(255,255,255,0.08);
  border-radius: 999px;
  overflow: hidden;
}

.progress-fill {
  height: 100%;
  width: 0%;
  background: var(--accent);
  transition: width 300ms ease;
}

.progress-text {
  margin-top: 6px;
  font-size: 0.75rem;
  color: var(--muted);
  text-align: right;
}

.scrape-btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

/* -----------------------------------
   Scraper action buttons
----------------------------------- */

.stop-btn {
    display: none;
}

.scraper-actions {
    display: flex;
    gap: 10px;
    margin-top: 16px;
}

/* Base danger button */
.btn.danger {
    background-color: #dc2626; /* red-600 */
    color: #fff;
    border: none;
}

.btn.danger:hover:not(:disabled) {
    background-color: #b91c1c; /* red-700 */
}

.btn.danger:active:not(:disabled) {
    background-color: #991b1b; /* red-800 */
}

/* Disabled state */
.btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

/* Optional: subtle pulse when running */
.scraper-card .status.running + .scraper-actions .stop-btn {
    animation: pulse-red 1.5s infinite;
}

@keyframes pulse-red {
    0% {
        box-shadow: 0 0 0 0 rgba(220, 38, 38, 0.6);
    }
    70% {
        box-shadow: 0 0 0 6px rgba(220, 38, 38, 0);
    }
    100% {
        box-shadow: 0 0 0 0 rgba(220, 38, 38, 0);
    }
}

/* ---------- Forbidden / error card ---------- */

.hero__content--card {
  width: min(560px, calc(100% - 48px));
  padding: 28px 26px;
  border-radius: 18px;
  background: var(--surface);
  border: 1px solid var(--surface-border);
  box-shadow:
    0 12px 40px rgba(0,0,0,0.35),
    inset 0 1px 0 rgba(255,255,255,0.04);
}

.hero__logo--small {
  font-size: clamp(28px, 3.2vw, 34px);
  margin: 12px 0 6px;
}

.hero__cta {
  display: flex;
  gap: 10px;
  justify-content: center;
  margin-top: 18px;
  flex-wrap: wrap;
}

.hero__hint {
  margin-top: 18px;
  color: var(--muted);
  font-size: 0.95rem;
  line-height: 1.5;
}

/* status badge */
.status-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  height: 28px;
  padding: 0 12px;
  border-radius: 999px;
  font-weight: 600;
  letter-spacing: 0.02em;
  font-size: 0.9rem;
  border: 1px solid var(--surface-border);
  background: rgba(255,255,255,0.03);
  color: var(--muted);
}

.status-badge--failed {
  color: var(--status-failed);
  border-color: rgba(248,113,113,0.35);
  background: rgba(248,113,113,0.08);
}

/* =============================================================
   LANDING PAGE
   ============================================================= */

html {
  scroll-behavior: smooth;
}

/* ── Landing nav ── */

.landing-nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 40px;
  height: 64px;
  background: rgba(11, 14, 20, 0.75);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
}

.landing-nav__logo {
  font-size: 1.05rem;
  font-weight: 600;
  color: var(--fg);
  text-decoration: none;
  letter-spacing: 0.02em;
}

.landing-nav__signin {
  font-size: 0.9rem;
  color: var(--muted);
  text-decoration: none;
  padding: 8px 16px;
  border-radius: 8px;
  border: 1px solid rgba(255,255,255,0.1);
  transition: color 140ms ease, border-color 140ms ease, background 140ms ease;
}

.landing-nav__signin:hover {
  color: var(--fg);
  border-color: rgba(255,255,255,0.2);
  background: rgba(255,255,255,0.04);
}

/* ── Sections ── */

.section {
  padding: 120px 40px;
}

.section--alt {
  /* intentionally unstyled — sections flow as one surface */
}

.section__inner {
  max-width: 1080px;
  margin: 0 auto;
}

.section__label {
  font-size: 0.85rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 16px;
}

.section__heading {
  font-size: clamp(2rem, 4vw, 2.9rem);
  font-weight: 700;
  line-height: 1.15;
  margin: 0 0 20px;
  color: var(--fg);
}

.section__lead {
  font-size: 1.15rem;
  color: var(--muted);
  line-height: 1.75;
  max-width: 620px;
  margin: 0;
}

/* ── Hero ── */

.landing-hero {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: flex-start;
  padding: 120px 40px 80px;
  max-width: 1080px;
  margin: 0 auto;
}

.landing-hero__eyebrow {
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 24px;
}

.landing-hero__title {
  font-size: clamp(2.8rem, 6.5vw, 4.8rem);
  font-weight: 700;
  line-height: 1.1;
  letter-spacing: -0.02em;
  color: var(--fg);
  margin: 0 0 28px;
  max-width: 820px;
}

.landing-hero__title em {
  font-style: normal;
  color: var(--accent);
}

.landing-hero__sub {
  font-size: 1.2rem;
  color: var(--muted);
  line-height: 1.7;
  max-width: 520px;
  margin: 0 0 44px;
}

.landing-hero__cta {
  display: flex;
  gap: 14px;
  align-items: center;
  flex-wrap: wrap;
}

.landing-hero__scroll {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: 80px;
  font-size: 0.8rem;
  color: rgba(154, 164, 178, 0.5);
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.landing-hero__scroll-line {
  width: 32px;
  height: 1px;
  background: rgba(154, 164, 178, 0.3);
}

/* ── Feature grid (automation / apps sections) ── */

.feature-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 64px;
  align-items: center;
  margin-top: 56px;
}

.feature-grid--reverse {
  direction: rtl;
}

.feature-grid--reverse > * {
  direction: ltr;
}

.feature-text__title {
  font-size: 1.3rem;
  font-weight: 600;
  color: var(--fg);
  margin: 0 0 14px;
}

.feature-text__body {
  font-size: 0.95rem;
  color: var(--muted);
  line-height: 1.8;
  margin: 0 0 28px;
}

.feature-list {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.feature-list li {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 0.9rem;
  color: var(--muted);
}

.feature-list li::before {
  content: '';
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: var(--accent);
  flex-shrink: 0;
}

.feature-visual {
  border-radius: 16px;
  background: rgba(255,255,255,0.02);
  border: 1px solid rgba(255,255,255,0.06);
  padding: 40px;
  display: flex;
  flex-direction: column;
  gap: 14px;
  min-height: 260px;
  justify-content: center;
}

.feature-visual__line {
  height: 10px;
  border-radius: 999px;
  background: rgba(255,255,255,0.06);
}

.feature-visual__line:nth-child(1) { width: 65%; background: rgba(59,130,246,0.25); }
.feature-visual__line:nth-child(2) { width: 80%; }
.feature-visual__line:nth-child(3) { width: 50%; }
.feature-visual__line:nth-child(4) { width: 70%; background: rgba(59,130,246,0.15); }
.feature-visual__line:nth-child(5) { width: 40%; }

/* ── Contact section ── */

.contact-form {
  margin-top: 48px;
  display: flex;
  flex-direction: column;
  gap: 20px;
  max-width: 580px;
}

.contact-form__row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
}

.contact-form__field {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.contact-form__field label {
  font-size: 0.82rem;
  color: var(--muted);
  font-weight: 500;
  letter-spacing: 0.02em;
}

.contact-form__field input,
.contact-form__field textarea {
  font-family: inherit;
  font-size: 0.95rem;
  background: rgba(255,255,255,0.03);
  border: 1px solid rgba(255,255,255,0.1);
  color: var(--fg);
  padding: 12px 14px;
  border-radius: 8px;
  transition: border-color 140ms ease;
  resize: none;
}

.contact-form__field input:focus,
.contact-form__field textarea:focus {
  outline: none;
  border-color: var(--accent);
}

.contact-form__field input::placeholder,
.contact-form__field textarea::placeholder {
  color: rgba(154, 164, 178, 0.4);
}

/* ── Landing footer ── */

.landing-footer {
  padding: 36px 40px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  opacity: 0.45;
}

.landing-footer__brand {
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--muted);
}

.landing-footer__copy {
  font-size: 0.82rem;
  color: rgba(154, 164, 178, 0.45);
}

/* ── Btn variants for landing ── */

.btn--primary {
  background: var(--accent);
  color: #fff;
  border-color: var(--accent);
  font-weight: 500;
}

.btn--primary:hover {
  background: #2563eb;
  border-color: #2563eb;
}

.btn--ghost {
  background: transparent;
  border-color: rgba(255,255,255,0.12);
  color: var(--fg);
}

.btn--ghost:hover {
  background: rgba(255,255,255,0.04);
  border-color: rgba(255,255,255,0.2);
}

/* =============================================================
   DASHBOARD (logged-in)
   ============================================================= */

.sidebar__logo {
  padding: 0 20px;
  height: 64px;
  display: flex;
  align-items: center;
  gap: 10px;
  border-bottom: 1px solid rgba(255,255,255,0.06);
  font-size: 0.9rem;
  font-weight: 700;
  color: var(--fg);
  letter-spacing: 0.02em;
  flex-shrink: 0;
}

.sidebar__logo-mark {
  width: 26px;
  height: 26px;
  border-radius: 7px;
  background: var(--accent);
  color: #fff;
  font-size: 0.8rem;
  font-weight: 800;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  letter-spacing: 0;
}

.sidebar__nav {
  flex: 1;
  overflow-y: auto;
  padding: 16px 0;
}

.sidebar__viewsite {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 14px 20px 6px;
  font-size: 0.8rem;
  color: rgba(154,164,178,0.4);
  text-decoration: none;
  transition: color 140ms ease;
}

.sidebar__viewsite:hover {
  color: var(--muted);
}

.sidebar__section-label {
  padding: 8px 20px 4px;
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: rgba(154,164,178,0.5);
}

.sidebar__footer {
  padding: 14px 20px;
  border-top: 1px solid rgba(255,255,255,0.06);
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-shrink: 0;
  gap: 10px;
}

.sidebar__user {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
}

.sidebar__avatar {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: rgba(59,130,246,0.18);
  border: 1px solid rgba(59,130,246,0.3);
  color: var(--accent);
  font-size: 0.75rem;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.sidebar__username {
  font-size: 0.82rem;
  color: var(--muted);
  font-weight: 500;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.sidebar__signout {
  font-size: 0.8rem;
  color: rgba(154,164,178,0.5);
  text-decoration: none;
  background: none;
  border: none;
  padding: 0;
  cursor: pointer;
  font-family: inherit;
  transition: color 140ms ease;
}

.sidebar__signout:hover {
  color: var(--fg);
}

/* ── Dashboard greeting ── */

.dashboard-greeting {
  padding: 44px 32px 36px;
}

.dashboard-greeting__time {
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--accent);
  margin: 0 0 12px;
  opacity: 0.8;
}

.dashboard-greeting__title {
  font-size: clamp(1.8rem, 3.5vw, 2.4rem);
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--fg);
  margin: 0 0 10px;
}

.dashboard-greeting__sub {
  font-size: 0.9rem;
  color: rgba(154,164,178,0.6);
  margin: 0;
}

.dashboard-divider {
  height: 1px;
  background: linear-gradient(to right, rgba(255,255,255,0.07) 0%, rgba(255,255,255,0) 80%);
  margin: 0 32px;
}

/* ── Project cards ── */

.project-cards-section {
  padding: 32px 32px 40px;
}

.project-cards-section__heading {
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: rgba(154,164,178,0.4);
  margin: 0 0 18px;
}

.project-cards {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 14px;
}

.project-card {
  background: rgba(255,255,255,0.02);
  border: 1px solid rgba(255,255,255,0.07);
  border-left: 2px solid rgba(59,130,246,0.25);
  border-radius: 10px;
  padding: 18px 20px;
  text-decoration: none;
  display: flex;
  flex-direction: column;
  gap: 8px;
  transition: background 150ms ease, border-color 150ms ease, border-left-color 150ms ease, transform 150ms ease;
}

.project-card:hover {
  background: rgba(255,255,255,0.04);
  border-color: rgba(255,255,255,0.1);
  border-left-color: var(--accent);
  transform: translateY(-2px);
}

.project-card__header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 4px;
}

.project-card__initial {
  width: 30px;
  height: 30px;
  border-radius: 8px;
  background: rgba(59,130,246,0.12);
  border: 1px solid rgba(59,130,246,0.2);
  color: var(--accent);
  font-size: 0.8rem;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
}

.project-card__name {
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--fg);
}

.project-card__slug {
  font-size: 0.75rem;
  color: rgba(154,164,178,0.4);
  font-family: 'SF Mono', 'Fira Code', monospace;
}

.project-card__arrow {
  font-size: 0.85rem;
  color: rgba(154,164,178,0.25);
  transition: color 150ms ease, transform 150ms ease;
}

.project-card:hover .project-card__arrow {
  color: var(--accent);
  transform: translateX(3px);
}

/* ── Dashboard empty state ── */

.dashboard-empty {
  padding: 40px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.dashboard-empty__box {
  margin-top: 16px;
  padding: 32px;
  border-radius: 12px;
  border: 1px dashed rgba(255,255,255,0.1);
  display: inline-flex;
  align-items: center;
  gap: 12px;
  font-size: 0.9rem;
  color: rgba(154,164,178,0.4);
  max-width: 360px;
}

/* ── Login page error state ── */

.auth-error {
  font-size: 0.85rem;
  color: var(--status-failed);
  padding: 10px 12px;
  background: rgba(248,113,113,0.08);
  border: 1px solid rgba(248,113,113,0.2);
  border-radius: 6px;
  display: none;
}

.auth-error.visible {
  display: block;
}

.auth-loading {
  opacity: 0.6;
  pointer-events: none;
}

/* =============================================================
   SERVICE CARDS  (landing page)
   ============================================================= */

.service-cards {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
  margin-top: 48px;
}

.service-card {
  display: flex;
  flex-direction: column;
  gap: 14px;
  padding: 40px;
  border-radius: 16px;
  background: rgba(255,255,255,0.02);
  border: 1px solid rgba(255,255,255,0.07);
  text-decoration: none;
  color: inherit;
  transition: background 160ms ease, border-color 160ms ease, transform 160ms ease;
}

.service-card:hover {
  background: rgba(255,255,255,0.04);
  border-color: rgba(255,255,255,0.13);
  transform: translateY(-3px);
}

.service-card__icon {
  width: 40px;
  height: 40px;
  border-radius: 10px;
  background: rgba(59,130,246,0.1);
  border: 1px solid rgba(59,130,246,0.2);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--accent);
}

.service-card__title {
  font-size: 1.25rem;
  font-weight: 600;
  color: var(--fg);
  margin: 0;
}

.service-card__body {
  font-size: 1rem;
  color: var(--muted);
  line-height: 1.75;
  margin: 0;
  flex: 1;
}

.service-card__link {
  font-size: 0.85rem;
  font-weight: 500;
  color: var(--accent);
  margin-top: 4px;
  transition: letter-spacing 160ms ease;
}

.service-card:hover .service-card__link {
  letter-spacing: 0.02em;
}

/* =============================================================
   DETAIL PAGES  (/automation/, /apps/)
   ============================================================= */

.detail-hero {
  padding: 140px 40px 72px;
}

.detail-back {
  font-size: 0.85rem;
  color: var(--muted);
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  transition: color 140ms ease;
}

.detail-back:hover {
  color: var(--fg);
}

.detail-hero__title {
  font-size: clamp(2.6rem, 5.5vw, 4rem);
  font-weight: 700;
  letter-spacing: -0.02em;
  line-height: 1.1;
  color: var(--fg);
  margin: 8px 0 20px;
}

.detail-hero__sub {
  font-size: 1.05rem;
  color: var(--muted);
  line-height: 1.75;
  max-width: 560px;
  margin: 0;
}

/* two-column layout for the "what it means" section */
.detail-grid {
  display: grid;
  grid-template-columns: 1fr 240px;
  gap: 64px;
  align-items: start;
}

.detail-section__heading {
  font-size: 1.5rem;
  font-weight: 600;
  color: var(--fg);
  margin: 0 0 18px;
}

.detail-section__body {
  font-size: 1.1rem;
  color: var(--muted);
  line-height: 1.85;
  margin: 0 0 20px;
}

.detail-section__body:last-child {
  margin-bottom: 0;
}

.detail-grid__side {
  display: flex;
  flex-direction: column;
  gap: 24px;
  padding-top: 4px;
}

.detail-stat {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.detail-stat__number {
  font-size: 2.4rem;
  font-weight: 700;
  color: var(--accent);
  letter-spacing: -0.02em;
}

.detail-stat__label {
  font-size: 0.95rem;
  color: rgba(154,164,178,0.6);
  letter-spacing: 0.02em;
}

/* items list */
.detail-items {
  display: flex;
  flex-direction: column;
  gap: 44px;
  margin-top: 56px;
}

.detail-item {
  display: flex;
  gap: 24px;
}

.detail-item__icon {
  width: 42px;
  height: 42px;
  border-radius: 8px;
  background: rgba(59,130,246,0.08);
  border: 1px solid rgba(59,130,246,0.15);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--accent);
  flex-shrink: 0;
  margin-top: 2px;
}

.detail-item__title {
  font-size: 1.2rem;
  font-weight: 600;
  color: var(--fg);
  margin: 0 0 8px;
}

.detail-item__body {
  font-size: 1.05rem;
  color: var(--muted);
  line-height: 1.8;
  margin: 0;
}

/* CTA block */
.detail-cta {
  text-align: center;
  max-width: 560px;
  margin: 0 auto;
}

.detail-cta__heading {
  font-size: 2rem;
  font-weight: 700;
  color: var(--fg);
  margin: 0 0 14px;
}

.detail-cta__sub {
  font-size: 1.1rem;
  color: var(--muted);
  line-height: 1.75;
  margin: 0 0 28px;
}

/* =============================================================
   NAV LINKS (landing)
   ============================================================= */

.landing-nav__links {
  display: flex;
  align-items: center;
  gap: 32px;
}

.landing-nav__link {
  font-size: 0.85rem;
  color: rgba(154,164,178,0.7);
  text-decoration: none;
  transition: color 140ms ease;
}

.landing-nav__link:hover {
  color: var(--fg);
}

/* =============================================================
   STATS STRIP
   ============================================================= */

.stats-strip {
  padding: 0 40px 100px;
}

.stats-strip__inner {
  max-width: 1080px;
  margin: 0 auto;
  display: flex;
  gap: 0;
  border: 1px solid rgba(255,255,255,0.06);
  border-radius: 14px;
  overflow: hidden;
}

.stats-strip__item {
  flex: 1;
  padding: 32px 36px;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.stats-strip__item + .stats-strip__item {
  border-left: 1px solid rgba(255,255,255,0.06);
}

.stats-strip__number {
  font-size: 2.3rem;
  font-weight: 700;
  color: var(--fg);
  letter-spacing: -0.02em;
  line-height: 1;
}

.stats-strip__label {
  font-size: 0.92rem;
  color: rgba(154,164,178,0.55);
  line-height: 1.4;
}

/* =============================================================
   REFERENCES SECTION
   ============================================================= */

.reference-cards {
  display: flex;
  flex-direction: column;
  gap: 2px;
  margin-top: 52px;
}

.reference-card {
  border-radius: 14px;
  border: 1px solid rgba(255,255,255,0.06);
  overflow: hidden;
  transition: border-color 160ms ease;
}

.reference-card:not(:first-child) {
  margin-top: 16px;
}

.reference-card:hover {
  border-color: rgba(255,255,255,0.12);
}

.reference-card__body {
  padding: 40px 48px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.reference-card__name {
  font-size: 0.82rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--accent);
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 4px;
  width: fit-content;
  transition: opacity 140ms ease;
}

.reference-card__name:hover {
  opacity: 0.75;
}

.reference-card__title {
  font-size: 1.15rem;
  font-weight: 600;
  color: var(--fg);
  margin: 0;
}

.reference-card__desc {
  font-size: 1rem;
  color: var(--muted);
  line-height: 1.75;
  margin: 0;
  max-width: 640px;
}

/* =============================================================
   FOUNDER / O NÁS PAGE
   ============================================================= */

.founder-grid {
  display: grid;
  grid-template-columns: 320px 1fr;
  gap: 80px;
  align-items: start;
  margin-top: 60px;
}

.founder-photo {
  position: sticky;
  top: 96px;
}

.founder-photo__img {
  width: 100%;
  border-radius: 16px;
  display: block;
  filter: grayscale(15%);
}

.founder-photo__caption {
  margin-top: 18px;
}

.founder-photo__name {
  font-size: 1rem;
  font-weight: 600;
  color: var(--fg);
  margin: 0 0 4px;
}

.founder-photo__role {
  font-size: 0.82rem;
  color: rgba(154,164,178,0.5);
}

.founder-text {
  display: flex;
  flex-direction: column;
  gap: 22px;
  padding-top: 6px;
}

.founder-text p {
  font-size: 1.05rem;
  color: var(--muted);
  line-height: 1.85;
  margin: 0;
}

.founder-text p:first-child {
  font-size: 1.2rem;
  color: rgba(230,232,235,0.85);
}

/* =============================================================
   FOUNDER TEASER (landing page)
   ============================================================= */

.founder-teaser {
  display: grid;
  grid-template-columns: 1fr 260px;
  gap: 80px;
  align-items: center;
}

.founder-teaser__photo {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.founder-teaser__img {
  width: 100%;
  border-radius: 14px;
  display: block;
  filter: grayscale(10%);
}

.founder-teaser__caption {
  display: flex;
  flex-direction: column;
  gap: 3px;
}

/* =============================================================
   FOOTER NAV LINKS
   ============================================================= */

.landing-footer__links {
  display: flex;
  gap: 24px;
}

.landing-footer__link {
  font-size: 0.8rem;
  color: rgba(154,164,178,0.35);
  text-decoration: none;
  transition: color 140ms ease;
}

.landing-footer__link:hover {
  color: rgba(154,164,178,0.7);
}

/* =============================================================
   AFFORDABILITY CALLOUT  (aplikace detail page)
   ============================================================= */

.afford-callout {
  border-radius: 16px;
  padding: 52px 56px;
  margin: 56px 0 0;
  background: rgba(37, 99, 235, 0.05);
  border: 1px solid rgba(37, 99, 235, 0.15);
  border-left: 5px solid var(--accent);
}

.afford-callout__headline {
  font-size: clamp(1.7rem, 3.2vw, 2.4rem);
  font-weight: 700;
  color: var(--fg);
  margin: 0 0 20px;
  line-height: 1.15;
  letter-spacing: -0.01em;
}

.afford-callout__body {
  font-size: 1.15rem;
  color: var(--muted);
  line-height: 1.85;
  margin: 0;
  max-width: 700px;
}

/* =============================================================
   LANDING PAGE — WARM LIGHT THEME
   Applied via body.landing-body so the dark dashboard is unaffected.
   ============================================================= */

body.landing-body {
  --bg:             #faf8f5;
  --fg:             #18130e;
  --muted:          #3d342c;
  --surface:        #ffffff;
  --surface-border: #e8e2da;
  --accent:         #2563eb;
  font-family: 'DM Sans', -apple-system, BlinkMacSystemFont, "Segoe UI",
               Roboto, Helvetica, Arial, sans-serif;
}

/* Nav */
body.landing-body .landing-nav {
  background: rgba(250, 248, 245, 0.88);
  border-bottom: 1px solid rgba(0,0,0,0.06);
}

body.landing-body .landing-nav__logo {
  color: var(--fg);
}

body.landing-body .landing-nav__link {
  color: #3d342c;
  font-size: 1rem;
  font-weight: 500;
}

body.landing-body .landing-nav__link:hover {
  color: var(--fg);
}

body.landing-body .landing-nav__signin {
  border-color: rgba(0,0,0,0.13);
  color: var(--fg);
}

body.landing-body .landing-nav__signin:hover {
  background: rgba(0,0,0,0.04);
  border-color: rgba(0,0,0,0.22);
  color: var(--fg);
}

/* Hero scroll hint */
body.landing-body .landing-hero__scroll {
  color: #8c7b70;
}

body.landing-body .landing-hero__scroll-line {
  background: #b5a69c;
}

/* Stats strip */
body.landing-body .stats-strip__inner {
  background: #ffffff;
  border-color: #e8e2da;
  box-shadow: 0 2px 16px rgba(0,0,0,0.05);
}

body.landing-body .stats-strip__item + .stats-strip__item {
  border-left-color: #e8e2da;
}

body.landing-body .stats-strip__label {
  color: var(--muted);
}

/* Service cards */
body.landing-body .service-card {
  background: #ffffff;
  border-color: #e8e2da;
  box-shadow: 0 2px 10px rgba(0,0,0,0.04);
}

body.landing-body .service-card:hover {
  background: #ffffff;
  border-color: #c9c2b8;
  box-shadow: 0 10px 32px rgba(0,0,0,0.09);
  transform: translateY(-4px);
}

body.landing-body .service-card__icon {
  background: rgba(37, 99, 235, 0.07);
  border-color: rgba(37, 99, 235, 0.18);
}

/* Reference cards */
body.landing-body .reference-card {
  background: #ffffff;
  border-color: #e8e2da;
}

body.landing-body .reference-card:hover {
  border-color: #c9c2b8;
}

/* Ghost button */
body.landing-body .btn--ghost {
  border-color: rgba(0,0,0,0.16);
  color: var(--fg);
}

body.landing-body .btn--ghost:hover {
  background: rgba(0,0,0,0.04);
  border-color: rgba(0,0,0,0.26);
}

/* Contact form */
body.landing-body .contact-form__field label {
  color: var(--muted);
}

body.landing-body .contact-form__field input,
body.landing-body .contact-form__field textarea {
  background: #ffffff;
  border-color: #d9d2c9;
  color: var(--fg);
  font-size: 1rem;
}

body.landing-body .contact-form__field input:focus,
body.landing-body .contact-form__field textarea:focus {
  border-color: var(--accent);
}

body.landing-body .contact-form__field input::placeholder,
body.landing-body .contact-form__field textarea::placeholder {
  color: rgba(110, 98, 88, 0.4);
}

/* Founder photos — show in full colour */
body.landing-body .founder-photo__img,
body.landing-body .founder-teaser__img {
  filter: none;
}

/* Footer — kill the dark-mode opacity, use explicit colours instead */
body.landing-body .landing-footer {
  opacity: 1;
}

body.landing-body .landing-footer__brand {
  color: #6b5c52;
}

body.landing-body .landing-footer__link {
  color: #6b5c52;
}

body.landing-body .landing-footer__link:hover {
  color: var(--fg);
}

body.landing-body .landing-footer__copy {
  color: #8c7b70;
}

/* Detail pages (o_nas, automatizace, aplikace) */
body.landing-body .detail-hero__sub {
  font-size: 1.15rem;
}

body.landing-body .detail-cta__sub {
  font-size: 1.05rem;
}

/* Dark-mode rgba colours that weren't overridden yet */
body.landing-body .detail-stat__label {
  color: var(--muted);
}

body.landing-body .founder-photo__role {
  color: #6b5c52;
}

body.landing-body .founder-teaser__caption .founder-photo__role {
  color: #6b5c52;
}

body.landing-body .afford-callout {
  background: rgba(37, 99, 235, 0.05);
  border-color: rgba(37, 99, 235, 0.18);
  border-left-color: var(--accent);
}

/* Responsive */
@media (max-width: 720px) {
  .service-cards,
  .detail-grid {
    grid-template-columns: 1fr;
  }

  .landing-hero {
    padding: 100px 24px 60px;
  }

  .section {
    padding: 64px 24px;
  }

  .detail-hero {
    padding: 110px 24px 56px;
  }

  .landing-nav {
    padding: 0 20px;
  }

  .landing-nav__links {
    display: none;
  }

  .stats-strip {
    padding: 0 24px 64px;
  }

  .stats-strip__inner {
    flex-direction: column;
  }

  .stats-strip__item + .stats-strip__item {
    border-left: none;
    border-top: 1px solid rgba(255,255,255,0.06);
  }

  .founder-grid {
    grid-template-columns: 1fr;
    gap: 40px;
  }

  .founder-photo {
    position: static;
    max-width: 260px;
  }

  .founder-teaser {
    grid-template-columns: 1fr;
    gap: 40px;
  }

  .founder-teaser__photo {
    max-width: 220px;
  }

  .landing-footer {
    flex-direction: column;
    gap: 16px;
    text-align: center;
  }

  .landing-footer__links {
    flex-wrap: wrap;
    justify-content: center;
  }
}
