@layer cinder.tokens, cinder.foundation, cinder.components, cinder.utilities;
@layer cinder.components {
  /* ========================================
   * DROP ZONE
   * A window-wide overlay shown while a file is dragged over the page. It never takes the
   * pointer: the drop lands on whatever is beneath it and the window's listener reads it.
   * ======================================== */

  .cinder-drop-zone {
    position: fixed;
    inset: 0;
    z-index: var(--cinder-z-backdrop);
    display: none;
    align-items: center;
    justify-content: center;
    padding: var(--cinder-space-6);
    background: var(--cinder-overlay-backdrop);
    font-family: var(--cinder-font-sans);
    pointer-events: none;
  }

  .cinder-drop-zone[data-cinder-active] {
    display: flex;
  }

  /* The label is always the drag-active face of FileUpload's dropzone (a solid accent edge on an
     8% accent tint, the same 2px weight), because it only shows while a file is dragged over. The
     tint mixes into FileUpload's own background token, so the two faces match in every theme and
     the scrim does not show through. */
  .cinder-drop-zone__label {
    margin: 0;
    border: 2px solid var(--cinder-accent-solid);
    border-radius: var(--cinder-radius-lg);
    background: color-mix(
      in srgb,
      var(--cinder-accent-solid) 8%,
      var(--cinder-file-upload-background)
    );
    padding: var(--cinder-space-6) var(--cinder-space-8);
    color: var(--cinder-text-default);
    font-size: var(--cinder-text-lg);
    font-weight: var(--cinder-font-semibold);
    text-align: center;
  }

  @media (forced-colors: active) {
    .cinder-drop-zone__label {
      border-color: Highlight;
    }
  }
}
