:root {
  color-scheme: dark;
  --bg: #000000;
  --nav-bg: #000000;
  --line: rgba(255, 255, 255, 0.065);
  --line-strong: rgba(255, 255, 255, 0.12);
  --text: #f8f8f8;
  --muted: #7f8791;
  --muted-strong: #b5bbc3;
  --nav-h: 54px;
  --cell: 112px;
  --max: 1120px;
}

[data-theme="light"] {
  color-scheme: light;
  --bg: #ffffff;
  --nav-bg: #ffffff;
  --line: rgba(0, 0, 0, 0.065);
  --line-strong: rgba(0, 0, 0, 0.12);
  --text: #1a1a1a;
  --muted: #707070;
  --muted-strong: #4a4a4a;
}

* {
  box-sizing: border-box;
  font-family: "Oswald", Arial, Helvetica, sans-serif;
}

body, 
button, 
input, 
select, 
textarea {
  font-family: "Oswald", Arial, Helvetica, sans-serif;
}

html {
  min-height: 100%;
  background: var(--bg);
}

body {
  min-height: 100vh;
  margin: 0;
  overflow-x: hidden;
  background: var(--bg);
  color: var(--text);
  font-weight: 300;
  transition: background-color 200ms ease, color 200ms ease;
}

a {
  color: inherit;
  text-decoration: none;
}

.site-shell {
  position: relative;
  z-index: 1;
  min-height: 100vh;
  padding-top: var(--nav-h);
}

.navbar {
  position: fixed;
  top: 0;
  left: 0;
  z-index: 20;
  display: grid;
  grid-template-columns: minmax(180px, 1fr) minmax(520px, 760px) minmax(180px, 1fr);
  width: 100%;
  height: var(--nav-h);
  background: var(--nav-bg);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  width: max-content;
  min-height: var(--nav-h);
  margin-left: clamp(18px, 5vw, 72px);
  color: var(--text);
  letter-spacing: 0.08em;
}

.brand-mark {
  width: 24px;
  height: 24px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: transparent;
  color: var(--text);
  border: 1.5px solid var(--text);
  border-radius: 2px;
}

.brand-mark svg {
  width: 22px;
  height: 22px;
  fill: currentColor;
}


.desktop-nav {
  position: relative;
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  background: var(--nav-bg);
}

.nav-link {
  position: relative;
  display: grid;
  place-items: center;
  min-width: 0;
  color: var(--muted);
  font-family: "Oswald", Arial, Helvetica, sans-serif;
  font-size: 13px;
  font-weight: 400;
  letter-spacing: 0.06em;
  transition: color 180ms ease, background-color 180ms ease;
}

.nav-link:hover,
.nav-link.is-active {
  color: var(--text);
  background-color: var(--line);
}

.nav-indicator {
  position: absolute;
  bottom: -1px;
  left: 0;
  width: 20%;
  height: 2px;
  background: var(--text);
  transform: translateX(0);
  transition: transform 220ms ease, width 220ms ease;
}

.theme-switcher-wrap {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  margin-right: clamp(18px, 5vw, 72px);
}

.theme-switcher {
  display: flex;
  gap: 2px;
}

.theme-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 26px;
  height: 26px;
  border: none;
  background: none;
  color: var(--muted);
  cursor: pointer;
  transition: color 180ms ease, background-color 180ms ease;
}

.theme-btn:hover {
  color: var(--text);
  background: var(--line);
}

.theme-btn.is-active {
  color: var(--text);
  background: var(--line-strong);
}

.theme-btn svg {
  width: 14px;
  height: 14px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.5;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.menu-toggle,
.mobile-panel {
  display: none;
}

.section {
  width: calc(100% - 40px);
  max-width: var(--max);
  margin: 0 auto;
}

.hero {
  display: grid;
  align-content: center;
  min-height: calc(100vh - var(--nav-h));
  padding: 72px 0;
}

.hero-kicker,
.section-label {
  margin: 0 0 20px;
  color: var(--muted-strong);
  font-family: "Oswald", Arial, Helvetica, sans-serif;
  font-size: 11px;
  font-weight: 400;
  letter-spacing: 0.12em;
}

.hero-kicker {
  width: max-content;
  border: 1px solid var(--line-strong);
  background: var(--bg);
  padding: 8px 11px;
}

h1, h2, h3, h4, h5, h6 {
  font-family: "Oswald", Arial, Helvetica, sans-serif;
}

.hero h1 {
  max-width: 860px;
  margin: 0;
  color: var(--text);
  font-weight: 500;
  letter-spacing: 0;
}

#services-intro h1,
.about-page h1,
.content-section h2,
.about-page h2 {
  max-width: 860px;
  margin: 0 auto;
  color: var(--text);
  font-weight: 500;
  letter-spacing: 0;
}

.content-section h1,
.about-page h1,
.content-section h2,
.about-page h2 {
  margin-inline: auto;
}

.hero h1 {
  font-size: clamp(42px, 6.8vw, 84px);
  line-height: 1;
}

#services-intro h1,
#contact-intro h1,
#work-intro h1 {
  font-size: clamp(36px, 5.5vw, 64px);
  line-height: 1.1;
}

.content-section h2 {
  font-size: clamp(30px, 4vw, 48px);
  line-height: 1.1;
}

.hero p,
.content-section p:not(.section-label) {
  max-width: 660px;
  margin: 24px 0 0;
  color: var(--muted-strong);
  font-size: clamp(16px, 2vw, 19px);
  line-height: 1.72;
}

.content-section p:not(.section-label) {
  margin-inline: auto;
}

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

.content-section .hero-actions {
  justify-content: center;
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 46px;
  border: 1px solid var(--line-strong);
  padding: 0 18px;
  background: var(--bg);
  color: var(--text);
  font-family: "Oswald", Arial, Helvetica, sans-serif;
  font-size: 12px;
  font-weight: 400;
  letter-spacing: 0.06em;
  transition: color 180ms ease, border-color 180ms ease, background-color 180ms ease;
}

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

.button-primary {
  background: var(--text);
  color: var(--bg);
  border-color: var(--text);
}

.button-primary:hover {
  opacity: 0.9;
  border-color: var(--text);
}

.button-secondary {
  color: var(--text);
}

.content-section {
  text-align: center;
  padding: 80px 0;
}

.connector-line {
  width: 1px;
  height: 180px;
  background-color: var(--text);
  margin: 0 auto;
  opacity: 0.3;
}

.horizontal-divider {
  width: calc(100% - 40px);
  max-width: var(--max);
  height: 1px;
  background-color: var(--text);
  margin: 0 auto;
  opacity: 0.08;
}

/* Contact Section & Footer */
.contact-grid {
  display: flex;
  justify-content: center;
  gap: 32px;
  margin: 48px 0;
}

.contact-item {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 64px;
  height: 64px;
  border: 1px solid var(--line-strong);
  background: var(--bg);
  color: var(--muted);
  transition: all 220ms ease;
  border-radius: 4px;
}

.contact-item:hover {
  color: var(--text);
  border-color: var(--text);
  transform: translateY(-4px);
  background: var(--line);
}

.contact-item svg {
  width: 28px;
  height: 28px;
  fill: currentColor;
}

.contact-note {
  max-width: 500px;
  margin: 32px auto 0;
  color: var(--muted-strong);
  font-size: 14px;
  letter-spacing: 0.02em;
}

.site-footer {
  border-top: 1px solid var(--line-strong);
  padding: 48px 0 32px;
  margin-top: 60px;
}

.footer-content {
  max-width: var(--max);
  margin: 0 auto;
  padding: 0 20px;
  text-align: center;
}

.footer-brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 16px;
  color: var(--text);
  font-size: 18px;
  letter-spacing: 0.1em;
  font-weight: 500;
}

.footer-desc {
  color: var(--muted);
  font-size: 14px;
  max-width: 400px;
  margin: 0 auto 28px;
  line-height: 1.6;
}

.footer-nav {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 24px;
  margin-bottom: 28px;
}

.footer-nav a {
  color: var(--muted);
  font-size: 12px;
  font-weight: 400;
  letter-spacing: 0.08em;
  transition: color 180ms ease;
}

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

.footer-bottom {
  border-top: 1px solid var(--line);
  padding-top: 24px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 20px;
}

.footer-legal {
  display: flex;
  gap: 20px;
}

.footer-legal a,
.copyright {
  color: var(--muted);
  font-size: 11px;
  letter-spacing: 0.04em;
}

.footer-legal a:hover {
  color: var(--text);
}

@media (max-width: 640px) {
  .contact-grid {
    gap: 16px;
  }
  
  .contact-item {
    width: 54px;
    height: 54px;
  }
  
  .footer-bottom {
    flex-direction: column;
    text-align: center;
  }
  
  .footer-legal {
    justify-content: center;
  }
}

/* Project Grid & Cards */
.project-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 32px;
  padding: 40px 0 80px;
}

.project-card {
  display: flex;
  flex-direction: column;
  background: var(--bg);
  border: 1px solid var(--line-strong);
  border-radius: 8px;
  overflow: hidden;
  text-decoration: none;
  transition: all 400ms cubic-bezier(0.16, 1, 0.3, 1);
  cursor: pointer;
  height: 100%;
  text-align: left;
}

.project-card:hover {
  transform: translateY(-8px) scale(1.02);
  border-color: var(--text);
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.4), 
              0 0 20px rgba(255, 255, 255, 0.05);
}

.project-image-wrap {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 10;
  overflow: hidden;
  background: var(--line);
}

.project-image-wrap img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 600ms cubic-bezier(0.16, 1, 0.3, 1);
}

.project-card:hover .project-image-wrap img {
  transform: scale(1.05);
}

.project-card-content {
  padding: 24px;
  flex-grow: 1;
  display: flex;
  flex-direction: column;
}

.project-category {
  font-size: 10px;
  font-weight: 500;
  letter-spacing: 0.1em;
  color: var(--muted);
  text-transform: uppercase;
  margin-bottom: 12px;
}

.project-card h3 {
  font-size: 20px;
  margin: 0 0 10px;
  color: var(--text);
  font-weight: 500;
  letter-spacing: 0.02em;
}

.project-card p {
  font-size: 14px;
  color: var(--muted-strong);
  line-height: 1.6;
  margin: 0;
}

@media (max-width: 1024px) {
  .project-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 24px;
  }
}

@media (max-width: 640px) {
  .project-grid {
    grid-template-columns: 1fr;
    gap: 24px;
  }
  
  .project-card h3 {
    font-size: 18px;
  }
}

/* Scroll Reveal Animations */
.reveal {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 800ms cubic-bezier(0.16, 1, 0.3, 1), 
              transform 800ms cubic-bezier(0.16, 1, 0.3, 1);
  will-change: opacity, transform;
}

.reveal.reveal-left {
  transform: translateX(-30px);
}

.reveal.reveal-right {
  transform: translateX(30px);
}

.reveal.is-visible {
  opacity: 1;
  transform: translate(0, 0);
}

.delay-1 { transition-delay: 100ms; }
.delay-2 { transition-delay: 200ms; }
.delay-3 { transition-delay: 300ms; }

/* About Page Specific Layout */
.about-page .content-section {
  text-align: left;
  padding: 120px 0;
}

.about-page .content-wrapper {
  display: grid;
  grid-template-columns: clamp(200px, 25vw, 300px) 1fr;
  gap: 60px;
  max-width: var(--max);
  margin: 0 auto;
  align-items: center;
}

.about-page h1,
.about-page h2 {
  font-size: clamp(32px, 4.5vw, 52px);
  line-height: 1.15;
  margin: 0 0 24px;
  max-width: 100%;
}

.about-page h1 {
  margin-bottom: 24px;
}

.about-page p:not(.section-label) {
  max-width: 780px;
  margin: 0;
}

.about-page .section-label {
  margin: 0;
  font-size: 14px;
  color: var(--text);
  opacity: 0.7;
  letter-spacing: 0.15em;
}

.about-page .vision-statement {
  background: none;
  padding: 160px 0 240px;
}

.about-page .vision-statement .content-wrapper {
  display: block;
  text-align: center;
}

.about-page .vision-statement .text-col {
  max-width: 920px;
  margin: 0 auto;
}

.about-page .vision-statement h2 {
  margin: 0 auto;
  font-size: clamp(24px, 3.2vw, 36px);
  line-height: 1.55;
  font-weight: 300;
  opacity: 0.8;
}

@media (max-width: 860px) {
  :root {
    --cell: 80px;
  }

  .navbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    padding: 0 16px;
  }

  .brand {
    margin-left: 0;
  }

  .desktop-nav,
  .theme-switcher-wrap {
    display: none;
  }

  .menu-toggle {
    display: inline-flex;
    flex: 0 0 auto;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 6px;
    width: 42px;
    height: 38px;
    border: 1px solid var(--line);
    background: var(--bg);
    cursor: pointer;
  }

  .menu-toggle span {
    width: 17px;
    height: 1px;
    background: var(--text);
    transition: transform 180ms ease;
  }

  .menu-toggle[aria-expanded="true"] span:first-child {
    transform: translateY(3.5px) rotate(45deg);
  }

  .menu-toggle[aria-expanded="true"] span:last-child {
    transform: translateY(-3.5px) rotate(-45deg);
  }

  .mobile-panel {
    position: fixed;
    top: var(--nav-h);
    right: 0;
    left: 0;
    z-index: 19;
    display: grid;
    overflow: hidden;
    max-height: 0;
    border-bottom: 1px solid transparent;
    background: var(--bg);
    transition: max-height 220ms ease, border-color 180ms ease;
  }

  .mobile-panel.is-open {
    max-height: 320px;
    border-color: var(--line-strong);
  }

  .mobile-panel a {
    border-bottom: 1px solid var(--line);
    padding: 17px 18px;
    color: var(--muted);
    font-family: "Oswald", Arial, Helvetica, sans-serif;
    font-size: 12px;
    font-weight: 400;
    letter-spacing: 0.08em;
  }

  .mobile-panel a.is-active {
    color: var(--text);
    background: var(--line);
  }

  .section {
    width: calc(100% - 32px);
  }

  .hero {
    min-height: calc(100vh - var(--nav-h));
    padding: 60px 0;
  }

  .hero h1 {
    max-width: 560px;
    overflow-wrap: break-word;
    font-size: clamp(36px, 10vw, 56px);
    line-height: 1.04;
  }

  .content-section {
    padding: 80px 0;
  }

  .about-page .content-section {
    padding: 80px 0;
  }

  .about-page .content-wrapper {
    grid-template-columns: 1fr;
    gap: 32px;
  }

  .about-page .vision-statement {
    padding: 100px 0 140px;
  }
}

@media (max-width: 480px) {
  :root {
    --cell: 64px;
  }

  .brand-text {
    display: none;
  }

  .hero-kicker {
    max-width: 100%;
    white-space: normal;
  }

  .hero h1 {
    max-width: 350px;
    font-size: clamp(34px, 9.5vw, 42px);
  }

  .hero p,
  .content-section p:not(.section-label) {
    max-width: 350px;
  }

  .button {
    width: 100%;
  }
}
