@use 'sass:color';

@use 'mixins';

@use 'spectre-css/_variables';

$max-mobile-width: 600px;
$min-desktop-width: $max-mobile-width + 1px;

@mixin mobile {
  @media only screen and (max-width: $max-mobile-width) {
    @content;
  }
}

@mixin desktop {
  @media only screen and (min-width: $min-desktop-width) {
    @content;
  }
}

@mixin default-button {
  border-color: color.adjust(
    variables.$gray-color-light,
    $lightness: 5%,
    $space: hsl
  );
  transition: none;
  &,
  &:visited {
    color: variables.$gray-color-dark;
  }
  &:hover {
    background-color: variables.$secondary-color-light;
    border-color: color.adjust(
      variables.$secondary-color,
      $lightness: 10%,
      $space: hsl
    );
    color: variables.$dark-color;
  }
  &:active,
  &.active {
    background-color: variables.$secondary-color-dark;
    border-color: color.adjust(
      variables.$secondary-color,
      $lightness: -10%,
      $space: hsl
    );
    color: white;
  }
}

.title_bold {
  @include mixins.title_bold;
}

.caption {
  @include mixins.standard_font;
  @include mixins.title_uppercase_weight;
  font-size: 12px;
  letter-spacing: mixins.$title-letter-spacing;
  opacity: 0.5;
}

.caption_lg {
  @include mixins.standard_font;
  @include mixins.title_uppercase_weight;
  font-size: 20px;
  letter-spacing: mixins.$button-letter-spacing;
  opacity: 0.5;
}

// NEW MENU STYLING

.new-menu-style {
  a {
    @include mixins.title_bold;
    text-transform: uppercase;
    border-top: 1px solid mixins.$text-color;
    color: mixins.$text-color;
    padding-top: 5px;
    text-decoration: none;

    &:focus,
    &:hover {
      color: #000 !important;
    }
    &.active {
      color: mixins.$text-color !important;
    }

    &:visited {
      color: mixins.$text-color !important;
    }
  }
  &:hover {
    color: #000 !important;
  }
}

.card-container {
  background-color: white;
  border-radius: 7px;
  border: #e4e8f0 solid 1px;
  padding: 20px;
}

// This is the opposite of aria-hidden="true"
.visually-hidden {
  clip: rect(0 0 0 0);
  clip-path: inset(50%);
  height: 1px;
  overflow: hidden;
  position: absolute;
  white-space: nowrap;
  width: 1px;
}
