/**
 * Mein TEN® — B2C Home (Phase 3 v2)
 * Quiet, spacious personal training area — not a dashboard grid.
 */

.myten-home {
  --home-ink: #1c1c1c;
  --home-muted: #6a6a6a;
  --home-surface: #ffffff;
  --home-pass: #1a1a1c;
  --home-ten: #cc0607;
  --home-green: #1f8a5b;
  --home-max: 1260px;
  width: min(var(--home-max), 100%);
  margin: 0 auto;
  padding: 0 0 80px;
  font-family: Calibri, Carlito, "Segoe UI", system-ui, sans-serif;
  color: var(--home-ink);
  -webkit-font-smoothing: antialiased;
}

/* ── Welcome ── */
.myten-home__welcome {
  max-width: 720px;
  margin: 0 0 48px;
  padding-top: 8px;
}
.myten-home__greeting {
  margin: 0;
  font-size: clamp(2.25rem, 4vw, 3rem);
  font-weight: 600;
  letter-spacing: -0.03em;
  line-height: 1.1;
}
.myten-home__context {
  margin: 12px 0 0;
  max-width: 560px;
  font-size: 1.1875rem;
  line-height: 1.45;
  color: var(--home-muted);
  font-weight: 400;
}

/* ── Hero: course + passport ── */
.myten-home__hero {
  display: grid;
  grid-template-columns: minmax(0, 1.62fr) minmax(0, 1fr);
  gap: 40px;
  align-items: start;
  margin-bottom: 64px;
}
.myten-home__kicker {
  margin: 0 0 16px;
  font-size: 0.8125rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--home-muted);
}
.myten-home__kicker--pass {
  color: rgba(255, 255, 255, 0.55);
}

/* Next course — dominant surface */
.myten-home__course {
  background: var(--home-surface);
  border-radius: 12px;
  padding: 32px;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.04);
}
.myten-home__course-title {
  margin: 0 0 16px;
  font-size: clamp(1.625rem, 2.5vw, 1.875rem);
  font-weight: 600;
  letter-spacing: -0.02em;
  line-height: 1.2;
}
.myten-home__course-when,
.myten-home__course-where {
  margin: 0 0 8px;
  font-size: 1.0625rem;
  line-height: 1.5;
  color: var(--home-ink);
}
.myten-home__course-where {
  color: var(--home-muted);
  font-size: 1rem;
}
.myten-home__course-timing {
  margin: 20px 0;
  font-size: 1rem;
  font-weight: 500;
  line-height: 1.3;
  color: var(--home-muted);
}
.myten-home__course-timing [data-countdown-value] {
  color: var(--home-ten);
}
.myten-home__course-empty {
  margin: 0 0 20px;
  font-size: 1.0625rem;
  line-height: 1.5;
  color: var(--home-muted);
  max-width: 28rem;
}
.myten-home__course-actions {
  margin-top: 8px;
}
.myten-home__cta {
  display: inline-flex;
}
.myten-home__secondary {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px 12px;
  margin-top: 16px;
}
.myten-home__link {
  font-size: 0.875rem;
  font-weight: 400;
  color: var(--home-muted);
  text-decoration: none;
  background: none;
  border: none;
  padding: 0;
  cursor: pointer;
  font-family: inherit;
  line-height: 1.4;
}
.myten-home__link:hover {
  color: var(--home-ink);
}
.myten-home__link--btn {
  text-decoration: underline;
  text-underline-offset: 2px;
}
.myten-home__late-form {
  display: inline;
  margin: 0;
}
.myten-home__secondary .myten-home__link:not(:last-child)::after {
  content: "·";
  margin-left: 12px;
  color: rgba(0, 0, 0, 0.2);
  pointer-events: none;
  text-decoration: none;
}

/* Passport — secondary credential */
.myten-home__passport-col {
  padding-top: 4px;
}
.myten-home__passport-card {
  background: var(--home-pass);
  color: #f5f5f5;
  border-radius: 12px;
  padding: 20px 22px 22px;
}
.myten-home__passport-name {
  margin: 0 0 6px;
  font-size: 1.25rem;
  font-weight: 600;
  letter-spacing: -0.02em;
  line-height: 1.25;
}
.myten-home__passport-role {
  margin: 0 0 10px;
  font-size: 0.9375rem;
  color: rgba(255, 255, 255, 0.75);
}
.myten-home__passport-status {
  margin: 0 0 4px;
  font-size: 0.875rem;
  font-weight: 500;
  color: #6ee7a0;
}
.myten-home__passport-status--pending {
  color: rgba(255, 255, 255, 0.55);
}
.myten-home__passport-valid {
  margin: 0 0 14px;
  font-size: 0.875rem;
  color: rgba(255, 255, 255, 0.55);
}
.myten-home__passport-link {
  display: inline-block;
  margin: 0;
  padding: 0;
  border: none;
  background: none;
  font-family: inherit;
  font-size: 0.875rem;
  font-weight: 500;
  color: #f5f5f5;
  cursor: pointer;
  text-decoration: underline;
  text-underline-offset: 3px;
}
.myten-home__passport-link:hover {
  opacity: 0.85;
}
.myten-home__next-step {
  margin: 16px 0 0;
  font-size: 0.875rem;
  line-height: 1.45;
  color: var(--home-muted);
}
.myten-home__next-step-link {
  color: var(--home-ink);
  text-decoration: underline;
  text-underline-offset: 2px;
}

/* ── Function rail (desktop only) ── */
.myten-b2c-rail {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 56px;
  padding-bottom: 4px;
  border-bottom: 1px solid rgba(0, 0, 0, 0.06);
}
.myten-b2c-rail__item {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 4px 12px;
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--home-muted);
  text-decoration: none;
  border-bottom: 2px solid transparent;
  margin-bottom: -1px;
  transition: color 0.15s ease;
}
.myten-b2c-rail__item:hover {
  color: var(--home-ink);
}
.myten-b2c-rail__item.is-active {
  color: var(--home-ink);
  border-bottom-color: var(--home-ten);
}
.myten-b2c-rail__icon {
  flex-shrink: 0;
  opacity: 0.7;
}

/* ── Further bookings ── */
.myten-home__bookings {
  margin-bottom: 48px;
}
.myten-home__bookings-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 20px;
}
.myten-home__section-title {
  margin: 0;
  font-size: 1.5rem;
  font-weight: 600;
  letter-spacing: -0.02em;
  line-height: 1.2;
}
.myten-home__section-link {
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--home-muted);
  text-decoration: none;
  white-space: nowrap;
}
.myten-home__section-link:hover {
  color: var(--home-ink);
}
.myten-home__booking-list {
  list-style: none;
  margin: 0;
  padding: 0;
}
.myten-home__booking-row {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 20px;
  padding: 24px 0;
  border-bottom: 1px solid rgba(0, 0, 0, 0.06);
}
.myten-home__booking-row:first-child {
  padding-top: 4px;
}
.myten-home__booking-row:last-child {
  border-bottom: none;
  padding-bottom: 0;
}
.myten-home__booking-title {
  display: block;
  margin: 0 0 4px;
  font-size: 1.125rem;
  font-weight: 600;
  letter-spacing: -0.01em;
  line-height: 1.3;
}
.myten-home__booking-meta {
  font-size: 0.875rem;
  line-height: 1.45;
  color: var(--home-muted);
}
.myten-home__booking-detail {
  flex-shrink: 0;
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--home-muted);
  text-decoration: none;
  padding-top: 2px;
}
.myten-home__booking-detail:hover {
  color: var(--home-ink);
}

/* ── Referral & upgrade ── */
.myten-home__referral {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin: 0;
  font-size: 0.875rem;
  color: var(--home-muted);
}
.myten-home__referral-action {
  padding: 0;
  border: none;
  background: none;
  font-family: inherit;
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--home-ink);
  cursor: pointer;
  text-decoration: underline;
  text-underline-offset: 2px;
}
.myten-home__upgrade {
  margin: 24px 0 0;
}
.myten-home__upgrade-link {
  font-size: 0.875rem;
  color: var(--home-muted);
  text-decoration: underline;
  text-underline-offset: 2px;
}

/* ── Passport modal ── */
.myten-passport-modal {
  position: fixed;
  inset: 0;
  z-index: 9600;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
}
.myten-passport-modal[hidden] {
  display: none;
}
.myten-passport-modal__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.4);
}
.myten-passport-modal__panel {
  position: relative;
  width: min(400px, 100%);
  padding: 28px 24px 24px;
  border-radius: 12px;
  background: #fff;
  text-align: center;
  box-shadow: 0 8px 40px rgba(0, 0, 0, 0.12);
}
.myten-passport-modal__title {
  margin: 0 0 8px;
  font-size: 1.125rem;
  font-weight: 600;
  letter-spacing: -0.02em;
}
.myten-passport-modal__name {
  margin: 0 0 20px;
  font-size: 1rem;
  color: var(--home-muted);
}
.myten-passport-modal__qr {
  display: inline-block;
  padding: 12px;
  background: #fff;
  border-radius: 8px;
  border: 1px solid rgba(0, 0, 0, 0.06);
}
.myten-passport-modal__qr img {
  display: block;
}
.myten-passport-modal__hint {
  margin: 12px 0 0;
  font-size: 0.8125rem;
  color: var(--home-muted);
  font-family: ui-monospace, monospace;
}
.myten-passport-modal__wallets {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 10px;
  margin-top: 20px;
}
.myten-passport-modal__wallet {
  display: inline-block;
  padding: 10px 16px;
  border-radius: 100px;
  font-size: 0.8125rem;
  font-weight: 600;
  text-decoration: none;
  color: var(--home-ink);
  border: 1px solid rgba(0, 0, 0, 0.1);
}
.myten-passport-modal__wallet:hover {
  background: rgba(0, 0, 0, 0.03);
}
.myten-passport-modal__close {
  display: block;
  width: 100%;
  margin-top: 20px;
  padding: 12px;
  border: none;
  border-radius: 8px;
  background: var(--home-pass);
  color: #fff;
  font-family: inherit;
  font-size: 0.9375rem;
  font-weight: 600;
  cursor: pointer;
}

/* ── B2C portal shell overrides ── */
.myten-portal--b2c.myten-portal--dashboard {
  background: transparent;
  max-width: none;
  width: min(var(--home-max), 100%) !important;
  padding-bottom: 0;
}
.myten-portal--b2c .myten-welcome,
.myten-portal--b2c .myten-main,
.myten-portal--b2c .myten-actions,
.myten-portal--b2c .myten-recent,
.myten-portal--b2c .myten-support-card,
.myten-portal--b2c .myten-upgrade,
.myten-portal--b2c .myten-referral-wrap {
  display: none;
}
.myten-portal--b2c .myten-ph__nav {
  display: none !important;
}

/* ── Mobile ── */
@media (max-width: 900px) {
  .myten-home__hero {
    grid-template-columns: 1fr;
    gap: 32px;
    margin-bottom: 40px;
  }
  .myten-home__course {
    padding: 24px 20px;
  }
  .myten-home__welcome {
    margin-bottom: 32px;
  }
  .myten-home__greeting {
    font-size: 2.25rem;
  }
  .myten-home__context {
    font-size: 1.0625rem;
  }
  .myten-b2c-rail {
    display: none !important;
  }
  .myten-home__cta {
    display: flex;
    width: 100%;
    justify-content: center;
  }
  .myten-home__secondary {
    flex-direction: column;
    align-items: flex-start;
    gap: 10px;
    margin-top: 14px;
  }
  .myten-home__secondary .myten-home__link:not(:last-child)::after {
    content: none;
  }
  .myten-home__bookings {
    margin-bottom: 32px;
  }
}

@media (max-width: 640px) {
  .myten-home {
    padding-bottom: 100px;
  }
  .myten-home__booking-row {
    flex-direction: column;
    gap: 8px;
    padding: 20px 0;
  }
}
