* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

:root {
  --black: #1a1a1a;
  --off-white: #f7f5f2;
  --gray-dark: #666;
  --accent: #2c2c2c;
  --green-accent: #3b5d38;
  --hardware-color: #bc8a60;
  --firmware-color: #569a9a;
  --server-color: #68916a;
  --mechanical-color: #817b73;
}

body {
  font-family: 'Montserrat', sans-serif;
  color: var(--black);
  background: linear-gradient(135deg, #f7f5f2 0%, #f4f1ec 100%);
  line-height: 1.6;
  letter-spacing: 0.04em;
}

h1, h2, h3 {
  font-family: 'Libre Baskerville', serif;
  font-weight: 700;
}

/* Site Header */
.site-header {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1.5rem 2rem;
}

.header-left {
  display: flex;
  align-items: center;
  gap: 1rem;
  text-decoration: none;
  color: inherit;
}

.site-header img {
  width: 45px;
  height: 45px;
  display: block;
  flex-shrink: 0;
}

.site-header span {
  font-family: 'Libre Baskerville', serif;
  font-weight: 700;
  font-size: 1.8rem;
  color: var(--black);
  line-height: 1;
}

.github-btn {
  font-family: 'Libre Baskerville', serif;
  padding: 0.8rem 1.8rem;
  background: #5c815e;
  color: #fff;
  text-decoration: none;
  font-size: 1.2rem;
  border-radius: 30px;
  transition: opacity 0.2s;
  display: flex;
  align-items: center;
  line-height: 1;
}

.github-btn:hover {
  opacity: 0.8;
}

/* Landing Section */
.landing {
  position: relative;
  height: 100vh;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: flex-start;
}

.landing-video {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  z-index: 0;
}

.landing-video.mobile {
  display: none;
}

.landing-content {
  position: relative;
  z-index: 1;
  text-align: left;
  color: var(--black);
  padding: 2rem;
  margin-left: 8%;
  margin-top: -15vh;
}

.landing-content h1 {
  font-size: clamp(1.5rem, 3vw, 2rem);
  margin-bottom: 0.5rem;
}

.landing-content p {
  font-size: clamp(0.9rem, 1.5vw, 1rem);
  color: var(--gray-dark);
  margin-top: 0;
}

/* Side View Section */
.side-view {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 1.5rem;
  padding: 1.5rem 4rem;
}

.side-view-content h2 {
  font-size: clamp(1.1rem, 2vw, 1.5rem);
  max-width: 320px;
  line-height: 1.5;
}

.side-view img {
  max-width: 670px;
  width: 100%;
  height: auto;
}

/* Indoor Photos Section */
.indoor-photos {
  padding: 1.5rem 4rem;
  text-align: center;
}

.photos-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2rem;
  margin-bottom: 2rem;
  max-width: 1200px;
  margin-left: auto;
  margin-right: auto;
}

.photos-grid img {
  width: 100%;
  height: auto;
  border-radius: 12px;
  box-shadow: 8px 8px 24px rgba(0,0,0,0.1);
}

.indoor-photos h2 {
  font-size: clamp(1.1rem, 2vw, 1.4rem);
  max-width: 600px;
  margin: 0 auto;
}

/* Exploded View Section */
.exploded-view {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 4rem;
  padding: 2rem 4rem;
}

.exploded-view img {
  max-width: 700px;
  width: 100%;
  height: auto;
  margin-top: 5vh;
}

.exploded-content {
  max-width: 400px;
}

.exploded-content h2 {
  font-size: clamp(1.1rem, 2vw, 1.4rem);
  margin-bottom: 1.5rem;
}

.exploded-content p {
  color: var(--gray-dark);
  line-height: 1.8;
}

/* Specifications Section */
.specifications {
  padding: 3rem 4rem;
  text-align: center;
}

.specifications > h2 {
  font-size: clamp(1.2rem, 2vw, 1.8rem);
  margin-bottom: 2rem;
  color: var(--black);
}

.specs-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1.5rem;
  max-width: 1100px;
  margin: 0 auto;
}

.spec-card {
  text-align: left;
  padding: 1.5rem;
  background: #e3e1db;
  border-radius: 30px;
  border: none;
  box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}

.spec-card h3 {
  font-size: 1rem;
  margin-bottom: 1.25rem;
  padding-bottom: 0.75rem;
  border-bottom: 1px solid rgba(0,0,0,0.08);
  color: var(--black);
}

.spec-card ul {
  list-style: none;
}

.spec-card li {
  display: flex;
  justify-content: space-between;
  padding: 0.5rem 0;
  font-size: 0.85rem;
}

.spec-card li span:first-child {
  color: var(--gray-dark);
}

.spec-card li span:last-child {
  color: var(--black);
}

/* Repositories Section */
.repositories {
  padding: 3rem 4rem;
}

.repos-top {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6rem;
  margin-bottom: 3rem;
}

.repos-header h2 {
  font-size: clamp(1.75rem, 3vw, 2.25rem);
  margin-bottom: 0.5rem;
}

.repos-header p {
  color: var(--gray-dark);
}

.repositories video {
  max-width: 500px;
  width: 100%;
  height: auto;
}

.repos-links {
  display: flex;
  justify-content: center;
  gap: 1rem;
  flex-wrap: wrap;
}

.repo-btn {
  display: block;
  padding: 1rem 3rem;
  color: #fff;
  text-decoration: none;
  font-family: 'Libre Baskerville', serif;
  font-size: 0.95rem;
  border-radius: 50px;
  transition: transform 0.2s, box-shadow 0.2s;
}

.repo-btn-hardware {
  background: var(--hardware-color);
}

.repo-btn-firmware {
  background: var(--firmware-color);
}

.repo-btn-server {
  background: var(--server-color);
}

.repo-btn-mechanical {
  background: var(--mechanical-color);
}

.repo-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(0,0,0,0.15);
}

/* Footer */
footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 3rem 4rem;
  border-top: 1px solid rgba(0,0,0,0.06);
}

.footer-left,
.footer-right {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.footer-left img {
  width: 18px;
  height: 18px;
  opacity: 0.6;
}

.footer-left a {
  color: var(--black);
  text-decoration: none;
  font-size: 0.9rem;
}

.footer-left a:hover {
  text-decoration: underline;
}

.footer-right img {
  width: 40px;
  height: 40px;
}

.footer-right span {
  font-family: 'Libre Baskerville', serif;
  font-weight: 700;
  font-size: 1.6rem;
}

/* Responsive */
@media (max-width: 1000px) {
  .specs-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 900px) {
  .site-header {
    padding: 1rem 1.25rem;
  }

  .github-btn {
    padding: 0.5rem 1.1rem;
    font-size: 0.9rem;
  }

  .site-header img {
    width: 32px;
    height: 32px;
  }

  .landing-video.desktop {
    display: none;
  }
  
  .landing-video.mobile {
    display: block;
  }
  
  .landing {
    justify-content: center;
  }
  
  .landing-content {
    margin-left: 0;
    margin-top: 10vh;
    padding: 1rem;
    text-align: center;
    width: 100%;
    max-width: 90vw;
  }
  
  .landing-content h1 {
    font-size: clamp(1.3rem, 5vw, 1.8rem);
    white-space: nowrap;
    margin-bottom: -0.1rem;
  }
  
  .landing-content p {
    font-size: clamp(0.85rem, 3.5vw, 1.1rem);
    white-space: nowrap;
  }
  
  .side-view {
    flex-direction: column-reverse;
    padding: 2rem;
    gap: 0.75rem;
    text-align: center;
  }
  
  .side-view-content h2 {
    max-width: 100%;
  }
  
  .photos-grid {
    grid-template-columns: 1fr;
    gap: 1.5rem;
    padding: 0 1rem;
  }
  
  .indoor-photos {
    padding: 2rem;
  }
  
  .exploded-view {
    flex-direction: column;
    padding: 2rem;
    gap: 1.5rem;
    text-align: center;
  }
  
  .specs-grid {
    grid-template-columns: 1fr;
  }
  
  .specifications {
    padding: 2rem;
  }
  
  .repositories {
    padding: 2rem;
  }

  .repos-top {
    flex-direction: column-reverse;
    gap: 2rem;
    text-align: center;
  }

  .repos-links {
    flex-direction: column;
    align-items: center;
  }

  .repo-btn {
    width: 100%;
    max-width: 280px;
    text-align: center;
  }
  
  footer {
    flex-direction: column;
    gap: 2rem;
    text-align: center;
    padding: 2rem;
  }
}
