/* =====================================================
   POLÍTICA Y TÉRMINOS — Premium Design (Theme Aware)
   Centralized CSS for politica.php and terminos.php
   ===================================================== */

.policy-root {
  background: var(--bg);
  min-height: 100vh;
  padding-bottom: 60px;
}

/* HERO SECTION */
.policy-hero {
  background: linear-gradient(135deg, #111827 0%, #1a1f2e 100%);
  padding: 80px 20px 70px;
  text-align: center;
  position: relative;
  overflow: hidden;
}

.policy-hero::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 3px;
  background: linear-gradient(90deg, transparent, #ffc21a 30%, #ffd000 70%, transparent);
}

.policy-hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  background: rgba(255,194,26,0.12);
  border: 1px solid rgba(255,194,26,0.3);
  border-radius: 50px;
  padding: 6px 16px;
  font-size: 0.78rem;
  font-weight: 700;
  color: #ffc21a;
  letter-spacing: 0.05em;
  margin-bottom: 1.2rem;
  text-transform: uppercase;
}

.policy-hero h1 {
  font-size: clamp(2rem, 5vw, 3.2rem);
  font-weight: 800;
  color: #ffffff;
  letter-spacing: -0.04em;
  margin-bottom: 0.75rem;
}

.policy-hero p {
  font-size: 1.05rem;
  color: #94a3b8;
  max-width: 580px;
  margin: 0 auto 1.8rem;
  line-height: 1.6;
}

.policy-meta-chips {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 12px;
}

.policy-meta-chip {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: rgba(255,255,255,0.06);
  border: 1px solid rgba(255,255,255,0.1);
  border-radius: 50px;
  padding: 6px 16px;
  font-size: 0.8rem;
  color: #cbd5e1;
  font-weight: 500;
}

.policy-meta-chip i { color: #ffc21a; }

/* LAYOUT */
.policy-layout {
  max-width: 1040px;
  margin: 0 auto;
  padding: 50px 20px 20px;
  display: grid;
  grid-template-columns: 240px 1fr;
  gap: 40px;
  align-items: start;
}

@media (max-width: 900px) {
  .policy-layout { grid-template-columns: 1fr; }
  .policy-toc { display: none; }
}

/* TABLE OF CONTENTS */
.policy-toc {
  position: sticky;
  top: 100px;
  background: var(--card);
  border-radius: 20px;
  border: 1px solid var(--border);
  padding: 24px;
  box-shadow: var(--shadow-sm);
}

.policy-toc-title {
  font-size: 0.75rem;
  font-weight: 800;
  color: #ffc21a;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  margin-bottom: 16px;
  display: flex;
  align-items: center;
  gap: 8px;
}

.policy-toc nav {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.policy-toc a {
  font-size: 0.85rem;
  color: var(--muted);
  text-decoration: none;
  font-weight: 500;
  padding: 8px 12px;
  border-radius: 10px;
  transition: all 0.25s ease;
  display: flex;
  align-items: center;
  gap: 9px;
}

.policy-toc a i {
  font-size: 0.8rem;
  color: #64748b;
  width: 16px;
  text-align: center;
  flex-shrink: 0;
  transition: color 0.2s;
}

.policy-toc a:hover {
  background: var(--hover);
  color: var(--text);
  transform: translateX(3px);
}

.policy-toc a:hover i { color: #ffc21a; }

/* SECTIONS AND CARDS */
.policy-sections {
  display: flex;
  flex-direction: column;
  gap: 24px;
}

.policy-card {
  background: var(--card);
  border-radius: 24px;
  border: 1px solid var(--border);
  padding: 32px 40px;
  box-shadow: var(--shadow-sm);
  scroll-margin-top: 110px;
  transition: border-color 0.3s;
}

.policy-card:target {
  border-color: rgba(255, 194, 26, 0.4);
}

.policy-card-header {
  display: flex;
  align-items: center;
  gap: 16px;
  margin-bottom: 18px;
}

.policy-card-icon {
  width: 44px;
  height: 44px;
  border-radius: 12px;
  background: linear-gradient(135deg, #fef9ec, #fef3c7);
  border: 1px solid #fde68a;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.1rem;
  color: #d97706;
  flex-shrink: 0;
  box-shadow: 0 4px 10px rgba(0,0,0,0.03);
}

/* Tema oscuro para iconos */
.dark-mode .policy-card-icon {
  background: linear-gradient(135deg, #332701, #4d3b01);
  border-color: rgba(255, 194, 26, 0.2);
  color: #ffc21a;
  box-shadow: 0 4px 15px rgba(0,0,0,0.2);
}

.policy-card h2 {
  font-size: 1.25rem;
  font-weight: 800;
  color: var(--text);
  margin: 0;
  letter-spacing: -0.02em;
}

.policy-card p,
.policy-card li {
  font-size: 0.95rem;
  color: var(--muted);
  line-height: 1.8;
  margin-bottom: 0.75rem;
}

.policy-card ul, .policy-card ol {
  padding-left: 1.25rem;
  margin: 0.6rem 0;
}

.policy-card li { margin-bottom: 0.5rem; }

.policy-card strong {
  color: var(--text);
  font-weight: 700;
}

.policy-card a {
  color: #d97706;
  text-decoration: underline;
  text-underline-offset: 3px;
  font-weight: 600;
  transition: color 0.2s;
}

.policy-card a:hover {
  color: #ffc21a;
}

.dark-mode .policy-card a {
  color: #ffc21a;
}

/* HIGHLIGHT BOXES */
.policy-highlight {
  background: #f0fdf4;
  border: 1px solid #bbf7d0;
  border-radius: 14px;
  padding: 16px 20px;
  margin-top: 15px;
  font-size: 0.92rem;
  color: #166534;
  display: flex;
  gap: 12px;
  align-items: flex-start;
  line-height: 1.6;
}

.policy-highlight.warning { background: #fffbeb; border-color: #fde68a; color: #92400e; }
.policy-highlight.info { background: #eff6ff; border-color: #bfdbfe; color: #1e40af; }

/* Tema oscuro para highlights */
.dark-mode .policy-highlight { background: rgba(16, 185, 129, 0.12); border-color: rgba(16, 185, 129, 0.25); color: #2ecc71; }
.dark-mode .policy-highlight.warning { background: rgba(245, 158, 11, 0.12); border-color: rgba(245, 158, 11, 0.25); color: #fdba74; }
.dark-mode .policy-highlight.info { background: rgba(59, 130, 246, 0.12); border-color: rgba(59, 130, 246, 0.25); color: #60a5fa; }

.policy-highlight i { margin-top: 3px; flex-shrink: 0; font-size: 1.15rem; }

/* TABLES */
.policy-table-wrapper {
  overflow-x: auto;
  margin: 1.5rem 0;
  border-radius: 12px;
  border: 1px solid var(--border);
}

.policy-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.88rem;
}

.policy-table th {
  background: var(--bg-elevated);
  color: var(--text);
  font-weight: 700;
  padding: 12px 16px;
  text-align: left;
  border-bottom: 2px solid var(--border);
}

.policy-table td {
  padding: 12px 16px;
  border-bottom: 1px solid var(--border);
  color: var(--muted);
  vertical-align: top;
}

.policy-table tr:last-child td { border-bottom: none; }

/* CONTACT CARD */
.policy-contact-card {
  background: linear-gradient(135deg, #111827, #1e293b);
  border-radius: 24px;
  padding: 35px 40px;
  text-align: center;
  position: relative;
  overflow: hidden;
  box-shadow: 0 15px 40px rgba(0,0,0,0.25);
}

.policy-contact-card::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 3px;
  background: linear-gradient(90deg, transparent, #ffc21a, transparent);
}

.policy-contact-card h2 {
  color: #fff;
  font-size: 1.5rem;
  font-weight: 800;
  margin-bottom: 10px;
}

.policy-contact-card p {
  color: #94a3b8;
  font-size: 0.95rem;
  margin-bottom: 25px;
  max-width: 450px;
  margin-left: auto;
  margin-right: auto;
}

.policy-contact-btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  background: #ffc21a;
  color: #000;
  font-weight: 800;
  font-size: 0.95rem;
  border-radius: 14px;
  padding: 12px 28px;
  text-decoration: none !important;
  transition: all 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.policy-contact-btn:hover {
  background: #ffd000;
  transform: translateY(-4px);
  box-shadow: 0 10px 20px rgba(255, 194, 26, 0.2);
  color: #000;
}

.policy-footer-note {
  margin-top: 20px;
  font-size: 0.85rem;
  color: #64748b;
}

.policy-footer-note a {
  color: #ffc21a;
  font-weight: 700;
  text-decoration: none;
}

.policy-footer-note a:hover {
  text-decoration: underline;
}

/* RESPONSIVE UPDATES */
@media (max-width: 600px) {
  .policy-card { padding: 25px 20px; }
  .policy-card h2 { font-size: 1.15rem; }
  .policy-hero h1 { font-size: 1.8rem; }
  .policy-contact-card { padding: 30px 20px; }
}
