/* /assets/css/privacy.css */
/* Mobile-first styles for the Privacy Policy iframe section */

:root {
  --ui-bg: #ffffff;
  --ui-text: #111827;     /* gray-900 */
  --ui-muted: #6b7280;    /* gray-500 */
  --ui-border: #e5e7eb;   /* gray-200 */
  --ui-accent: #0ea5e9;   /* sky-500 */
  --ui-shadow: 0 14px 40px rgba(0,0,0,.08);
  --radius-lg: 14px;
}

/* Container */
.policy-iframe-section {
  max-width: 980px;
  margin: 20px auto 28px;
  padding: 0 16px;
}

/* Header */
.policy-iframe-header {
  display: flex;
  flex-direction: column;
  gap: 6px;
  align-items: flex-start;
}

#privacyPolicyTitle {
  margin: 0;
  font-size: 1.25rem;        /* ~20px on mobile */
  line-height: 1.25;
  color: var(--ui-text);
}

#privacyPolicyMeta {
  font-size: 0.875rem;
  color: var(--ui-muted);
}

/* Iframe wrap */
.policy-iframe-wrap {
  margin-top: 10px;
  background: var(--ui-bg);
  border: 1px solid var(--ui-border);
  border-radius: var(--radius-lg);
  box-shadow: var(--ui-shadow);
  overflow: hidden;
}

/* The iframe itself */
#privacyPolicyFrame {
  display: block;
  width: 100%;
  min-height: 360px;
  border: 0;
}

/* Empty/error state */
#privacyPolicyEmpty {
  margin-top: 10px;
  color: #9b1c1c;             /* subtle red text */
  background: #fff5f5;
  border: 1px solid #fed7d7;
  border-radius: var(--radius-lg);
  padding: 12px 14px;
  font-size: 0.95rem;
}

/* Links in surrounding page (not inside iframe) */
.policy-iframe-section a {
  color: var(--ui-accent);
  text-decoration: underline;
}

/* Focus states for accessibility */
.policy-iframe-section :where(button, [tabindex], a):focus {
  outline: 2px solid var(--ui-accent);
  outline-offset: 2px;
  border-radius: 8px;
}

/* ————— Desktop & larger tablets ————— */
@media (min-width: 768px) {
  .policy-iframe-section {
    margin: 28px auto 40px;
    padding: 0 20px;
  }
  #privacyPolicyTitle {
    font-size: 1.5rem;        /* ~24px */
  }
  .policy-iframe-wrap {
    margin-top: 14px;
    border-radius: 16px;
  }
  #privacyPolicyFrame {
    min-height: 520px;
  }
}

/* ————— Very large screens ————— */
@media (min-width: 1200px) {
  .policy-iframe-section {
    max-width: 1040px;
  }
}

/* ————— Dark mode ————— */
@media (prefers-color-scheme: dark) {
  :root {
    --ui-bg: #0b0b0c;
    --ui-text: #e5e7eb;       /* gray-200 */
    --ui-muted: #9ca3af;      /* gray-400 */
    --ui-border: #1f2937;     /* gray-800 */
    --ui-shadow: 0 14px 40px rgba(0,0,0,.45);
  }
  .policy-iframe-wrap {
    background: var(--ui-bg);
    border-color: var(--ui-border);
  }
  #privacyPolicyEmpty {
    color: #fca5a5;           /* light red */
    background: #2b1111;
    border-color: #7f1d1d;
  }
}

/* ————— Reduced motion (gentler shadows/transitions if you add any) ————— */
@media (prefers-reduced-motion: reduce) {
  * {
    transition: none !important;
  }
}

#privacyFrame { min-height: 70vh; }
