@use "../../../styles/abstracts/variables";
@use "../../../styles/abstracts/mixins";

/* =========================================
   DESIGN TOKENS (YOUR SYSTEM)
========================================= */

$primary: #5e3817;
$primary-2: #7a4b20;

$primary-light: rgba(122, 75, 32, 0.08);
$primary-soft: rgba(122, 75, 32, 0.12);
$primary-soft-strong: rgba(122, 75, 32, 0.18);
$primary-border: rgba(122, 75, 32, 0.25);
$primary-muted: rgba(122, 75, 32, 0.6);

$border-light: rgba(0, 0, 0, 0.06);
$text-dark: #1a1a1a;
$text-muted: #6b6b6b;
$bg-soft: #faf8f6;

/* =========================================
   PROGRAMS WRAPPER
========================================= */

.programs {
  @include mixins.dashPageComponent;
  position: relative;

  &__header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 1rem;
  }

  &__title {
    display: flex;
    align-items: center;
    gap: 0.5rem;

    svg {
      font-size: 1.2rem;
      color: $primary;
    }

    h2 {
      font-size: 0.95rem;
      font-weight: 600;
      color: $text-dark;

      @media only screen and (max-width: 1000px) {
        font-size: 1rem;
      }
    }
  }

  &__viewAll {
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.4px;
    color: $primary;
    text-decoration: none;
    padding: 0.4rem 0.9rem;
    border-radius: 8px;
    background: $primary-light;
    transition: all 0.25s ease;

    &:hover {
      background: $primary-soft;
      transform: translateY(-1px);
    }
  }

  &__content {
    display: flex;
    flex-direction: column;
    gap: 0.9rem;
  }
}

/* =========================================
   PROGRAM ITEM
========================================= */

.program {
  padding: 0.85rem 0.95rem;
  border-radius: 12px;
  background: $primary-light;
  border: 1px solid $border-light;
  transition: all 0.25s ease;

  &:hover {
    background: $primary-soft;
    border-color: $primary-border;
    transform: translateY(-2px);
    box-shadow: 0 10px 24px rgba(122, 75, 32, 0.08);
  }

  h3 {
    font-size: 0.9rem;
    font-weight: 600;
    color: $text-dark;
    margin-bottom: 0.25rem;

    @media only screen and (max-width: 1000px) {
      font-size: 1.05rem;
    }
  }

  p {
    font-size: 0.85rem;
    line-height: 1.6;
    color: $text-muted;
    margin-bottom: 0.4rem;

    @media only screen and (max-width: 1000px) {
      font-size: 0.95rem;
    }
  }

  &__date {
    font-size: 0.7rem;
    font-weight: 600;
    color: $primary;
    text-transform: uppercase;
    letter-spacing: 0.5px;
  }
}

/* =========================================
   EMPTY STATE
========================================= */

.programs__empty {
  display: flex;
  padding: 2rem 1rem;
  text-align: center;
  justify-content: center;
  align-items: center;
  flex-direction: column;
  border-radius: 12px;
  background: $bg-soft;
  border: 1px dashed $primary-border;

  svg {
    font-size: 2rem;
    color: $primary-muted;
    margin-bottom: 0.5rem;
  }

  h4 {
    font-size: 0.9rem;
    font-weight: 600;
    color: $text-dark;
    margin-bottom: 0.25rem;
  }

  p {
    font-size: 0.8rem;
    color: $text-muted;
  }
}