/* ==========================================================================
   Admina kit — tokens e componentes fiéis ao template Tailwind
   (ícones circulares, forms, selects pill, tabs, cards, charts)
   ========================================================================== */

body.admina-test {
  --admina-primary: #487FFF;
  --admina-success: #45B369;
  --admina-danger: #EF4A00;
  --admina-warning: #FF9F29;
  --admina-info: #00B8F2;
  --admina-indigo: #4F46E5;
  --admina-text: #1f2937;
  --admina-muted: #6b7280;
  --admina-line: #e5e7eb;
  --admina-soft: #f3f4f6;
  --admina-radius-card: 20px;
  font-family: Inter, system-ui, sans-serif;
}

/* ---- Icon circle (Top Customers pattern) ---- */
.admina-icon {
  width: 3rem;
  height: 3rem;
  border-radius: 9999px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  border: 1px solid transparent;
  font-size: 1.25rem;
  line-height: 1;
}
.admina-icon--sm { width: 2.5rem; height: 2.5rem; font-size: 1.1rem; }
.admina-icon--lg { width: 3.5rem; height: 3.5rem; font-size: 1.5rem; }

.admina-icon--primary {
  background: rgb(72 127 255 / 0.1);
  border-color: rgb(72 127 255 / 0.25);
  color: var(--admina-primary);
}
.admina-icon--success {
  background: rgb(69 179 105 / 0.12);
  border-color: rgb(69 179 105 / 0.28);
  color: var(--admina-success);
}
.admina-icon--danger {
  background: rgb(239 74 0 / 0.1);
  border-color: rgb(239 74 0 / 0.25);
  color: var(--admina-danger);
}
.admina-icon--warning {
  background: rgb(255 159 41 / 0.12);
  border-color: rgb(255 159 41 / 0.3);
  color: var(--admina-warning);
}
.admina-icon--info {
  background: rgb(0 184 242 / 0.1);
  border-color: rgb(0 184 242 / 0.25);
  color: var(--admina-info);
}

/* ---- Card header with icon + title + pill select ---- */
.admina-card-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 0.75rem;
  flex-wrap: wrap;
  margin-bottom: 1.25rem;
  padding-bottom: 1.25rem;
  border-bottom: 1px solid var(--admina-line);
}
.admina-card-head__main {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  min-width: 0;
  width: 100%;
}
.admina-card-head__copy {
  min-width: 0;
  flex: 1 1 auto;
  overflow-wrap: anywhere;
}
.admina-card-head__title {
  margin: 0;
  font-size: 1.125rem;
  font-weight: 600;
  color: var(--admina-text);
  line-height: 1.3;
  overflow-wrap: anywhere;
}
.admina-card-head__sub {
  display: block;
  font-size: 0.875rem;
  font-weight: 400;
  color: var(--admina-muted);
  margin-top: 0.1rem;
  overflow-wrap: anywhere;
}

/* ---- Pill select (This Week pattern) ---- */
.admina-select-pill {
  width: auto;
  appearance: none;
  -webkit-appearance: none;
  border-radius: 9999px !important;
  border: 1px solid #d1d5db !important;
  background-color: #f3f4f6 !important;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%236b7280' stroke-width='2.5'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E") !important;
  background-repeat: no-repeat !important;
  background-position: right 0.75rem center !important;
  background-size: 12px !important;
  color: #6b7280 !important;
  font-size: 0.875rem !important;
  font-weight: 500 !important;
  line-height: 1.25 !important;
  padding: 0.375rem 2rem 0.375rem 0.75rem !important;
  min-height: 0 !important;
  height: auto !important;
  box-shadow: none !important;
  cursor: pointer;
}
.admina-select-pill:hover {
  border-color: #9ca3af !important;
}
.admina-select-pill:focus {
  outline: none !important;
  border-color: var(--admina-primary) !important;
  background-color: #fff !important;
  box-shadow: 0 0 0 3px rgb(72 127 255 / 0.18) !important;
  color: #374151 !important;
}

/* ---- Tabs (view-profile tab-style-gradient: top border + soft blue wash) ---- */
.admina-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 0;
  border-bottom: 1px solid #eeeeee;
  margin: 0 0 1.25rem;
  padding: 0;
  list-style: none;
}
.admina-tabs__btn {
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.625rem 1rem;
  border: 0;
  border-top: 2px solid transparent;
  background: transparent;
  color: #4b5563;
  font-size: 1rem;
  font-weight: 600;
  font-family: inherit;
  cursor: pointer;
  white-space: nowrap;
  transition: background 0.15s ease, color 0.15s ease, border-color 0.15s ease;
}
.admina-tabs__btn.is-active,
.admina-tabs__btn[aria-selected="true"] {
  border-top-color: var(--admina-primary);
  background: linear-gradient(180deg, rgba(72, 127, 255, 0.12) 0%, rgba(72, 127, 255, 0.03) 100%);
  color: #4b5563;
}
.admina-tabs__btn:hover {
  color: #1f2937;
}

/* radios disguised as tabs (situação cadastral) */
.admina-tabs__btn input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}
.admina-tabs__btn:has(input:checked) {
  border-top-color: var(--admina-primary);
  background: linear-gradient(180deg, rgba(72, 127, 255, 0.12) 0%, rgba(72, 127, 255, 0.03) 100%);
}

[data-admina-panel].is-active-panel {
  outline: 2px solid rgba(72, 127, 255, 0.28);
  background: #f8faff;
  border-radius: 1rem;
}

/* ---- Forms (icon-field + form-control) ---- */
body.admina-test .form-label {
  margin-bottom: 0.5rem;
  display: inline-block;
  font-size: 0.875rem;
  font-weight: 600;
  color: #4b5563;
}
body.admina-test .form-control,
body.admina .form-control {
  width: 100%;
  border-radius: 0.5rem;
  border: 1px solid #d1d5db;
  background: #fff;
  padding: 0.625rem 1.25rem;
  font-size: 1rem;
  color: var(--admina-text);
  min-height: 46px;
  font-family: Inter, system-ui, sans-serif;
}
body.admina-test .form-control:focus,
body.admina .form-control:focus {
  outline: none;
  border-color: #1c64f2;
  box-shadow: 0 0 0 1px #1c64f2;
}
body.admina-test .form-control::placeholder {
  color: #9ca3af;
}
body.admina .icon-field,
body.admina-test .icon-field {
  position: relative;
}
body.admina .icon-field .icon,
body.admina-test .icon-field .icon {
  position: absolute;
  top: 0;
  bottom: 0;
  inset-inline-start: 0;
  display: flex;
  width: 2.75rem;
  align-items: center;
  justify-content: center;
  font-size: 1.15rem;
  color: #9ca3af;
  pointer-events: none;
}
body.admina .icon-field .icon .ph,
body.admina-test .icon-field .icon .ph {
  font-size: 1.15rem;
  line-height: 1;
}
body.admina .icon-field .form-control,
body.admina-test .icon-field .form-control {
  padding-inline-start: 2.75rem;
}

/* ---- Home search: input + button same height ---- */
.admina-search__row {
  display: flex;
  flex-wrap: wrap;
  align-items: stretch;
  gap: 0.75rem;
}
.admina-search__field {
  flex: 1 1 16rem;
  min-width: 0;
}
.admina-search__field .form-control {
  height: 3rem;
  min-height: 3rem;
  width: 100%;
  box-sizing: border-box;
}
.admina-search__btn {
  flex: 0 0 auto;
  height: 3rem;
  min-height: 3rem;
  padding: 0 1.5rem !important;
  border-radius: 9999px !important;
  font-weight: 600;
  line-height: 1;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  white-space: nowrap;
}
@media (max-width: 640px) {
  .admina-search__btn {
    width: 100%;
  }
}

.admina-search__examples {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-top: 0.75rem;
}
.admina-search__chip {
  appearance: none;
  border: 1px solid #e5e7eb;
  background: #f9fafb;
  color: #4b5563;
  font-size: 0.8125rem;
  font-weight: 500;
  line-height: 1.2;
  padding: 0.4rem 0.75rem;
  border-radius: 9999px;
  cursor: pointer;
}
.admina-search__chip:hover {
  border-color: #93c5fd;
  background: #eff6ff;
  color: #1d4ed8;
}

/* ---- White cards ---- */
.admina-surface {
  background: #fff;
  border-radius: var(--admina-radius-card);
  padding: 1.5rem;
  box-shadow: none;
}

/* ---- Buttons ---- */
body.admina-test .btn-primary,
body.admina-test .btn-primary-600 {
  background: var(--admina-primary) !important;
  border-color: var(--admina-primary) !important;
  color: #fff !important;
  border-radius: 9999px;
  font-weight: 600;
}

/* ---- Checkboxes / radios accent ---- */
body.admina-test input[type="checkbox"],
body.admina-test input[type="radio"] {
  accent-color: var(--admina-primary);
}

/* ---- Alerts (servicos / avisos) ---- */
.admina-alert {
  border-radius: 12px;
  padding: 0.85rem 1rem;
  font-size: 0.9rem;
  line-height: 1.45;
  border: 1px solid transparent;
}
.admina-alert--warn {
  background: rgb(255 159 41 / 0.12);
  border-color: rgb(255 159 41 / 0.28);
  color: #92400e;
}
.admina-alert--danger {
  background: rgb(239 74 0 / 0.1);
  border-color: rgb(239 74 0 / 0.25);
  color: #9a3412;
}

/* ---- Catálogo de serviços (tiers) ---- */
.admina-tier-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}
.admina-tier {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  padding: 0.75rem 0.85rem;
  border: 1px solid var(--admina-line);
  border-radius: 12px;
  background: #fafbfc;
}
.admina-tier strong {
  display: block;
  font-size: 0.9rem;
  color: var(--admina-text);
}
.admina-tier small {
  display: block;
  margin-top: 0.15rem;
  font-size: 0.8rem;
  color: var(--admina-muted);
}
.admina-tier__buy {
  flex-shrink: 0;
  display: inline-flex;
  align-items: center;
  border-radius: 9999px;
  border: 1px solid rgb(72 127 255 / 0.35);
  background: #fff;
  color: var(--admina-primary);
  font-size: 0.8rem;
  font-weight: 600;
  padding: 0.35rem 0.85rem;
  text-decoration: none;
}
.admina-tier__buy:hover {
  background: rgb(72 127 255 / 0.08);
}

/* FAQ summary without default marker */
body.admina-test .admina-faq summary::-webkit-details-marker { display: none; }
body.admina-test .admina-faq summary::after {
  content: "";
  float: right;
  width: 0.5rem;
  height: 0.5rem;
  border-right: 2px solid #9ca3af;
  border-bottom: 2px solid #9ca3af;
  transform: rotate(45deg);
  margin-top: 0.35rem;
}
body.admina-test .admina-faq details[open] summary::after {
  transform: rotate(-135deg);
  margin-top: 0.55rem;
}
