/* ===== Checkout Styles - Light Theme ===== */

@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700;800&display=swap');

* {
  box-sizing: border-box;
}

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* ===== Scrollbar ===== */
::-webkit-scrollbar {
  width: 6px;
  height: 6px;
}
::-webkit-scrollbar-track {
  background: transparent;
}
::-webkit-scrollbar-thumb {
  background: #cbd5e1;
  border-radius: 3px;
}
::-webkit-scrollbar-thumb:hover {
  background: #94a3b8;
}

/* ===== Loading Spinner ===== */
.spinner {
  border: 3px solid #e2e8f0;
  border-top: 3px solid #0066cc;
  border-radius: 50%;
  width: 36px;
  height: 36px;
  animation: spin 0.8s linear infinite;
  margin: 0 auto;
}

@keyframes spin {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

/* CEP Loading Animation */
.animate-spin {
  animation: spin 1s linear infinite;
}

/* ===== Form Elements ===== */
input::placeholder, textarea::placeholder {
  color: #94a3b8;
}

input:focus, select:focus, textarea:focus {
  outline: none;
  border-color: #0066cc;
  box-shadow: 0 0 0 3px rgba(0, 102, 204, 0.12);
}

input, select, textarea {
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

/* Valid/Invalid field states */
input.border-green-500 {
  border-color: #10b981 !important;
}

input.border-green-500:focus {
  box-shadow: 0 0 0 3px rgba(16, 185, 129, 0.15) !important;
}

input.border-red-500 {
  border-color: #ef4444 !important;
}

input.border-red-500:focus,
input.focus\:ring-red-500:focus {
  box-shadow: 0 0 0 3px rgba(239, 68, 68, 0.15) !important;
}

/* Field error messages */
p[id$="-error"]:not(.hidden) {
  animation: fadeIn 0.2s ease-in;
}

@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(-4px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* ===== Transitions ===== */
a, button {
  transition: all 0.15s ease;
}

/* ===== Cycle Cards ===== */
.cycle-card {
  position: relative;
  text-align: left;
  padding: 1rem 1rem 0.875rem;
  border-radius: 0.875rem;
  border: 1.5px solid #e5e7eb;
  min-height: 124px;
  background: #fff;
  cursor: pointer;
  transition: all 0.2s ease;
}
.cycle-card:hover {
  border-color: #d1d5db;
  box-shadow: 0 2px 8px rgba(0,0,0,0.04);
}
.cycle-card.active {
  border-color: var(--brand-accent, #061E2D);
  background: linear-gradient(135deg, rgba(var(--brand-accent-rgb, 6,30,45), 0.02), rgba(var(--brand-accent-rgb, 6,30,45), 0.05));
  box-shadow: 0 0 0 1px rgba(var(--brand-accent-rgb, 6,30,45), 0.1), 0 4px 12px rgba(var(--brand-accent-rgb, 6,30,45), 0.08);
}

/* Radio indicator */
.cycle-radio {
  width: 14px;
  height: 14px;
  border-radius: 50%;
  border: 1.5px solid #d1d5db;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  transition: all 0.2s ease;
}
.cycle-card.active .cycle-radio {
  border-color: var(--brand-accent, #061E2D);
  background: var(--brand-accent, #061E2D);
}
.cycle-radio-dot {
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: #fff;
  transform: scale(0);
  transition: transform 0.15s ease;
}
.cycle-card.active .cycle-radio-dot {
  transform: scale(1);
}

/* "Mais popular" badge — chip discreto no canto sup-direito do card */
.cycle-best-choice {
  position: absolute;
  top: 8px;
  right: 8px;
  font-size: 9px;
  font-weight: 700;
  color: var(--brand-accent, #061E2D);
  background: rgb(var(--brand-accent-rgb, 6 30 45) / 0.12);
  padding: 2px 8px;
  border-radius: 999px;
  white-space: nowrap;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

/* ===== Selection ===== */
::selection {
  background: rgba(6, 30, 45, 0.15);
  color: inherit;
}

/* ===== Product Description (WHMCS features list) ===== */
#product-desc ul {
  list-style: none;
  padding: 0;
  margin: 0.75rem 0 0;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 0.375rem;
}
#product-desc li {
  font-size: 0.8125rem;
  color: #64748b;
  padding-left: 1.25rem;
  position: relative;
}
#product-desc li::before {
  content: '';
  position: absolute;
  left: 0;
  top: 0.45em;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #0066cc;
}
#product-desc li b {
  color: #1e293b;
  font-weight: 600;
}

/* ===== International Phone Input ===== */
.iti {
  width: 100%;
}

.iti__country-list {
  border-radius: 0.5rem;
  box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
  border: 1px solid #e2e8f0;
  background: #ffffff;
  margin-top: 4px;
  max-height: 200px;
}

.iti__country-list .iti__country-name,
.iti__country-list .iti__dial-code {
  color: #1e293b;
}

.iti__country:hover {
  background-color: #f1f5f9;
}

.iti__country.iti__highlight {
  background-color: rgba(6, 30, 45, 0.05);
}

.iti__country.iti__active {
  background-color: rgba(6, 30, 45, 0.08);
}

.iti__divider {
  border-bottom: 1px solid #e2e8f0;
}

.iti__search-input {
  background: #f8fafc !important;
  border-color: #e2e8f0 !important;
  color: #1e293b !important;
}

/* ===== Subtle shadow on accent buttons ===== */
button.bg-accent:hover,
a.bg-accent:hover {
  box-shadow: 0 4px 12px rgba(6, 30, 45, 0.25);
}

/* ===== Catalog Sidebar ===== */
.no-scrollbar { scrollbar-width: none; -ms-overflow-style: none; }
.no-scrollbar::-webkit-scrollbar { display: none; }

.cat-nav-item {
  display: block;
  width: 100%;
  text-align: left;
  padding: 7px 0 7px 16px;
  font-size: 0.8125rem;
  font-weight: 450;
  color: #9ca3af;
  background: none;
  border: none;
  border-left: 2px solid transparent;
  cursor: pointer;
  transition: color 0.15s, border-color 0.15s;
  line-height: 1.45;
}
.cat-nav-item:hover {
  color: #374151;
}
.cat-nav-item.active {
  color: #111827;
  font-weight: 600;
  border-left-color: var(--brand-accent, #111827);
}

/* ===== Catalog Product Grid ===== */
.catalog-grid {
  display: grid;
  gap: 10px;
  grid-template-columns: 1fr;
}
@media (min-width: 768px) {
  .catalog-grid {
    grid-template-columns: repeat(3, 1fr);
    gap: 12px;
  }
}
.catalog-card {
  position: relative;
  padding: 28px 24px 24px;
  border: 1px solid #e8e8e8;
  border-radius: 10px;
  background: #fff;
}
@media (max-width: 767px) {
  .catalog-card {
    padding: 20px 18px 18px;
  }
  .catalog-price {
    font-size: 1.75rem;
  }
}
.catalog-card.popular {
  border-color: var(--brand-accent, #111827);
  border-width: 1.5px;
}
.catalog-name {
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: #6b7280;
  margin-bottom: 14px;
}
.catalog-card.popular .catalog-name {
  color: var(--brand-accent, #111827);
}
.catalog-popular-tag {
  display: inline-block;
  font-size: 0.6rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: #fff;
  background: var(--brand-accent, #111827);
  padding: 2px 7px;
  border-radius: 3px;
  margin-left: 6px;
  vertical-align: middle;
}
.catalog-price {
  font-size: 2rem;
  font-weight: 700;
  color: #111827;
  line-height: 1;
  letter-spacing: -0.035em;
}
.catalog-price-period {
  font-size: 0.8125rem;
  font-weight: 400;
  color: #9ca3af;
  margin-left: 2px;
}
.catalog-price-note {
  font-size: 0.6875rem;
  color: #b0b0b0;
  margin-top: 2px;
}
.catalog-cta {
  display: inline-block;
  padding: 8px 24px;
  font-size: 0.8125rem;
  font-weight: 600;
  text-align: center;
  border-radius: 7px;
  text-decoration: none;
  transition: background 0.15s, color 0.15s;
  border: 1.5px solid #d1d5db;
  color: #374151;
  background: #fff;
}
.catalog-cta:hover {
  background: #f9fafb;
  border-color: #9ca3af;
}
.catalog-card.popular .catalog-cta {
  background: var(--brand-accent, #111827);
  color: #fff;
  border-color: var(--brand-accent, #111827);
}
.catalog-card.popular .catalog-cta:hover {
  opacity: 0.92;
}
.catalog-specs {
  list-style: none;
  padding: 0;
  margin: 0;
}
.catalog-specs li {
  display: flex;
  justify-content: space-between;
  padding: 5px 0;
  font-size: 0.8125rem;
  color: #6b7280;
}
.catalog-specs li + li {
  border-top: 1px solid #f5f5f5;
}
.catalog-specs .spec-val {
  color: #111827;
  font-weight: 500;
  font-variant-numeric: tabular-nums;
}
/* Included items — banner above cards */
.catalog-included-banner {
  padding: 12px 16px;
  margin-bottom: 12px;
  border: 1px solid #e8e8e8;
  border-radius: 8px;
  background: #fafafa;
  display: flex;
  align-items: baseline;
  gap: 10px;
  flex-wrap: wrap;
}
.catalog-included-banner .cb-title {
  font-size: 0.6875rem;
  font-weight: 600;
  color: #9ca3af;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  white-space: nowrap;
}
.catalog-included-banner .cb-items {
  display: flex;
  flex-wrap: wrap;
  gap: 4px 6px;
  align-items: baseline;
}
.catalog-included-banner .cb-item {
  font-size: 0.75rem;
  color: #374151;
  font-weight: 500;
}
.catalog-included-banner .cb-sep {
  color: #cbd5e1;
  font-size: 0.75rem;
  user-select: none;
}

/* ===== OS Selection Cards ===== */
.os-card {
  border: 1.5px solid #e2e8f0;
  border-radius: 0.75rem;
  background: #fff;
  cursor: pointer;
  transition: border-color 0.15s, background 0.15s, box-shadow 0.15s;
}
.os-card:hover {
  border-color: #cbd5e1;
}
.os-card.selected {
  border-color: #0066cc;
  background: rgba(0, 102, 204, 0.04);
  box-shadow: 0 0 0 1px rgba(0, 102, 204, 0.12);
}

.os-card-inner {
  display: flex;
  align-items: center;
  gap: 0.625rem;
  padding: 0.75rem;
}

.os-card-icon {
  flex-shrink: 0;
}
.os-icon {
  width: 32px;
  height: 32px;
  object-fit: contain;
  border-radius: 4px;
}
.os-icon-fallback {
  width: 32px;
  height: 32px;
  color: #9ca3af;
}

.os-card-info {
  flex: 1;
  min-width: 0;
}
.os-card-name {
  font-weight: 500;
  font-size: 0.8125rem;
  color: #111827;
  line-height: 1.25;
}
.os-card-version {
  font-size: 0.6875rem;
  color: #9ca3af;
  margin-top: 1px;
}

.os-expand-arrow {
  width: 14px;
  height: 14px;
  color: #9ca3af;
  transition: transform 0.15s;
  flex-shrink: 0;
}

.os-versions {
  border-top: 1px solid #e5e7eb;
}
.os-version-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.5rem 0.75rem;
  border-top: 1px solid #f3f4f6;
  font-size: 0.8125rem;
  color: #374151;
  cursor: pointer;
  transition: background 0.1s;
}
.os-version-row:first-child {
  border-top: none;
}
.os-version-row:hover {
  background: #f3f4f6;
}
.os-version-check {
  width: 16px;
  height: 16px;
  color: #111827;
}

/* ===== Botoes primarios: cor da marca + sombra colorida ===== */
button.bg-accent,
a.bg-accent,
input[type="submit"].bg-accent,
input[type="button"].bg-accent {
  background-color: var(--brand-accent, #061E2D) !important;
  box-shadow: 0 1px 2px rgba(var(--brand-accent-rgb, 6 30 45) / 0.18) !important;
}
button.bg-accent:hover:not(:disabled),
a.bg-accent:hover,
input[type="submit"].bg-accent:hover:not(:disabled),
input[type="button"].bg-accent:hover:not(:disabled) {
  background-color: var(--brand-accent-dark, #04151f) !important;
  box-shadow: 0 4px 12px rgba(var(--brand-accent-rgb, 6 30 45) / 0.28) !important;
}
button.bg-accent:disabled {
  background-color: #9ca3af !important;
  box-shadow: none !important;
}

/* ===== Shop Pay inspired palette ===== */
body { background-color: #F6F6F7 !important; }
/* Remove shadow default dos cards (flat look) */
.bg-white.shadow-sm { box-shadow: none !important; }
/* Inputs mais Shop-Pay: borda sutil, radius consistente */
input[type="text"], input[type="email"], input[type="tel"], textarea, select {
  border-radius: 0.625rem !important;
}

/* ===== HospedaInfo-inspired accents: gradientes sutis + mono em valores tecnicos ===== */

/* Mono fica apenas em codigos/identificadores (cupom), nao em precos */
@import url('https://fonts.googleapis.com/css2?family=JetBrains+Mono:wght@500;600;700&display=swap');

.font-mono-tech,
[data-mono],
#coupon-code {
  font-family: 'JetBrains Mono', ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace !important;
  letter-spacing: -0.01em;
}

/* Header com gradiente sutil quando ha brand-accent definido */
header.bg-white {
  background-image:
    linear-gradient(
      180deg,
      rgb(var(--brand-accent-rgb, 6 30 45) / 0.025) 0%,
      transparent 100%
    ) !important;
}

/* CTA primario: brilho sutil tipo HospedaInfo (gradient diagonal) */
button.bg-accent:not(:disabled),
a.bg-accent {
  background-image: linear-gradient(
    135deg,
    var(--brand-accent, #061E2D) 0%,
    var(--brand-accent-light, var(--brand-accent, #061E2D)) 100%
  ) !important;
}
button.bg-accent:hover:not(:disabled),
a.bg-accent:hover {
  background-image: linear-gradient(
    135deg,
    var(--brand-accent-dark, var(--brand-accent, #061E2D)) 0%,
    var(--brand-accent, #061E2D) 100%
  ) !important;
}

/* Badge "Mais popular" com gradient + glow sutil */
.cycle-best-choice {
  background: linear-gradient(
    135deg,
    rgb(var(--brand-accent-rgb, 6 30 45) / 0.14),
    rgb(var(--brand-accent-rgb, 6 30 45) / 0.08)
  ) !important;
  box-shadow: 0 0 0 1px rgb(var(--brand-accent-rgb, 6 30 45) / 0.08);
}

/* Card ciclo selecionado: gradient mais pronunciado (alinhado ao site) */
.cycle-card.active {
  background-image: linear-gradient(
    135deg,
    rgb(var(--brand-accent-rgb, 6 30 45) / 0.04) 0%,
    rgb(var(--brand-accent-rgb, 6 30 45) / 0.08) 100%
  ) !important;
}

/* Total no resumo: peso visual extra na cor da marca */
#summary-total {
  font-weight: 700;
  font-size: 1.5rem;
  color: var(--brand-accent, #061E2D);
  font-variant-numeric: tabular-nums;
}
