.create-resume-page {
  background:
    radial-gradient(circle at top right, rgba(46, 91, 255, 0.06), transparent 28rem),
    var(--bg-secondary, #f8f9fa);
  min-height: calc(100vh - 4rem);
}

.create-resume-eyebrow {
  color: var(--primary-color, #2e5bff);
  font-size: 0.8125rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.create-resume-title {
  font-size: clamp(1.75rem, 4vw, 2.5rem);
  font-weight: 800;
  letter-spacing: -0.02em;
}

.account-quota-strip {
  background: #fff;
  border: 1px solid var(--border-color, #e9ecef);
  border-radius: 16px;
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  justify-content: flex-end;
  padding: 0.85rem 1rem;
}

.account-quota-item {
  display: flex;
  flex-direction: column;
  gap: 0.15rem;
  min-width: 5.5rem;
}

.account-quota-item .label {
  color: var(--text-muted, #6c757d);
  font-size: 0.6875rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.account-quota-item .value {
  font-size: 0.9375rem;
  font-weight: 700;
}

.gallery-toolbar {
  align-items: center;
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  justify-content: space-between;
  padding: 0.85rem 1rem;
}

.gallery-filters {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
}

.gallery-filter-btn {
  background: transparent;
  border: 1px solid transparent;
  border-radius: 999px;
  color: var(--text-secondary, #4a4a4a);
  font-size: 0.875rem;
  font-weight: 600;
  padding: 0.4rem 0.85rem;
  transition: background-color 0.15s ease, color 0.15s ease;
}

.gallery-filter-btn:hover:not(:disabled),
.gallery-filter-btn.active {
  background: rgba(46, 91, 255, 0.1);
  border-color: rgba(46, 91, 255, 0.18);
  color: var(--primary-color, #2e5bff);
}

.gallery-filter-btn:disabled {
  cursor: not-allowed;
  opacity: 0.45;
}

.gallery-search-wrap {
  align-items: center;
  display: flex;
  flex: 1;
  gap: 0.5rem;
  max-width: 320px;
  min-width: 200px;
}

.gallery-search-wrap i {
  color: var(--text-muted, #6c757d);
}

.gallery-search {
  border-radius: 999px;
  font-size: 0.875rem;
}

.gallery-carousel {
  margin: 0 auto;
  position: relative;
}

.gallery-swiper {
  padding: 0.25rem 0.25rem 2.75rem;
}

.gallery-swiper .swiper-wrapper {
  align-items: stretch;
}

.gallery-swiper .swiper-slide {
  display: flex;
  height: auto;
}

.gallery-swiper .swiper-slide.is-hidden {
  display: none;
}

.gallery-template-card {
  background: #fff;
  border: 1px solid var(--border-color, #e9ecef);
  border-radius: 18px;
  box-shadow: 0 8px 24px rgba(15, 23, 42, 0.06);
  display: flex;
  flex-direction: column;
  height: 100%;
  overflow: hidden;
  transition: box-shadow 0.2s ease, transform 0.2s ease;
  width: 100%;
}

.gallery-template-card:hover {
  box-shadow: 0 16px 40px rgba(46, 91, 255, 0.12);
  transform: translateY(-2px);
}

.gallery-template-card.is-hidden {
  display: none;
}

.gallery-template-preview {
  height: 180px;
  object-fit: cover;
  object-position: top;
  width: 100%;
}

.gallery-template-preview-empty {
  align-items: center;
  background: #f1f5f9;
  color: var(--text-muted, #6c757d);
  display: flex;
  font-size: 0.875rem;
  justify-content: center;
}

.gallery-template-body {
  display: flex;
  flex: 1;
  flex-direction: column;
  gap: 0.65rem;
  padding: 1rem;
}

.gallery-template-head {
  align-items: flex-start;
  display: flex;
  gap: 0.5rem;
  justify-content: space-between;
}

.gallery-template-name {
  font-size: 1rem;
  font-weight: 700;
  line-height: 1.3;
  margin: 0;
}

.gallery-template-desc {
  color: var(--text-muted, #6c757d);
  display: -webkit-box;
  font-size: 0.8125rem;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  margin: 0;
  overflow: hidden;
}

.gallery-badge {
  border-radius: 999px;
  flex-shrink: 0;
  font-size: 0.625rem;
  font-weight: 800;
  letter-spacing: 0.04em;
  padding: 0.22rem 0.45rem;
  text-transform: uppercase;
  white-space: nowrap;
}

.gallery-badge-free {
  background: #dcfce7;
  color: #166534;
}

.gallery-badge-owned {
  background: #dbeafe;
  color: #1d4ed8;
}

.gallery-badge-premium {
  background: #ede9fe;
  color: #5b21b6;
}

.gallery-badge-warning {
  background: #fef3c7;
  color: #92400e;
}

.gallery-template-meta {
  align-items: center;
  display: flex;
  flex-wrap: wrap;
  gap: 0.65rem;
}

.gallery-price {
  color: var(--text-primary, #1a1a1a);
  font-size: 0.9375rem;
  font-weight: 800;
}

.gallery-price-free {
  color: #059669;
}

.gallery-stat {
  color: var(--text-muted, #6c757d);
  font-size: 0.75rem;
}

.gallery-quota-row {
  color: var(--text-secondary, #4a4a4a);
  display: flex;
  gap: 1rem;
}

.gallery-template-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-top: auto;
  padding-top: 0.35rem;
}

.gallery-empty-state {
  color: var(--text-muted, #6c757d);
  padding: 3rem 1rem;
  text-align: center;
}

.gallery-empty-state i {
  display: block;
  font-size: 2rem;
  margin-bottom: 0.75rem;
}

.gallery-pagination {
  bottom: 0 !important;
  position: relative !important;
}

.gallery-pagination .swiper-pagination-bullet-active {
  background: var(--primary-color, #2e5bff);
}

.gallery-carousel-nav-row {
  align-items: center;
  display: flex;
  gap: 1rem;
  justify-content: center;
  margin-top: 0.25rem;
}

.gallery-carousel-nav {
  align-items: center;
  background: #fff;
  border: 1px solid rgba(46, 91, 255, 0.2);
  border-radius: 50%;
  box-shadow: 0 2px 4px rgba(46, 91, 255, 0.05);
  color: var(--primary-color, #2e5bff);
  cursor: pointer;
  display: inline-flex;
  height: 2.75rem;
  justify-content: center;
  padding: 0;
  transition: background-color 0.2s ease, box-shadow 0.2s ease, transform 0.2s ease;
  width: 2.75rem;
}

.gallery-carousel-nav:hover {
  background: rgba(46, 91, 255, 0.06);
  box-shadow: 0 8px 16px rgba(46, 91, 255, 0.08);
  transform: scale(1.05);
}

.gallery-carousel-nav.swiper-button-disabled {
  box-shadow: none;
  cursor: not-allowed;
  opacity: 0.35;
  transform: none;
}

.glass-card {
  background: rgba(255, 255, 255, 0.92);
  border: 1px solid rgba(15, 23, 42, 0.08);
  border-radius: 18px;
  box-shadow: 0 8px 24px rgba(15, 23, 42, 0.05);
}

@media (max-width: 767.98px) {
  .create-resume-page .container {
    padding-left: 1rem;
    padding-right: 1rem;
  }

  .account-quota-strip {
    justify-content: flex-start;
    margin-top: 0.5rem;
    width: 100%;
  }

  .account-quota-item {
    flex: 1 1 8.5rem;
  }

  .gallery-toolbar {
    align-items: stretch;
    flex-direction: column;
    gap: 0.75rem;
  }

  .gallery-filters {
    flex-wrap: nowrap;
    margin: 0 -0.25rem;
    overflow-x: auto;
    padding: 0 0.25rem 0.25rem;
    scrollbar-width: none;
  }

  .gallery-filters::-webkit-scrollbar {
    display: none;
  }

  .gallery-filter-btn {
    flex: 0 0 auto;
  }

  .gallery-search-wrap {
    max-width: none;
    min-width: 0;
    width: 100%;
  }

  .gallery-swiper {
    margin-left: -0.25rem;
    margin-right: -0.25rem;
  }

  .gallery-template-preview {
    height: clamp(190px, 62vw, 260px);
  }

  .gallery-template-actions .btn {
    flex: 1 1 100%;
  }
}
