/* === VARIABLES === */
:root {
  --bg-1: 6, 12, 26; /* deep navy */
  --bg-2: 12, 22, 48; /* darker blue */
  --accent1: 110, 78, 255; /* purple */
  --accent2: 0, 210, 255; /* aqua */
  --accent3: 255, 140, 97; /* coral */
  --glass: rgba(255, 255, 255, 0.03);
  --muted: rgba(255, 255, 255, 0.72);
  --card-shadow: 0 18px 50px rgba(2, 6, 23, 0.6);
  --radius-lg: 16px;
  --radius-md: 12px;
  --max-page-width: 1200px;
}

/* reset / base */
* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  opacity: 0;
  transition: opacity 0.5s ease;
}

body.fade-in {
  opacity: 1;
}

body.fade-out {
  opacity: 0;
}

html,
body {
  height: 100%;
  margin: 0;
  padding: 0;
}
body {
  font-family: "Inter", system-ui, -apple-system, "Segoe UI", Roboto,
    "Helvetica Neue", Arial;
  color: #e6eef8;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  background: linear-gradient(
      180deg,
      rgba(var(--bg-1), 1) 0%,
      rgba(var(--bg-2), 1) 65%
    ),
    radial-gradient(
      1200px 600px at 10% 10%,
      rgba(var(--accent1), 0.06),
      transparent 15%
    ),
    radial-gradient(
      1000px 500px at 90% 90%,
      rgba(var(--accent2), 0.04),
      transparent 12%
    );
  min-height: 100vh;
  position: relative;
  overflow-x: hidden;
}

/* make sure blobs are behind everything */
.bg-blobs {
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
}
.blob {
  position: absolute;
  filter: blur(60px);
  opacity: 0.22;
  transform: translate3d(0, 0, 0);
}
.b1 {
  width: 520px;
  height: 520px;
  left: -10%;
  top: -8%;
  background: radial-gradient(
    circle at 30% 30%,
    rgba(var(--accent1), 1),
    rgba(var(--accent2), 1)
  );
  animation: float1 14s ease-in-out infinite;
}
.b2 {
  width: 420px;
  height: 420px;
  right: -6%;
  top: 6%;
  background: radial-gradient(
    circle at 70% 30%,
    rgba(var(--accent3), 1),
    rgba(var(--accent2), 1)
  );
  animation: float2 16s ease-in-out infinite;
}
.b3 {
  width: 320px;
  height: 320px;
  left: 50%;
  bottom: -12%;
  background: radial-gradient(
    circle at 50% 50%,
    rgba(var(--accent2), 1),
    rgba(var(--accent1), 1)
  );
  animation: float3 18s ease-in-out infinite;
}

@keyframes float1 {
  0% {
    transform: translateY(0) rotate(0);
  }
  50% {
    transform: translateY(28px) rotate(6deg);
  }
  100% {
    transform: translateY(0) rotate(0);
  }
}
@keyframes float2 {
  0% {
    transform: translateY(0) rotate(0);
  }
  50% {
    transform: translateY(-22px) rotate(-5deg);
  }
  100% {
    transform: translateY(0) rotate(0);
  }
}
@keyframes float3 {
  0% {
    transform: translateY(0) rotate(0);
  }
  50% {
    transform: translateY(36px) rotate(10deg);
  }
  100% {
    transform: translateY(0) rotate(0);
  }
}

/* content container stacking */
.container,
.hero,
section {
  position: relative;
  z-index: 2;
  max-width: var(--max-page-width);
}

/* NAV */
.navbar {
  background: transparent;
  padding-top: 0.6rem;
  padding-bottom: 0.6rem;
}
.navbar-glass {
  background: linear-gradient(
    180deg,
    rgba(255, 255, 255, 0.02),
    rgba(255, 255, 255, 0.01)
  );
  border-radius: 12px;
  padding: 0.45rem 0.75rem;
  border: 1px solid rgba(255, 255, 255, 0.04);
  backdrop-filter: blur(6px);
  box-shadow: 0 6px 26px rgba(2, 6, 23, 0.45);
}

/* brand */
.brand-badge {
  width: 44px;
  height: 44px;
  border-radius: 10px;
  background: linear-gradient(
    135deg,
    rgba(var(--accent1), 1),
    rgba(var(--accent2), 1)
  );
  display: inline-grid;
  place-items: center;
  font-weight: 800;
  color: white;
  font-family: monospace;
  box-shadow: 0 8px 30px rgba(2, 6, 23, 0.5);
}

/* HERO */
.hero {
  padding-top: 3.25rem;
  padding-bottom: 3.25rem;
}
.device-card {
  width: 360px;
  max-width: 92%;
  margin: 0 auto;
  border-radius: 20px;
  padding: 14px;
  background: linear-gradient(
    180deg,
    rgba(255, 255, 255, 0.02),
    rgba(255, 255, 255, 0.01)
  );
  border: 1px solid rgba(255, 255, 255, 0.035);
  box-shadow: var(--card-shadow);
}
.device-card:hover {
  transition: all 0.25s ease;
  box-shadow: 1px 1px 25px 10px rgba(146, 148, 248, 0.4);
}
.device-card:before {
  content: "";
  background: linear-gradient(
    120deg,
    transparent,
    rgba(146, 148, 248, 0.4),
    transparent
  );
  transition: all 650ms;
}

.device-card:hover:before {
  left: 100%;
}
.screenshot {
  border-radius: 12px;
  width: 100%;
  height: auto;
  display: block;
}

/* Hero text */
.display-5 {
  color: #fff;
  letter-spacing: -0.5px;
}
.lead {
  color: rgba(255, 255, 255, 0.82);
}

/* Sections: subtle band & padding */
section {
  padding-top: 3.25rem;
  padding-bottom: 3.25rem;
}
#features,
#about,
#download {
  padding-left: 0.25rem;
  padding-right: 0.25rem;
}

/* Section inner card wrapper for subtle separation */
.section-inner {
  background: linear-gradient(
    180deg,
    rgba(255, 255, 255, 0.012),
    rgba(255, 255, 255, 0.007)
  );
  border-radius: 14px;
  padding: 1.25rem;
  border: 1px solid rgba(255, 255, 255, 0.02);
  box-shadow: 0 14px 40px rgba(2, 6, 23, 0.35);
}

/* section titles */
.section-title {
  font-weight: 700;
  margin-bottom: 0.5rem;
  color: #fff;
}

/* CARDS */
.card {
  background: linear-gradient(
    180deg,
    rgba(0, 0, 0, 0.18),
    rgba(255, 255, 255, 0.02)
  );
  border-radius: 12px;
  border: none;
  color: #eaf2ff;
}
.feature-card,
.download-card,
.about-card {
  border-radius: 14px;
  padding: 0;
  overflow: hidden;
}
.feature-card .card-body,
.about-card .card-body,
.download-card .card-body {
  background: transparent;
  padding: 1.35rem;
}

/* subtle hover */
.about-card:hover,
.feature-card:hover,
.download-card:hover,
.system-card:hover {
  transform: translateY(-6px);
  transition: transform 0.18s ease;
  box-shadow: 0 26px 70px rgba(2, 6, 23, 0.45);
}

/* Buttons */
.btn-glow {
  background: linear-gradient(
    90deg,
    rgba(var(--accent1), 1),
    rgba(var(--accent2), 1)
  );
  color: #fff;
  border: none;
  padding: 12px 18px;
  border-radius: 12px;
  font-weight: 600;
  box-shadow: 0 8px 38px rgba(12, 8, 60, 0.35);
  animation: pulse 2s infinite;
}
.btn-outline-light {
  border-radius: 12px;
  padding: 10px 16px;
}

/* different looking button */
.btn-dif {
  color: #000;
  background-color: #fff;
}
.btn-dif:hover {
  background-color: transparent;
  color: #fff;
}

/* download buttons */
.btn-download {
  display: inline-block;
  text-align: center;
  width: 100%;
  padding: 10px 12px;
  border-radius: 10px;
  background: linear-gradient(
    180deg,
    rgba(255, 255, 255, 0.015),
    rgba(255, 255, 255, 0.01)
  );
  color: #fff;
  border: 1px solid rgba(255, 255, 255, 0.035);
  font-weight: 600;
  transition: transform 0.14s ease, box-shadow 0.14s ease;
}
.btn-download:hover {
  transform: translateY(-4px);
  box-shadow: 0 18px 40px rgba(2, 6, 23, 0.45);
}

/* Gallery band */
#gallery {
  background: linear-gradient(
    180deg,
    rgba(255, 255, 255, 0.01),
    rgba(255, 255, 255, 0.005)
  );
  border-radius: 14px;
  padding: 1rem;
  box-shadow: 0 10px 30px rgba(2, 6, 23, 0.28);
}

/* gallery cards */
.gallery-card {
  overflow: hidden;
  border-radius: 12px;
  transition: transform 0.18s ease, box-shadow 0.18s ease;
  border: 1px solid rgba(255, 255, 255, 0.03);
}
.gallery-card img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.gallery-card:hover {
  transform: translateY(-6px) scale(1.01);
  box-shadow: 0 20px 40px rgba(2, 6, 23, 0.6);
}

/* small utilities */
.text-muted {
  color: rgba(255, 255, 255, 0.72) !important;
  font-size: 1.1rem;
}
small {
  color: rgba(255, 255, 255, 0.7);
}
footer {
  padding-top: 1.5rem;
  padding-bottom: 1.5rem;
  color: rgba(255, 255, 255, 0.7);
}

/* responsive */
@media (max-width: 991px) {
  .device-card {
    width: 280px;
  }
  .gallery-card img {
    height: 160px;
  }
}
@media (max-width: 575px) {
  .display-5 {
    font-size: 28px;
  }
  .screenshot {
    max-height: 520px;
  }
  .gallery-card img {
    height: 130px;
  }
}

/* slightly dark backdrop inside modal content for focus */
.modal-content.bg-transparent {
  background: rgba(6, 10, 25, 0.65);
  backdrop-filter: blur(6px);
  border-radius: 12px;
  overflow: hidden;
}

/* ---- modal crossfade helpers ---- */
/* modal image fade */
#modalImage {
  transition: opacity 0.45s ease;
  opacity: 0.4;
  will-change: opacity;
}
#modalImage.visible {
  opacity: 1;
}

/* modal content darken */
.modal-content.bg-transparent {
  background: rgba(6, 10, 25, 0.75);
  backdrop-filter: blur(6px);
  border-radius: 12px;
  overflow: hidden;
}

/* ---- full-page blur when modal open ---- */
#site-root.blurred {
  filter: blur(8px) brightness(0.86);
  transition: filter 0.22s ease;
  pointer-events: none; /* prevent interaction while modal open */
  user-select: none;
}

/* re-enable pointer events for modal close button (modal is outside site-root) */
/* ---- report button ---- */
.btn-report {
  position: fixed;
  right: 18px;
  bottom: 18px;
  z-index: 1200;
  border-radius: 12px;
  padding: 12px 16px;
  font-weight: 600;
  color: #fff;
  border: none;

  background-repeat: no-repeat;
  background-size: 120% 100%;
  background-position: center;

  /* subtle inset highlight + drop shadow for depth */
  box-shadow: 0 12px 36px rgba(6, 10, 25, 0.6),
    inset 0 1px 0 rgba(255, 255, 255, 0.06);

  /* avoid rasterization artifacts */
  -webkit-font-smoothing: antialiased;
  transform: translateZ(0);

  /* accessibility */
  outline: none;
}

/* focus style */
.btn-report:focus {
  box-shadow: 0 12px 36px rgba(6, 10, 25, 0.6),
    0 0 0 4px rgba(110, 78, 255, 0.12);
}

/* slightly smaller on phones */
@media (max-width: 575px) {
  .btn-report {
    right: 12px;
    bottom: 12px;
    padding: 10px 12px;
    font-size: 14px;
  }
}

/* ---- page transition classes ---- */
body.fade-in {
  opacity: 1;
  transition: opacity 0.2s ease;
}
body.fade-out {
  opacity: 0;
  transition: opacity 0.2s ease;
}

/* accessibility: reduce motion */
@media (prefers-reduced-motion: reduce) {
  .blob,
  * {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
  }
}

/* Release notes specific */
.release-card {
  background: rgba(255, 255, 255, 0.08);
  border-radius: 16px;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.release-card:hover {
  transform: translateY(-4px) scale(1.01);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.5);
  background: rgba(255, 255, 255, 0.1);
}
.tag-badge {
  display: inline-block;
  padding: 0.25rem 0.6rem;
  border-radius: 999px;
  font-size: 0.75rem;
  font-weight: 600;
  margin-left: 0.25rem;
  color: #fff;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.25);
}
.tag-badge:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.5);
  background: rgba(255, 255, 255, 0.1);
}

@keyframes pulse {
  0% {
    box-shadow: 0 0 0 0 rgba(var(--accent1), 0.7);
  }
  70% {
    box-shadow: 0 0 0 10px rgba(var(--accent1), 0);
  }
  100% {
    box-shadow: 0 0 0 0 rgba(var(--accent1), 0);
  }
}
