/* Hard Disk Sentinel micro-site — supplemental styles (Tailwind handles utilities) */

:root {
  --hds-accent: #0d9488;
  --hds-accent-hover: #0f766e;
  --hds-ring: rgba(13, 148, 136, 0.35);
  --home-icon-from: #0f766e;
  --home-icon-to: #14b8a6;
  --home-icon-fg: #fff;
  --home-ribbon: rgba(13, 148, 136, 0.22);
}

html {
  scroll-behavior: smooth;
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
  .motion-safe\:animate-none {
    animation: none !important;
  }
}

[data-reveal] {
  opacity: 0;
  transform: translateY(1.25rem);
  transition:
    opacity 0.6s cubic-bezier(0.22, 1, 0.36, 1),
    transform 0.6s cubic-bezier(0.22, 1, 0.36, 1);
}

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

@media (prefers-reduced-motion: reduce) {
  [data-reveal] {
    opacity: 1;
    transform: none;
    transition: none;
  }
}

/* Fixed download rail — desktop: middle right */
.fixed-download-btn {
  position: fixed;
  z-index: 50;
  right: max(1rem, env(safe-area-inset-right));
  top: 50%;
  transform: translateY(-50%);
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.75rem 1rem;
  border-radius: 9999px;
  background: linear-gradient(145deg, #0f766e 0%, #0d9488 55%, #14b8a6 100%);
  color: #fff;
  font-size: 0.875rem;
  font-weight: 600;
  box-shadow:
    0 10px 40px -10px rgba(13, 148, 136, 0.55),
    0 0 0 1px rgba(255, 255, 255, 0.12) inset;
  transition:
    transform 0.2s ease,
    box-shadow 0.2s ease,
    opacity 0.2s ease;
}

.fixed-download-btn:hover {
  transform: translateY(-50%) translateY(-2px);
  box-shadow:
    0 14px 44px -8px rgba(13, 148, 136, 0.65),
    0 0 0 1px rgba(255, 255, 255, 0.18) inset;
}

.fixed-download-btn:focus-visible {
  outline: 2px solid var(--hds-accent);
  outline-offset: 3px;
}

/* Hebrew hero: keep text RTL but same visual column order as LTR (copy left, screenshot right) */
@media (min-width: 1024px) {
  html[lang="he"] .hero-top-grid {
    direction: ltr;
  }

  html[lang="he"] .hero-top-grid__copy {
    direction: rtl;
    text-align: start;
  }

  html[lang="he"] .hero-top-grid .hero-gallery-card {
    direction: ltr;
  }
}

/* Russian hero: copy wraps to more lines than English, so top-align both columns
   to keep the gallery image at the top instead of getting visually "dropped" by items-center */
@media (min-width: 1024px) {
  html[lang="ru"] .hero-top-grid {
    align-items: start;
  }
}

/* Hero screenshot gallery — named tabs (no horizontal image strip) */
.hero-gallery-card {
  border: 1px solid rgba(255, 255, 255, 0.12);
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.11), rgba(255, 255, 255, 0.055)),
    rgba(15, 23, 42, 0.42);
  padding: 0.7rem;
  box-shadow:
    0 28px 80px -40px rgba(20, 184, 166, 0.58),
    0 18px 54px -42px rgba(0, 0, 0, 0.8),
    inset 0 1px 0 rgba(255, 255, 255, 0.12);
  backdrop-filter: blur(18px);
}

.hero-gallery-window {
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.13);
  border-radius: 0.45rem;
  background: rgba(2, 6, 23, 0.72);
  box-shadow:
    0 18px 45px -26px rgba(0, 0, 0, 0.85),
    inset 0 1px 0 rgba(255, 255, 255, 0.08);
}

.hero-gallery-window__bar {
  display: flex;
  align-items: center;
  gap: 0.35rem;
  height: 1.45rem;
  padding-inline: 0.65rem;
  background: linear-gradient(180deg, rgba(248, 250, 252, 0.16), rgba(15, 23, 42, 0.3));
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.hero-gallery-window__bar span {
  width: 0.42rem;
  height: 0.42rem;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.32);
}

.hero-gallery-window__bar span:first-child {
  background: rgba(248, 113, 113, 0.82);
}

.hero-gallery-window__bar span:nth-child(2) {
  background: rgba(251, 191, 36, 0.82);
}

.hero-gallery-window__bar span:nth-child(3) {
  background: rgba(45, 212, 191, 0.82);
}

.hero-gallery-panel {
  display: block;
  width: 100%;
  aspect-ratio: 16 / 9;
  object-fit: cover;
  object-position: top center;
}

.hero-gallery-panel.hidden {
  display: none;
}

.hero-gallery-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
  margin-top: 0.7rem;
}

.hero-gallery-tab {
  border-radius: 0.45rem;
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: rgba(15, 23, 42, 0.48);
  padding: 0.38rem 0.68rem;
  font-size: 0.72rem;
  font-weight: 650;
  color: rgb(177, 190, 207);
  transition:
    border-color 0.15s ease,
    background 0.15s ease,
    color 0.15s ease;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}

.hero-gallery-tab:hover {
  border-color: rgba(45, 212, 191, 0.35);
  color: rgb(226, 232, 240);
}

.hero-gallery-tab:focus-visible {
  outline: 2px solid var(--hds-accent);
  outline-offset: 2px;
}

.hero-gallery-tab[aria-selected='true'] {
  border-color: rgba(45, 212, 191, 0.65);
  background: rgba(13, 148, 136, 0.3);
  color: rgb(204, 251, 241);
}

.hero-stats-grid {
  display: grid;
  gap: 0.65rem;
  padding-top: 0.7rem;
}

.hero-stat {
  border: 1px solid rgba(255, 255, 255, 0.09);
  border-radius: 0.55rem;
  background: rgba(255, 255, 255, 0.075);
  padding: 0.72rem;
  color: #fff;
}

.hero-stat strong {
  display: block;
  font-size: 1.12rem;
  line-height: 1.15;
}

.hero-stat span {
  display: block;
  margin-top: 0.16rem;
  color: rgb(203, 213, 225);
  font-size: 0.7rem;
  line-height: 1.1rem;
}

@media (min-width: 640px) {
  .hero-stats-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

/* Hero tabbed screenshots — tighter corners than default media-frame (1rem) */
.media-frame--dark:has(#hero-interface-gallery) {
  border-radius: 0.5rem;
}

.fixed-download-btn i {
  font-size: 1rem;
}

@media (max-width: 768px) {
  .fixed-download-btn {
    top: auto;
    bottom: max(5.5rem, calc(env(safe-area-inset-bottom) + 4.5rem));
    transform: none;
    right: max(1rem, env(safe-area-inset-right));
  }

  .fixed-download-btn:hover {
    transform: translateY(-2px);
  }
}

/* Back to top */
.back-to-top {
  position: fixed;
  z-index: 50;
  bottom: max(1.25rem, env(safe-area-inset-bottom));
  right: max(1.25rem, env(safe-area-inset-right));
  width: 3rem;
  height: 3rem;
  border-radius: 9999px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #fff;
  color: #0f172a;
  border: 1px solid rgba(15, 23, 42, 0.08);
  box-shadow: 0 10px 30px -12px rgba(15, 23, 42, 0.35);
  opacity: 0;
  pointer-events: none;
  transform: translateY(8px);
  transition:
    opacity 0.25s ease,
    transform 0.25s ease,
    background 0.2s ease;
}

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

.back-to-top:hover {
  background: #f8fafc;
}

.back-to-top:focus-visible {
  outline: 2px solid var(--hds-accent);
  outline-offset: 3px;
}

@media (max-width: 768px) {
  .back-to-top {
    bottom: max(1.25rem, env(safe-area-inset-bottom));
    right: max(1rem, env(safe-area-inset-right));
  }
}

/* Anchor offset under sticky header */
section[id],
[id='download'] {
  scroll-margin-top: 5.5rem;
}

/* Focus rings for summary/details FAQ */
details summary {
  list-style: none;
}

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

/* Subtle link underline */
.link-subtle {
  text-decoration: underline;
  text-decoration-color: rgba(13, 148, 136, 0.35);
  text-underline-offset: 0.2em;
  transition: text-decoration-color 0.2s ease;
}

.link-subtle:hover {
  text-decoration-color: rgba(13, 148, 136, 0.8);
}

/* UI screenshots & GIFs: keep intrinsic proportions — no tiny asset stretched edge-to-edge */
.media-frame {
  display: flex;
  justify-content: center;
  align-items: flex-start;
  width: 100%;
}

.media-natural {
  display: block;
  width: auto;
  height: auto;
  max-width: 100%;
  margin-inline: auto;
  object-fit: contain;
  object-position: top center;
}

.media-frame--dark {
  padding: clamp(0.75rem, 2.5vw, 1.25rem);
  background: linear-gradient(180deg, rgb(15 23 42 / 0.55), rgb(15 23 42 / 0.92));
  border-radius: 1rem;
}

.media-frame--light {
  padding: clamp(0.75rem, 2.5vw, 1rem);
  background: rgb(248 250 252);
  border-radius: 1rem;
}

/* Typography scale
   We override Tailwind's text-* utility sizes to keep a clear, consistent
   hierarchy across pages without touching every template string. */
.text-xs {
  font-size: 0.75rem;
  line-height: 1.1rem;
}

.text-sm {
  font-size: 0.9rem;
  line-height: 1.4rem;
}

.text-base {
  font-size: 1rem;
  line-height: 1.6rem;
}

.text-lg {
  font-size: 1.125rem;
  line-height: 1.75rem;
}

.text-xl {
  font-size: 1.25rem;
  line-height: 1.85rem;
}

.text-2xl {
  font-size: 1.5rem;
  line-height: 2.1rem;
}

.text-3xl {
  font-size: clamp(1.75rem, 1.25rem + 1.3vw, 2.25rem);
  line-height: 1.15;
}

.text-4xl {
  font-size: clamp(2.125rem, 1.45rem + 1.8vw, 2.75rem);
  line-height: 1.12;
}

.text-5xl {
  font-size: clamp(2.5rem, 1.65rem + 2.2vw, 3.25rem);
  line-height: 1.1;
}

/* Blog post title block (inside article column) */
.blog-post-head__title {
  text-wrap: balance;
}

/* Homepage <main> sections: unified vertical rhythm (replaces mixed py-20 / py-24) */
main#main > section.section-y {
  padding-block: clamp(5rem, 4.25rem + 2.5vw, 7rem);
}

main#main > section.section-y-compact {
  padding-block: clamp(2.5rem, 2.25rem + 1vw, 3.25rem);
}

/* Centered section intros: responsive headline + lead without editing every locale block */
main#main > section .mx-auto.max-w-2xl.text-center > h2.font-display,
main#main > section .mx-auto.max-w-3xl.text-center > h2.font-display {
  font-size: clamp(1.625rem, 1.35rem + 1.1vw, 2.25rem);
  line-height: 1.2;
  letter-spacing: -0.02em;
}

main#main > section .mx-auto.max-w-2xl.text-center > p,
main#main > section .mx-auto.max-w-3xl.text-center > p {
  font-size: clamp(1rem, 0.95rem + 0.25vw, 1.125rem);
  line-height: 1.65;
}

/* “By hardware” — slightly tighter scale than generic section intros */
main#main > section[data-section='drive-types'] .mx-auto.max-w-2xl.text-center > h2.font-display {
  font-size: clamp(1.375rem, 1.12rem + 0.85vw, 1.875rem);
  line-height: 1.22;
  letter-spacing: -0.02em;
}

main#main > section[data-section='drive-types'] .mx-auto.max-w-2xl.text-center > p {
  font-size: clamp(0.9375rem, 0.9rem + 0.2vw, 1.0625rem);
  line-height: 1.62;
}

/* Homepage sections — icon kickers, accent ribbon, cohesive spacing */
main#main > section.home-section {
  position: relative;
  isolation: isolate;
}

main#main > section.home-section::before {
  content: '';
  position: absolute;
  inset-inline: clamp(1.25rem, 6vw, 4rem);
  top: 0;
  height: 2px;
  border-radius: 999px;
  background: linear-gradient(
    90deg,
    transparent,
    var(--home-ribbon),
    transparent
  );
  pointer-events: none;
}

main#main > section.home-section[data-section='media']::before {
  background: linear-gradient(
    90deg,
    transparent,
    rgba(45, 212, 191, 0.35),
    transparent
  );
}

main#main > section.home-section .home-section__kicker {
  display: flex;
  justify-content: center;
  margin: 0 0 clamp(1rem, 2.4vw, 1.75rem);
}

main#main > section.home-section .home-section__icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2.75rem;
  height: 2.75rem;
  border-radius: 0.875rem;
  font-size: 1.05rem;
  line-height: 1;
  color: var(--home-icon-fg);
  background: linear-gradient(
    155deg,
    var(--home-icon-from) 0%,
    var(--home-icon-to) 100%
  );
  box-shadow:
    0 10px 28px -10px rgba(15, 23, 42, 0.22),
    0 0 0 1px rgba(255, 255, 255, 0.14) inset;
}

main#main > section.home-section .home-section__icon--sm {
  width: 2.35rem;
  height: 2.35rem;
  font-size: 0.95rem;
  border-radius: 0.75rem;
}

main#main > section.home-section[data-section='trust'] {
  --home-icon-from: #475569;
  --home-icon-to: #334155;
  --home-ribbon: rgba(71, 85, 105, 0.28);
}

main#main > section.home-section[data-section='stories'] {
  --home-icon-from: #b45309;
  --home-icon-to: #d97706;
  --home-ribbon: rgba(217, 119, 6, 0.28);
}

main#main > section.home-section[data-section='section9'] {
  --home-icon-from: #be123c;
  --home-icon-to: #e11d48;
  --home-ribbon: rgba(225, 29, 72, 0.22);
}

main#main > section.home-section[data-section='faq'] {
  --home-icon-from: #475569;
  --home-icon-to: #64748b;
  --home-ribbon: rgba(100, 116, 139, 0.25);
}

main#main > section.home-section[data-section='blog'] {
  --home-icon-from: #3f3f46;
  --home-icon-to: #52525b;
  --home-ribbon: rgba(82, 82, 91, 0.22);
}

main#main > section.home-section[data-section='beyond-smart'] {
  --home-icon-from: #4f46e5;
  --home-icon-to: #6366f1;
  --home-ribbon: rgba(99, 102, 241, 0.22);
}

main#main > section.home-section[data-section='media'] .home-section__icon {
  color: rgb(204 251 241);
  background: linear-gradient(
    155deg,
    rgba(255, 255, 255, 0.12) 0%,
    rgba(45, 212, 191, 0.18) 100%
  );
  box-shadow:
    0 0 0 1px rgba(255, 255, 255, 0.12) inset,
    0 12px 36px -14px rgba(0, 0, 0, 0.45);
}

main#main > section.home-section.section-y {
  padding-block: clamp(5.25rem, 4.35rem + 2.8vw, 7.35rem);
}

main#main > section.home-section.section-y-compact {
  padding-block: clamp(2.75rem, 2.35rem + 1.2vw, 3.5rem);
}

/* Site primary header — chic polish (INDEX_HEADER_HTML on hub + blog index) */
header.sticky.top-0.z-40.border-b {
  position: relative;
  box-shadow:
    0 1px 0 rgba(255, 255, 255, 0.72) inset,
    0 14px 42px -32px rgba(15, 23, 42, 0.1);
}

header.sticky.top-0.z-40.border-b::after {
  content: '';
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 1px;
  background: linear-gradient(
    90deg,
    transparent 0%,
    rgba(13, 148, 136, 0.22) 45%,
    rgba(13, 148, 136, 0.22) 55%,
    transparent 100%
  );
  pointer-events: none;
}

header.sticky nav[aria-label='Primary'] > a.inline-flex:not(.rounded-full) {
  border-radius: 0.625rem;
  padding: 0.35rem 0.6rem;
  letter-spacing: 0.01em;
  transition:
    color 0.18s ease,
    background-color 0.18s ease,
    box-shadow 0.18s ease;
}

header.sticky nav[aria-label='Primary'] > a.inline-flex:not(.rounded-full):hover,
header.sticky nav[aria-label='Primary'] > a.inline-flex:not(.rounded-full):focus-visible {
  color: rgb(15 23 42);
  background-color: rgba(248, 250, 252, 0.95);
  box-shadow: 0 1px 0 rgba(255, 255, 255, 0.85) inset;
}

header.sticky nav[aria-label='Primary'] > a.inline-flex:not(.rounded-full):focus-visible {
  outline: 2px solid var(--hds-ring);
  outline-offset: 2px;
}

header.sticky nav[aria-label='Primary'] > a.inline-flex.rounded-full.bg-accent {
  box-shadow:
    0 1px 0 rgba(255, 255, 255, 0.22) inset,
    0 10px 26px -12px rgba(13, 148, 136, 0.42);
  transition:
    transform 0.18s ease,
    box-shadow 0.18s ease,
    background-color 0.18s ease;
}

header.sticky nav[aria-label='Primary'] > a.inline-flex.rounded-full.bg-accent:hover {
  transform: translateY(-1px);
  box-shadow:
    0 1px 0 rgba(255, 255, 255, 0.28) inset,
    0 14px 32px -12px rgba(13, 148, 136, 0.5);
}

header.sticky .site-nav__bar > a.group:first-of-type {
  transition:
    transform 0.2s ease,
    box-shadow 0.2s ease;
}

header.sticky .site-nav__bar > a.group:first-of-type:hover {
  transform: translateY(-0.5px);
}

header.sticky #mobile-menu-btn {
  transition:
    border-color 0.15s ease,
    background-color 0.15s ease,
    box-shadow 0.15s ease;
}

header.sticky #mobile-menu-btn:hover {
  border-color: rgb(203 213 225);
  background-color: rgb(248 250 252);
  box-shadow: 0 1px 0 rgba(255, 255, 255, 0.9) inset;
}

header.sticky #mobile-menu-btn:focus-visible {
  outline: 2px solid var(--hds-ring);
  outline-offset: 2px;
}

header.sticky #mobile-menu {
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.55);
}

header.sticky #mobile-menu .site-nav__drawer-inner > a {
  border-radius: 0.75rem;
  transition:
    background-color 0.15s ease,
    color 0.15s ease;
}

header.sticky #mobile-menu .site-nav__drawer-inner > a:hover,
header.sticky #mobile-menu .site-nav__drawer-inner > a:focus-visible {
  background-color: rgba(248, 250, 252, 0.95);
}

header.sticky #mobile-menu .site-nav__drawer-inner > a:focus-visible {
  outline: 2px solid var(--hds-ring);
  outline-offset: 2px;
}

@media (max-width: 767px) {
  header.sticky nav.hidden {
    display: flex !important;
    max-width: 100%;
    overflow-x: auto;
    gap: 0.25rem;
    padding-block: 0.35rem;
    scrollbar-width: none;
  }

  header.sticky nav.hidden::-webkit-scrollbar {
    display: none;
  }

  header.sticky nav.hidden a {
    white-space: nowrap;
  }
}

.prose {
  color: rgb(71 85 105);
}

.prose h2 {
  margin-top: 2.25rem;
  color: rgb(15 23 42);
  font-size: clamp(1.5rem, 1.2rem + 1vw, 2rem);
  line-height: 1.2;
}

.prose p {
  margin-top: 0.9rem;
  font-size: 1.05rem;
  line-height: 1.85;
}

@media (prefers-reduced-motion: reduce) {
  header.sticky nav[aria-label='Primary'] > a.inline-flex.rounded-full.bg-accent:hover,
  header.sticky .site-nav__bar > a.group:first-of-type:hover {
    transform: none;
  }
}

