/* ===== Variables ===== */
:root {
  --bg-dark: #0a0c10;
  --bg-card: #12151c;
  --bg-elevated: #161a24;
  --text: #e4e8ef;
  --text-muted: #8b92a4;
  --accent: #00d4aa;
  --accent-dim: rgba(0, 212, 170, 0.15);
  --accent-glow: rgba(0, 212, 170, 0.25);
  --border: rgba(255, 255, 255, 0.06);
  --font-sans: "DM Sans", system-ui, sans-serif;
  --font-mono: "JetBrains Mono", monospace;
  --radius: 10px;
  --radius-lg: 16px;
  --space: 1.25rem;
  --max-width: 1100px;
}

/* ===== Reset & Base ===== */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: var(--font-sans);
  font-size: 1rem;
  line-height: 1.6;
  color: var(--text);
  background: var(--bg-dark);
  -webkit-font-smoothing: antialiased;
}

a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; }
img { max-width: 100%; height: auto; display: block; }

.container {
  width: 100%;
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 var(--space);
}

/* ===== Header ===== */
.header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  padding: 1rem 0;
  background: rgba(10, 12, 16, 0.85);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
}

.header .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.logo {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  color: var(--text);
  font-weight: 700;
  font-size: 1.25rem;
  text-decoration: none;
}

.logo:hover { text-decoration: none; color: var(--accent); }

.logo-icon {
  color: var(--accent);
  font-size: 1.35rem;
}

.nav {
  display: flex;
  gap: 2rem;
}

.nav a {
  color: var(--text-muted);
  font-weight: 500;
  font-size: 0.95rem;
  transition: color 0.2s;
}

.nav a:hover { color: var(--accent); text-decoration: none; }

/* ===== Activity Areas Dropdown ===== */
.nav-dropdown {
  position: relative;
}

.nav-dropdown-trigger {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  padding: 0;
  border: none;
  background: none;
  font-family: var(--font-sans);
  font-weight: 500;
  font-size: 0.95rem;
  color: var(--text-muted);
  cursor: pointer;
  transition: color 0.2s;
}

.nav-dropdown-trigger:hover,
.nav-dropdown-trigger.is-open {
  color: var(--accent);
}

.dropdown-arrow {
  font-size: 0.65rem;
  transition: transform 0.2s;
}

.nav-dropdown-trigger.is-open .dropdown-arrow {
  transform: rotate(180deg);
}

.nav-dropdown-menu {
  position: absolute;
  top: 100%;
  left: 50%;
  transform: translateX(-50%) translateY(0.5rem);
  min-width: 260px;
  padding: 1rem 0;
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.4);
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition: opacity 0.2s, visibility 0.2s, transform 0.2s;
  z-index: 200;
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

.nav-dropdown-menu[aria-hidden="false"] {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
  transform: translateX(-50%) translateY(0.25rem);
}

.dropdown-column {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

.nav-dropdown-menu .dropdown-column {
  flex: none;
}

.nav-dropdown-item {
  padding: 0.5rem 1rem;
  border-radius: 6px;
}

.nav-dropdown-item a {
  color: var(--text);
  font-size: 0.95rem;
  display: block;
}

.nav-dropdown-item a:hover {
  color: var(--accent);
  text-decoration: none;
}

.nav-dropdown-item.has-submenu {
  position: relative;
}

.nav-dropdown-item .dropdown-label {
  display: block;
  color: var(--text);
  font-weight: 600;
  font-size: 0.9rem;
  padding: 0.5rem 1rem;
  border-radius: 6px;
}

.nav-dropdown-submenu {
  list-style: none;
  margin: 0.25rem 0 0 0;
  padding: 0 0 0 1rem;
  border-left: 2px solid var(--accent-dim);
  max-height: 0;
  overflow: hidden;
  opacity: 0;
  transition: max-height 0.2s ease, opacity 0.2s;
}

.nav-dropdown-item.has-submenu:hover .nav-dropdown-submenu {
  max-height: 200px;
  opacity: 1;
}

.nav-dropdown-submenu li {
  margin: 0;
}

.nav-dropdown-submenu a {
  display: block;
  padding: 0.4rem 0.75rem;
  font-size: 0.9rem;
  color: var(--text-muted);
  font-weight: 400;
}

.nav-dropdown-submenu a:hover {
  color: var(--accent);
}

@media (max-width: 768px) {
  .nav-dropdown-menu {
    position: static;
    transform: none;
    min-width: auto;
    max-height: 0;
    overflow: hidden;
    margin-top: 0;
    padding: 0 1rem;
    grid-template-columns: 1fr;
    box-shadow: none;
    border: none;
    background: transparent;
  }

  .nav-dropdown-menu[aria-hidden="false"] {
    max-height: 400px;
    margin-top: 0.5rem;
    padding: 0.5rem 1rem 1rem;
    border-top: 1px solid var(--border);
  }

  .nav-dropdown-trigger {
    width: 100%;
    justify-content: space-between;
    text-align: left;
  }
}

.nav-toggle {
  display: none;
  width: 28px;
  height: 28px;
  padding: 0;
  border: none;
  background: transparent;
  cursor: pointer;
  position: relative;
}

.nav-toggle::before,
.nav-toggle::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  height: 2px;
  background: var(--text);
  transition: transform 0.2s;
}

.nav-toggle::before { top: 6px; }
.nav-toggle::after { bottom: 6px; }

.nav-toggle.is-open::before {
  top: 13px;
  transform: rotate(45deg);
}

.nav-toggle.is-open::after {
  bottom: 13px;
  transform: rotate(-45deg);
}

@media (max-width: 768px) {
  .nav {
    position: fixed;
    top: 57px;
    left: 0;
    right: 0;
    flex-direction: column;
    padding: 1.5rem;
    background: var(--bg-elevated);
    border-bottom: 1px solid var(--border);
    gap: 1rem;
    transform: translateY(-100%);
    opacity: 0;
    pointer-events: none;
    transition: transform 0.25s, opacity 0.25s;
  }

  .nav.is-open {
    transform: translateY(0);
    opacity: 1;
    pointer-events: auto;
  }

  .nav-toggle { display: block; }
}

/* ===== Hero ===== */
.hero {
  position: relative;
  min-height: 100vh;
  display: flex;
  align-items: center;
  padding: 6rem 0 4rem;
  overflow: hidden;
}

.hero-bg {
  position: absolute;
  inset: 0;
  pointer-events: none;
}

.grid-overlay {
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(255,255,255,0.02) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,0.02) 1px, transparent 1px);
  background-size: 60px 60px;
  mask-image: radial-gradient(ellipse 80% 60% at 50% 40%, black, transparent 70%);
}

.waveform {
  position: absolute;
  bottom: 15%;
  left: 0;
  right: 0;
  height: 120px;
  background: linear-gradient(90deg,
    transparent 0%,
    var(--accent-dim) 20%,
    var(--accent-glow) 50%,
    var(--accent-dim) 80%,
    transparent 100%);
  opacity: 0.6;
  filter: blur(40px);
  animation: pulse 4s ease-in-out infinite;
}

@keyframes pulse {
  0%, 100% { opacity: 0.4; transform: scaleY(0.8); }
  50% { opacity: 0.7; transform: scaleY(1); }
}

.hero-content {
  position: relative;
  z-index: 1;
}

.hero-label {
  font-family: var(--font-mono);
  font-size: 0.85rem;
  color: var(--accent);
  text-transform: uppercase;
  letter-spacing: 0.15em;
  margin-bottom: 1rem;
}

.hero-title {
  font-size: clamp(2.5rem, 6vw, 4rem);
  font-weight: 700;
  line-height: 1.15;
  letter-spacing: -0.02em;
  margin: 0 0 1.25rem;
  max-width: 14ch;
}

.hero-title .highlight {
  color: var(--accent);
  position: relative;
}

.hero-desc {
  font-size: 1.15rem;
  color: var(--text-muted);
  max-width: 42ch;
  margin: 0 0 2rem;
}

.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.85rem 1.75rem;
  font-family: var(--font-sans);
  font-weight: 600;
  font-size: 1rem;
  border-radius: var(--radius);
  border: none;
  cursor: pointer;
  transition: background 0.2s, transform 0.15s;
}

.btn-primary {
  background: var(--accent);
  color: var(--bg-dark);
  text-decoration: none;
}

.btn-primary:hover {
  background: #00e6b8;
  text-decoration: none;
  transform: translateY(-1px);
}

.scroll-hint {
  position: absolute;
  bottom: 2rem;
  left: 50%;
  transform: translateX(-50%);
  width: 24px;
  height: 40px;
  border: 2px solid var(--text-muted);
  border-radius: 12px;
  opacity: 0.6;
}

.scroll-hint span {
  position: absolute;
  top: 8px;
  left: 50%;
  transform: translateX(-50%);
  width: 4px;
  height: 8px;
  background: var(--accent);
  border-radius: 2px;
  animation: scroll-bounce 2s ease-in-out infinite;
}

@keyframes scroll-bounce {
  0%, 100% { opacity: 1; transform: translateX(-50%) translateY(0); }
  50% { opacity: 0.5; transform: translateX(-50%) translateY(8px); }
}

/* ===== Sections ===== */
.section {
  padding: 5rem 0;
}

.section-title {
  font-size: clamp(1.75rem, 3vw, 2.25rem);
  font-weight: 700;
  letter-spacing: -0.02em;
  margin: 0 0 0.5rem;
}

.section-intro {
  color: var(--text-muted);
  font-size: 1.1rem;
  margin-bottom: 2.5rem;
  max-width: 55ch;
}

/* ===== About ===== */
.about-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 3rem;
  align-items: start;
}

.about-content .lead {
  font-size: 1.2rem;
  color: var(--text);
  margin: 0 0 1.25rem;
}

.about-content p {
  margin: 0 0 1rem;
  color: var(--text-muted);
}

.card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 1.75rem;
}

.card-accent {
  border-color: var(--accent-dim);
  background: linear-gradient(135deg, var(--bg-card) 0%, rgba(0, 212, 170, 0.05) 100%);
}

.card-label {
  font-family: var(--font-mono);
  font-size: 0.8rem;
  color: var(--accent);
  text-transform: uppercase;
  letter-spacing: 0.1em;
  display: block;
  margin-bottom: 1rem;
}

.focus-list {
  list-style: none;
  margin: 0;
  padding: 0;
}

.focus-list li {
  position: relative;
  padding-left: 1.25rem;
  margin-bottom: 0.75rem;
  color: var(--text);
}

.focus-list li::before {
  content: "▹";
  position: absolute;
  left: 0;
  color: var(--accent);
}

@media (max-width: 768px) {
  .about-grid {
    grid-template-columns: 1fr;
  }
}

/* ===== Services ===== */
.services {
  background: var(--bg-elevated);
}

.services-grid {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 1.5rem;
}

.service-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 1.75rem;
  transition: border-color 0.2s, box-shadow 0.2s;
}

.service-card:hover {
  border-color: var(--accent-dim);
  box-shadow: 0 0 0 1px var(--accent-dim);
}

.service-icon {
  font-size: 2rem;
  color: var(--accent);
  margin-bottom: 1rem;
  font-family: var(--font-mono);
}

.service-card h3 {
  font-size: 1.15rem;
  font-weight: 600;
  margin: 0 0 0.5rem;
}

.service-card p {
  margin: 0;
  font-size: 0.95rem;
  color: var(--text-muted);
  line-height: 1.55;
}

/* ===== Contact ===== */
.contact-block {
  max-width: 480px;
}

.contact-link {
  display: inline-block;
  padding: 1.25rem 1.5rem;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  transition: border-color 0.2s, background 0.2s;
  text-decoration: none;
}

.contact-link:hover {
  border-color: var(--accent-dim);
  background: var(--bg-elevated);
  text-decoration: none;
}

.contact-label {
  display: block;
  font-family: var(--font-mono);
  font-size: 0.8rem;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin-bottom: 0.25rem;
}

.contact-value {
  font-size: 1.15rem;
  font-weight: 500;
  color: var(--accent);
}

.contact-note {
  margin-top: 1rem;
  font-size: 0.9rem;
  color: var(--text-muted);
}

/* ===== Footer ===== */
.footer {
  padding: 2rem 0;
  border-top: 1px solid var(--border);
}

.footer-inner {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 1rem;
}

.footer-inner .logo-footer {
  justify-self: start;
}

.footer-inner .footer-contact-link {
  justify-self: center;
}

.footer-inner .footer-copy {
  justify-self: end;
  margin: 0;
}

.logo-footer {
  color: var(--text-muted);
  font-size: 1rem;
}

.logo-footer:hover { color: var(--accent); }

.footer-copy {
  margin: 0;
  font-size: 0.9rem;
  color: var(--text-muted);
}

.footer-contact-link {
  font-size: 0.75rem;
  color: var(--text-muted);
  margin: 0;
}

.footer-contact-link:hover {
  color: var(--accent);
}

/* ===== Inner page layout ===== */
.page-header {
  padding: 7rem 0 3rem;
  border-bottom: 1px solid var(--border);
}

.page-header .breadcrumb {
  font-family: var(--font-mono);
  font-size: 0.8rem;
  color: var(--text-muted);
  margin-bottom: 0.75rem;
}

.page-header .breadcrumb a {
  color: var(--text-muted);
}

.page-header .breadcrumb a:hover {
  color: var(--accent);
}

.page-title {
  font-size: clamp(1.75rem, 3vw, 2.25rem);
  font-weight: 700;
  margin: 0;
}

/* ===== Product list ===== */
.products-section {
  padding: 3rem 0 5rem;
}

.products-section .section-title {
  margin-bottom: 1.5rem;
}

.products-grid {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 1.5rem;
}

.product-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 1.75rem;
  transition: border-color 0.2s, box-shadow 0.2s;
}

.product-card:hover {
  border-color: var(--accent-dim);
  box-shadow: 0 0 0 1px var(--accent-dim);
}

.product-card a {
  color: inherit;
  text-decoration: none;
  display: block;
}

.product-card a:hover {
  color: var(--accent);
}

.product-card h3 {
  font-size: 1.15rem;
  font-weight: 600;
  margin: 0 0 0.5rem;
}

.product-card p {
  margin: 0;
  font-size: 0.95rem;
  color: var(--text-muted);
  line-height: 1.5;
}
