:root {
  color-scheme: dark;
  --bg: #1e1a22;
  --bg-elevated: #2a2430;
  --surface: rgba(43, 36, 49, 0.9);
  --surface-strong: #312a39;
  --surface-soft: #3a3142;
  --ink: #f5f1eb;
  --muted: #b8aea4;
  --line: rgba(255, 255, 255, 0.08);
  --accent: #e95420;
  --accent-soft: rgba(233, 84, 32, 0.16);
  --shadow: 0 30px 90px rgba(7, 10, 16, 0.34);
  --heading: "Sora", "Segoe UI", sans-serif;
  --body: "Manrope", "Segoe UI", sans-serif;
}

* {
  box-sizing: border-box;
}

html {
  background: #18141d;
}

body {
  margin: 0;
  min-height: 100vh;
  background:
    radial-gradient(circle at top left, rgba(233, 84, 32, 0.14), transparent 28rem),
    radial-gradient(circle at 80% 10%, rgba(119, 33, 111, 0.14), transparent 26rem),
    linear-gradient(180deg, #241f2a 0%, #1c1822 50%, #17131c 100%);
  color: var(--ink);
  font-family: var(--body);
  line-height: 1.7;
}

a {
  color: inherit;
}

.site-header,
.site-footer,
main {
  width: min(1320px, calc(100vw - 48px));
  margin: 0 auto;
}

.site-header,
.site-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  margin-top: 12px;
  padding: 16px 22px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: rgba(35, 29, 41, 0.76);
  backdrop-filter: blur(18px);
  box-shadow: 0 14px 50px rgba(8, 12, 18, 0.18);
}

.site-footer {
  margin-bottom: 40px;
  padding: 24px 6px 0;
  color: var(--muted);
  font-size: 0.95rem;
}

.brand,
.site-nav,
.footer-links {
  display: flex;
  align-items: center;
  gap: 14px;
}

.brand,
.site-nav a,
.footer-links a,
.text-link,
.card h3 a {
  text-decoration: none;
}

.brand {
  font-weight: 800;
  letter-spacing: -0.02em;
}

.brand-mark {
  width: 14px;
  height: 14px;
  border-radius: 4px;
  background: linear-gradient(135deg, #e95420, #77216f);
  box-shadow: 0 0 0 8px rgba(233, 84, 32, 0.14);
}

.brand-text {
  font-family: var(--heading);
  font-size: 0.98rem;
}

.site-nav {
  flex-wrap: wrap;
  justify-content: flex-end;
}

.site-nav a,
.footer-links a {
  border: 1px solid transparent;
  border-radius: 999px;
  padding: 9px 14px;
  color: var(--muted);
  transition: background-color 0.2s ease, border-color 0.2s ease, color 0.2s ease;
}

.site-nav a:hover,
.footer-links a:hover,
.text-link:hover {
  color: var(--ink);
  background: var(--accent-soft);
  border-color: rgba(124, 183, 255, 0.16);
}

main {
  padding: 26px 0 72px;
}

.hero,
.page-hero,
.article,
.card {
  border: 1px solid var(--line);
  background: var(--surface);
  box-shadow: var(--shadow);
  backdrop-filter: blur(12px);
}

.hero {
  min-height: 560px;
  padding: 56px;
  border-radius: 28px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(320px, 500px);
  gap: 32px;
  align-items: stretch;
}

.hero-copy {
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding-right: 12px;
}

.eyebrow,
.card-meta {
  margin: 0 0 12px;
  color: var(--accent);
  font-size: 0.82rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.hero h1,
.page-hero h1,
.article h1 {
  margin: 0;
  max-width: 860px;
  font-family: var(--heading);
  font-size: clamp(2.4rem, 5vw, 5rem);
  line-height: 1.02;
  letter-spacing: -0.04em;
}

.hero-text,
.page-hero p,
.section-copy,
.card p:not(.card-meta) {
  color: var(--muted);
}

.hero-text {
  max-width: 720px;
  margin: 20px 0 0;
  font-size: 1.08rem;
}

.hero-visual {
  position: relative;
  min-height: 360px;
  overflow: hidden;
  border: 1px solid rgba(233, 84, 32, 0.14);
  border-radius: 24px;
  background:
    radial-gradient(circle at 50% 35%, rgba(233, 84, 32, 0.12), transparent 42%),
    linear-gradient(180deg, rgba(255, 255, 255, 0.03), rgba(32, 24, 36, 0.72)),
    #241e29;
}

.hero-canvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  display: block;
}

.hero-badges {
  position: absolute;
  left: 22px;
  right: 22px;
  bottom: 22px;
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.hero-badges span {
  min-height: 34px;
  padding: 7px 12px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 999px;
  background: rgba(34, 27, 40, 0.74);
  color: #f1e7dd;
  font-size: 0.9rem;
  backdrop-filter: blur(10px);
}

.section {
  padding-top: 60px;
}

.section-head {
  margin-bottom: 20px;
}

.section-head h2 {
  margin: 0;
  font-family: var(--heading);
  font-size: clamp(1.8rem, 4vw, 2.8rem);
  letter-spacing: -0.03em;
}

.section-copy {
  max-width: 760px;
  margin: 8px 0 0;
}

.card-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 20px;
}

.project-slider {
  position: relative;
  overflow: hidden;
  padding-bottom: 6px;
}

.slider-controls {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
  margin-bottom: 18px;
}

.slider-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 42px;
  height: 42px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: rgba(43, 36, 49, 0.92);
  color: var(--ink);
  cursor: pointer;
  transition: background-color 0.2s ease, border-color 0.2s ease, transform 0.2s ease;
}

.slider-button:hover {
  background: var(--accent-soft);
  border-color: rgba(233, 84, 32, 0.28);
  transform: translateY(-1px);
}

.project-slider-track {
  display: flex;
  gap: 20px;
  will-change: transform;
}

.project-slide {
  flex: 0 0 calc((100% - 40px) / 3);
  min-width: 0;
}

.project-slide .card {
  height: 100%;
}

.project-slide-clone {
  user-select: none;
}

.post-feed {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 20px;
}

.post-feed-item {
  min-width: 0;
}

.post-feed-item.is-hidden {
  display: none;
}

.post-feed-item .card {
  min-height: 0;
}

.post-feed-sentinel {
  height: 1px;
}

.card {
  min-height: 280px;
  padding: 24px;
  border-radius: 22px;
  display: flex;
  flex-direction: column;
  transition: transform 0.22s ease, border-color 0.22s ease, background-color 0.22s ease;
}

.card:hover {
  transform: translateY(-3px);
  border-color: rgba(233, 84, 32, 0.22);
  background: rgba(57, 47, 65, 0.96);
}

.card-image-link {
  display: block;
  margin: -24px -24px 18px;
  overflow: hidden;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
  border-top-left-radius: 22px;
  border-top-right-radius: 22px;
  background:
    radial-gradient(circle at center, rgba(233, 84, 32, 0.12), transparent 55%),
    linear-gradient(180deg, rgba(255, 255, 255, 0.025), rgba(0, 0, 0, 0.1)),
    #221c27;
}

.card-image {
  display: block;
  width: 100%;
  height: 220px;
  object-fit: contain;
  padding: 22px;
}

.card-image-cover {
  object-fit: cover;
  padding: 0;
}

.card h3 {
  margin: 0;
  font-family: var(--heading);
  font-size: 1.32rem;
  line-height: 1.24;
  letter-spacing: -0.02em;
}

.text-link {
  width: fit-content;
  margin-top: auto;
  color: var(--accent);
  font-weight: 700;
}

.page-hero {
  padding: 44px;
  border-radius: 24px;
}

.article {
  width: 100%;
  padding: 48px;
  margin: 0 auto;
  border-radius: 24px;
}

.article-header {
  padding-bottom: 24px;
  margin-bottom: 28px;
  border-bottom: 1px solid var(--line);
}

.article-cover-wrap {
  overflow: hidden;
  margin-bottom: 32px;
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-radius: 22px;
  background: #241d29;
}

.article-cover {
  display: block;
  width: 100%;
  height: auto;
}

.profile-hero {
  display: grid;
  grid-template-columns: 220px minmax(0, 1fr);
  gap: 28px;
  align-items: center;
  margin-bottom: 32px;
  padding: 24px;
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-radius: 22px;
  background: rgba(255, 255, 255, 0.02);
}

.profile-photo-wrap {
  aspect-ratio: 1;
  overflow: hidden;
  border: 1px solid rgba(233, 84, 32, 0.18);
  border-radius: 22px;
  background: #231d28;
}

.profile-photo {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.profile-role {
  margin: 0 0 10px;
  color: var(--accent);
  font-weight: 800;
  letter-spacing: -0.01em;
}

.profile-intro {
  margin: 0;
  color: #f2e8de;
  font-size: 1.08rem;
}

.profile-facts {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 16px;
}

.profile-facts span {
  display: inline-flex;
  min-height: 34px;
  align-items: center;
  padding: 6px 12px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 999px;
  color: var(--muted);
  background: rgba(119, 33, 111, 0.18);
}

.article time {
  display: block;
  margin-top: 12px;
  color: var(--muted);
  font-size: 0.95rem;
}

.content {
  color: #f0e8de;
}

.content h2,
.content h3 {
  font-family: var(--heading);
  letter-spacing: -0.03em;
  line-height: 1.15;
}

.content h2 {
  margin-top: 2.4rem;
  color: #fff4eb;
}

.content h3 {
  color: #f1ddd3;
}

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

.content code {
  padding: 0.14rem 0.38rem;
  border: 1px solid rgba(233, 84, 32, 0.16);
  border-radius: 7px;
  background: rgba(119, 33, 111, 0.22);
  color: #ffd8c6;
  font-size: 0.95em;
}

.content img {
  max-width: 100%;
  border-radius: 16px;
}

.content pre {
  overflow-x: auto;
  padding: 18px;
  border: 1px solid rgba(233, 84, 32, 0.14);
  border-radius: 16px;
  background: #1b151f;
  color: #eff5fb;
}

.content pre code {
  padding: 0;
  border: 0;
  background: transparent;
  color: inherit;
}

@media (max-width: 980px) {
  .hero {
    grid-template-columns: 1fr;
    padding: 34px;
  }

  .hero-visual {
    min-height: 320px;
  }

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

  .project-slide {
    flex-basis: calc((100% - 20px) / 2);
  }

  .post-feed {
    grid-template-columns: 1fr;
  }

  .article,
  .page-hero {
    padding: 32px;
  }

  .profile-hero {
    grid-template-columns: 1fr;
  }

  .profile-photo-wrap {
    max-width: 240px;
  }

  .site-header,
  .site-footer {
    flex-direction: column;
    align-items: flex-start;
  }

  .site-nav {
    justify-content: flex-start;
  }
}

@media (max-width: 640px) {
  .site-header,
  .site-footer,
  main {
    width: min(1320px, calc(100vw - 28px));
  }

  .site-header {
    padding: 14px 16px;
    border-radius: 14px;
  }

  .hero,
  .article,
  .page-hero {
    padding: 24px;
    border-radius: 20px;
  }

  .hero-visual {
    min-height: 280px;
    border-radius: 18px;
  }

  .project-slide {
    flex-basis: 100%;
  }
}
