.button:hover {
  text-decoration: none;
}

img.logo {
  margin: 0 auto 1.2rem;
  width: 10rem;

  @media (max-width: 768px) {
    margin: 0 auto;
  }
}

h1 {
  color: var(--green);
  margin-top: 0;
}

.login-modal {
  text-align: center;
  display: flex;
  flex-direction: column;
  gap: 1.8rem;
  width: 22rem;
  margin: 5rem auto;
}

.login-button {
  background: var(--primary-green);
  border: none;
  border-radius: 999px;
  color: white;
  font-size: 1rem;
  padding: 1.1rem 0;
  text-decoration: none;
  display: block;
  width: 100%;
  box-shadow: 0 2px 6px rgba(0,0,0,0.15);
  transition: scale .15s ease, box-shadow .15s ease;

  &:hover {
    box-shadow: 0 2px 12px rgba(0,0,0,0.15);
    scale: 1.02;
    text-decoration: none;
  }
}

.login-button:active {
  transform: scale(0.98);
}

.login-modal button[data-controller="passkey-login"] {
  align-items: center;
  background: white;
  border-radius: 0.9rem;
  border: 1px solid var(--off-white);
  cursor: pointer;
  display: flex;
  font-size: 1rem;
  gap: 0.5rem;
  justify-content: center;
  max-height: 3.5rem;
  padding: 0.9rem 0;
  transition: scale .15s ease, box-shadow .15s ease;
  width: 100%;

  &:hover {
    box-shadow: 0 2px 6px rgba(0,0,0,0.15);
    scale: 1.02;
    text-decoration: none;
  }

  &:active {
    scale: 0.98;
  }
}

.login-modal .divider {
  align-items: center;
  color: #777;
  display: flex;
  font-size: 0.9rem;
  gap: 1rem;
  justify-content: center;
  margin: 0.5rem 0;
}

.login-modal .divider::before,
.login-modal .divider::after {
  content: "";
  flex: 1;
  height: 1px;
  background: #ddd;
}

.login-modal .touch-id-icon {
  display: none;
  @media (min-width: 768px) {
    display: block;
  }
}

.login-modal .face-id-icon {
  display: block;
  @media (min-width: 768px) {
    display: none;
  }
}

.subject-list {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  width: 100%;
}

.continue-subject {
  padding: 2rem 0;
  width: 100%;
}

.dive-back-in-subjects {
  padding: 2rem 0;
  width: 100%;
}

.new-for-you-subjects {
  padding: 2rem 0;
  width: 100%;
}

.continue-subject,
.dive-back-in-subjects,
.new-for-you-subjects {
  @media (max-width: 768px) {
    padding: 1rem 0;
  }
}

.continue-subject-container,
.dive-back-in-subjects-container,
.new-for-you-subjects-container {
  margin: 0 auto;
  max-width: 40rem;

  @media (max-width: 768px) {
    max-width: 30rem;
    padding: 0 0.5rem;

    > h2 {
      margin-left: 1rem;
    }
  }
}

.continue-card-wrapper {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

.last-activity {
  color: var(--gray);
  font-size: 0.85rem;
  font-style: italic;
  margin: 0;
  text-align: right;
}

.recent-sessions {
  width: 100%;
}

.recent-sessions-container {
  align-items: center;
  display: flex;
  flex-wrap: wrap;
  font-size: 0.85rem;
  gap: 0.5rem;
  justify-content: center;
  margin: 0 auto;
  max-width: 40rem;
  padding: 0 1rem;
}

.session-item a {
  align-items: center;
  background: rgba(255, 255, 255, 0.7);
  border-radius: 0.5rem;
  color: var(--dark-text);
  display: flex;
  gap: 0.5rem;
  padding: 0.4rem 0.75rem;
  text-decoration: none;
  transition: background 0.15s ease;

  &:hover {
    background: rgba(255, 255, 255, 0.9);
  }
}

.session-subjects {
  max-width: 12rem;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.session-date {
  color: #999;
  font-size: 0.75rem;
}

.new-session-link {
  color: var(--primary-purple);
  font-size: 0.85rem;
  text-decoration: none;
  white-space: nowrap;

  &:hover {
    text-decoration: underline;
  }
}

.first-run-home {
  --first-run-card: #FCF8F4;
  --first-run-card-hover: #FFFDFB;
  --first-run-border: #EFE7DF;
  --first-run-ink: #27272A;
  --first-run-ink-soft: #52525B;
  --first-run-violet: #7C3AED;
  --first-run-indigo: #4F46E5;
  --first-run-lavender: #EEEBFE;
  --first-run-green: #15A05A;
  width: 100%;
}

.first-run-home .wrap {
  margin: 0 auto;
  max-width: 640px;
  padding: 2rem 24px 96px;
}

.first-run-home h1 {
  color: var(--first-run-ink);
  font-size: 30px;
  font-weight: 800;
  letter-spacing: -0.01em;
  line-height: 1.2;
  margin: 0 0 10px;
}

.first-run-home .lede {
  color: var(--first-run-ink-soft);
  font-size: 16px;
  line-height: 1.55;
  margin: 0;
  max-width: 46ch;
}

.first-run-home .label {
  color: var(--first-run-ink);
  font-size: 17px;
  font-weight: 700;
  margin: 40px 0 14px;
}

.first-run-home .cards {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.first-run-home .tcard {
  align-items: center;
  background: var(--first-run-card);
  border: 1px solid var(--first-run-border);
  border-radius: 16px;
  box-shadow: 0 1px 2px rgba(60, 40, 20, 0.04);
  color: inherit;
  display: flex;
  gap: 16px;
  padding: 18px 20px;
  text-decoration: none;
  transition: transform 0.12s ease, box-shadow 0.12s ease, background 0.12s ease;
  width: 100%;

  &:hover {
    background: var(--first-run-card-hover);
    box-shadow: 0 6px 18px rgba(60, 40, 20, 0.08);
    text-decoration: none;
    transform: translateY(-1px);
  }
}

.first-run-home .tcard__body {
  flex: 1;
  min-width: 0;
}

.first-run-home .tcard__title {
  color: var(--first-run-violet);
  font-size: 18px;
  font-weight: 700;
  line-height: 1.25;
  margin: 0 0 3px;
}

.first-run-home .tcard__desc {
  color: var(--first-run-ink-soft);
  font-size: 14px;
  line-height: 1.45;
  margin: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.first-run-home .count {
  background: var(--first-run-lavender);
  border-radius: 999px;
  color: var(--first-run-indigo);
  flex: none;
  font-size: 14px;
  font-weight: 700;
  min-width: 44px;
  padding: 6px 14px;
  text-align: center;
}

.first-run-home .chev {
  color: #B9AFA4;
  flex: none;
  transition: transform 0.12s ease, color 0.12s ease;
}

.first-run-home .tcard:hover .chev {
  color: var(--first-run-violet);
  transform: translateX(2px);
}

.first-run-home .alt {
  align-items: center;
  border-top: 1px solid var(--first-run-border);
  display: flex;
  flex-wrap: wrap;
  gap: 18px;
  justify-content: space-between;
  margin-top: 36px;
  padding-top: 28px;
}

.first-run-home .alt__text {
  color: var(--first-run-ink-soft);
  font-size: 15px;
  margin: 0;
}

.first-run-home .alt__actions {
  align-items: center;
  display: inline-flex;
  gap: 18px;
}

.first-run-home .btn-green {
  align-items: center;
  background: var(--first-run-green);
  border-radius: 999px;
  color: white;
  display: inline-flex;
  font-size: 15px;
  font-weight: 700;
  padding: 11px 22px;
  text-decoration: none;
  transition: filter 0.12s ease;

  &:hover {
    filter: brightness(1.05);
    text-decoration: none;
  }
}

.first-run-home .link-quiet {
  color: var(--first-run-indigo);
  font-size: 15px;
  font-weight: 600;
  text-decoration: none;
  white-space: nowrap;

  &:hover {
    text-decoration: underline;
  }
}
