/* ============================================
   X F Box — Components
   ============================================ */

/* ── Navbar ─────────────────────────────────────── */
.navbar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: var(--nav-height);
  z-index: 100;
  display: flex;
  align-items: center;
  transition: background var(--dur-base) var(--ease-out),
              border-color var(--dur-base) var(--ease-out),
              backdrop-filter var(--dur-base) var(--ease-out);
  border-bottom: 1px solid transparent;
}

.navbar.is-scrolled {
  background: rgba(6, 7, 13, 0.72);
  backdrop-filter: saturate(180%) blur(20px);
  -webkit-backdrop-filter: saturate(180%) blur(20px);
  border-bottom-color: var(--border-subtle);
}

.navbar__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  max-width: var(--container-max);
  margin: 0 auto;
  padding: 0 var(--container-pad);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 18px;
  letter-spacing: -0.02em;
  color: var(--text-primary);
  position: relative;
}

.brand__mark {
  width: 32px;
  height: 32px;
  border-radius: 8px;
  background: var(--gradient-brand);
  display: grid;
  place-items: center;
  box-shadow: 0 4px 20px rgba(0, 229, 255, 0.35);
  position: relative;
  overflow: hidden;
}

.brand__mark::before {
  content: '';
  position: absolute;
  inset: 1px;
  border-radius: 7px;
  background: var(--bg-base);
}

.brand__mark span {
  position: relative;
  z-index: 1;
  font-size: 14px;
  font-weight: 800;
  background: var(--gradient-brand);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

.brand__name { display: inline-flex; gap: 4px; }
.brand__name b { color: var(--accent-cyan); font-weight: 700; }

.nav-links {
  display: flex;
  align-items: center;
  gap: 4px;
}

.nav-links a {
  padding: 8px 16px;
  border-radius: var(--radius-full);
  font-size: 14px;
  font-weight: 500;
  color: var(--text-secondary);
  transition: all var(--dur-fast) var(--ease-out);
  position: relative;
}

.nav-links a:hover {
  color: var(--text-primary);
  background: rgba(255, 255, 255, 0.04);
}

.nav-links a.is-active {
  color: var(--accent-cyan);
  background: rgba(0, 229, 255, 0.08);
}

.nav-actions {
  display: flex;
  align-items: center;
  gap: 12px;
}

.nav-toggle {
  display: none;
  width: 40px;
  height: 40px;
  border-radius: 8px;
  border: 1px solid var(--border-default);
  background: var(--bg-card);
  align-items: center;
  justify-content: center;
}

@media (max-width: 860px) {
  .nav-links { display: none; }
  .nav-toggle { display: inline-flex; }
}

/* ── Buttons ────────────────────────────────────── */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px 24px;
  font-family: var(--font-body);
  font-size: 14px;
  font-weight: 600;
  letter-spacing: 0.01em;
  border-radius: var(--radius-full);
  transition: all var(--dur-base) var(--ease-out);
  cursor: pointer;
  position: relative;
  overflow: hidden;
  white-space: nowrap;
  border: 1px solid transparent;
}

.btn--primary {
  background: var(--gradient-brand);
  color: #06070D;
  box-shadow:
    0 6px 24px rgba(0, 229, 255, 0.30),
    inset 0 1px 0 rgba(255, 255, 255, 0.3);
}

.btn--primary:hover {
  transform: translateY(-2px);
  box-shadow:
    0 10px 32px rgba(0, 229, 255, 0.45),
    inset 0 1px 0 rgba(255, 255, 255, 0.3);
}

.btn--ghost {
  background: rgba(255, 255, 255, 0.04);
  color: var(--text-primary);
  border-color: var(--border-default);
  backdrop-filter: blur(10px);
}

.btn--ghost:hover {
  background: rgba(255, 255, 255, 0.08);
  border-color: var(--border-strong);
  transform: translateY(-2px);
}

.btn--lg { padding: 16px 32px; font-size: 15px; }
.btn--sm { padding: 8px 16px; font-size: 13px; }
.btn--block { display: flex; width: 100%; }

.btn__icon { width: 16px; height: 16px; flex-shrink: 0; }

/* ── Cards ──────────────────────────────────────── */
.card {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-xl);
  padding: var(--space-6);
  position: relative;
  transition: all var(--dur-base) var(--ease-out);
  overflow: hidden;
}

.card--hover:hover {
  border-color: var(--border-default);
  background: var(--bg-card-hover);
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
}

.card--glass {
  background: var(--bg-glass);
  backdrop-filter: blur(20px) saturate(180%);
  -webkit-backdrop-filter: blur(20px) saturate(180%);
}

/* ── Badge / Pill ───────────────────────────────── */
.badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 12px;
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  border-radius: var(--radius-full);
  background: rgba(0, 229, 255, 0.10);
  color: var(--accent-cyan);
  border: 1px solid rgba(0, 229, 255, 0.20);
}

.badge--violet { background: rgba(176, 38, 255, 0.10); color: var(--accent-violet); border-color: rgba(176, 38, 255, 0.25); }
.badge--pink   { background: rgba(255, 45, 120, 0.10); color: var(--accent-pink); border-color: rgba(255, 45, 120, 0.25); }
.badge--lime   { background: rgba(198, 255, 61, 0.10); color: var(--accent-lime); border-color: rgba(198, 255, 61, 0.25); }
.badge--new    { background: var(--gradient-warm); color: white; border: none; }

/* ── Product Card ───────────────────────────────── */
.product-card {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-2xl);
  overflow: hidden;
  position: relative;
  transition: all var(--dur-base) var(--ease-out);
  isolation: isolate;
}

.product-card::before {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at var(--mx, 50%) var(--my, 0%),
              rgba(0, 229, 255, 0.12), transparent 50%);
  opacity: 0;
  transition: opacity var(--dur-base) var(--ease-out);
  pointer-events: none;
  z-index: 0;
}

.product-card:hover {
  border-color: rgba(0, 229, 255, 0.30);
  transform: translateY(-6px);
  box-shadow:
    0 24px 60px rgba(0, 0, 0, 0.5),
    0 0 80px rgba(0, 229, 255, 0.10);
}

.product-card:hover::before { opacity: 1; }

.product-card__media {
  aspect-ratio: 4 / 3;
  background:
    radial-gradient(circle at 30% 30%, rgba(0, 229, 255, 0.18), transparent 60%),
    radial-gradient(circle at 70% 70%, rgba(176, 38, 255, 0.18), transparent 60%),
    linear-gradient(135deg, #14171F 0%, #0B0D14 100%);
  position: relative;
  display: grid;
  place-items: center;
  overflow: hidden;
}

.product-card__media::after {
  content: '';
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.03) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.03) 1px, transparent 1px);
  background-size: 28px 28px;
  pointer-events: none;
}

.product-card__body {
  padding: var(--space-5) var(--space-6) var(--space-6);
  position: relative;
  z-index: 1;
}

.product-card__title {
  font-size: 1.25rem;
  font-weight: 600;
  margin-bottom: 4px;
}

.product-card__subtitle {
  color: var(--text-secondary);
  font-size: 14px;
  margin-bottom: var(--space-4);
}

.product-card__specs {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: var(--space-5);
}

.product-card__specs li {
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--text-muted);
  padding: 4px 10px;
  background: rgba(255, 255, 255, 0.03);
  border-radius: var(--radius-full);
  border: 1px solid var(--border-subtle);
}

.product-card__footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-top: var(--space-4);
  border-top: 1px solid var(--border-subtle);
}

.product-card__price {
  font-family: var(--font-display);
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--text-primary);
}

.product-card__price small {
  font-size: 13px;
  color: var(--text-muted);
  font-weight: 400;
  margin-left: 4px;
}

/* ── Stat block ─────────────────────────────────── */
.stat {
  text-align: left;
}
.stat__value {
  font-family: var(--font-display);
  font-size: clamp(2.5rem, 5vw, 3.75rem);
  font-weight: 700;
  letter-spacing: -0.03em;
  background: var(--gradient-cool);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  line-height: 1;
}
.stat__label {
  margin-top: 8px;
  color: var(--text-secondary);
  font-size: 14px;
}

/* ── Feature card ───────────────────────────────── */
.feature {
  padding: var(--space-6);
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-xl);
  transition: all var(--dur-base) var(--ease-out);
  position: relative;
  overflow: hidden;
}

.feature:hover {
  border-color: var(--border-default);
  transform: translateY(-3px);
  background: var(--bg-card-hover);
}

.feature__icon {
  width: 48px;
  height: 48px;
  border-radius: var(--radius-md);
  background: rgba(0, 229, 255, 0.08);
  border: 1px solid rgba(0, 229, 255, 0.20);
  display: grid;
  place-items: center;
  margin-bottom: var(--space-5);
  color: var(--accent-cyan);
}

.feature__title {
  font-size: 1.125rem;
  margin-bottom: 8px;
}

.feature__desc {
  color: var(--text-secondary);
  font-size: 14px;
  line-height: 1.6;
}

/* ── Footer ─────────────────────────────────────── */
.footer {
  border-top: 1px solid var(--border-subtle);
  background: var(--bg-elevated);
  padding: var(--space-9) 0 var(--space-6);
  position: relative;
  z-index: 1;
}

.footer__grid {
  display: grid;
  grid-template-columns: 1.4fr repeat(3, 1fr);
  gap: var(--space-7);
  margin-bottom: var(--space-8);
}

@media (max-width: 768px) {
  .footer__grid { grid-template-columns: 1fr 1fr; gap: var(--space-6); }
}

.footer__col h4 {
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--text-muted);
  margin-bottom: var(--space-4);
}

.footer__col ul li {
  margin-bottom: var(--space-3);
}

.footer__col ul li a {
  color: var(--text-secondary);
  font-size: 14px;
  transition: color var(--dur-fast) var(--ease-out);
}

.footer__col ul li a:hover {
  color: var(--accent-cyan);
}

.footer__bottom {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-top: var(--space-6);
  border-top: 1px solid var(--border-subtle);
  font-size: 13px;
  color: var(--text-muted);
  flex-wrap: wrap;
  gap: var(--space-3);
}

.footer__social {
  display: flex;
  gap: 8px;
}

.footer__social a {
  width: 36px;
  height: 36px;
  display: grid;
  place-items: center;
  border-radius: var(--radius-full);
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  color: var(--text-secondary);
  transition: all var(--dur-fast) var(--ease-out);
}

.footer__social a:hover {
  color: var(--accent-cyan);
  border-color: rgba(0, 229, 255, 0.30);
  background: rgba(0, 229, 255, 0.06);
  transform: translateY(-2px);
}

/* ── Glow Orbs (decorative) ─────────────────────── */
.glow-orb {
  position: absolute;
  border-radius: 50%;
  filter: blur(80px);
  opacity: 0.55;
  pointer-events: none;
  z-index: 0;
}

.glow-orb--cyan   { background: rgba(0, 229, 255, 0.45); }
.glow-orb--violet { background: rgba(176, 38, 255, 0.40); }
.glow-orb--pink   { background: rgba(255, 45, 120, 0.35); }

/* ── Divider ────────────────────────────────────── */
.divider {
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--border-default), transparent);
  margin: var(--space-7) 0;
}

/* ── Mobile Menu ────────────────────────────────── */
.mobile-menu {
  position: fixed;
  top: var(--nav-height);
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(6, 7, 13, 0.96);
  backdrop-filter: blur(24px);
  z-index: 99;
  padding: var(--space-6) var(--container-pad);
  transform: translateX(100%);
  transition: transform var(--dur-base) var(--ease-out);
  display: flex;
  flex-direction: column;
  gap: var(--space-3);
}

.mobile-menu.is-open { transform: translateX(0); }

.mobile-menu a {
  padding: var(--space-4);
  border-radius: var(--radius-md);
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  font-family: var(--font-display);
  font-size: 1.25rem;
  font-weight: 500;
  color: var(--text-primary);
}

.mobile-menu a:hover { background: var(--bg-card-hover); }

/* ── Tabs ───────────────────────────────────────── */
.tabs {
  display: inline-flex;
  padding: 4px;
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-full);
  gap: 2px;
}

.tabs__item {
  padding: 8px 18px;
  font-size: 13px;
  font-weight: 500;
  color: var(--text-secondary);
  border-radius: var(--radius-full);
  transition: all var(--dur-fast) var(--ease-out);
  cursor: pointer;
}

.tabs__item.is-active {
  background: var(--gradient-brand);
  color: #06070D;
}

/* ── Forms ──────────────────────────────────────── */
.form-group {
  margin-bottom: var(--space-5);
}

.form-label {
  display: block;
  font-size: 13px;
  font-weight: 500;
  color: var(--text-secondary);
  margin-bottom: 8px;
  font-family: var(--font-mono);
  letter-spacing: 0.04em;
}

.form-input,
.form-textarea,
.form-select {
  width: 100%;
  padding: 14px 16px;
  background: var(--bg-base);
  border: 1px solid var(--border-default);
  border-radius: var(--radius-md);
  color: var(--text-primary);
  font-family: var(--font-body);
  font-size: 15px;
  transition: all var(--dur-fast) var(--ease-out);
}

.form-input:focus,
.form-textarea:focus,
.form-select:focus {
  outline: none;
  border-color: var(--accent-cyan);
  box-shadow: 0 0 0 4px rgba(0, 229, 255, 0.10);
  background: var(--bg-elevated);
}

.form-textarea {
  min-height: 140px;
  resize: vertical;
  font-family: var(--font-body);
}

/* ── Marquee ────────────────────────────────────── */
.marquee {
  overflow: hidden;
  position: relative;
  mask-image: linear-gradient(90deg, transparent, black 10%, black 90%, transparent);
}

.marquee__track {
  display: flex;
  gap: 64px;
  animation: marquee 30s linear infinite;
  white-space: nowrap;
}

@keyframes marquee {
  to { transform: translateX(-50%); }
}

/* ── Hero Product Render (CSS-only) ─────────────── */
.render-box {
  --size: clamp(280px, 38vw, 480px);
  width: var(--size);
  height: var(--size);
  position: relative;
  perspective: 1200px;
  margin: 0 auto;
}

.render-box__inner {
  position: absolute;
  inset: 0;
  transform-style: preserve-3d;
  animation: tilt 12s ease-in-out infinite;
}

@keyframes tilt {
  0%, 100% { transform: rotateY(-12deg) rotateX(8deg) translateZ(0); }
  50%      { transform: rotateY(12deg)  rotateX(-4deg) translateZ(0); }
}

.render-box__glow {
  position: absolute;
  inset: 10%;
  border-radius: 32px;
  background: radial-gradient(circle, rgba(0, 229, 255, 0.4), transparent 70%);
  filter: blur(40px);
  animation: pulse-glow 4s ease-in-out infinite;
}

@keyframes pulse-glow {
  0%, 100% { opacity: 0.4; transform: scale(1); }
  50%      { opacity: 0.7; transform: scale(1.1); }
}

/* ── Spec table ─────────────────────────────────── */
.spec-table {
  width: 100%;
  border-collapse: collapse;
}
.spec-table tr {
  border-bottom: 1px solid var(--border-subtle);
}
.spec-table th,
.spec-table td {
  padding: var(--space-4) var(--space-5);
  text-align: left;
  font-size: 14px;
}
.spec-table th {
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--text-muted);
  background: var(--bg-elevated);
}
.spec-table td:first-child {
  color: var(--text-secondary);
  font-weight: 500;
}
.spec-table td:last-child {
  color: var(--text-primary);
  font-family: var(--font-mono);
  font-size: 13px;
}

/* ── Container helpers ──────────────────────────── */
.grid { display: grid; gap: var(--space-5); }
.grid-2 { grid-template-columns: repeat(2, 1fr); }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.grid-4 { grid-template-columns: repeat(4, 1fr); }

@media (max-width: 960px) {
  .grid-3, .grid-4 { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 640px) {
  .grid-2, .grid-3, .grid-4 { grid-template-columns: 1fr; }
}

.flex { display: flex; }
.flex-center { display: flex; align-items: center; justify-content: center; }
.flex-between { display: flex; align-items: center; justify-content: space-between; }
.gap-2 { gap: var(--space-2); }
.gap-3 { gap: var(--space-3); }
.gap-4 { gap: var(--space-4); }
.gap-5 { gap: var(--space-5); }

.mt-4 { margin-top: var(--space-4); }
.mt-5 { margin-top: var(--space-5); }
.mt-6 { margin-top: var(--space-6); }
.mt-7 { margin-top: var(--space-7); }

.text-center { text-align: center; }
.text-secondary { color: var(--text-secondary); }
.text-muted { color: var(--text-muted); }
