/* ================================================================
   FASTCODING — TERMS OF USE
   Modal (overlay) + Standalone Page (termos-de-uso.html)
   ================================================================ */

/* ----------------------------------------------------------------
   MODAL — OVERLAY
   ---------------------------------------------------------------- */
.terms-overlay {
  position: fixed;
  inset: 0;
  z-index: 99999;
  background: rgba(0, 0, 0, 0.80);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  opacity: 0;
  transition: opacity 0.4s ease;
}
.terms-overlay.tm-visible { opacity: 1; }
.terms-overlay.tm-hidden  { display: none; }

/* ----------------------------------------------------------------
   MODAL — CARD
   ---------------------------------------------------------------- */
.terms-modal {
  background: var(--bg-surface);
  border: 1px solid var(--border-mid);
  border-radius: 20px;
  width: 100%;
  max-width: 680px;
  /* height explícito é obrigatório para o flex-child tm-body poder rolar */
  height: 88vh;
  max-height: 680px;
  display: flex;
  flex-direction: column;
  box-shadow: 0 32px 80px rgba(0, 0, 0, 0.55), 0 0 0 1px rgba(168, 85, 247, 0.08);
  transform: translateY(28px) scale(0.98);
  transition: transform 0.45s cubic-bezier(0.16, 0.84, 0.44, 1);
  overflow: hidden;
}
.terms-overlay.tm-visible .terms-modal {
  transform: translateY(0) scale(1);
}

/* ----------------------------------------------------------------
   MODAL — HEADER
   ---------------------------------------------------------------- */
.tm-header {
  padding: 24px 28px 0;
  flex-shrink: 0;
}
.tm-brand {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: var(--blue-tint);
  border: 1px solid var(--border-mid);
  border-radius: var(--radius-full);
  padding: 4px 12px 4px 8px;
  margin-bottom: 14px;
}
.tm-brand-dot {
  width: 6px; height: 6px;
  border-radius: 50%;
  background: var(--blue-hi);
  box-shadow: 0 0 6px var(--blue-hi);
  animation: tmPulse 2s ease infinite;
}
@keyframes tmPulse {
  0%, 100% { opacity: 1; }
  50%       { opacity: 0.4; }
}
.tm-brand span {
  font-size: .72rem;
  font-weight: 700;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--blue-hi);
}
.tm-header h2 {
  font-size: 1.25rem;
  font-weight: 800;
  letter-spacing: -.025em;
  color: var(--text);
  margin-bottom: 4px;
}
.tm-header p {
  font-size: .83rem;
  color: var(--text-3);
  line-height: 1.5;
}

/* ----------------------------------------------------------------
   MODAL — PROGRESS BAR
   ---------------------------------------------------------------- */
.tm-progress-wrap {
  padding: 16px 28px 0;
  flex-shrink: 0;
}
.tm-progress-labels {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: .73rem;
  color: var(--text-3);
  margin-bottom: 6px;
}
.tm-progress-labels strong {
  font-size: .73rem;
  color: var(--text-2);
}
.tm-progress-track {
  height: 4px;
  background: var(--border);
  border-radius: var(--radius-full);
  overflow: hidden;
}
.tm-progress-fill {
  height: 100%;
  width: 0%;
  background: linear-gradient(90deg, var(--blue) 0%, var(--blue-hi) 100%);
  border-radius: var(--radius-full);
  transition: width 0.12s linear;
  box-shadow: 0 0 8px var(--blue-glow);
}

/* ----------------------------------------------------------------
   MODAL — SCROLLABLE BODY
   ---------------------------------------------------------------- */
.tm-body {
  flex: 1 1 0%;
  min-height: 0;
  overflow-y: scroll;                /* scroll sempre ativo */
  -webkit-overflow-scrolling: touch;
  overscroll-behavior: contain;
  padding: 20px 28px 8px;
  font-size: .875rem;
  line-height: 1.85;
  color: var(--text-2);
}
.tm-body::-webkit-scrollbar       { width: 4px; }
.tm-body::-webkit-scrollbar-track { background: transparent; }
.tm-body::-webkit-scrollbar-thumb { background: var(--border-mid); border-radius: 4px; }

.tm-body h3 {
  font-size: .92rem;
  font-weight: 700;
  color: var(--text);
  margin: 24px 0 8px;
  padding-top: 20px;
  border-top: 1px solid var(--border);
}
.tm-body h3:first-child    { margin-top: 0; padding-top: 0; border-top: none; }
.tm-body p                 { margin-bottom: 10px; }
.tm-body ul                { padding-left: 18px; margin-bottom: 10px; }
.tm-body ul li             { margin-bottom: 5px; }
.tm-body strong            { color: var(--text); font-weight: 600; }
.tm-body .tm-highlight     {
  background: var(--blue-tint);
  border-left: 3px solid var(--blue);
  border-radius: 0 var(--radius-md) var(--radius-md) 0;
  padding: 12px 16px;
  margin: 14px 0;
  font-size: .83rem;
  color: var(--text-2);
}
.tm-date {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: .78rem;
  color: var(--text-3);
  background: var(--border);
  border-radius: var(--radius-full);
  padding: 3px 10px;
  margin-bottom: 16px;
}

/* ----------------------------------------------------------------
   MODAL — FOOTER
   ---------------------------------------------------------------- */
.tm-footer {
  padding: 14px 28px 22px;
  flex-shrink: 0;
  border-top: 1px solid var(--border);
  display: flex;
  flex-direction: column;
  gap: 10px;
  background: var(--bg-surface);
}
.tm-scroll-hint {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  font-size: .78rem;
  color: var(--text-3);
  min-height: 20px;
  transition: opacity 0.35s ease;
}
.tm-scroll-hint svg {
  animation: tmBounce 1.3s ease infinite;
}
@keyframes tmBounce {
  0%, 100% { transform: translateY(0); }
  50%       { transform: translateY(4px); }
}
.tm-scroll-hint.tm-done { opacity: 0; pointer-events: none; }

.tm-accept-btn {
  width: 100%;
  padding: 15px 20px;
  border-radius: var(--radius-lg);
  border: none;
  font-family: var(--font-sans);
  font-size: .95rem;
  font-weight: 700;
  letter-spacing: -.01em;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  cursor: not-allowed;
  color: var(--text-3);
  background: var(--border);
  transition: all 0.35s cubic-bezier(0.16, 0.84, 0.44, 1);
}
.tm-accept-btn.tm-ready {
  cursor: pointer;
  color: #ffffff;
  background: linear-gradient(135deg, var(--blue) 0%, var(--blue-hi) 100%);
  box-shadow: 0 6px 24px rgba(124, 58, 237, 0.35);
}
.tm-accept-btn.tm-ready:hover {
  transform: translateY(-2px);
  box-shadow: 0 10px 32px rgba(124, 58, 237, 0.5);
}
.tm-accept-btn.tm-ready:active { transform: translateY(0); }
.tm-accept-btn svg { flex-shrink: 0; }

.tm-reject {
  text-align: center;
  font-size: .76rem;
  color: var(--text-3);
}
.tm-reject a {
  color: var(--text-3);
  text-decoration: underline;
  text-underline-offset: 2px;
  transition: color 0.2s;
}
.tm-reject a:hover { color: var(--text-2); }

/* ----------------------------------------------------------------
   MODAL — RESPONSIVE
   ---------------------------------------------------------------- */
@media (max-width: 520px) {
  .terms-overlay   { padding: 12px; align-items: flex-end; }
  .terms-modal     { max-height: 92vh; border-radius: 20px 20px 0 0; }
  .tm-header,
  .tm-progress-wrap,
  .tm-body,
  .tm-footer       { padding-left: 20px; padding-right: 20px; }
}

/* ----------------------------------------------------------------
   COOKIE BANNER — link "Ler Termos de Uso"
   ---------------------------------------------------------------- */
.cookie-terms-link {
  color: var(--blue-hi);
  text-decoration: underline;
  text-underline-offset: 2px;
  white-space: nowrap;
  transition: opacity 0.2s;
}
.cookie-terms-link:hover { opacity: 0.8; }

/* ================================================================
   STANDALONE PAGE — termos-de-uso.html
   ================================================================ */

/* ── Hero ── */
.terms-page-hero {
  padding: 120px 0 64px;
  text-align: center;
  border-bottom: 1px solid var(--border);
  position: relative;
  overflow: hidden;
}
.terms-page-hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse 60% 50% at 50% 0%, rgba(124,58,237,0.08) 0%, transparent 70%);
  pointer-events: none;
}
.terms-page-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: .75rem;
  font-weight: 700;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--blue-hi);
  background: var(--blue-tint);
  border: 1px solid var(--border-mid);
  border-radius: var(--radius-full);
  padding: 5px 14px;
  margin-bottom: 20px;
}
.terms-page-hero h1 {
  font-size: clamp(1.8rem, 4.5vw, 3rem);
  font-weight: 800;
  letter-spacing: -.035em;
  color: var(--text);
  margin-bottom: 10px;
}
.terms-page-hero .tp-sub {
  font-size: .9rem;
  color: var(--text-3);
  margin-bottom: 24px;
}
.terms-page-meta {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: .78rem;
  color: var(--text-3);
  background: var(--bg-raised);
  border: 1px solid var(--border);
  border-radius: var(--radius-full);
  padding: 6px 16px;
}
.terms-page-meta svg { color: var(--blue-hi); flex-shrink: 0; }

/* ── Content ── */
.terms-page-content {
  max-width: 780px;
  margin: 0 auto;
  padding: 64px 24px 100px;
}
.terms-page-content h2 {
  display: flex;
  align-items: baseline;
  gap: 10px;
  font-size: 1.1rem;
  font-weight: 800;
  color: var(--text);
  margin: 44px 0 14px;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--border);
}
.terms-page-content h2:first-child { margin-top: 0; }
.tp-sec-num {
  font-size: .72rem;
  font-weight: 700;
  letter-spacing: .08em;
  text-transform: uppercase;
  background: var(--grad-text);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  flex-shrink: 0;
}
.terms-page-content h3 {
  font-size: .98rem;
  font-weight: 700;
  color: var(--text);
  margin: 20px 0 8px;
}
.terms-page-content p {
  font-size: .93rem;
  line-height: 1.9;
  color: var(--text-2);
  margin-bottom: 14px;
}
.terms-page-content ul {
  padding-left: 20px;
  margin-bottom: 14px;
}
.terms-page-content ul li {
  font-size: .93rem;
  line-height: 1.9;
  color: var(--text-2);
  margin-bottom: 6px;
}
.terms-page-content strong { color: var(--text); font-weight: 600; }

.tp-highlight {
  background: var(--blue-tint);
  border: 1px solid var(--border-mid);
  border-left: 3px solid var(--blue);
  border-radius: 0 var(--radius-md) var(--radius-md) 0;
  padding: 14px 18px;
  margin: 18px 0;
}
.tp-highlight p { margin: 0; font-size: .88rem; }

.tp-warning {
  background: rgba(239, 68, 68, 0.07);
  border: 1px solid rgba(239, 68, 68, 0.2);
  border-left: 3px solid var(--red);
  border-radius: 0 var(--radius-md) var(--radius-md) 0;
  padding: 14px 18px;
  margin: 18px 0;
}
.tp-warning p { margin: 0; font-size: .88rem; color: var(--text-2); }

/* ── Contact box ── */
.tp-contact-box {
  background: var(--bg-raised);
  border: 1px solid var(--border-mid);
  border-radius: var(--radius-xl);
  padding: 36px;
  margin-top: 48px;
  text-align: center;
}
.tp-contact-box h3 {
  font-size: 1.15rem;
  font-weight: 800;
  letter-spacing: -.02em;
  color: var(--text);
  margin-bottom: 8px;
}
.tp-contact-box p {
  color: var(--text-3);
  font-size: .88rem;
  margin-bottom: 22px;
}
.tp-contact-methods {
  display: flex;
  flex-direction: column;
  gap: 10px;
  align-items: center;
}
.tp-contact-row {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: .88rem;
  color: var(--text-2);
}
.tp-contact-row svg { color: var(--blue-hi); flex-shrink: 0; }
.tp-contact-row a   { color: var(--text-2); text-decoration: none; transition: color 0.2s; }
.tp-contact-row a:hover { color: var(--blue-hi); }

@media (max-width: 767px) {
  .terms-page-hero { padding: 100px 0 48px; }
  .terms-page-content { padding: 40px 20px 80px; }
  .tp-contact-box { padding: 24px 20px; }
}
