@use "sass:map";
@use "@twig/scss/_global" as global;
@use "@twig/scss/variables/_variables-components" as components;

$params: (
   "flex": 0 0 auto,
   "margin-left": 30px,
   "show-breakpoint": global.$xl,

   "img-border-radius": global.$border-radius-base,
);

@if global-variable-exists(c-header-sections-banner, components) {
   $keys: map.keys(components.$c-header-sections-banner);
   @each $name in $keys {
      @if not map.get($params, $name) {
         @warn "Neexistující proměnná '#{$name}' v komponentě '$#{component("Header:Sections:Banner", "class")}'.";
      }
   }

   $params: map.merge($params, components.$c-header-sections-banner);
}

.#{component("Header:Sections:Banner", "class")} {
   flex: map.get($params, "flex");
   display: none;
   margin-left: map.get($params, "margin-left");

   @media screen and (min-width: map.get($params, "show-breakpoint")) {
      display: block;
   }

   .#{component("Picture", "class")} {
      img {
         border-radius: map.get($params, "img-border-radius");
      }
   }
}
