/* =====================================================================
   TECH24.dev — Coming Soon
   Component: .coming-soon   (markup lives in index.html)
   ---------------------------------------------------------------------
   ONE single full-screen background photo. The TECH24 logo and all the
   copy that belongs on the page are already inside the artwork, so the
   page renders NO navbar, NO footer, NO sections, NO cards and NO text
   on top of it (only a visually hidden <h1> for accessibility).

   The photo is never edited, recoloured, stretched, cropped in a way
   that hides the logo, or distorted — it is only positioned/scaled with
   aspect-ratio-preserving CSS.
   ===================================================================== */

:root {
  /* Pure black. Matches the dark edges of the artwork, so anything the
     photo does not reach blends in invisibly. */
  --cs-bg: #000000;

  /* Optional readability overlay. The artwork is already dark and
     self-contained, so it is fully transparent by default — the photo
     keeps its exact original colours. Raise it to e.g.
     rgba(0, 0, 0, 0.08) if you ever want a slightly deeper look. */
  --cs-overlay: rgba(0, 0, 0, 0);

  /* The artwork lives in /public/assets/images/ */
  --cs-image: url("public/assets/images/tech24-coming-soon.png");

  /* Native aspect ratio of the artwork (1672 x 941). Used to keep the
     mobile letterbox mask perfectly aligned with the photo. */
  --cs-image-ratio: 1.7768331562;

  /* Mobile / narrow-screen backdrop: the same photo, heavily blurred and
     dimmed, used only to fill the space around the untouched artwork on
     tall screens. */
  --cs-backdrop-blur: 46px;
  --cs-backdrop-dim: 0.3;
}

*,
*::before,
*::after { box-sizing: border-box; }

html,
body {
  height: 100%;
  margin: 0;
  padding: 0;
  background-color: var(--cs-bg);
  -webkit-text-size-adjust: 100%;
  -webkit-tap-highlight-color: transparent;
  /* The page is a single full-screen visual: no horizontal and no
     vertical scrolling is possible on any device. */
  overflow: hidden;
  overflow-x: hidden;
  overscroll-behavior: none;
}

/* =====================================================================
   ComingSoon component — desktop / wide screens
   ===================================================================== */

.coming-soon {
  position: relative;
  z-index: 1;
  display: block;
  width: 100%;
  max-width: 100%;
  height: 100vh;                      /* fallback for older browsers     */
  height: 100dvh;                     /* exact dynamic viewport height   */
  margin: 0;
  background-color: var(--cs-bg);

  /* --- the full-screen photo --- */
  background-image:
    linear-gradient(var(--cs-overlay), var(--cs-overlay)),  /* optional veil */
    var(--cs-image);
  background-repeat: no-repeat;
  background-position: center center, center center;
  background-size: 100% 100%, cover;  /* cover = fills 100% of the screen */
  background-attachment: scroll;

  animation: cs-fade-in 700ms ease-out both;
}

@keyframes cs-fade-in {
  from { opacity: 0; }
  to   { opacity: 1; }
}

/* Accessible name for the visual — never rendered on screen. */
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  clip-path: inset(50%);
  white-space: nowrap;
  border: 0;
}

/* =====================================================================
   Responsive — portrait phones, tablets, squares, narrow windows
   (anything narrower than 3:2)

   The 16:9 artwork is shown WHOLE: `background-size: 100% auto` keeps the
   original aspect ratio, so the TECH24 logo, the tagline and every
   service line stay completely visible and nothing is squashed or
   crooked. The space above and below is filled with an extremely
   out-of-focus copy of the SAME photo, and the edges of the sharp photo
   are feathered into it, so the screen still reads as one continuous
   full-screen image.

   Want a plain black letterbox instead? Delete everything inside this
   media query except the `.coming-soon` block, and also delete the two
   `mask-image` declarations.
   ===================================================================== */
@media (orientation: portrait), (max-aspect-ratio: 3 / 2) {

  /* Ambient full-screen backdrop — same photo, blurred and dimmed. */
  body::before {
    content: "";
    position: fixed;
    inset: -8%;                    /* pushes the soft blur edges away  */
    z-index: 0;
    background-image: var(--cs-image);
    background-repeat: no-repeat;
    background-position: center center;
    background-size: cover;
    filter: blur(var(--cs-backdrop-blur)) brightness(var(--cs-backdrop-dim));
    pointer-events: none;
    animation: cs-fade-in 900ms ease-out both;
  }

  .coming-soon {
    /* Height of the artwork when it is exactly as wide as the screen. */
    --cs-band-h: calc(100vw / var(--cs-image-ratio));

    background-color: transparent;         /* backdrop shows through     */
    background-position: center center, center center;
    background-size: 100% 100%, 100% auto; /* whole photo, no distortion */

    /* Feather the top/bottom edge of the photo into the blurred
       backdrop, so there is no hard cut line on tall screens. */
    -webkit-mask-image: linear-gradient(to bottom,
      transparent calc(50% - var(--cs-band-h) / 2),
      #000 calc(50% - var(--cs-band-h) * 0.43),
      #000 calc(50% + var(--cs-band-h) * 0.43),
      transparent calc(50% + var(--cs-band-h) / 2));
    mask-image: linear-gradient(to bottom,
      transparent calc(50% - var(--cs-band-h) / 2),
      #000 calc(50% - var(--cs-band-h) * 0.43),
      #000 calc(50% + var(--cs-band-h) * 0.43),
      transparent calc(50% + var(--cs-band-h) / 2));
  }
}

/* ---------------------------------------------------------------------
   Phones.

   The artwork is deliberately NOT zoomed here. The TECH24 logo block spans
   roughly 7%–95% of the artwork width, so any horizontal zoom would slice
   through the logo, the service list or the "Ju mirepresim" script. Keeping
   `100% auto` shows the whole composition at phone width, and centring it
   (background-position: center) guarantees the logo can never be pushed off
   the screen — the branding stays exactly as visible as it is on a tablet.

   Only the ambient backdrop is tuned: on a small screen the sharp band sits
   on a calmer, slightly deeper blur so the artwork reads as one clean piece.
   --------------------------------------------------------------------- */
@media (max-width: 600px) {
  body::before {
    filter: blur(var(--cs-backdrop-blur)) brightness(0.24);
  }

  .coming-soon {
    background-size: 100% 100%, 100% auto;
    background-position: center center, center center;
  }
}

/* ---------------------------------------------------------------------
   Very large displays: unchanged composition, screen filled.
   --------------------------------------------------------------------- */
@media (min-width: 1600px) {
  .coming-soon {
    background-position: center center, center center;
    background-size: 100% 100%, cover;
  }
}

/* ---------------------------------------------------------------------
   Respect the user's motion preferences.
   --------------------------------------------------------------------- */
@media (prefers-reduced-motion: reduce) {
  .coming-soon,
  body::before {
    animation: none;
    background-attachment: scroll;
  }
}
