:root {
  /* Font */
  --font-sans: 'Inter', system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  --line-height: 1.5;

  /* Core palette (light) */
  --color-text: #0f172a;
  --color-bg: #f5f7fb;
  --color-bg-gradient-start: #e2e8f0;
  --color-bg-gradient-end: #f8fafc;

  --color-white: #ffffff;
  --color-slate-900: #0b1120;
  --color-gray: #64748b;

  /* Brand */
  --color-primary: #111827;
  --color-primary-hover: #000000;

  /* Status */
  --color-success: #22c55e;
  --color-success-hover: #16a34a;

  --color-danger: #ef4444;
  --color-danger-hover: #dc2626;

  --color-subtle: #e5e7eb;
  --color-subtle-hover: #d4d4d8;
  --color-surface-subtle: rgba(15, 23, 42, 0.08);
  --color-surface-subtle-hover: rgba(15, 23, 42, 0.14);

  /* Dark surfaces (detail pages) */
  --color-detail-text: #f8fafc;
  --color-detail-surface: rgba(15, 23, 42, 0.8);
  --color-detail-surface-strong: rgba(15, 23, 42, 0.6);

  /* Borders (light) */
  --border-light: 1px solid rgba(15, 23, 42, 0.12);
  --border-light-soft: 1px solid rgba(15, 23, 42, 0.08);
  --border-light-med: 1px solid rgba(15, 23, 42, 0.15);

  /* Borders (dark) */
  --border-dark: 1px solid rgba(148, 163, 184, 0.2);
  --border-detail: 1px solid rgba(248, 250, 252, 0.3);

  /* Radii */
  --radius-pill: 999px;
  --radius-lg: 20px; /* previously --radius */
  --radius-xl: 24px;
  --radius-md: 14px;
  --radius-sm: 10px;
  --radius-xs: 8px;
  --radius-btn: 6px;

  /* Shadows */
  --shadow-float: 0 12px 30px rgba(15, 23, 42, 0.2);
  --shadow-float-hover: 0 16px 36px rgba(15, 23, 42, 0.25);
  --shadow-card: 0 25px 55px rgba(15, 23, 42, 0.08);
  --shadow-card-dark: 0 25px 60px rgba(2, 6, 23, 0.6);
  --shadow-modal: 0 30px 60px rgba(15, 23, 42, 0.2);
  --shadow-auth: 0 30px 60px rgba(15, 23, 42, 0.12);

  /* Misc commonly reused */
  --btn-hover-shadow: 0 15px 30px rgba(37, 99, 235, 0.35);
  --header-icon-size: 40px;

  /* “Muted” colors used in dark sections */
  --color-muted-dark: #cbd5f5;
  --color-muted-dark-2: #a5b4fc;
  --color-muted-light: #475569;

  /* Pose status */
  --pose-bg: #444;
  --pose-text: #fff;
  --pose-ready-bg: #2ecc71;
  --pose-ready-text: #0b2a12;
}

:root {
  font-family: var(--font-sans);
  color: var(--color-text);
  background-color: var(--color-bg);
  line-height: var(--line-height);
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  background: linear-gradient(180deg, var(--color-bg-gradient-start) 0%, var(--color-bg-gradient-end) 100%);
}

/* Normalizing Page Layout Classes */
.page {
  flex: 1;
  display: block;
}

.page-pad {
  padding: 2.5rem clamp(1rem, 6vw, 5rem);
}

.container {
  width: 100%;
  max-width: 720px;
  margin: 0 auto;
}

.container--wide {
  max-width: 1100px;
}

.stack {
  display: grid;
  gap: 1.5rem;
}

/* ============================= */
/* App Header (Top Bar)          */
/* ============================= */

.app-header {
  position: sticky;
  top: 0;
  z-index: 30;
  width: 100%;
  background: #eef2f6;
  border-bottom: var(--border-light-soft);
}

.app-header__inner {
  max-width: 1200px;
  margin: 0 auto;
  padding: 1rem clamp(1rem, 4vw, 2.5rem);

  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}

.app-header__brand {
  display: inline-flex;
  align-items: center;
  gap: 0.75rem;

  text-decoration: none;             /* remove purple underline */
  color: var(--color-slate-900);
}

.app-header__logo {
  width: 42px;
  height: 42px;
  object-fit: contain;
  display: block;
}

.app-header__title {
  font-size: 1.75rem;
  font-weight: 800;
  letter-spacing: -0.02em;
}

/* right-side icon row */
.app-header__actions {
  position: relative;
  display: flex;
  align-items: center;
  gap: 0.75rem;
  flex-wrap: nowrap;
}

/* square-ish icon buttons like Figma */
.icon-btn {
  width: 40px;
  height: 40px;
  min-width: 40px;
  min-height: 40px;
  flex: 0 0 40px;

  border-radius: 10px;
  background: var(--color-white);
  border: var(--border-light-soft);

  display: inline-flex;
  align-items: center;
  justify-content: center;

  padding: 0;
  margin: 0;
  text-decoration: none;

  appearance: none;
  -webkit-appearance: none;
  cursor: pointer;
  line-height: 1;
  overflow: hidden;
}

.icon-btn:hover {
  background: var(--color-subtle);
}

.icon-btn__img {
  width: 22px;
  height: 22px;
  object-fit: contain;
  display: block;
  flex: 0 0 auto;
}

@media (max-width: 640px) {
  .app-header__inner {
    padding: 0.75rem 1rem;
    gap: 0.75rem;
  }

  .app-header__brand {
    gap: 0.5rem;
    min-width: 0;
    flex: 1 1 auto;
  }

  .app-header__logo {
    width: 32px;
    height: 32px;
    flex-shrink: 0;
  }

  .app-header__title {
    font-size: 1.1rem;
    line-height: 1.1;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
  }

  .app-header__actions {
    gap: 0.4rem;
    flex-shrink: 0;
  }

  .icon-btn {
    width: 34px;
    height: 34px;
    min-width: 34px;
    min-height: 34px;
    flex: 0 0 34px;
    border-radius: 8px;
  }

  .icon-btn__img {
    width: 18px;
    height: 18px;
  }
}

.logo-mark__image {
  width: clamp(90px, 14vw, 150px);
  height: auto;
  margin: 0 auto 0.15rem;
}

.logo-mark__text {
  font-size: clamp(3rem, 10vw, 5rem);
  font-weight: 700;
  letter-spacing: 0.15em;
  text-transform: uppercase;
}

/* Home grid */
.quadrants {
  flex: 1;
  display: grid;
  grid-template-columns: repeat(3, minmax(280px, 1fr));
  gap: 2rem;
  padding: 3rem clamp(1.5rem, 6vw, 5rem);
  max-width: 1200px;
  margin: 0 auto;
}

/* Footer */
.footer {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
  padding: 2rem clamp(1rem, 5vw, 4rem);
  font-size: 0.95rem;
  color: var(--color-gray);
}

.footer a {
  color: var(--color-muted-light);
  font-weight: 600;
  text-decoration: none;
}

.footer a:hover {
  color: var(--color-text);
  text-decoration: underline;
  text-underline-offset: 2px;
}

.footer__socials,
.footer__links {
  display: flex;
  flex-wrap: wrap;
  gap: 1.25rem;
}

.footer_version {
  color: var(--color-gray);
  font-size: 0.82rem;
  letter-spacing: 0.02em;
}

.footer_version p {
  margin: 0;
}

@media (max-width: 640px) {
  .footer {
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 0.85rem;
    text-align: center;
    padding: 1.25rem 1rem 1.5rem;
  }

  .footer__socials,
  .footer__links {
    justify-content: center;
    gap: 0.65rem 0.75rem;
  }

  .footer__socials {
    order: 1;
  }

  .footer__links {
    order: 2;
  }

  .footer_version {
    order: 3;
  }

  .footer__socials a,
  .footer__links a {
    padding: 0;
    border: 0;
    border-radius: 0;
    background: transparent;
  }
}

/* Quadrant cards */
.quadrant {
  background: var(--color-white);
  border-radius: var(--radius-lg);
  display: flex;
  flex-direction: row;
  flex-wrap: wrap;
  align-items: center;
  gap: 1.5rem;
  padding: 1.5rem;
  box-shadow: var(--shadow-card);
}

.quadrant img {
  width: clamp(100px, 22%, 150px);
  height: auto;
  border-radius: var(--radius-lg);
  object-fit: contain;
  align-self: center;
}

.quadrant__copy {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  flex: 1 1 220px;
  min-width: 220px;
}

.eyebrow {
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.25em;
  color: var(--color-gray);
}

/* Buttons */
.btn {
  align-self: flex-start;
  border-radius: var(--radius-pill);
  padding: 0.75rem 1.5rem;
  font-weight: 600;
  border: none;
  background: var(--color-primary);
  color: var(--color-white);
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.btn:hover {
  background: var(--color-primary-hover);
  transform: translateY(-2px);
  box-shadow: var(--btn-hover-shadow);
}

@media (max-width: 768px) {
  .quadrant {
    flex-direction: column;
    text-align: center;
  }

  .quadrant img {
    width: min(240px, 80%);
    height: auto;
  }

  .quadrant__copy {
    align-items: center;
  }

  .quadrant__copy .btn {
    align-self: center;
  }
}

@media (max-width: 1100px) {
  .quadrants {
    grid-template-columns: repeat(2, minmax(280px, 1fr));
  }
}

@media (max-width: 640px) {
  .quadrants {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 1rem;
    padding: 1.25rem 1rem 2rem;
  }
}

/* Detail pages */
.detail {
  background: var(--color-slate-900);
  color: var(--color-detail-text);
}

.detail__wrapper {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
  padding: 2.5rem clamp(1rem, 6vw, 5rem);
}

.detail__back,
.capture__back {
  font-size: 1rem;
  font-weight: 700;
  letter-spacing: 0.02em;
  padding: 0.35rem 0.9rem;
  border-radius: var(--radius-pill);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.35rem;
}

.detail__back {
  color: var(--color-detail-text);
  background: rgba(248, 250, 252, 0.12);
  border: var(--border-detail);
}

.detail__back:hover {
  background: rgba(248, 250, 252, 0.2);
}

.capture__back {
  color: #1e293b;
  background: var(--color-surface-subtle);
  border: var(--border-light-med);
  margin-right: 3.25rem;
}

.capture__back:hover {
  background: var(--color-surface-subtle-hover);
  text-decoration: none;
}

.detail__card {
  background: var(--color-detail-surface);
  border-radius: var(--radius-lg);
  padding: 2rem;
  display: grid;
  grid-template-columns: minmax(240px, 320px) 1fr;
  gap: 2rem;
  box-shadow: var(--shadow-card-dark);
}

.detail__card img {
  width: 100%;
  border-radius: var(--radius-lg);
  object-fit: cover;
}

@media (max-width: 640px) {
  .detail__card {
    grid-template-columns: 1fr;
  }
  .profile-link {
    top: 0.75rem;
    right: 0.75rem;
    width: 38px;
    height: 38px;
  }

  .profile-link__icon {
    width: 18px;
    height: 18px;
  }

  .capture__back {
    margin-right: 0;
  }
}

/* Capture pages */
.capture {
  background: var(--color-bg);
  color: var(--color-text);
}

.capture__main {
  flex: 1;
  display: block;
}

.capture__frame {
  width: 640px;
  height: 360px;
  max-width: 90vw;
  max-height: 60vh;
  background: var(--color-white);
  border-radius: var(--radius-lg);
  padding: 2rem;
  box-shadow: var(--shadow-card);
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: center;
}

.capture__viewport {
  position: relative;
  width: 100%;
  height: 100%;
  border-radius: var(--radius-lg);
  overflow: hidden;
}

.capture__image {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: contain;
  display: block;
  opacity: 0;
}

.capture__viewport--active .capture__image {
  opacity: 1;
}

.capture__viewport--unmirror .capture__image,
.capture__viewport--unmirror .capture__overlay {
  transform: scaleX(-1);
  transform-origin: center;
}

.capture__placeholder {
  position: absolute;
  inset: 0;
  display: grid;
  grid-template-rows: auto minmax(0, 1fr) auto;
  align-items: center;
  justify-items: center;
  gap: 0.5rem;
  text-align: center;
  padding: 0.6rem;
  background: var(--color-white);
}

.capture__placeholder-text {
  margin: 0;
  font-weight: 600;
  font-size: 0.9rem;
  line-height: 1.15;
  color: var(--color-text);
}

.capture__placeholder-image {
  max-width: 80%;
  max-height: 58%;
  width: auto;
  height: auto;
  border-radius: var(--radius-lg);
}

.capture__viewport--active .capture__placeholder {
  display: none;
}

.capture__overlay {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
}

.capture__controls {
  display: flex;
  gap: 0.75rem;
  justify-content: center;
}

.capture__controls .btn {
  border-radius: var(--radius-btn);
  padding: 0.6rem 2.4rem;
  font-size: 0.9rem;
  box-shadow: none;
}

.capture__note {
  margin: 0;
  text-align: center;
  color: var(--color-text-muted);
  font-size: 0.9rem;
}

.capture__analysis {
  margin-top: 0.5rem;
  border: var(--border-light-soft);
  border-radius: var(--radius-lg);
  background: var(--color-white);
  padding: 0.9rem 1rem;
}

.capture__analysis-title {
  margin: 0;
  font-size: 0.95rem;
  font-weight: 700;
}

.capture__analysis-output {
  margin: 0.6rem 0 0;
  padding: 0.7rem;
  border-radius: var(--radius-sm);
  background: var(--color-subtle);
  color: var(--color-text-muted);
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 0.82rem;
  line-height: 1.45;
  white-space: pre-wrap;
  word-break: break-word;
}

.capture__analysis-output--success {
  background: #ecfdf5;
  color: #065f46;
}

.capture__analysis-output--error {
  background: #fef2f2;
  color: #991b1b;
}

.capture__switch--hidden {
  display: none;
}

.btn--start {
  background: var(--color-success);
  color: #052e16;
  transform: none;
  box-shadow: none;
}

.btn--start:hover {
  background: var(--color-success-hover);
  color: #ecfdf5;
  transform: none;
  box-shadow: none;
}

.btn--subtle {
  background: var(--color-subtle);
  color: #6b7280;
  transform: none;
  box-shadow: none;
}

.btn--subtle:hover {
  background: var(--color-subtle-hover);
  transform: none;
  box-shadow: none;
}

.btn--danger {
  background: var(--color-danger);
}

.btn--danger:hover {
  background: var(--color-danger-hover);
}

.btn--dark {
  background: #374151;
}

.btn--dark:hover {
  background: #111827;
}

@media (max-width: 768px) {
  .capture__frame {
    padding: 1.5rem;
  }

  .capture__controls {
    flex-direction: column;
  }

  .capture__controls .btn {
    width: 100%;
    text-align: center;
  }

  .capture__analysis {
    padding: 0.8rem;
  }

  .capture__header-inner {
    align-items: flex-start;
  }

  .capture__branding .logo-mark__text {
    max-width: 100%;
  }
}

/* Pose status */
.pose-status {
  margin-bottom: 12px;
  padding: 8px 12px;
  border-radius: var(--radius-xs);
  background: var(--pose-bg);
  color: var(--pose-text);
  font-weight: 600;
}
.pose-status--hidden {
  display: none;
}
.pose-status.ready {
  background: var(--pose-ready-bg);
  color: var(--pose-ready-text);
}

/* Team / panel layouts */
.team-panel {
  margin: 1.5rem auto 0;
  max-width: 720px;
  display: grid;
  gap: 1rem;
  text-align: center;
}

.team-panel__header {
  display: grid;
  gap: 0.35rem;
}

.team-panel__section {
  display: grid;
  gap: 1rem;
}

.team-panel__section--hidden {
  display: none;
}

.team-panel__row {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
}

.team-panel__hint {
  color: #94a3b8;
  font-size: 0.9rem;
}

.team-form {
  display: grid;
  gap: 0.75rem;
  text-align: left;
}

.team-form__row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  align-items: center;
}

.team-form__field {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
  flex: 1 1 160px;
}

.team-form__label {
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.15em;
  color: #94a3b8;
}

.team-form__input {
  width: 100%;
  border-radius: var(--radius-sm);
  border: 1px solid rgba(148, 163, 184, 0.35);
  background: var(--color-detail-surface-strong);
  color: var(--color-detail-text);
  padding: 0.55rem 0.75rem;
  font-size: 0.95rem;
}

.team-form__input::placeholder {
  color: rgba(226, 232, 240, 0.6);
}

.team-members {
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  gap: 0.75rem;
}

.team-members__item {
  padding: 0.75rem 0.9rem;
  border-radius: 12px;
  background: var(--color-detail-surface-strong);
  border: var(--border-dark);
}

.team-members__title {
  font-weight: 600;
  margin-bottom: 0.35rem;
}

.team-members__meta,
.team-members__empty {
  color: var(--color-muted-dark);
  font-size: 0.85rem;
}

.team-load-more {
  justify-self: center;
}

.team-load-more--hidden {
  display: none;
}

.team-message {
  min-height: 1.2rem;
  font-size: 0.9rem;
  color: var(--color-muted-dark);
}

.team-message--error {
  color: #fca5a5;
}

.team-message--success {
  color: #86efac;
}

/* Centered/light variant */
.team-panel--centered h2,
.team-panel--centered h3 {
  color: var(--color-slate-900);
  font-weight: 700;
}

.team-panel--centered p,
.team-panel--centered .team-message {
  color: var(--color-text);
  font-weight: 600;
}

.team-panel--centered .team-panel__hint {
  color: var(--color-text);
  font-weight: 600;
}

.team-panel--centered .team-form__label {
  color: var(--color-slate-900);
  font-weight: 700;
}

.team-panel--centered .team-form__input {
  background: var(--color-white);
  color: var(--color-text);
  border: var(--border-light-med);
}

.team-panel--centered .team-form__input::placeholder {
  color: #94a3b8;
}

.team-panel--centered .team-members__item {
  background: var(--color-white);
  border: var(--border-light);
}

.team-panel--centered .team-members__meta,
.team-panel--centered .team-members__empty {
  color: var(--color-muted-light);
  font-weight: 600;
}

/* Recordings */
.recordings-panel {
  background: var(--color-detail-surface);
  border-radius: var(--radius-lg);
  padding: 1.75rem;
  display: grid;
  gap: 1rem;
  box-shadow: var(--shadow-card-dark);
}

.recordings-panel__header h2 {
  font-size: 1.4rem;
}

.recordings-panel__header p {
  color: var(--color-muted-dark);
  font-weight: 500;
}

.recordings-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 1rem;
}

.recording-card {
  background: rgba(15, 23, 42, 0.7);
  border-radius: 14px;
  padding: 0.75rem;
  border: var(--border-dark);
}

.recording-card video {
  width: 100%;
  border-radius: var(--radius-sm);
  display: block;
  background: var(--color-text);
}

.recording-card__meta {
  margin-top: 0.5rem;
  font-size: 0.85rem;
  color: var(--color-muted-dark);
}

.workout-card__row {
  display: flex;
  justify-content: space-between;
  gap: 0.5rem;
  align-items: center;
}

.workout-card__title {
  margin: 0;
  font-size: 1rem;
  color: #e2e8f0;
}

.workout-card__pill {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.2rem 0.65rem;
  border-radius: var(--radius-pill);
  background: rgba(134, 239, 172, 0.2);
  color: #86efac;
  font-weight: 700;
  font-size: 0.85rem;
}

.workout-card__summary {
  margin: 0.4rem 0 0;
  color: #284b73;
  font-weight: 500;
}

.workout-card__score {
  margin: 0.75rem 0 0;
  font-size: 1.05rem;
  font-weight: 800;
}

.workout-card__score--ok {
  color: #166534;
}

.workout-card__score--missing {
  color: #991b1b;
}

.workout-card__metrics {
  margin-top: 0.75rem;
  display: grid;
  gap: 0.35rem;
}

.workout-card__metric {
  margin: 0;
  color: #284b73;
  font-size: 0.92rem;
}

.workout-card__metric--subtle {
  color: #4a6485;
  font-size: 0.84rem;
}

.workout-card__metric-label {
  font-weight: 600;
  color: #111111;
}

.workout-card__metric-value {
  margin-left: 0.3rem;
  font-weight: 400;
  color: #284b73;
}

.recordings-message {
  min-height: 1.2rem;
  font-size: 0.9rem;
  color: var(--color-muted-dark);
}

.recordings-message--error {
  color: #fca5a5;
}

.recordings-message--success {
  color: #86efac;
}

.recordings-empty {
  color: var(--color-muted-dark);
  font-size: 0.9rem;
}

.recordings-load-more {
  justify-self: center;
}

.recordings-load-more--hidden {
  display: none;
}

/* Auth */
.auth {
  background: linear-gradient(180deg, var(--color-bg-gradient-start) 0%, var(--color-bg-gradient-end) 100%);
  color: var(--color-text);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 2rem;
}

.auth__panel {
  width: min(480px, 92vw);
  background: var(--color-white);
  border-radius: var(--radius-xl);
  padding: 2.5rem;
  box-shadow: var(--shadow-auth);
  display: grid;
  gap: 1rem;
  text-align: center;
  max-width: 100%;
  overflow-wrap: anywhere;
}

.auth__brand {
  display: grid;
  justify-items: center;
  gap: 0.25rem;
}

.auth .logo-mark__text {
  font-size: clamp(2.2rem, 6vw, 3.2rem);
  letter-spacing: 0.12em;
}

.auth__cta {
  align-self: center;
  padding: 0.85rem 2rem;
}

.auth__error {
  color: var(--color-danger-hover);
  font-weight: 600;
}

/* Snapshot (light variant of “detail” pages) */
.snapshot .detail__wrapper {
  padding-top: 0;
  gap: 1rem;
  color: var(--color-text);
}

.snapshot .detail__card {
  background: var(--color-white);
  border: var(--border-light);
  box-shadow: 0 20px 40px rgba(15, 23, 42, 0.08);
  color: var(--color-text);
}

.snapshot .detail__card p {
  color: var(--color-text);
}

.snapshot .recordings-panel {
  background: var(--color-white);
  border: var(--border-light);
  box-shadow: 0 20px 40px rgba(15, 23, 42, 0.08);
  color: var(--color-text);
}

.snapshot .recordings-panel__header p {
  color: #1e293b;
}

.snapshot .recording-card {
  background: var(--color-white);
  border: var(--border-light);
}

.snapshot .recording-card video {
  background: var(--color-bg-gradient-start);
}

.snapshot .recording-card__meta,
.snapshot .recordings-message,
.snapshot .recordings-empty {
  color: #1e293b;
}

.snapshot .workout-card__title {
  color: var(--color-text);
}

.snapshot .workout-card__summary {
  color: #1f2937;
}

.snapshot .workout-card__meta {
  color: #334155;
}

.snapshot .workout-card__pill {
  background: rgba(34, 197, 94, 0.12);
  color: #166534;
}

/* Profile page card */
.profile-card {
  display: grid;
  gap: 1.5rem;
}

.profile-list {
  display: grid;
  gap: 0.75rem;
  margin-top: 1rem;
}

.profile-item {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 0.5rem;
  padding: 0.75rem 0.9rem;
  background: var(--color-detail-surface-strong);
  border: var(--border-dark);
  border-radius: 12px;
}

.profile-label {
  text-transform: uppercase;
  letter-spacing: 0.12em;
  font-size: 0.7rem;
  color: var(--color-muted-dark);
}

.profile-value {
  font-weight: 600;
  color: var(--color-detail-text);
}

.profile-actions {
  margin-top: 1.25rem;
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
}

/* Account delete confirm */
.account-delete {
  display: grid;
  gap: 0.75rem;
  margin-top: 0.75rem;
}

.account-delete__text {
  margin: 0;
  font-weight: 600;
}

.account-delete__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
}

.account-delete--hidden {
  display: none;
}

/* Profile modal */
.profile-modal {
  position: fixed;
  inset: 0;
  display: grid;
  place-items: center;
  z-index: 60;
}

.profile-modal[aria-hidden="true"] {
  display: none;
}

.profile-modal__overlay {
  position: absolute;
  inset: 0;
  background: rgba(15, 23, 42, 0.65);
}

.profile-modal__content {
  position: relative;
  z-index: 1;
  width: min(520px, 92vw);
  background: var(--color-white);
  color: var(--color-text);
  border-radius: var(--radius-lg);
  padding: 2rem;
  box-shadow: var(--shadow-modal);
  display: grid;
  gap: 0.85rem;
}

.profile-modal__close {
  position: absolute;
  top: 0.75rem;
  right: 0.75rem;
  border: none;
  background: rgba(15, 23, 42, 0.08);
  color: var(--color-text);
  width: 36px;
  height: 36px;
  border-radius: 50%;
  font-size: 1.4rem;
  line-height: 1;
  cursor: pointer;
}

.profile-modal__subtitle {
  color: var(--color-muted-light);
}

.profile-modal .profile-item {
  background: var(--color-bg-gradient-end);
  border: var(--border-light);
}

.profile-modal .profile-label {
  color: var(--color-gray);
}

.profile-modal .profile-value {
  color: var(--color-text);
}

.modal-open {
  overflow: hidden;
}

/* ============================= */
/* Notifaction Drop Down         */
/* ============================= */
.notifications-dropdown {
  position: absolute;
  top: calc(100% + 0.5rem);
  right: 0;
  z-index: 70;
}

.notifications-dropdown[aria-hidden="true"] {
  display: none;
}

.notifications-dropdown__panel {
  width: min(360px, calc(100vw - 2rem));
  background: var(--color-white);
  color: var(--color-text);
  border: var(--border-light);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-modal);
  padding: 1rem;
  display: grid;
  gap: 0.85rem;
}

.notifications-dropdown__header {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.notifications-dropdown__title {
  margin: 0;
  font-size: 1.05rem;
  font-weight: 700;
}

.notifications-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 0.75rem;
}

.notifications-list__item {
  padding: 0.75rem 0.9rem;
  background: var(--color-bg-gradient-end);
  border: var(--border-light);
  border-radius: 12px;
}

.notifications-list__text {
  margin: 0;
  color: var(--color-text);
  font-weight: 500;
  font-size: 12px;
}

@media (max-width: 640px) {
  .notifications-dropdown {
    top: 4.75rem;
    right: 1rem;
    left: 1rem;
  }

  .notifications-dropdown__panel {
    width: 100%;
  }
}


/* ============================= */
/* Landing page (Startup)        */
/* ============================= */

main.landing {
  flex: 1;
  display: grid;
  place-items: center;
  text-align: center;
  padding: 3.5rem 1rem;
  min-height: calc(100svh - 88px);
  box-sizing: border-box;
}

.landing__hero {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2.25rem;
  width: 100%;
  max-width: 900px;
}

.landing__brand {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.6rem;
}

.landing__logo {
  width: min(520px, 80vw);
  height: auto;
  max-height: 260px;
  object-fit: contain;
  display: block;
}

.landing__wordmark {
  margin: 0;
  font-size: clamp(3rem, 7vw, 6rem);
  font-weight: 800;
  letter-spacing: -0.02em;
}

.landing__actions {
  display: flex;
  gap: 2rem;
  justify-content: center;
  flex-wrap: wrap;
}

.landing__btn {
  min-width: 260px;
  min-height: 84px;
  font-size: 1.6rem;
  border-radius: 10px;
  padding: 1.25rem 2rem;

  align-self: center;
}


@media (max-width: 640px) {
  .app-header__inner {
    padding: 0.75rem 1rem;
    gap: 0.75rem;
  }

  .app-header__brand {
    gap: 0.5rem;
    min-width: 0;
    flex: 1 1 auto;
  }

  .app-header__logo {
    width: 32px;
    height: 32px;
    flex-shrink: 0;
  }

  .app-header__title {
    font-size: 1.1rem;
    line-height: 1.1;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
  }

  .app-header__actions {
    gap: 0.4rem;
    flex-shrink: 0;
  }

  .icon-btn {
    width: 34px;
    height: 34px;
    min-width: 34px;
    min-height: 34px;
    flex: 0 0 34px;
    border-radius: 8px;
  }

  .icon-btn__img {
    width: 18px;
    height: 18px;
  }

  .quadrants {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 1rem;
    padding: 1.25rem 1rem 2rem;
  }

  .quadrant {
    gap: 0.75rem;
    padding: 1rem;
  }

  .quadrant img {
    width: min(120px, 70%);
  }

  .quadrant__copy {
    min-width: 0;
    gap: 0.75rem;
  }

  .quadrant__copy h2 {
    font-size: 1rem;
  }

  .quadrant__copy p {
    font-size: 0.9rem;
  }

  .quadrant__copy .btn {
    width: 100%;
    text-align: center;
    padding: 0.7rem 1rem;
  }

  .notifications-dropdown {
    top: 4.25rem;
    right: 1rem;
    left: 1rem;
  }

  .notifications-dropdown__panel {
    width: 100%;
  }

  body.landing {
    min-height: 100svh;
    display: flex;
    flex-direction: column;
  }

  main.landing {
    flex: 1 1 auto;
    min-height: 0;
    display: flex;
    align-items: stretch;
    padding: 1rem 1rem 1rem;
  }

  .landing__hero {
    flex: 1;
    justify-content: space-evenly;
    gap: 1rem;
    max-width: 100%;
    padding-block: 0.5rem 1.05rem;
  }

  .landing__brand {
    gap: 0.1rem;
  }

  .landing__logo {
    width: min(60vw, 220px);
    max-height: 122px;
    margin-bottom: 0;
  }

  .landing__wordmark {
    font-size: clamp(1.95rem, 9vw, 2.8rem);
    line-height: 0.95;
  }

  .landing__actions {
    width: 100%;
    gap: 0.75rem;
    flex-direction: column;
    align-items: stretch;
  }

  .landing__btn {
    min-width: 0;
    width: 100%;
    min-height: 50px;
    font-size: 1rem;
    padding: 0.75rem 1rem;
  }

  body.landing .footer {
    margin-top: auto;
    gap: 0.55rem;
    padding: 0.7rem 1rem max(0.7rem, env(safe-area-inset-bottom));
    font-size: 0.82rem;
  }

  body.landing .footer__socials,
  body.landing .footer__links {
    gap: 0.45rem 0.65rem;
  }

  body.landing .footer_version {
    font-size: 0.72rem;
  }
}
