html {
  font-size: 14px;
}

@media (min-width: 768px) {
  html {
    font-size: 16px;
  }
}

.btn:focus, .btn:active:focus, .btn-link.nav-link:focus, .form-control:focus, .form-check-input:focus {
  box-shadow: 0 0 0 0.1rem white, 0 0 0 0.25rem #258cfb;
}

html {
  position: relative;
  min-height: 100%;
}

body {
  margin-bottom: 60px;
}

.form-floating > .form-control-plaintext::placeholder, .form-floating > .form-control::placeholder {
  color: var(--bs-secondary-color);
  text-align: end;
}

.form-floating > .form-control-plaintext:focus::placeholder, .form-floating > .form-control:focus::placeholder {
  text-align: start;
}

.app-navbar {
  background: rgba(15, 23, 42, 0.95);
  backdrop-filter: blur(8px);
}

.app-navbar .navbar-brand,
.app-navbar .nav-link,
.app-navbar .navbar-toggler {
  color: #f8fafc;
}

.app-navbar .nav-link.text-dark {
  color: #f8fafc;
}

.app-navbar .nav-link:hover {
  color: #e2e8f0;
}

.nav-link-quiet {
  opacity: 0.8;
}

.nav-cta {
  border-radius: 999px;
  padding-left: 1rem;
  padding-right: 1rem;
}

.nav-user-email {
  color: #e2e8f0;
  font-size: 0.85rem;
  font-weight: 600;
}

.app-navbar .btn-primary {
  background: #38bdf8;
  border-color: #38bdf8;
  color: #0f172a;
  font-weight: 600;
}

.app-navbar .btn-primary:hover {
  background: #22c55e;
  border-color: #22c55e;
  color: #0f172a;
}

.welcome-hero {
  position: relative;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 2.5rem;
  align-items: center;
  padding: 4rem 1.5rem;
  margin-top: 1rem;
  border-radius: 28px;
  background: radial-gradient(circle at top left, #ffe6b3 0%, #f7f4ff 45%, #d7f4ff 100%);
  overflow: hidden;
  color: #111827;
}

.welcome-hero__content {
  max-width: 560px;
}

.welcome-hero__eyebrow {
  font-family: "Trebuchet MS", "Segoe UI", sans-serif;
  letter-spacing: 0.3em;
  text-transform: uppercase;
  font-size: 0.75rem;
  font-weight: 700;
  color: #0f172a;
}

.welcome-hero__title {
  font-family: "Palatino Linotype", "Book Antiqua", Palatino, serif;
  font-size: clamp(2.2rem, 4vw, 3.5rem);
  font-weight: 700;
  line-height: 1.05;
  margin: 1rem 0 1.25rem;
}

.welcome-hero__subtitle {
  font-size: 1.1rem;
  color: #1f2937;
  margin-bottom: 1.75rem;
}

.welcome-hero__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  margin-bottom: 1.5rem;
}

.welcome-cta {
  background: #111827;
  border-color: #111827;
  color: #f9fafb;
  padding: 0.8rem 1.7rem;
  border-radius: 999px;
}

.welcome-cta:hover {
  background: #0f172a;
  border-color: #0f172a;
}

.welcome-cta-secondary {
  border-radius: 999px;
  color: #111827;
  border-color: #111827;
}

.welcome-hero__meta {
  display: flex;
  flex-wrap: wrap;
  gap: 1.25rem;
  font-size: 0.85rem;
  color: #1f2937;
  font-weight: 600;
}

.welcome-hero__visual {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 320px;
}

.welcome-card {
  width: min(340px, 100%);
  background: #111827;
  color: #f9fafb;
  border-radius: 22px;
  padding: 1.5rem;
  box-shadow: 0 24px 60px rgba(15, 23, 42, 0.3);
  position: relative;
  z-index: 1;
}

.welcome-card__top {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 1.2rem;
}

.welcome-pill {
  background: #22c55e;
  color: #0f172a;
  font-weight: 700;
  padding: 0.25rem 0.65rem;
  border-radius: 999px;
  font-size: 0.75rem;
}

.welcome-card__time {
  font-size: 0.75rem;
  color: #cbd5f5;
}

.welcome-card__title {
  font-size: 1.1rem;
  font-weight: 600;
  margin-bottom: 0.5rem;
}

.welcome-card__url {
  font-size: 0.85rem;
  color: #94a3b8;
  margin-bottom: 1rem;
}

.welcome-card__progress {
  height: 8px;
  border-radius: 999px;
  background: rgba(148, 163, 184, 0.2);
  overflow: hidden;
  margin-bottom: 1.25rem;
}

.welcome-card__bar {
  height: 100%;
  width: 62%;
  background: linear-gradient(90deg, #60a5fa 0%, #38bdf8 100%);
}

.welcome-card__actions {
  display: flex;
  gap: 0.75rem;
}

.welcome-glow {
  position: absolute;
  width: 280px;
  height: 280px;
  background: radial-gradient(circle, rgba(15, 23, 42, 0.25), transparent 70%);
  right: -40px;
  bottom: -40px;
  filter: blur(2px);
}

.welcome-features {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 1.5rem;
  margin: 2.5rem 0 1rem;
}

.welcome-feature {
  background: #fff;
  border: 1px solid #e5e7eb;
  border-radius: 18px;
  padding: 1.5rem;
  box-shadow: 0 12px 25px rgba(15, 23, 42, 0.06);
}

.welcome-feature h3 {
  font-family: "Palatino Linotype", "Book Antiqua", Palatino, serif;
  font-size: 1.15rem;
  margin-bottom: 0.5rem;
}

.welcome-feature p {
  margin-bottom: 0;
  color: #4b5563;
}

.download-page {
  max-width: 1200px;
}

.download-card {
  background: #fff;
  border: 1px solid #e5e7eb;
  border-radius: 18px;
  padding: 2rem;
  box-shadow: 0 18px 30px rgba(15, 23, 42, 0.08);
}

.download-card__header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1.5rem;
  flex-wrap: wrap;
}

.download-credits {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  padding: 0.4rem 0.7rem;
  background: #f8fafc;
  border: 1px solid #e5e7eb;
  border-radius: 999px;
}

.download-credits__label {
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: #64748b;
  font-weight: 700;
}

.download-credits__value {
  font-weight: 700;
  color: #111827;
}

.download-credits__cta {
  border-radius: 999px;
  padding: 0.25rem 0.75rem;
  font-weight: 600;
}

.download-title {
  font-family: "Palatino Linotype", "Book Antiqua", Palatino, serif;
  font-size: 2rem;
  font-weight: 700;
  margin-bottom: 1.5rem;
}

.download-input-group {
  flex-wrap: nowrap;
  gap: 0.75rem;
}

.download-input {
  border-radius: 12px;
  border: 1px solid #e5e7eb;
  padding: 0.85rem 1rem;
  font-size: 1rem;
}

.download-btn {
  border-radius: 12px;
  padding: 0.75rem 1.5rem;
  font-weight: 600;
}

.download-section-title {
  margin: 2.5rem 0 1.25rem;
  font-weight: 700;
}

.download-table-wrap {
  border-radius: 18px;
  background: transparent;
  box-shadow: none;
  overflow: visible;
}

.download-table {
  margin-bottom: 0;
  border-collapse: separate;
  border-spacing: 0 12px;
}

.download-table thead th {
  font-weight: 700;
  color: #111827;
  background: #fff;
  border: 1px solid #e5e7eb;
  padding: 0.85rem 1rem;
}

.download-table tbody td {
  vertical-align: middle;
  background: #fff;
  padding: 1rem;
  border-top: none;
}

.download-table thead tr th:first-child {
  border-top-left-radius: 16px;
  border-bottom-left-radius: 16px;
}

.download-table thead tr th:last-child {
  border-top-right-radius: 16px;
  border-bottom-right-radius: 16px;
}

.download-table tbody tr {
  box-shadow: 0 8px 18px rgba(15, 23, 42, 0.08);
}

.download-table tbody tr td:first-child {
  border-top-left-radius: 16px;
  border-bottom-left-radius: 16px;
}

.download-table tbody tr td:last-child {
  border-top-right-radius: 16px;
  border-bottom-right-radius: 16px;
}

.download-url-cell {
  min-width: 320px;
}

.download-video {
  display: flex;
  gap: 1rem;
  align-items: center;
}

.download-thumb {
  width: 96px;
  height: 54px;
  object-fit: cover;
  border-radius: 10px;
  border: 1px solid #e5e7eb;
  background: #f3f4f6;
  flex-shrink: 0;
}

.download-video__text {
  min-width: 0;
}

.download-video__title {
  font-weight: 600;
  color: #111827;
  margin-bottom: 0.25rem;
}

.download-video__meta {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  font-size: 0.85rem;
  color: #64748b;
  margin-bottom: 0.35rem;
}

.download-video__url {
  font-size: 0.85rem;
  color: #94a3b8;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 420px;
}

.download-actions {
  display: flex;
  gap: 0.75rem;
  align-items: center;
}

.download-action-btn {
  border-radius: 10px;
  font-weight: 600;
}

.status-pill {
  display: inline-flex;
  align-items: center;
  padding: 0.35rem 0.75rem;
  border-radius: 999px;
  font-weight: 600;
  font-size: 0.85rem;
}

.status-pill--success {
  background: #dcfce7;
  color: #166534;
}

.status-pill--danger {
  background: #fee2e2;
  color: #991b1b;
}

.status-pill--info {
  background: #dbeafe;
  color: #1d4ed8;
}

.status-pill--warning {
  background: #fef3c7;
  color: #92400e;
}

@media (max-width: 768px) {
  .download-input-group {
    flex-direction: column;
    align-items: stretch;
  }

  .download-btn {
    width: 100%;
  }

  .download-actions {
    flex-direction: column;
    align-items: flex-start;
  }
}

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

  .welcome-hero__actions {
    flex-direction: column;
    align-items: stretch;
  }

  .welcome-cta,
  .welcome-cta-secondary {
    width: 100%;
    text-align: center;
  }
}
