:root {
  --ink: #0c1a1f;
  --ink-soft: #1e333b;
  --paper: #f3f0e8;
  --paper-2: #e8e4d8;
  --teal: #0d7a6f;
  --teal-bright: #12a396;
  --amber: #e8a317;
  --danger: #b33a2b;
  --line: rgba(12, 26, 31, 0.12);
  --shadow: 0 18px 50px rgba(12, 26, 31, 0.12);
  --font-display: "Syne", "Segoe UI", sans-serif;
  --font-body: "Manrope", "Segoe UI", sans-serif;
  --radius: 4px;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: var(--font-body);
  color: var(--ink);
  background:
    radial-gradient(1200px 600px at 10% -10%, rgba(18, 163, 150, 0.18), transparent 55%),
    radial-gradient(900px 500px at 100% 0%, rgba(232, 163, 23, 0.12), transparent 50%),
    linear-gradient(165deg, #f7f4ec 0%, #ebe6d8 45%, #e2ddd0 100%);
  min-height: 100vh;
  line-height: 1.5;
}

a {
  color: var(--teal);
  text-decoration-thickness: 1px;
  text-underline-offset: 3px;
}

a:hover {
  color: var(--ink);
}

img {
  max-width: 100%;
}

.wrap {
  width: min(1120px, calc(100% - 2.5rem));
  margin-inline: auto;
}

.site-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1.25rem 0;
  gap: 1rem;
}

.brand {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 1.35rem;
  letter-spacing: -0.03em;
  color: var(--ink);
  text-decoration: none;
}

.brand span {
  color: var(--teal);
}

.nav {
  display: flex;
  gap: 0.75rem;
  align-items: center;
  flex-wrap: wrap;
}

.btn {
  appearance: none;
  border: 1px solid transparent;
  background: var(--ink);
  color: var(--paper);
  font-family: var(--font-body);
  font-weight: 700;
  font-size: 0.95rem;
  padding: 0.7rem 1.15rem;
  border-radius: var(--radius);
  cursor: pointer;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  transition: transform 0.15s ease, background 0.15s ease;
}

.btn:hover {
  background: var(--ink-soft);
  color: var(--paper);
  transform: translateY(-1px);
}

.btn:focus-visible,
input:focus-visible,
textarea:focus-visible {
  outline: 2px solid var(--teal-bright);
  outline-offset: 2px;
}

.btn-ghost {
  background: transparent;
  color: var(--ink);
  border-color: var(--line);
}

.btn-ghost:hover {
  background: rgba(12, 26, 31, 0.05);
  color: var(--ink);
}

.btn-teal {
  background: var(--teal);
}

.btn-teal:hover {
  background: var(--teal-bright);
}

.btn-danger {
  background: var(--danger);
}

.hero {
  padding: 4.5rem 0 3.5rem;
  display: grid;
  grid-template-columns: 1.15fr 0.85fr;
  gap: 2.5rem;
  align-items: end;
}

.hero h1 {
  font-family: var(--font-display);
  font-size: clamp(2.4rem, 5vw, 4.2rem);
  line-height: 0.95;
  letter-spacing: -0.045em;
  margin: 0 0 1rem;
}

.hero p {
  font-size: 1.1rem;
  max-width: 36ch;
  margin: 0 0 1.75rem;
  color: var(--ink-soft);
}

.hero-visual {
  min-height: 280px;
  background:
    linear-gradient(145deg, rgba(13, 122, 111, 0.92), rgba(12, 26, 31, 0.88)),
    repeating-linear-gradient(
      -18deg,
      transparent,
      transparent 12px,
      rgba(243, 240, 232, 0.07) 12px,
      rgba(243, 240, 232, 0.07) 13px
    );
  border-radius: 6px;
  color: var(--paper);
  padding: 1.75rem;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  box-shadow: var(--shadow);
  animation: rise 0.7s ease both;
}

.hero-visual strong {
  font-family: var(--font-display);
  font-size: 1.6rem;
  letter-spacing: -0.03em;
}

.section {
  padding: 2.5rem 0 3.5rem;
}

.section h2 {
  font-family: var(--font-display);
  font-size: 1.8rem;
  letter-spacing: -0.03em;
  margin: 0 0 0.5rem;
}

.section > p {
  margin: 0 0 1.5rem;
  color: var(--ink-soft);
  max-width: 50ch;
}

.feature-row {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1rem;
}

.feature {
  padding: 1.25rem 1.1rem;
  border-top: 2px solid var(--ink);
  background: rgba(243, 240, 232, 0.55);
}

.feature h3 {
  font-family: var(--font-display);
  margin: 0 0 0.4rem;
  font-size: 1.15rem;
}

.feature p {
  margin: 0;
  color: var(--ink-soft);
  font-size: 0.95rem;
}

.panel {
  background: rgba(243, 240, 232, 0.75);
  border: 1px solid var(--line);
  border-radius: 6px;
  padding: 1.5rem;
  box-shadow: var(--shadow);
  animation: rise 0.45s ease both;
}

.panel h1,
.panel h2 {
  font-family: var(--font-display);
  letter-spacing: -0.03em;
  margin-top: 0;
}

label {
  display: block;
  font-weight: 650;
  font-size: 0.85rem;
  margin: 0.85rem 0 0.35rem;
}

input,
textarea,
select {
  width: 100%;
  border: 1px solid var(--line);
  background: #fffef9;
  border-radius: var(--radius);
  padding: 0.7rem 0.8rem;
  font: inherit;
  color: var(--ink);
}

.form-actions {
  display: flex;
  gap: 0.75rem;
  margin-top: 1.25rem;
  flex-wrap: wrap;
}

.muted {
  color: var(--ink-soft);
  font-size: 0.92rem;
}

.error {
  color: var(--danger);
  font-weight: 650;
  margin: 0.5rem 0 0;
}

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

.project-card {
  border: 1px solid var(--line);
  background: #fffef9;
  padding: 1.15rem;
  border-radius: 6px;
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
  transition: border-color 0.15s ease, transform 0.15s ease;
}

.project-card:hover {
  border-color: var(--teal);
  transform: translateY(-2px);
}

.project-card.active {
  border-color: var(--teal);
  box-shadow: inset 3px 0 0 var(--teal);
}

.project-card h3 {
  font-family: var(--font-display);
  margin: 0;
  font-size: 1.2rem;
}

.swatch {
  width: 1rem;
  height: 1rem;
  border-radius: 2px;
  display: inline-block;
  vertical-align: middle;
}

.toolbar {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  align-items: center;
  flex-wrap: wrap;
  margin-bottom: 1.25rem;
}

.tabs {
  display: flex;
  gap: 0.35rem;
  flex-wrap: wrap;
  margin-bottom: 1rem;
}

.tab {
  border: 1px solid var(--line);
  background: transparent;
  padding: 0.45rem 0.8rem;
  border-radius: 999px;
  cursor: pointer;
  font: inherit;
  font-weight: 650;
}

.tab.on {
  background: var(--ink);
  color: var(--paper);
  border-color: var(--ink);
}

.table {
  width: 100%;
  border-collapse: collapse;
}

.table th,
.table td {
  text-align: left;
  padding: 0.65rem 0.4rem;
  border-bottom: 1px solid var(--line);
  font-size: 0.95rem;
}

.live-block {
  border: 1px solid var(--line);
  background: #0c1a1f;
  color: var(--paper);
  border-radius: 6px;
  overflow: hidden;
  margin: 1rem 0;
}

.live-block .live-head {
  padding: 0.85rem 1rem;
  display: flex;
  justify-content: space-between;
  gap: 0.75rem;
  align-items: center;
  background: rgba(18, 163, 150, 0.18);
}

.live-block .live-head strong {
  font-family: var(--font-display);
}

.live-embed {
  aspect-ratio: 16 / 9;
  background: #061014;
  display: grid;
  place-items: center;
  color: rgba(243, 240, 232, 0.65);
  font-size: 0.95rem;
}

.live-embed iframe {
  width: 100%;
  height: 100%;
  border: 0;
}

.live-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem;
  padding: 1rem;
}

.chip {
  display: inline-block;
  font-size: 0.75rem;
  font-weight: 700;
  padding: 0.2rem 0.5rem;
  border-radius: 999px;
  background: rgba(13, 122, 111, 0.12);
  color: var(--teal);
}

.footer {
  padding: 2rem 0 3rem;
  color: var(--ink-soft);
  font-size: 0.88rem;
  border-top: 1px solid var(--line);
  margin-top: 2rem;
}

@keyframes rise {
  from {
    opacity: 0;
    transform: translateY(10px);
  }
  to {
    opacity: 1;
    transform: none;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation: none !important;
    transition: none !important;
  }
}

@media (max-width: 800px) {
  .hero,
  .feature-row {
    grid-template-columns: 1fr;
  }
  .hero {
    padding-top: 2.5rem;
  }
}
