:root {
  color-scheme: light;
  --bg: #f5f2ec;
  --panel: #ffffff;
  --fg: #171717;
  --muted: #64615c;
  --line: #d9d2c7;
  --accent: #2447ff;
  --accent-2: #b6662c;
}

* {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  min-height: 100%;
}

body {
  min-height: 100vh;
  background:
    linear-gradient(90deg, rgba(23, 23, 23, 0.045) 1px, transparent 1px),
    linear-gradient(rgba(23, 23, 23, 0.045) 1px, transparent 1px),
    var(--bg);
  background-size: 44px 44px;
  color: var(--fg);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  letter-spacing: 0;
}

a {
  color: inherit;
}

body::before {
  background: linear-gradient(180deg, rgba(245, 242, 236, 0.28), var(--bg) 88%);
  content: "";
  inset: 0;
  pointer-events: none;
  position: fixed;
  z-index: -1;
}

.topbar {
  align-items: center;
  background: rgba(245, 242, 236, 0.84);
  border-bottom: 1px solid rgba(217, 210, 199, 0.7);
  backdrop-filter: blur(18px);
  display: flex;
  justify-content: space-between;
  left: 0;
  padding: 18px 32px;
  position: fixed;
  right: 0;
  top: 0;
  z-index: 10;
}

.brand,
.nav {
  align-items: center;
  display: flex;
}

.brand {
  gap: 12px;
  font-size: 15px;
  font-weight: 720;
  text-decoration: none;
}

.brand__mark {
  background: var(--fg);
  color: var(--panel);
  display: grid;
  font-size: 13px;
  font-weight: 820;
  height: 36px;
  place-items: center;
  width: 36px;
}

.nav {
  gap: 22px;
}

.nav a {
  color: var(--muted);
  font-size: 14px;
  text-decoration: none;
}

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

.nav__login {
  border: 1px solid var(--fg);
  color: var(--fg) !important;
  font-weight: 720;
  min-height: 36px;
  padding: 8px 14px;
}

.hero {
  align-items: center;
  display: grid;
  gap: 48px;
  grid-template-columns: minmax(0, 1fr) 360px;
  min-height: 92vh;
  padding: 128px 32px 64px;
  position: relative;
}

.hero::before {
  border-bottom: 1px solid var(--line);
  content: "";
  inset: auto 32px 0;
  height: 1px;
  pointer-events: none;
  position: absolute;
}

.hero__content {
  max-width: 1040px;
  padding: 0;
  position: relative;
  text-align: left;
  z-index: 1;
}

.hero__eyebrow {
  color: var(--accent);
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0;
  margin: 0 0 18px;
  text-transform: uppercase;
}

h1 {
  font-size: clamp(64px, 13vw, 172px);
  font-weight: 820;
  line-height: 0.86;
  margin: 0;
  max-width: 980px;
}

.hero__subtitle {
  color: var(--muted);
  font-size: clamp(20px, 2.2vw, 28px);
  line-height: 1.45;
  margin: 30px 0 0;
  max-width: 720px;
}

.hero__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 34px;
}

.button {
  align-items: center;
  border: 1px solid var(--fg);
  display: inline-flex;
  font-size: 14px;
  font-weight: 720;
  min-height: 46px;
  padding: 0 18px;
  text-decoration: none;
}

.button--primary {
  background: var(--fg);
  color: var(--panel);
}

.button--ghost {
  background: rgba(255, 255, 255, 0.35);
  color: var(--fg);
}

.hero__panel {
  background: var(--panel);
  border: 1px solid var(--line);
  box-shadow: 18px 18px 0 rgba(23, 23, 23, 0.08);
  min-height: 340px;
  padding: 22px;
}

.panel-line {
  align-items: center;
  border-bottom: 1px solid var(--line);
  display: flex;
  justify-content: space-between;
  min-height: 98px;
}

.panel-line:first-child {
  border-top: 1px solid var(--line);
}

.panel-line span {
  color: var(--fg);
  font-size: 22px;
  font-weight: 740;
}

.panel-line strong {
  color: var(--accent-2);
  font-size: 13px;
}

.work {
  display: grid;
  gap: 18px;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  margin: 32px 32px;
  position: relative;
}

.work article {
  background: var(--panel);
  border: 1px solid var(--line);
  min-height: 250px;
  padding: 28px;
}

.work span {
  color: var(--accent-2);
  display: block;
  font-size: 13px;
  font-weight: 780;
  margin-bottom: 54px;
}

.work h2 {
  font-size: 24px;
  margin: 0;
}

.work p,
.contact p {
  color: var(--muted);
  font-size: 16px;
  line-height: 1.6;
  margin: 14px 0 0;
}

.contact {
  align-items: center;
  border-top: 1px solid var(--line);
  display: flex;
  justify-content: space-between;
  margin: 0 32px;
  padding: 32px 0 46px;
}

.contact p {
  margin: 0;
}

.contact a {
  color: var(--accent);
  font-size: 18px;
  font-weight: 720;
  text-decoration: none;
}

.auth-page,
.dashboard-page {
  min-height: 100vh;
}

.auth-shell,
.dashboard-shell {
  padding: 128px 32px 56px;
}

.auth-shell {
  display: grid;
  min-height: 100vh;
  place-items: center;
}

.auth-card,
.dashboard-hero,
.dashboard-grid article {
  background: var(--panel);
  border: 1px solid var(--line);
}

.auth-card {
  box-shadow: 18px 18px 0 rgba(23, 23, 23, 0.08);
  max-width: 520px;
  padding: 32px;
  width: 100%;
}

.auth-card h1,
.dashboard-hero h1 {
  font-size: clamp(48px, 8vw, 92px);
}

.auth-copy {
  color: var(--muted);
  font-size: 18px;
  line-height: 1.55;
  margin: 18px 0 0;
}

.auth-form {
  display: grid;
  gap: 18px;
  margin-top: 30px;
}

.auth-form label {
  color: var(--muted);
  display: grid;
  font-size: 14px;
  gap: 8px;
}

.auth-form input {
  background: #fbfaf7;
  border: 1px solid var(--line);
  color: var(--fg);
  font: inherit;
  min-height: 48px;
  padding: 0 12px;
}

.auth-form input:focus {
  border-color: var(--accent);
  outline: none;
}

.auth-message {
  color: #b22b2b;
  min-height: 22px;
  margin: 0;
}

.auth-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.auth-actions button,
.nav__button {
  cursor: pointer;
  font: inherit;
}

.dashboard-hero {
  padding: 32px;
}

.dashboard-grid {
  display: grid;
  gap: 18px;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  margin-top: 24px;
}

.dashboard-grid article {
  min-height: 220px;
  padding: 28px;
}

.dashboard-grid span {
  color: var(--accent-2);
  display: block;
  font-size: 13px;
  font-weight: 780;
  margin-bottom: 54px;
}

.dashboard-grid h2 {
  font-size: 24px;
  margin: 0;
}

.dashboard-grid p {
  color: var(--muted);
  line-height: 1.6;
  margin: 14px 0 0;
}

.dashboard-card-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 20px;
}

.dashboard-card-actions .button {
  min-height: 38px;
  padding: 0 12px;
}

.demo-list {
  display: grid;
  gap: 10px;
  margin-top: 18px;
}

.demo-item {
  align-items: center;
  border: 1px solid var(--line);
  display: flex;
  gap: 14px;
  justify-content: space-between;
  padding: 12px;
}

.demo-main {
  align-items: center;
  display: flex;
  gap: 12px;
  min-width: 0;
}

.demo-icon {
  align-items: center;
  background: var(--fg);
  color: var(--bg);
  display: inline-flex;
  flex: 0 0 auto;
  font-size: 12px;
  font-weight: 800;
  height: 36px;
  justify-content: center;
  width: 36px;
}

.demo-item strong,
.demo-item small {
  display: block;
}

.demo-item strong {
  font-size: 16px;
}

.demo-item small {
  color: var(--muted);
  line-height: 1.45;
  margin-top: 4px;
}

.demo-actions {
  align-items: center;
  display: inline-flex;
  flex: 0 0 auto;
  gap: 8px;
}

.demo-status {
  color: var(--muted);
  font-size: 12px;
  font-weight: 720;
}

.demo-actions a {
  border: 1px solid var(--line);
  color: var(--muted);
  font-size: 12px;
  font-weight: 720;
  padding: 6px 8px;
  text-decoration: none;
}

.demo-actions a:hover {
  border-color: var(--fg);
  color: var(--fg);
}

@media (max-width: 640px) {
  .topbar {
    padding: 16px 18px;
  }

  .nav {
    gap: 14px;
  }

  .demo-item {
    align-items: flex-start;
    flex-direction: column;
  }

  .demo-actions {
    width: 100%;
  }

  .hero {
    grid-template-columns: 1fr;
    min-height: auto;
    padding: 104px 18px 28px;
  }

  .hero::before {
    inset: auto 18px 0;
  }

  .hero__eyebrow {
    font-size: 12px;
  }

  .hero__content {
    padding: 0;
  }

  .hero__subtitle {
    max-width: 360px;
  }

  .button {
    justify-content: center;
    width: 100%;
  }

  .hero__panel {
    box-shadow: 10px 10px 0 rgba(23, 23, 23, 0.08);
    min-height: auto;
    width: 100%;
  }

  .panel-line {
    min-height: 74px;
  }

  .work {
    grid-template-columns: 1fr;
    margin: 0 14px 28px;
  }

  .work article {
    min-height: 190px;
    padding: 22px;
  }

  .work span {
    margin-bottom: 34px;
  }

  .contact {
    align-items: flex-start;
    flex-direction: column;
    gap: 16px;
    margin: 0 18px;
  }

  .auth-shell,
  .dashboard-shell {
    padding: 104px 18px 36px;
  }

  .auth-card,
  .dashboard-hero {
    padding: 22px;
  }

  .auth-actions .button {
    width: 100%;
  }

  .dashboard-grid {
    grid-template-columns: 1fr;
  }
}
