/* Hard Disk Sentinel — harddisksentinel.io companion styles */

:root {
  scroll-behavior: smooth;
}

/* Screen-reader only (works without Tailwind purge) */
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border-width: 0;
}

/* Section heading icon — mint token, reusable on long pages */
.section-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2.75rem;
  height: 2.75rem;
  border-radius: 0.875rem;
  border: 1px solid rgb(20 184 166 / 0.22);
  background: linear-gradient(145deg, rgb(20 184 166 / 0.12) 0%, rgb(20 184 166 / 0.05) 100%);
  color: #0d9488;
  box-shadow: 0 1px 2px rgb(15 23 42 / 0.04);
}

.section-icon--lg {
  width: 3rem;
  height: 3rem;
  border-radius: 1rem;
}

@media (min-width: 640px) {
  .section-icon--lg {
    width: 3.25rem;
    height: 3.25rem;
  }
}

/* —— Global site header: dark rail —— */
header.site-nav-primary {
  border-radius: 0;
  overflow: visible;
  border-bottom: 1px solid rgb(51 65 85 / 0.9);
  background: linear-gradient(165deg, #0f172a 0%, #1e293b 42%, #0f172a 100%);
  box-shadow: 0 12px 36px rgb(0 0 0 / 0.38);
}

header.site-nav-primary > div:first-of-type {
  overflow: visible;
  max-width: 90rem;
  flex-wrap: nowrap;
  align-items: center;
  min-height: 3.75rem;
  padding-top: 0.6rem;
  padding-bottom: 0.6rem;
}

header.site-nav-primary > div:first-of-type > a:first-of-type {
  color: #f8fafc !important;
  flex-shrink: 0;
  white-space: nowrap;
}

header.site-nav-primary > div:first-of-type > a:first-of-type span {
  white-space: nowrap;
}

/* Long German labels used to wrap Blog/FAQ onto a second row beside the language button. */
header.site-nav-primary nav[aria-label="Primary"] {
  display: none;
  flex: 1 1 auto;
  flex-wrap: nowrap !important;
  align-items: center;
  justify-content: flex-end;
  gap: 0.15rem;
  min-width: 0;
}

header.site-nav-primary nav[aria-label="Primary"] a {
  flex: 0 0 auto;
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  white-space: nowrap;
  color: #cbd5e1 !important;
  border-radius: 0.5rem;
  padding: 0.4rem 0.55rem;
  font-size: 0.8125rem;
  line-height: 1.2;
  font-weight: 500;
  transition:
    color 0.15s ease,
    background-color 0.15s ease;
}

header.site-nav-primary nav[aria-label="Primary"] a:hover {
  color: #5eead4 !important;
  background-color: rgb(255 255 255 / 0.06);
}

header.site-nav-primary nav[aria-label="Primary"] a[aria-current="page"] {
  color: #5eead4 !important;
  background-color: rgb(20 184 166 / 0.14);
  box-shadow: inset 0 0 0 1px rgb(45 212 191 / 0.35);
}

header.site-nav-primary nav[aria-label="Primary"] a i {
  display: none;
  font-size: 0.8em;
  opacity: 0.9;
}

header.site-nav-primary .lang-switcher {
  flex-shrink: 0;
}

header.site-nav-primary .lang-switcher [role="menu"] {
  z-index: 1000 !important;
}

header.site-nav-primary .lang-switcher > summary {
  list-style: none;
  white-space: nowrap;
}

header.site-nav-primary .lang-switcher > summary::-webkit-details-marker {
  display: none;
}

header.site-nav-primary .lang-switcher[open] > summary {
  background-color: rgb(255 255 255 / 0.1);
}

header.site-nav-primary #nav-toggle {
  display: inline-flex;
  border-color: rgb(71 85 105 / 0.95) !important;
  color: #e2e8f0 !important;
  background-color: rgb(30 41 59 / 0.6);
}

header.site-nav-primary #nav-toggle:hover {
  background-color: rgb(51 65 85 / 0.75);
}

header.site-nav-primary #nav-panel {
  border-radius: 0;
  background: linear-gradient(180deg, #0f172a 0%, #1e293b 100%) !important;
  border-top-color: rgb(51 65 85 / 0.85) !important;
}

header.site-nav-primary #nav-panel a {
  color: #e2e8f0 !important;
  border-radius: 0.375rem;
}

header.site-nav-primary #nav-panel a:hover {
  color: #5eead4 !important;
  background-color: rgb(255 255 255 / 0.05);
}

header.site-nav-primary #nav-panel a[aria-current="page"] {
  color: #5eead4 !important;
  background-color: rgb(20 184 166 / 0.12);
}

header.site-nav-primary #nav-panel i[class*="fa-"] {
  color: #2dd4bf !important;
}

@media (min-width: 1200px) {
  header.site-nav-primary nav[aria-label="Primary"] {
    display: flex !important;
  }

  header.site-nav-primary #nav-toggle {
    display: none !important;
  }

  header.site-nav-primary #nav-panel {
    display: none !important;
  }
}

@media (min-width: 1440px) {
  header.site-nav-primary nav[aria-label="Primary"] a {
    padding: 0.45rem 0.65rem;
    font-size: 0.875rem;
  }

  header.site-nav-primary nav[aria-label="Primary"] a i {
    display: inline-block;
  }
}

/* Home hero: dark stage + framed screenshot (index only) */
.hero-home {
  position: relative;
  z-index: 0;
  overflow: hidden;
  isolation: isolate;
  border-bottom: 1px solid rgb(30 41 59 / 0.95);
  border-radius: 0;
  /* Solid underpaint so anti-aliased corners never show the page background */
  background-color: #0f172a;
  background-image: linear-gradient(145deg, #0f172a 0%, #1e293b 55%, #0f172a 100%);
  color: #e2e8f0;
  transform: translateZ(0);
}

.hero-home::before {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: 0;
  opacity: 0.22;
  background-image: radial-gradient(circle at center, rgb(148 163 184 / 0.35) 1px, transparent 1px);
  background-size: 22px 22px;
  pointer-events: none;
}

.hero-home::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: 0;
  background:
    radial-gradient(ellipse 80% 55% at 85% 12%, rgb(20 184 166 / 0.18), transparent 55%),
    radial-gradient(ellipse 60% 50% at 8% 88%, rgb(244 63 94 / 0.1), transparent 50%);
  pointer-events: none;
}

/* Seal 1px hairline between hero and the next light section */
main > section.hero-home + section {
  margin-top: -1px;
}

.hero-home .hero-home-inner {
  position: relative;
  z-index: 1;
}

/* Space after hero brand line when Tailwind/flex gap is unavailable (CDN blocked): strong+span stay inline. */
.hero-run > strong {
  margin-inline-end: 0.35em;
}

.hero-home-frame {
  border-radius: 0;
  padding: 0.5rem;
  background: linear-gradient(160deg, rgb(51 65 85 / 0.65) 0%, rgb(15 23 42 / 0.9) 100%);
  box-shadow:
    0 24px 48px rgb(0 0 0 / 0.45),
    inset 0 1px 0 rgb(255 255 255 / 0.06);
  border: 1px solid rgb(71 85 105 / 0.55);
}

@media (min-width: 640px) {
  .hero-home-frame {
    padding: 0.65rem;
  }
}

.hero-home-carousel {
  overflow: hidden;
  border-radius: 0;
  border: 1px solid rgb(51 65 85 / 0.85);
  background: rgb(15 23 42 / 0.85);
  box-shadow: 0 4px 24px rgb(0 0 0 / 0.35);
}

.hero-home-carousel .hero-carousel-bar {
  border-top-color: rgb(51 65 105 / 0.85) !important;
  background: rgb(15 23 42 / 0.92) !important;
}

.hero-home-carousel .hero-carousel-bar button {
  background-color: rgb(30 41 59 / 0.85) !important;
  color: #cbd5e1 !important;
}

.hero-home-carousel .hero-carousel-bar button:hover {
  background-color: rgb(20 184 166 / 0.12) !important;
  color: #5eead4 !important;
}

.hero-home-carousel .hero-carousel-bar p {
  color: #cbd5e1 !important;
  border-color: rgb(51 65 105 / 0.85) !important;
}

@media (prefers-reduced-motion: reduce) {
  :root {
    scroll-behavior: auto;
  }
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}

html {
  scroll-padding-top: 5rem;
}

.skip-link {
  position: absolute;
  left: -9999px;
  top: 0.5rem;
  z-index: 100;
  padding: 0.5rem 1rem;
  border-radius: 0.5rem;
  background: #0f172a;
  color: #fff;
  font-weight: 600;
  text-decoration: none;
}

.skip-link:focus {
  left: 0.5rem;
  outline: 2px solid #14b8a6;
  outline-offset: 2px;
}

/* Back to top */
.back-to-top {
  position: fixed;
  bottom: 1.5rem;
  right: 1.5rem;
  z-index: 50;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 3rem;
  height: 3rem;
  border-radius: 9999px;
  background: linear-gradient(145deg, #0f172a 0%, #1e293b 100%);
  color: #fff;
  border: 1px solid rgba(148, 163, 184, 0.35);
  box-shadow: 0 10px 40px rgba(15, 23, 42, 0.25);
  cursor: pointer;
  opacity: 0;
  visibility: hidden;
  transform: translateY(8px);
  transition:
    opacity 0.25s ease,
    visibility 0.25s ease,
    transform 0.25s ease;
}

.back-to-top.visible {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.back-to-top:focus-visible {
  outline: 2px solid #14b8a6;
  outline-offset: 3px;
}

/* Fixed download rail */
.fixed-download-btn {
  position: fixed;
  top: 50%;
  right: 0;
  z-index: 45;
  display: inline-flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.35rem;
  padding: 0.75rem 0.5rem;
  border-radius: 0.75rem 0 0 0.75rem;
  background: linear-gradient(180deg, #0d9488 0%, #0f766e 100%);
  color: #fff;
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  text-decoration: none;
  box-shadow: -4px 8px 24px rgba(13, 148, 136, 0.35);
  transform: translateY(-50%);
  transition:
    transform 0.2s ease,
    box-shadow 0.2s ease;
}

.fixed-download-btn:hover {
  box-shadow: -6px 12px 32px rgba(13, 148, 136, 0.45);
}

.fixed-download-btn:focus-visible {
  outline: 2px solid #f8fafc;
  outline-offset: 2px;
}

.fixed-download-btn span {
  writing-mode: vertical-rl;
  transform: rotate(180deg);
  text-transform: uppercase;
}

@media (max-width: 640px) {
  .fixed-download-btn {
    padding: 0.5rem 0.35rem;
    font-size: 0.65rem;
  }

  .fixed-download-btn span {
    display: none;
  }

  .back-to-bottom-safe {
    bottom: 5rem;
  }
}

/* FAQ accordion details */
.faq-details summary {
  cursor: pointer;
  list-style: none;
}

.faq-details summary::-webkit-details-marker {
  display: none;
}

.faq-details summary::after {
  content: "";
  width: 0.6rem;
  height: 0.6rem;
  margin-inline-start: auto;
  border-right: 2px solid #64748b;
  border-bottom: 2px solid #64748b;
  transform: rotate(45deg);
  transition: transform 0.2s ease;
}

.faq-details[open] summary::after {
  transform: rotate(-135deg);
}

/* Blog article hero — full image visible, no harsh cropping */
.blog-article-media {
  display: flex;
  justify-content: center;
  align-items: center;
  margin: 2.5rem 0;
  padding: clamp(0.625rem, 2.5vw, 1rem);
  border-radius: 1rem;
  border: 1px solid #e2e8f0;
  background: #f8fafc;
  box-shadow:
    0 1px 2px rgb(15 23 42 / 0.04),
    0 8px 28px rgb(15 23 42 / 0.08);
}

@media (min-width: 640px) {
  .blog-article-media {
    margin: 3rem 0;
    border-radius: 1.125rem;
    padding: 0.75rem 1rem;
  }
}

.blog-article-media img {
  display: block;
  width: auto;
  max-width: 100%;
  height: auto;
  max-height: min(36rem, 82vh);
  object-fit: contain;
  object-position: center;
  border-radius: 0.5rem;
}

@media (min-width: 640px) {
  .blog-article-media img {
    max-height: min(40rem, 78vh);
    border-radius: 0.625rem;
  }
}

/* UI screenshots — extra vertical room, align from top */
.blog-article-media--screenshot {
  align-items: flex-start;
  background: #f1f5f9;
}

.blog-article-media--screenshot img {
  max-height: min(44rem, 88vh);
  border-radius: 0.375rem;
}

/* Reveal on scroll (enhancement) */
.reveal {
  opacity: 0;
  transform: translateY(12px);
  transition:
    opacity 0.6s ease,
    transform 0.6s ease;
}

.reveal.is-visible {
  opacity: 1;
  transform: translateY(0);
}

@media (prefers-reduced-motion: reduce) {
  .reveal {
    opacity: 1;
    transform: none;
  }
}
