/* Acólitos & Missal — components
   Botões, cards, chips, listas e componentes do calendário — estilo sacro-minimalista. */

.icon { width: 18px; height: 18px; display: inline-block; vertical-align: middle; }

/* ---------- BOTÕES ---------- */
.btn-primary {
  background: linear-gradient(135deg, var(--gold-deep) 0%, var(--gold) 100%);
  color: #FDFBF5; border: none; padding: 14px 28px; border-radius: 8px; font-size: 13.5px; font-weight: 600;
  transition: all .18s ease;
  box-shadow: var(--shadow-sm);
  cursor: pointer;
  letter-spacing: 0.03em;
}
.btn-primary:hover { box-shadow: var(--shadow-md); transform: translateY(-1px); }
.btn-primary:active { transform: translateY(0); box-shadow: var(--shadow-sm); }

.btn-ghost {
  font-size: 13.5px; padding: 13px 26px; border-radius: 8px;
  border: 1.5px solid var(--border-strong); background: var(--surface); color: var(--text-primary); font-weight: 600;
  transition: all .18s ease;
  cursor: pointer;
  letter-spacing: 0.03em;
}
.btn-ghost:hover { border-color: var(--gold); background: var(--surface-2); }
.btn-sm { padding: 9px 18px; font-size: 12.5px; }

/* ---------- TAGS / STATUS ---------- */
.status-tag {
  font-size: 11px; padding: 4px 12px; border-radius: 999px; background: var(--surface-2); color: var(--text-secondary);
  display: inline-block; border: 1px solid var(--border); font-weight: 500;
}

/* ---------- FILTROS (chips) ---------- */
.filter-bar { display: flex; flex-wrap: wrap; gap: 9px; margin-bottom: 20px; }
.filter-chip {
  font-family: var(--font-mono); font-size: 11.5px; padding: 9px 17px; border-radius: 999px;
  border: 1.5px solid var(--border-strong); background: var(--surface); color: var(--text-secondary); font-weight: 500;
  transition: all .15s ease; cursor: pointer;
}
.filter-chip:hover { border-color: var(--gold); color: var(--text-primary); }
.filter-chip.active {
  background: var(--gold-deep);
  color: #FDFBF5; border-color: var(--gold-deep);
}

/* ---------- CARD GRID (cards genéricos, home/formação) ---------- */
.card-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; }
.resource-card {
  border: 1px solid var(--border); border-radius: var(--radius-card); background: var(--surface);
  overflow: hidden; transition: all .2s ease;
  box-shadow: var(--shadow-sm);
}
.resource-card:hover { box-shadow: var(--shadow-md); border-color: var(--border-strong); transform: translateY(-2px); }
.resource-cover {
  height: 80px; background: var(--surface-2); display: flex; align-items: center; justify-content: center;
  font-family: var(--font-mono); font-size: 11px; color: var(--gold-deep); overflow: hidden;
  border-bottom: 1px solid var(--border);
}
.resource-cover .icon { width: 24px; height: 24px; color: var(--gold-deep); }
.resource-body { padding: 20px; }
.resource-title { font-family: var(--font-display); font-size: 18px; font-weight: 600; margin: 0 0 8px; }
.resource-desc { font-size: 13px; color: var(--text-secondary); margin: 0 0 14px; }
.resource-foot { display: flex; align-items: center; justify-content: space-between; gap: 8px; }

@media (max-width: 720px) { .card-grid { grid-template-columns: 1fr 1fr; } }
@media (max-width: 520px) { .card-grid { grid-template-columns: 1fr; } }

/* ---------- CALLOUT ---------- */
.callout-box {
  border: 1px solid var(--border); border-radius: var(--radius-lg); padding: 44px 32px; text-align: center;
  background: var(--surface);
  position: relative;
}
.callout-box::before {
  content: ""; position: absolute; top: 22px; left: 50%; transform: translateX(-50%);
  width: 34px; height: 1px; background: var(--gold);
}
.callout-title { font-family: var(--font-display); font-size: 27px; font-weight: 600; margin: 12px 0 12px; }
.callout-sub { font-size: 14px; color: var(--text-secondary); margin: 0 0 24px; max-width: 440px; margin-left: auto; margin-right: auto; }

/* ---------- ROADMAP-LIST ---------- */
.roadmap-list { display: flex; flex-direction: column; gap: 0; margin: 22px 0 30px; }
.roadmap-step {
  display: flex; align-items: flex-start; gap: 16px; padding: 20px 6px;
  border-bottom: 1px solid var(--border);
}
.roadmap-step:last-child { border-bottom: none; }
.roadmap-index {
  font-family: var(--font-display); font-size: 15px; font-weight: 600; color: var(--gold-deep);
  width: 32px; height: 32px; border-radius: 50%; flex-shrink: 0;
  display: flex; align-items: center; justify-content: center;
  background: var(--surface-2); border: 1px solid var(--border-strong);
}
.roadmap-step-title { font-size: 16px; font-weight: 600; margin: 0 0 5px; font-family: var(--font-display); color: var(--text-primary); }
.roadmap-step-level { font-family: var(--font-mono); font-size: 10.5px; color: var(--text-muted); text-transform: uppercase; margin-bottom: 6px; letter-spacing: 0.04em; }
.roadmap-subtopicos { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 8px; }
.roadmap-subtopico {
  font-size: 11.5px; padding: 4px 11px; border-radius: 20px;
  background: var(--lit-roxo-bg); color: var(--lit-roxo); font-weight: 500;
  border: 1px solid rgba(92, 63, 115, 0.18);
}

/* ---------- INFO LIST (estrutura do missal) ---------- */
.info-list { display: flex; flex-direction: column; gap: 12px; margin: 18px 0 30px; }
.info-list-item {
  border: 1px solid var(--border); border-left: 3px solid var(--gold); border-radius: 8px; padding: 16px 18px; background: var(--surface);
}
.info-list-title { font-size: 15px; font-weight: 600; margin: 0 0 5px; font-family: var(--font-display); color: var(--text-primary); }
.info-list-sub { font-size: 13px; color: var(--text-secondary); margin: 0; }

/* ---------- CHIPS ---------- */
.chip-list { display: flex; flex-wrap: wrap; gap: 8px; margin: 16px 0 28px; }
.chip {
  font-family: var(--font-mono); font-size: 11.5px; padding: 7px 14px; border-radius: 999px;
  border: 1px solid var(--gold); color: var(--gold-deep); background: var(--lit-branco-bg); font-weight: 500;
}

/* ---------- ACCORDION ---------- */
.accordion { border: 1px solid var(--border); border-radius: var(--radius-card); overflow: hidden; margin-bottom: 12px; background: var(--surface); }
.accordion-head {
  width: 100%; text-align: left; padding: 17px 20px; background: none; border: none;
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  font-family: var(--font-display); font-size: 16px; font-weight: 600; color: var(--text-primary);
}
.accordion-head .icon { width: 15px; height: 15px; flex-shrink: 0; transition: transform .2s ease; color: var(--gold-deep); }
.accordion.open .accordion-head .icon { transform: rotate(45deg); }
.accordion-body { max-height: 0; overflow: hidden; transition: max-height .3s ease; }
.accordion-body-inner { padding: 0 20px 20px; font-size: 13.5px; color: var(--text-secondary); }
.accordion.open .accordion-body { max-height: 900px; }

/* ================================================================
   CALENDÁRIO LITÚRGICO
   ================================================================ */

.color-legend { display: flex; flex-wrap: wrap; gap: 10px; margin: 4px 0 22px; }
.color-legend-item {
  display: flex; align-items: center; gap: 7px; font-size: 11.5px; font-family: var(--font-mono);
  color: var(--text-secondary); border: 1px solid var(--border); padding: 6px 13px; border-radius: 999px; background: var(--surface);
}
.color-dot { width: 10px; height: 10px; border-radius: 50%; border: 1px solid rgba(42,33,24,.15); flex-shrink: 0; }
.color-dot.branco { background: var(--lit-branco); }
.color-dot.verde { background: var(--lit-verde); }
.color-dot.roxo { background: var(--lit-roxo); }
.color-dot.vermelho { background: var(--lit-vermelho); }
.color-dot.rosa { background: var(--lit-rosa); }

.calendar-controls { display: flex; align-items: center; justify-content: space-between; gap: 16px; flex-wrap: wrap; margin-bottom: 26px; }
.year-toggle { display: flex; gap: 8px; }
.month-nav { display: flex; align-items: center; gap: 12px; }
.month-nav button {
  width: 36px; height: 36px; border-radius: 50%; border: 1.5px solid var(--border-strong); background: var(--surface);
  display: flex; align-items: center; justify-content: center; transition: all .15s ease; color: var(--text-secondary);
}
.month-nav button:hover { border-color: var(--gold); color: var(--gold-deep); }
.month-nav button svg { width: 15px; height: 15px; }
.month-label { font-family: var(--font-display); font-size: 20px; font-weight: 600; min-width: 172px; text-align: center; color: var(--text-primary); }

.today-card {
  border: 1px solid var(--border); border-radius: var(--radius-lg); padding: 28px 30px; background: var(--surface);
  box-shadow: var(--shadow-sm); display: flex; gap: 22px; align-items: center; flex-wrap: wrap;
  transition: box-shadow .2s ease;
}
a.today-card:hover { box-shadow: var(--shadow-md); }
.today-color-bar { width: 4px; align-self: stretch; border-radius: 6px; min-height: 60px; flex-shrink: 0; }
.today-color-bar.branco { background: var(--lit-branco); }
.today-color-bar.verde { background: var(--lit-verde); }
.today-color-bar.roxo { background: var(--lit-roxo); }
.today-color-bar.vermelho { background: var(--lit-vermelho); }
.today-color-bar.rosa { background: var(--lit-rosa); }
.today-eyebrow { font-family: var(--font-mono); font-size: 11.5px; color: var(--gold-deep); margin: 0 0 7px; text-transform: uppercase; letter-spacing: .06em; }
.today-title { font-family: var(--font-display); font-size: 23px; font-weight: 600; margin: 0 0 10px; color: var(--text-primary); }
.today-meta { display: flex; gap: 8px; flex-wrap: wrap; }

/* grade do calendário mensal */
.month-grid { display: grid; grid-template-columns: repeat(7, 1fr); gap: 7px; }
.weekday-label { font-family: var(--font-mono); font-size: 10px; color: var(--text-muted); text-align: center; padding-bottom: 8px; text-transform: uppercase; letter-spacing: 0.05em; }
.day-cell {
  min-height: 84px; border-radius: 9px; border: 1px solid var(--border); background: var(--surface);
  padding: 9px; position: relative; cursor: pointer; transition: all .15s ease; overflow: hidden;
}
.day-cell:hover { border-color: var(--gold); box-shadow: var(--shadow-sm); }
.day-cell.empty { visibility: hidden; }
.day-cell.today { border: 1.5px solid var(--gold-deep); background: var(--lit-branco-bg); }
.day-num { font-family: var(--font-mono); font-weight: 600; font-size: 12.5px; color: var(--text-secondary); }
.day-rank-badge {
  font-size: 9px; font-weight: 700; padding: 1px 6px; border-radius: 999px; color: #FDFBF5;
  display: inline-block; margin-top: 5px; letter-spacing: 0.02em;
}
.day-title-mini { font-size: 10.5px; color: var(--text-secondary); margin-top: 4px; line-height: 1.3; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.day-cell::before {
  content: ""; position: absolute; top: 0; left: 0; right: 0; height: 3px;
}
.day-cell.color-branco::before { background: var(--lit-branco); }
.day-cell.color-verde::before { background: var(--lit-verde); }
.day-cell.color-roxo::before { background: var(--lit-roxo); }
.day-cell.color-vermelho::before { background: var(--lit-vermelho); }
.day-cell.color-rosa::before { background: var(--lit-rosa); }

@media (max-width: 640px) {
  .month-grid { gap: 4px; }
  .day-cell { min-height: 60px; padding: 5px; border-radius: 7px; }
  .day-title-mini { display: none; }
  .weekday-label { font-size: 9px; }
}

/* modal de detalhe do dia */
.day-modal-overlay {
  position: fixed; inset: 0; background: rgba(42,33,24,0.45); z-index: 200;
  display: flex; align-items: center; justify-content: center; padding: 20px;
  backdrop-filter: blur(2px);
}
.day-modal {
  background: var(--surface); border-radius: var(--radius-lg); border: 1px solid var(--border-strong);
  max-width: 420px; width: 100%; padding: 30px; box-shadow: var(--shadow-lg); position: relative;
}
.day-modal-close { position: absolute; top: 16px; right: 16px; width: 30px; height: 30px; border-radius: 50%; border: 1px solid var(--border-strong); background: var(--surface); display:flex; align-items:center; justify-content:center; color: var(--text-secondary); }
.day-modal-close:hover { border-color: var(--gold); color: var(--gold-deep); }
.day-modal-close svg { width: 13px; height: 13px; }

/* visão de lista */
.day-list { display: flex; flex-direction: column; gap: 8px; }
.day-list-item {
  display: flex; align-items: center; gap: 14px; padding: 13px 15px; border: 1px solid var(--border);
  border-radius: 9px; background: var(--surface);
}
.day-list-date { font-family: var(--font-mono); font-size: 11.5px; color: var(--text-muted); width: 78px; flex-shrink: 0; }
.day-list-color { width: 4px; height: 32px; border-radius: 4px; flex-shrink: 0; }
.day-list-color.branco { background: var(--lit-branco); }
.day-list-color.verde { background: var(--lit-verde); }
.day-list-color.roxo { background: var(--lit-roxo); }
.day-list-color.vermelho { background: var(--lit-vermelho); }
.day-list-color.rosa { background: var(--lit-rosa); }
.day-list-title { font-size: 13.5px; font-weight: 600; margin: 0; font-family: var(--font-display); }
.day-list-sub { font-size: 11.5px; color: var(--text-muted); margin: 2px 0 0; }

/* ---------- ESTADOS ---------- */
.state-msg {
  font-family: var(--font-mono); font-size: 12px; color: var(--text-muted);
  padding: 30px 0; text-align: center;
}

/* ---------- BUSCA (calendário) ---------- */
.search-box {
  display: flex; align-items: center; gap: 10px; border: 1px solid var(--border-strong);
  border-radius: 999px; padding: 12px 18px; background: var(--surface); margin-bottom: 14px;
  transition: border-color .15s ease;
}
.search-box:focus-within { border-color: var(--gold); }
.search-box .icon { color: var(--text-muted); flex-shrink: 0; }
.search-box input {
  border: none; outline: none; background: none; font-family: var(--font-body);
  font-size: 14px; color: var(--text-primary); width: 100%;
}
.search-box input::placeholder { color: var(--text-muted); }

/* ---------- IMPRESSÃO (mês do calendário) ---------- */
@media print {
  .no-print { display: none !important; }
  body { background: #fff; }
  .wrap { max-width: 100%; padding: 0; }
  section { border-top: none; padding: 0; }
  .month-grid { gap: 3px; }
  .day-cell { min-height: 70px; border: 1px solid #ccc; break-inside: avoid; }
  .day-cell::before { height: 3px; }
  .day-title-mini { display: -webkit-box !important; -webkit-line-clamp: 2; font-size: 8.5px; }
  .month-label { font-size: 22px; }
  .calendar-controls { justify-content: center; margin-bottom: 14px; }
}

