/* Pagina principală — mișcare „cinematică”. Doar transform / opacity.
   Clase pe <html> puse de assets/hub-motion.js: hm-full | hm-reduced (nimic la „off”), hm-go la afișare. */
@media screen {
  /* Intrare: cardurile vin din adâncime, pe rând */
  html.hm-full:not(.hm-go) .cards-row .card,
  html.hm-full:not(.hm-go) .hub-card,
  html.hm-full:not(.hm-go) .hero,
  html.hm-full:not(.hm-go) .info-bar,
  html.hm-reduced:not(.hm-go) .cards-row .card { opacity: 0; }

  html.hm-full.hm-go .hero { animation: hm-drop .7s cubic-bezier(.2,.75,.25,1) backwards; }
  html.hm-full.hm-go .info-bar { animation: hm-rise .6s cubic-bezier(.2,.75,.25,1) .12s backwards; }
  html.hm-full.hm-go .greeting { display: inline-block; animation: hm-greet .7s cubic-bezier(.2,.75,.25,1) .3s backwards; }
  html.hm-full.hm-go .cards-row .card,
  html.hm-full.hm-go .hub-card {
    animation: hm-card .62s cubic-bezier(.2,.75,.25,1) backwards;
    animation-delay: calc(.26s + var(--hm-i, 0) * 60ms);
  }
  html.hm-reduced.hm-go .cards-row .card { animation: hm-fade .4s ease-out backwards; }

  /* Prima deschidere din zi: salut mare, apoi pagina intră mai rar și mai amplu */
  .hm-welcome { position: fixed; inset: 0; z-index: 50; display: grid; place-content: center; gap: 10px; text-align: center; pointer-events: none;
    background: radial-gradient(ellipse at center, rgba(8,19,34,.94) 0%, rgba(8,19,34,.82) 55%, rgba(8,19,34,.6) 100%); animation: hm-welcome-bg 3.1s ease both; }
  .hm-welcome strong { color: #fff; font: 600 clamp(28px, 4.4vw, 58px)/1.1 Inter, system-ui, sans-serif; letter-spacing: -.03em; animation: hm-welcome-text 3.1s cubic-bezier(.2,.75,.25,1) both; }
  .hm-welcome span { color: #7dbdff; font: 600 12px/1 Inter, system-ui, sans-serif; letter-spacing: .32em; text-transform: uppercase; animation: hm-welcome-text 3.1s cubic-bezier(.2,.75,.25,1) .12s both; }
  html.hm-full.hm-first.hm-go .hero { animation-delay: 1.9s; animation-duration: .9s; }
  html.hm-full.hm-first.hm-go .info-bar { animation-delay: 2.1s; }
  html.hm-full.hm-first.hm-go .greeting { animation-delay: 2.3s; }
  html.hm-full.hm-first.hm-go .cards-row .card,
  html.hm-full.hm-first.hm-go .hub-card { animation-duration: .8s; animation-delay: calc(2.25s + var(--hm-i, 0) * 95ms); }
  /* logo-ul animat își începe intrarea după salut */
  html.hm-first.hm-go.lm-on .hero-copy { animation-delay: 2.15s; }
  html.hm-first.hm-go.lm-on :is(.lm-gl, .lm-bal) { animation-delay: 2.08s; }
  html.hm-first.hm-go.lm-on :is(.lm-globe-in, .lm-halo) { animation-delay: 1.9s; }
  html.hm-first.hm-go.lm-on .lm-text { animation-delay: 2.6s; }
  html.hm-first.hm-go.lm-on .lm-orbit { animation-delay: 3.05s; }
  html.hm-first.hm-go.lm-on .lm-shine { animation-delay: 4.3s; }
  /* Hover: înclinare 3D după mouse + lumină care urmărește cursorul */
  html.hm-full .cards-row { perspective: 1100px; }
  html.hm-full .cards-row .card.hm-tilt { transition: border-color .18s ease, background-color .18s ease; will-change: transform; }
  html.hm-full .cards-row .card.hm-settle { transition: transform .45s cubic-bezier(.2,.75,.25,1), border-color .18s ease, background-color .18s ease; }
  .hm-light {
    position: absolute; left: 0; top: 0; width: 340px; height: 340px; margin: -170px 0 0 -170px;
    border-radius: 50%; pointer-events: none; opacity: 0; transition: opacity .25s ease;
    background: radial-gradient(circle, rgba(125,189,255,.26) 0%, rgba(125,189,255,.09) 38%, transparent 68%);
    will-change: transform, opacity;
  }
  html.hm-full .card.hm-tilt .hm-light { opacity: 1; }
  html:not(.hm-full) .hm-light { display: none; }

  /* Fundal cu profunzime: strat propriu, mișcat fin după mouse */
  .hm-bg {
    position: fixed; inset: -14px; z-index: 0; pointer-events: none; will-change: transform;
    background-position: center; background-size: cover; background-repeat: no-repeat; /* imaginea e pusă din JS (URL relativ la pagină) */
  }
  html.hm-full body.home-navy::before { opacity: 0; }
  html:not(.hm-full) .hm-bg { display: none; }

  .hm-clock { font-variant-numeric: tabular-nums; }
  .hm-clock::before { content: "·"; margin: 0 8px 0 2px; opacity: .55; }

  @keyframes hm-welcome-bg { 0% { opacity: 0; } 10%, 68% { opacity: 1; } 100% { opacity: 0; } }
  @keyframes hm-welcome-text { 0% { opacity: 0; transform: translateY(16px) scale(.97); } 16%, 66% { opacity: 1; transform: none; } 100% { opacity: 0; transform: translateY(-10px); } }
  @keyframes hm-card { from { opacity: 0; transform: translateY(18px) scale(.96); } to { opacity: 1; transform: none; } }
  @keyframes hm-fade { from { opacity: 0; } to { opacity: 1; } }
  @keyframes hm-drop { from { opacity: 0; transform: translateY(-12px); } to { opacity: 1; transform: none; } }
  @keyframes hm-rise { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: none; } }
  @keyframes hm-greet { from { opacity: 0; transform: translateX(-14px); } to { opacity: 1; transform: none; } }
}
@media print { .hm-bg, .hm-light { display: none !important; } }
