/* RESET */
* {
  box-sizing: border-box;
}

body {
  margin: 0;
  background: #0a0a0a;
  color: #eaeaea;
  font-family: Inter, system-ui, -apple-system, BlinkMacSystemFont, sans-serif;
  font-size: clamp(15px, 1.2vw, 17px);
  overflow-x: hidden;
  min-height: 100vh;
}

/* HERO */
.hero {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  padding: 20px 24px 16px;
  text-align: center;
  background: #0a0a0a;
  z-index: 10;
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.logo {
  width: 70px;
  margin-bottom: 12px;
  padding: 6px;
  border-radius: 16px;
  background: radial-gradient(110% 110% at 50% 25%, rgba(255, 255, 255, 0.18), rgba(255, 255, 255, 0));
  box-shadow:
    0 0 0 1px rgba(255, 255, 255, 0.12),
    0 0 24px rgba(255, 255, 255, 0.18),
    0 10px 28px rgba(0, 0, 0, 0.3);
}

h1 {
  margin: 0 0 12px;
  font-size: clamp(1.8rem, 3vw, 2.2rem);
  letter-spacing: 0.18em;
  color: #ffffff;
  text-shadow: 0 4px 18px rgba(0, 0, 0, 0.4);
}

.tagline {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  max-width: 760px;
  margin: 8px auto 0;
  padding: 12px 18px;
  font-size: clamp(0.95rem, 1.4vw, 1.05rem);
  color: #b8beca;
  background: linear-gradient(120deg, rgba(255, 255, 255, 0.04), rgba(255, 255, 255, 0.01));
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 999px;
  line-height: 1.6;
  letter-spacing: 0.02em;
  box-shadow:
    0 10px 30px rgba(0, 0, 0, 0.25),
    0 0 0 1px rgba(255, 255, 255, 0.06),
    0 0 22px rgba(255, 255, 255, 0.12);
}

/* PANELS WRAPPER */
.panels-wrapper {
  position: relative;
  display: flex;
  align-items: center;
  min-height: 100vh;
  padding-top: max(160px, calc((100vh - 600px) / 2));
  padding-bottom: max(120px, calc((100vh - 600px) / 2));
  overflow: hidden;
}

/* PANELS (horizontal) */
.panels {
  display: flex;
  gap: 0;
  padding: 0;
  overflow-x: auto;
  overflow-y: hidden;
  scroll-snap-type: x mandatory;
  scroll-behavior: smooth;
  -webkit-overflow-scrolling: touch;
  flex: 1;
  align-items: center;
  justify-content: flex-start;
  padding-left: 0;
  padding-right: 0;
  scroll-padding-left: 0;
  scroll-padding-right: 0;
}

/* NAVIGATION ARROWS */
.nav-arrow {
  position: fixed;
  top: 50%;
  transform: translateY(-50%);
  z-index: 20;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.15);
  color: #eaeaea;
  width: 50px;
  height: 50px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.3s ease;
  font-size: 1.5rem;
  font-weight: 300;
  backdrop-filter: blur(10px);
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
}

.nav-arrow:hover {
  background: rgba(255, 255, 255, 0.1);
  border-color: rgba(255, 255, 255, 0.25);
  transform: translateY(-50%) scale(1.1);
}

.nav-arrow:active {
  transform: translateY(-50%) scale(0.95);
}

.nav-arrow-left {
  left: 24px;
}

.nav-arrow-right {
  right: 24px;
}

.nav-arrow span {
  display: block;
  line-height: 1;
}

.nav-arrow:disabled {
  opacity: 0.3;
  cursor: not-allowed;
  pointer-events: none;
}

/* Hide scrollbar but keep scrolling functionality */
.panels {
  scrollbar-width: none; /* Firefox */
  -ms-overflow-style: none; /* IE and Edge */
}

.panels::-webkit-scrollbar {
  display: none; /* Chrome, Safari, Opera */
}

/* INDIVIDUAL PANEL */
.panel {
  width: 100vw;
  min-width: 100vw;
  max-width: 100vw;
  padding: 60px 40px;
  scroll-snap-align: center;
  scroll-snap-stop: always;
  flex-shrink: 0;
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  align-items: center;
  text-align: center;
  scroll-margin: 0;
  box-sizing: border-box;
  overflow-y: auto;
  overflow-x: hidden;
}

.panel > * {
  max-width: min(640px, calc(100vw - 80px));
  width: 100%;
  box-sizing: border-box;
}

/* SUBTLE APPLE-STYLE BORDER */
.bordered {
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 16px;
  background: linear-gradient(
    135deg,
    rgba(255, 255, 255, 0.04) 0%,
    rgba(255, 255, 255, 0.01) 100%
  );
  backdrop-filter: blur(10px);
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
}

/* HEADINGS */
h2 {
  margin-top: 0;
  margin-bottom: 24px;
  padding-top: 0;
  font-size: clamp(1.1rem, 2vw, 1.35rem);
  letter-spacing: 0.14em;
  color: #ffffff;
  font-weight: 500;
  scroll-margin-top: 0;
}

/* PARAGRAPHS */
.panel p {
  color: #d1d5db;
  line-height: 1.8;
  margin-bottom: 16px;
  max-width: 100%;
  word-wrap: break-word;
  overflow-wrap: break-word;
}

.panel p:last-child {
  margin-bottom: 0;
}

/* SYSTEM BLOCKS */
.systems-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
  width: 100%;
  max-width: 100%;
  margin-top: 20px;
  box-sizing: border-box;
}

.system-item {
  padding: 16px;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid rgba(255, 255, 255, 0.05);
  color: #d1d5db;
  line-height: 1.7;
  font-size: 0.95rem;
  max-width: 100%;
  box-sizing: border-box;
  word-wrap: break-word;
  overflow-wrap: break-word;
}

.system-item strong {
  color: #ffffff;
  font-weight: 500;
  display: block;
  margin-bottom: 4px;
  letter-spacing: 0.02em;
}

/* Responsive grid for mobile */
@media (max-width: 768px) {
  .systems-grid {
    grid-template-columns: 1fr;
    gap: 12px;
  }

  .system-item {
    padding: 14px;
    font-size: 0.9rem;
  }
}

/* FOOTER */
footer {
  position: fixed;
  bottom: 0;
  left: 0;
  width: 100%;
  padding: 20px;
  text-align: center;
  background: #0a0a0a;
  z-index: 10;
  border-top: 1px solid rgba(255, 255, 255, 0.05);
}

footer a {
  color: #eaeaea;
  text-decoration: none;
  border: 1px solid rgba(255, 255, 255, 0.15);
  padding: 10px 20px;
  font-size: 0.9rem;
  border-radius: 6px;
  transition: all 0.2s ease;
  display: inline-block;
}

footer a:hover {
  background: rgba(255, 255, 255, 0.1);
  border-color: rgba(255, 255, 255, 0.25);
}

footer .copyright {
  margin: 16px 0 0;
  color: #6b7280;
  font-size: 0.85rem;
  line-height: 1.5;
}

/* RESPONSIVE */
@media (max-width: 768px) {
  .hero {
    padding: 16px 16px 12px;
  }

  h1 {
    font-size: 1.6rem;
  }

  .tagline {
    font-size: 0.95rem;
    padding: 10px 14px;
    margin-top: 6px;
  }

  .panels-wrapper {
    padding-top: max(140px, calc((100vh - 500px) / 2));
    padding-bottom: max(100px, calc((100vh - 500px) / 2));
    overflow: hidden;
  }

  .panels {
    padding: 0;
    gap: 0;
    padding-left: 0;
    padding-right: 0;
    scroll-padding-left: 0;
    scroll-padding-right: 0;
  }

  .nav-arrow {
    width: 40px;
    height: 40px;
    font-size: 1.2rem;
  }

  .nav-arrow-left {
    left: 12px;
  }

  .nav-arrow-right {
    right: 12px;
  }

  .panel {
    min-width: 100vw;
    width: 100vw;
    padding: 40px 28px;
    overflow-y: auto;
    overflow-x: hidden;
    justify-content: flex-start;
  }

  .panel > * {
    max-width: calc(100vw - 56px);
  }

  h2 {
    font-size: 1.1rem;
    margin-top: 0;
    padding-top: 0;
  }

  footer .copyright {
    font-size: 0.8rem;
    margin-top: 12px;
  }
}

/* REDUCED MOTION */
@media (prefers-reduced-motion: reduce) {
  * {
    animation: none !important;
    transition: none !important;
  }
}
