// This Source Code Form is subject to the terms of the Mozilla Public
// License, v. 2.0. If a copy of the MPL was not distributed with this
// file, You can obtain one at http://mozilla.org/MPL/2.0/.
//
// Copyright (c) KALEIDOS INC Sucursal en España SL

@use "refactor/basic-rules.scss" as *;
@use "ds/typography.scss" as t;

.modal-overlay {
  @extend %modal-overlay-base;

  &.transparent {
    background-color: transparent;
  }
}

.modal-container {
  @extend %modal-container-base;

  display: grid;
  gap: var(--sp-xxl);
  grid-template-rows: auto minmax(0, 1fr) auto;
}

.list-wrapper {
  display: grid;
  grid-template-rows: auto 1fr auto;
  max-height: 100%;
}

.modal-title {
  @include t.use-typography("headline-medium");

  color: var(--modal-title-foreground-color);
}

.modal-close-btn {
  @extend %modal-close-btn-base;
}

.modal-content {
  @include t.use-typography("body-small");

  display: grid;
  gap: var(--sp-s);
}

.element-list {
  @include t.use-typography("body-large");

  color: var(--modal-text-foreground-color);
  overflow-y: auto;
  margin-block: 0;
}

.action-buttons {
  @extend %modal-action-btns;
}

.cancel-button {
  @extend %modal-cancel-btn;
}

.accept-btn {
  @extend %modal-accept-btn;

  &.danger {
    @extend %modal-danger-btn;
  }
}

.modal-scd-msg {
  margin-block: 0;
}

.modal-scd-msg,
.modal-subtitle,
.modal-msg {
  @include t.use-typography("body-large");

  color: var(--modal-text-foreground-color);
  line-height: 1.5;
}
