/*
  Busca Brasíndice – Guia rápido de estilos (styles.css)

  Paleta e tokens:
    - Gradiente de fundo: var(--bg-top) → var(--bg-bottom)
    - Cartões: var(--card-bg), sombra var(--card-shadow), raio var(--card-radius)
    - Botões pílula: gradiente var(--btn-start) → var(--btn-end)

  Convenções:
    - Layout em 3 etapas com cartões (.card)
    - Estados de UI via classes utilitárias (.hidden, .state)
    - Componentes principais: .pill-button, .input, .results-list, .details

  Acessibilidade:
    - Foco visível em inputs
    - Contraste em títulos e estados
*/
:root {
  --bg-top: #0d6c96;
  --bg-mid: #3f8fb9;
  --bg-bottom: #e8f3fb;

  --card-bg: #ffffff;
  --card-shadow: 0 8px 20px rgba(13, 29, 61, 0.12);
  --card-radius: 8px;

  --btn-start: #0ea5a3;
  --btn-end: #1769aa;
  --btn-hover-start: #11b9b6;
  --btn-hover-end: #1d78c3;
  --btn-text: #ffffff;
}

html, body {
  height: 100%;
}

body {
  margin: 0;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen,
    Ubuntu, Cantarell, "Helvetica Neue", Arial, "Apple Color Emoji",
    "Segoe UI Emoji", "Segoe UI Symbol";
  color: #0f2a3a;
  --background: linear-gradient(to top, #ffffff, #0056a6);
  background-attachment: fixed;
}

.page {
  max-width: 1100px;
  margin: 56px auto 120px;
  padding: 0 24px 24px;
}

.pill-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 10px 18px;
  color: var(--btn-text);
  text-decoration: none;
  font-weight: 600;
  border-radius: 999px;
  background-image: linear-gradient(90deg, var(--btn-start), var(--btn-end));
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
  transition: transform 150ms ease, box-shadow 150ms ease, filter 150ms ease,
    background-image 150ms ease;
  border: none;
  cursor: pointer;
}

.pill-button:hover {
  transform: translateY(-1px);
  background-image: linear-gradient(90deg, var(--btn-hover-start), var(--btn-hover-end));
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.18);
  filter: saturate(1.05);
}

/* Cards and layout for the 3-stage flow */
.card {
  background: var(--card-bg);
  border-radius: var(--card-radius);
  box-shadow: var(--card-shadow);
  padding: 22px 20px;
  margin-bottom: 20px;
}

.title {
  color: #ffffff;
  font-size: 22px;
  font-weight: 600;
  margin: 0 0 18px 2px;
}

.search-row {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 12px;
}

.input {
  height: 40px;
  padding: 0 14px;
  border-radius: 8px;
  border: 1px solid rgba(0,0,0,0.08);
  background: #f9fbfd;
  font-size: 15px;
  outline: none;
  transition: box-shadow 150ms ease, border-color 150ms ease;
}

.input:focus {
  border-color: #6fb6e0;
  box-shadow: 0 0 0 3px rgba(111, 182, 224, 0.25);
  background: #ffffff;
}

.results-list {
  list-style: none;
  margin: 0;
  padding: 0;
}

.result-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 14px 12px;
  border-radius: 10px;
  border: 1px solid rgba(0,0,0,0.06);
  background: #ffffff;
  box-shadow: 0 2px 8px rgba(0,0,0,0.06);
  margin-bottom: 12px;
  gap: 12px;
}

.result-title {
  font-weight: 600;
  color: #1c3e57;
  margin: 0 0 2px;
}

.result-subtitle {
  color: #5b7b91;
  font-size: 13px;
  margin: 0;
}

.state {
  color: #35586f;
  background: rgba(255,255,255,0.7);
  border-radius: 10px;
  padding: 12px 14px;
  border: 1px dashed rgba(0,0,0,0.1);
}

.hidden { display: none; }

table.details {
  width: 100%;
  border-collapse: collapse;
  font-size: 14px;
}

.details th, .details td {
  text-align: left;
  padding: 10px 12px;
  border-bottom: 1px solid #edf2f7;
}

.details th {
  width: 28%;
  color: #32566e;
  background: #f3f8fb;
  font-weight: 600;
}

.section-title {
  font-size: 18px;
  font-weight: 700;
  color: #1c3e57;
  margin: 0 0 10px;
}

.price-group { margin-bottom: 16px; }

.price-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  margin-top: 12px;
}

.price-box {
  background: #ffffff;
  border: 1px solid rgba(0,0,0,0.06);
  border-radius: 8px;
  padding: 12px;
  box-shadow: 0 2px 8px rgba(0,0,0,0.06);
}

.select {
  height: 40px;
  border-radius: 8px;
  border: 1px solid rgba(0,0,0,0.08);
  background: #f9fbfd;
  padding: 0 12px;
}

.muted { color: #5b7b91; }
