:root {
  --scrollbar-width: 0px;
}

.session-modal * {
  box-sizing: border-box;
}

.session-modal {
  position: fixed;
  inset: 0;
  height: 100vh;
  width: 100vw;
  width: auto;
  z-index: 99999;
  transition: opacity 0.3s ease, visibility 0.3s ease;
  display: flex;
  align-items: center;
  justify-content: center;
  background-color: rgba(16, 1, 19, 0.4);
  padding: var(--h-space-6);
  padding-top: var(--h-space-8);
  display: none;
  opacity: 0;
  visibility: hidden;
}

.session-modal.show {
  opacity: 1;
  visibility: visible;
}

html.modal-open {
  overflow: hidden;
}

html.modal-open body {
  padding-right: var(--scrollbar-width);
}

body.modal-open {
  overflow: hidden;
}

.session-modal-wrapper {
  position: relative;
  background-color: var(--h-color-neutral-light);
  border-radius: var(--h-border-radius-lg);
  box-shadow: var(--h-shadow-lg);
}

.session-modal-content {
  height: 100%;
  width: 100%;
  max-width: 800px;
  max-height: 90vh;
  display: flex;
  flex-direction: column;
  gap: var(--h-space-4);
  margin-bottom: var(--h-space-6);
  padding: var(--h-space-10) var(--h-space-4);
  overflow: auto;

  &::-webkit-scrollbar {
    width: 8px;
  }

  &::-webkit-scrollbar-thumb {
    background-color: var(--h-color-neutral);
    border-radius: var(--h-border-radius-lg);
  }

  &::-webkit-scrollbar-track {
    background-color: var(--h-color-neutral-light);
    border-radius: var(--h-border-radius-lg);
  }

  @media (min-width: 768px) {
    max-height: 60vh;
    padding: var(--h-space-12) var(--h-space-8);
  }
}

.session-modal-close-button {
  border: 0 solid transparent;
  box-sizing: border-box;
  position: absolute;
  top: var(--h-space-4);
  right: var(--h-space-4);
  background-color: var(--h-color-accent);
  height: var(--h-space-6);
  width: var(--h-space-6);
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--h-border-radius-round);
  color: var(--h-color-accent-light);
  font-size: var(--h-text-lg);
  font-weight: var(--h-wt-semibold);
  line-height: 1;
  cursor: pointer;
  transition: background-color 0.3s ease, transform 0.3s ease;

  &:hover {
    background-color: var(--h-color-accent-dark);
  }

  @media (min-width: 768px) {
    top: var(--h-space-3);
    right: var(--h-space-5);
  }
}

.session-modal-content-subheader {
  display: flex;
  flex-wrap: wrap;
  gap: var(--h-space-2);
  justify-content: center;
}

.session-modal-content-subheader-wrapper {
  display: flex;
  gap: var(--h-space-1);
  align-items: center;
  justify-content: center;
  background-color: var(--h-color-primary-light);
  padding: var(--h-space-1) var(--h-space-3);
  border-radius: var(--h-border-radius-md);

  p {
    text-transform: uppercase;
    font-size: var(--h-text-xs);
    margin: 0;

    @media (min-width: 768px) {
      font-size: var(--h-text-sm);
    }
  }
}

.modal-content-subheader-icon {
  width: 24px;
  height: 24px;
}

.modal-content-header {
  display: flex;
  flex-direction: column;
  gap: var(--h-space-2);
  align-items: center;
  justify-content: center;
}

.modal-content-header-name {
  font-size: var(--h-text-lg);
  font-weight: var(--h-wt-semibold);
  text-align: center;

  @media (min-width: 768px) {
    font-size: var(--h-text-xl);
  }
}

.modal-content-body {
  display: flex;
  flex-direction: column;
  gap: var(--h-space-4);
}

.modal-content-body-description {
  margin-bottom: var(--h-space-4);
  line-height: 1.5;

  p {
    font-size: var(--h-text-sm);
  }
}

.session-tag {
  width: 100%;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: var(--h-space-2);
}

.session-tag-content {
  font-size: var(--h-text-xs);
  font-weight: var(--h-wt-semibold);
  padding: var(--h-space-2) var(--h-space-4);
}

.session-tag-filled {
  border: var(--h-border-width-thin) solid var(--h-color-accent);
  background-color: var(--h-color-accent);
  color: var(--h-color-accent-light);
  border-radius: var(--h-border-radius-full);
}

.modal-content-speakers {
  display: flex;
  flex-direction: column;
  gap: var(--h-space-4);
}

.modal-content-speaker-type {
  font-size: var(--h-text-md);
  font-weight: var(--h-wt-semibold);
  margin: 0;
}

.modal-content-body-speakers {
  display: flex;
  flex-direction: column;
  gap: var(--h-space-4);
}

.modal-content-body-speaker {
  display: flex;
  gap: var(--h-space-4);
  align-items: center;
}

.modal-content-body-speaker-info {
  display: flex;
  flex-direction: column;
  gap: var(--h-space-1);

  p {
    font-size: var(--h-text-sm);
    margin: 0;
    line-height: 1;
  }
}

.modal-content-body-speaker-full-name {
  font-weight: var(--h-wt-semibold);
  color: var(--h-color-accent);
}

.modal-content-body-speaker-job-title {
  font-weight: var(--h-wt-semibold);
}

.modal-content-body-speaker-company-name {
  font-style: italic;
}

.speaker-avatar-wrapper {
  position: relative;
  border: var(--h-border-width-normal) solid var(--h-color-white);
  border-radius: var(--h-border-radius-round);
  background-color: var(--h-color-primary);
  overflow: hidden;
  margin-right: calc(var(--h-space-2) * -1);
  transition: 0.2s ease-in-out;
  height: var(--h-avatar-size-lg);
  width: var(--h-avatar-size-lg);
  flex-shrink: 0;

  &:hover {
    transform: scale(1.1);
  }

  &.avatar-placeholder {
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: var(--h-text-3xl);
  }
}

.speaker-avatar {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
