/* ═══════════════════════════════════════════════════════════════════
   hardware-handoff / software-extra.css
   CSS-only patterns Tailwind cannot express: multi-value shadows,
   1.5px borders, rgba/hex-opacity accent backgrounds, and video UI.
   Linked by preview.html for local QA; included by WordPress theme
   alongside software-main.css.
═══════════════════════════════════════════════════════════════════ */

/* ── Generic card shell (hero + chip section) ────────────────────── */
.hw-card {
  background: #FFFFFF;
  border: 1.5px solid rgba(11, 18, 32, 0.08);
  box-shadow: 0 1px 4px rgba(11,18,32,0.06), 0 4px 16px rgba(11,18,32,0.04);
}

/* ── Hero value-prop card (per-color border via Tailwind utility) ── */
.hw-value-card {
  background: #FFFFFF;
  box-shadow: 0 1px 4px rgba(11,18,32,0.06), 0 4px 16px rgba(11,18,32,0.04);
  height: 100%;
}

/* ── Boards: 4-across hover-reveal cards (v2 handoff) ─────────────── */
.hw-boards-row {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}
@media (min-width: 768px) {
  .hw-boards-row { flex-direction: row; }
}

.hw-board-card {
  --c: #5998DD;
  position: relative;
  border-radius: 14px;
  overflow: hidden;
  background: #FFFFFF;
  display: flex;
  flex-direction: column;
  cursor: pointer;
  border: 1.5px solid color-mix(in srgb, var(--c) 20%, transparent);
  box-shadow: 0 1px 4px rgba(11,18,32,0.06), 0 4px 16px rgba(11,18,32,0.04);
  transition: border-color 0.25s ease, box-shadow 0.25s ease;
}
.hw-bc-accent { --c: #A4CC2D; }
.hw-bc-blue   { --c: #5998DD; }
.hw-bc-dgreen { --c: #2A9C4F; }
.hw-bc-purple { --c: #9089B5; }

.hw-board-card.hw-board-card--plain {
  border: 1px solid #e5e5ea;
  box-shadow: 0 2px 12px rgba(0, 0, 0, 0.04);
}
.hw-board-card.hw-board-card--plain .hw-board-line {
  background: #e5e5ea;
  opacity: 1;
}

.hw-board-line {
  height: 3px;
  background: var(--c);
  opacity: 0.45;
  flex-shrink: 0;
  transition: opacity 0.25s ease;
}

.hw-board-imgwrap {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px 20px 16px;
  background: linear-gradient(160deg, color-mix(in srgb, var(--c) 8%, transparent) 0%, #F3F7FC 100%);
}
.hw-board-imgwrap img {
  height: 150px;
  max-width: 85%;
  object-fit: contain;
  filter: drop-shadow(0 4px 12px rgba(0,0,0,0.1));
  transition: transform 0.35s cubic-bezier(0.34, 1.56, 0.64, 1);
}
.hw-board-imgwrap--mlsoc img { height: 110px; transform: scale(1.45); }

.hw-board-namebar { padding: 14px 18px 16px; flex-shrink: 0; }
.hw-board-sub { color: var(--c); }

.hw-board-overlay {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  background: #FFFFFF;
  border-top: 2px solid var(--c);
  box-shadow: 0 -4px 24px rgba(0,0,0,0.07);
  padding: 18px 18px 20px;
  transform: translateY(100%);
  transition: transform 0.32s cubic-bezier(0.4, 0, 0.2, 1);
}

.hw-board-link {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 11px;
  font-weight: 500;
  color: var(--c);
  background: none;
  border: none;
  padding: 0;
  cursor: pointer;
  text-decoration: none;
  transition: opacity 0.15s ease;
}
.hw-board-link:hover { opacity: 0.7; }

@media (hover: hover) and (min-width: 768px) {
  .hw-board-card { height: 340px; }
  .hw-board-card:hover {
    border-color: color-mix(in srgb, var(--c) 55%, transparent);
    box-shadow: 0 12px 40px color-mix(in srgb, var(--c) 20%, transparent), 0 1px 4px rgba(11,18,32,0.06), 0 4px 16px rgba(11,18,32,0.04);
  }
  .hw-board-card.hw-board-card--plain:hover {
    border-color: #d1d1d6;
    box-shadow: 0 8px 28px rgba(0, 0, 0, 0.07), 0 1px 4px rgba(11,18,32,0.06);
  }
  .hw-board-card:hover .hw-board-line { opacity: 1; }
  .hw-board-card:hover .hw-board-imgwrap img { transform: translateY(-4px) scale(1.04); }
  .hw-board-card:hover .hw-board-imgwrap--mlsoc img { transform: translateY(-4px) scale(1.508); }
  .hw-board-card:hover .hw-board-overlay { transform: translateY(0); }
}

@media not all and (hover: hover), (max-width: 767px) {
  .hw-board-card { height: auto; }
  .hw-board-overlay {
    position: static;
    transform: none;
    box-shadow: none;
  }
}

/* ── Video trigger (Watch Video button) ──────────────────────────── */
.hw-video-trigger { cursor: pointer; background: none; }

/* ── Light border utility ────────────────────────────────────────── */
.hw-border-light { border: 1px solid rgba(11,18,32,0.08); }
.hw-border-t-light { border-top: 1px solid rgba(11,18,32,0.08); }
.hw-border-b-light { border-bottom: 1px solid rgba(11,18,32,0.08); }

/* ── Video card: bottom gradient (covers YT watermark) ──────────── */
.hw-video-gradient {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 64px;
  background: linear-gradient(to bottom, transparent, rgba(0, 0, 0, 0.60));
  pointer-events: none;
  z-index: 2;
}

/* ── Video card: control button row ──────────────────────────────── */
.hw-video-controls {
  position: absolute;
  bottom: 10px;
  left: 10px;
  display: flex;
  gap: 6px;
  z-index: 10;
}

.hw-video-btn-ctrl {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: rgba(0, 0, 0, 0.52);
  border: none;
  color: #ffffff;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
  flex-shrink: 0;
  padding: 0;
  transition: background 0.15s ease;
}

.hw-video-btn-ctrl:hover {
  background: rgba(0, 0, 0, 0.72);
}

/* ── Video card: partner logo (bottom-right) ─────────────────────── */
.hw-video-logo {
  position: absolute;
  bottom: 10px;
  right: 10px;
  z-index: 10;
  background: rgba(255, 255, 255, 0.90);
  border-radius: 6px;
  padding: 3px 7px;
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.14);
  line-height: 1;
}

/* ── Scroll-reveal: IntersectionObserver-based animation ─────────── */
/* Default: always visible (safe fallback if JS is disabled)          */
.hw-reveal { opacity: 1; transform: none; }

/* JS adds .hw-will-reveal to hide elements before they animate in.    */
/* No transition here, so the initial hide is instant (no flash-out).  */
.hw-will-reveal {
  opacity: 0;
  transform: translateY(28px);
}

/* JS adds .hw-revealed to fade + slide the element into view. The      */
/* transition lives here so it only runs on the way IN, not the hide.  */
.hw-revealed {
  opacity: 1 !important;
  transform: translateY(0) !important;
  transition: opacity 0.7s cubic-bezier(0.22, 1, 0.36, 1),
              transform 0.7s cubic-bezier(0.22, 1, 0.36, 1);
}

/* ── Nav bar: translucent frosted-glass default state ─────────────── */
/* JS (#hw-nav) overrides background / border-bottom / box-shadow on    */
/* scroll; backdrop-filter persists across states.                     */
#hw-nav {
  background: rgba(255, 255, 255, 0.7);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid transparent;
}

/* ── Hero radial gradient washes (Tailwind can't express cleanly) ─── */
.hw-glow-top {
  background: radial-gradient(ellipse 80% 60% at 50% -10%, #5998DD14, transparent);
}
.hw-glow-br {
  background: radial-gradient(ellipse, #A4CC2D80, transparent 70%);
}

/* ── Video modal: frosted backdrop; JS toggles display flex/none ──── */
.hw-video-modal {
  display: none;
  background: rgba(11, 18, 32, 0.85);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
}
