/* ==========================================================================
   Find My Phone with Clap - Privacy Policy Stylesheet
   Brand Theme: JEWEALITY Soft Pink & Warm Cream
   ========================================================================== */

@import url('https://fonts.googleapis.com/css2?family=Outfit:wght@400;500;600;700;800&family=Plus+Jakarta+Sans:wght@400;500;600;700&family=JetBrains+Mono:wght@400;500&display=swap');

:root {
  /* Brand Palette - Soft Pink & Warm Cream */
  --primary: #F21867;
  --primary-hover: #D81B60;
  --primary-deep: #C2185B;
  --primary-light: #FCE4EC;
  --primary-soft: #FFF0F5;
  --primary-border: #FFB6C1;
  --primary-glow: rgba(242, 24, 103, 0.22);

  /* Light Theme Defaults */
  --bg-body: #FFF8F0;
  --bg-surface: #FFFFFF;
  --bg-surface-elevated: #FFFDF9;
  --bg-subtle: #FFF0F5;
  --border-color: #F7E6E8;
  --border-focus: #F21867;
  
  /* Text */
  --text-primary: #2B2024;
  --text-secondary: #6E5E65;
  --text-tertiary: #8F7F86;
  --text-muted: #A8999E;

  /* Accent Badges */
  --badge-bg: #FCE4EC;
  --badge-text: #D81B60;
  --success-bg: #ECFDF5;
  --success-text: #059669;
  --success-border: #A7F3D0;
  --warning-bg: #FFFBEB;
  --warning-text: #D97706;
  --warning-border: #FDE68A;
  --info-bg: #EFF6FF;
  --info-text: #2563EB;
  --info-border: #BFDBFE;

  /* Layout & Shadows */
  --shadow-sm: 0 1px 3px rgba(43, 32, 36, 0.05);
  --shadow-md: 0 4px 10px -2px rgba(242, 24, 103, 0.07), 0 2px 4px -2px rgba(43, 32, 36, 0.04);
  --shadow-lg: 0 12px 24px -4px rgba(242, 24, 103, 0.09), 0 4px 8px -4px rgba(43, 32, 36, 0.04);
  --shadow-xl: 0 20px 32px -8px rgba(242, 24, 103, 0.12), 0 8px 12px -6px rgba(43, 32, 36, 0.05);

  --radius-sm: 8px;
  --radius-md: 14px;
  --radius-lg: 20px;
  --radius-xl: 28px;
  --radius-full: 9999px;

  --transition-fast: 0.15s ease;
  --transition-normal: 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}

/* Dark Theme */
[data-theme="dark"] {
  --primary: #FF3377;
  --primary-hover: #FF4D88;
  --primary-deep: #D81B60;
  --primary-light: #3D1F2E;
  --primary-soft: #2D1B25;
  --primary-border: #632B45;
  --primary-glow: rgba(255, 51, 119, 0.28);

  --bg-body: #141216;
  --bg-surface: #1C1820;
  --bg-surface-elevated: #231E28;
  --bg-subtle: #2D2332;
  --border-color: #382F3E;
  --border-focus: #FF3377;

  --text-primary: #F7EEF2;
  --text-secondary: #C8BAC1;
  --text-tertiary: #9E8E96;
  --text-muted: #7A6C73;

  --badge-bg: rgba(255, 51, 119, 0.18);
  --badge-text: #FF6699;
  --success-bg: rgba(16, 185, 129, 0.15);
  --success-text: #34D399;
  --success-border: rgba(16, 185, 129, 0.3);
  --warning-bg: rgba(245, 158, 11, 0.15);
  --warning-text: #FBBF24;
  --warning-border: rgba(245, 158, 11, 0.3);
  --info-bg: rgba(37, 99, 235, 0.15);
  --info-text: #60A5FA;
  --info-border: rgba(37, 99, 235, 0.3);

  --shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.5);
  --shadow-md: 0 4px 10px -2px rgba(0, 0, 0, 0.6);
  --shadow-lg: 0 12px 24px -4px rgba(0, 0, 0, 0.7);
  --shadow-xl: 0 20px 32px -8px rgba(0, 0, 0, 0.8);
}

/* Global Reset */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  font-family: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  font-size: 16px;
  line-height: 1.65;
  color: var(--text-primary);
  background-color: var(--bg-body);
  scroll-behavior: smooth;
  scroll-padding-top: 88px;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  background-color: var(--bg-body);
  transition: background-color var(--transition-normal), color var(--transition-normal);
}

/* Reading Progress Bar */
#reading-progress {
  position: fixed;
  top: 0;
  left: 0;
  height: 3px;
  background: linear-gradient(90deg, var(--primary), #FF85A2);
  width: 0%;
  z-index: 1000;
  transition: width 0.1s ease-out;
}

/* Container */
.container {
  width: 100%;
  max-width: 1240px;
  margin: 0 auto;
  padding: 0 24px;
}

/* Header & Navigation */
.header {
  position: sticky;
  top: 0;
  z-index: 900;
  background-color: rgba(255, 248, 240, 0.88);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--border-color);
  transition: background-color var(--transition-normal), border-color var(--transition-normal);
}

[data-theme="dark"] .header {
  background-color: rgba(20, 18, 22, 0.88);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 72px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 14px;
  text-decoration: none;
  color: inherit;
}

.brand-logo {
  width: 44px;
  height: 44px;
  border-radius: 12px;
  box-shadow: 0 4px 12px var(--primary-glow);
  object-fit: cover;
  transition: transform var(--transition-fast);
}

.brand:hover .brand-logo {
  transform: scale(1.05);
}

.brand-text {
  display: flex;
  flex-direction: column;
}

.brand-title {
  font-family: 'Outfit', sans-serif;
  font-size: 1.15rem;
  font-weight: 800;
  color: var(--text-primary);
  line-height: 1.2;
}

.brand-subtitle {
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--primary);
}

.nav-actions {
  display: flex;
  align-items: center;
  gap: 12px;
}

.btn-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  background-color: var(--bg-surface);
  color: var(--text-secondary);
  border: 1px solid var(--border-color);
  padding: 8px 14px;
  border-radius: var(--radius-full);
  font-size: 0.875rem;
  font-weight: 600;
  cursor: pointer;
  transition: all var(--transition-fast);
}

.btn-icon:hover {
  background-color: var(--primary-soft);
  color: var(--primary);
  border-color: var(--primary-border);
  transform: translateY(-1px);
}

/* Hero Section */
.hero {
  padding: 56px 0 36px;
  position: relative;
  overflow: hidden;
}

.hero-glow {
  position: absolute;
  top: -120px;
  right: 10%;
  width: 420px;
  height: 420px;
  background: radial-gradient(circle, var(--primary-glow) 0%, rgba(242, 24, 103, 0) 70%);
  pointer-events: none;
  z-index: 0;
}

.hero-content {
  position: relative;
  z-index: 1;
  max-width: 880px;
}

.hero-badge-group {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 20px;
}

.badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 5px 12px;
  border-radius: var(--radius-full);
  font-size: 0.775rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.badge-primary {
  background-color: var(--badge-bg);
  color: var(--badge-text);
  border: 1px solid var(--primary-border);
}

.badge-success {
  background-color: var(--success-bg);
  color: var(--success-text);
  border: 1px solid var(--success-border);
}

.badge-warning {
  background-color: var(--warning-bg);
  color: var(--warning-text);
  border: 1px solid var(--warning-border);
}

.badge-info {
  background-color: var(--info-bg);
  color: var(--info-text);
  border: 1px solid var(--info-border);
}

.hero-title {
  font-family: 'Outfit', sans-serif;
  font-size: 2.85rem;
  font-weight: 800;
  line-height: 1.15;
  color: var(--text-primary);
  margin-bottom: 16px;
  letter-spacing: -0.02em;
}

.hero-title span {
  color: var(--primary);
}

.hero-description {
  font-size: 1.125rem;
  color: var(--text-secondary);
  line-height: 1.7;
  margin-bottom: 24px;
}

.meta-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 20px;
  padding: 16px 20px;
  background-color: var(--bg-surface);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-sm);
}

.meta-item {
  display: flex;
  flex-direction: column;
}

.meta-label {
  font-size: 0.725rem;
  font-weight: 700;
  text-transform: uppercase;
  color: var(--text-tertiary);
  letter-spacing: 0.05em;
}

.meta-val {
  font-size: 0.925rem;
  font-weight: 600;
  color: var(--text-primary);
}

/* Privacy Guarantee Banner */
.guarantee-card {
  margin-top: 32px;
  background: linear-gradient(135deg, var(--primary-soft) 0%, var(--bg-surface) 100%);
  border: 1px solid var(--primary-border);
  border-radius: var(--radius-lg);
  padding: 24px 28px;
  box-shadow: var(--shadow-md);
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 24px;
  align-items: center;
}

[data-theme="dark"] .guarantee-card {
  background: linear-gradient(135deg, var(--primary-soft) 0%, var(--bg-surface) 100%);
}

.guarantee-icon {
  width: 56px;
  height: 56px;
  border-radius: 16px;
  background-color: var(--primary);
  color: #FFFFFF;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 28px;
  box-shadow: 0 8px 16px var(--primary-glow);
}

.guarantee-title {
  font-family: 'Outfit', sans-serif;
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 6px;
}

.guarantee-text {
  font-size: 0.95rem;
  color: var(--text-secondary);
  line-height: 1.6;
}

/* Main Layout Grid */
.layout-grid {
  display: grid;
  grid-template-columns: 280px 1fr;
  gap: 40px;
  padding: 32px 0 80px;
}

/* Sidebar / Table of Contents */
.sidebar {
  position: sticky;
  top: 104px;
  height: fit-content;
  max-height: calc(100vh - 120px);
  overflow-y: auto;
  padding-right: 8px;
}

.sidebar::-webkit-scrollbar {
  width: 4px;
}

.sidebar::-webkit-scrollbar-thumb {
  background: var(--border-color);
  border-radius: 4px;
}

.toc-card {
  background-color: var(--bg-surface);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  padding: 20px;
  box-shadow: var(--shadow-sm);
}

.toc-title {
  font-family: 'Outfit', sans-serif;
  font-size: 0.95rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--text-tertiary);
  margin-bottom: 14px;
  display: flex;
  align-items: center;
  gap: 8px;
}

.toc-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.toc-link {
  display: block;
  padding: 8px 12px;
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--text-secondary);
  text-decoration: none;
  border-radius: var(--radius-sm);
  transition: all var(--transition-fast);
  line-height: 1.4;
  border-left: 2px solid transparent;
}

.toc-link:hover {
  background-color: var(--primary-soft);
  color: var(--primary);
}

.toc-link.active {
  background-color: var(--primary-soft);
  color: var(--primary);
  font-weight: 700;
  border-left-color: var(--primary);
}

/* Content Area */
.content-area {
  display: flex;
  flex-direction: column;
  gap: 48px;
}

.section {
  background-color: var(--bg-surface);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-xl);
  padding: 36px 40px;
  box-shadow: var(--shadow-sm);
  transition: border-color var(--transition-normal);
}

.section:hover {
  border-color: var(--primary-border);
}

.section-header {
  margin-bottom: 24px;
  padding-bottom: 16px;
  border-bottom: 1px solid var(--border-color);
}

.section-number {
  font-size: 0.8rem;
  font-weight: 800;
  color: var(--primary);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin-bottom: 4px;
}

.section-title {
  font-family: 'Outfit', sans-serif;
  font-size: 1.75rem;
  font-weight: 800;
  color: var(--text-primary);
  letter-spacing: -0.01em;
}

.section-p {
  font-size: 1rem;
  color: var(--text-secondary);
  line-height: 1.75;
  margin-bottom: 20px;
}

.section-p:last-child {
  margin-bottom: 0;
}

/* Highlights Grid */
.highlights-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 16px;
  margin: 24px 0;
}

.highlight-box {
  background-color: var(--bg-subtle);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 20px;
  transition: transform var(--transition-fast), border-color var(--transition-fast);
}

.highlight-box:hover {
  transform: translateY(-2px);
  border-color: var(--primary-border);
}

.highlight-icon {
  font-size: 24px;
  margin-bottom: 10px;
}

.highlight-title {
  font-family: 'Outfit', sans-serif;
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 6px;
}

.highlight-text {
  font-size: 0.875rem;
  color: var(--text-secondary);
  line-height: 1.5;
}

/* Tables */
.table-wrapper {
  overflow-x: auto;
  margin: 24px 0;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  background-color: var(--bg-surface);
}

.policy-table {
  width: 100%;
  border-collapse: collapse;
  text-align: left;
  font-size: 0.925rem;
}

.policy-table th {
  background-color: var(--bg-subtle);
  color: var(--text-primary);
  font-family: 'Outfit', sans-serif;
  font-weight: 700;
  padding: 14px 18px;
  border-bottom: 1px solid var(--border-color);
  white-space: nowrap;
}

.policy-table td {
  padding: 14px 18px;
  border-bottom: 1px solid var(--border-color);
  color: var(--text-secondary);
  vertical-align: top;
}

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

.policy-table tr:hover td {
  background-color: var(--primary-soft);
}

.code-badge {
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.825rem;
  font-weight: 600;
  background-color: var(--bg-subtle);
  color: var(--primary-deep);
  padding: 3px 8px;
  border-radius: 6px;
  border: 1px solid var(--border-color);
}

[data-theme="dark"] .code-badge {
  color: #FF6699;
}

/* Callouts / Alert Boxes */
.callout {
  border-radius: var(--radius-md);
  padding: 20px 24px;
  margin: 24px 0;
  display: flex;
  gap: 16px;
  align-items: flex-start;
}

.callout-info {
  background-color: var(--info-bg);
  border: 1px solid var(--info-border);
  color: var(--info-text);
}

.callout-success {
  background-color: var(--success-bg);
  border: 1px solid var(--success-border);
  color: var(--success-text);
}

.callout-warning {
  background-color: var(--warning-bg);
  border: 1px solid var(--warning-border);
  color: var(--warning-text);
}

.callout-primary {
  background-color: var(--primary-soft);
  border: 1px solid var(--primary-border);
  color: var(--primary-deep);
}

.callout-icon {
  font-size: 22px;
  line-height: 1;
  flex-shrink: 0;
}

.callout-body {
  font-size: 0.95rem;
  line-height: 1.6;
}

.callout-title {
  font-family: 'Outfit', sans-serif;
  font-weight: 700;
  font-size: 1rem;
  margin-bottom: 4px;
}

/* Bullet List */
.styled-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin: 18px 0;
}

.styled-list li {
  position: relative;
  padding-left: 28px;
  font-size: 0.975rem;
  color: var(--text-secondary);
  line-height: 1.6;
}

.styled-list li::before {
  content: '✓';
  position: absolute;
  left: 0;
  top: 0;
  color: var(--primary);
  font-weight: 800;
  font-size: 1rem;
}

.styled-list.bullet li::before {
  content: '•';
  font-size: 1.3rem;
  line-height: 1.2;
}

/* Step-by-Step Cards */
.steps-container {
  display: flex;
  flex-direction: column;
  gap: 14px;
  margin: 20px 0;
}

.step-card {
  display: flex;
  gap: 16px;
  align-items: flex-start;
  padding: 16px 20px;
  background-color: var(--bg-subtle);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
}

.step-num {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background-color: var(--primary);
  color: #FFFFFF;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 0.875rem;
  flex-shrink: 0;
}

.step-text {
  font-size: 0.925rem;
  color: var(--text-secondary);
  line-height: 1.5;
}

.step-text strong {
  color: var(--text-primary);
}

/* Contact Card */
.contact-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 20px;
  margin-top: 24px;
}

.contact-card {
  background-color: var(--bg-subtle);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 24px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.contact-label {
  font-size: 0.775rem;
  font-weight: 700;
  text-transform: uppercase;
  color: var(--text-tertiary);
  letter-spacing: 0.05em;
}

.contact-value {
  font-family: 'Outfit', sans-serif;
  font-size: 1.2rem;
  font-weight: 700;
  color: var(--text-primary);
  text-decoration: none;
  transition: color var(--transition-fast);
}

.contact-value:hover {
  color: var(--primary);
}

/* Footer */
.footer {
  margin-top: auto;
  background-color: var(--bg-surface);
  border-top: 1px solid var(--border-color);
  padding: 48px 0 32px;
  transition: background-color var(--transition-normal);
}

.footer-content {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 16px;
}

.footer-brand {
  display: flex;
  align-items: center;
  gap: 10px;
  font-family: 'Outfit', sans-serif;
  font-size: 1.15rem;
  font-weight: 800;
  color: var(--text-primary);
}

.footer-copy {
  font-size: 0.875rem;
  color: var(--text-tertiary);
  max-width: 600px;
}

.footer-badges {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  justify-content: center;
  margin-top: 8px;
}

/* Back to Top Floating Button */
.back-to-top {
  position: fixed;
  bottom: 28px;
  right: 28px;
  width: 46px;
  height: 46px;
  border-radius: 50%;
  background-color: var(--primary);
  color: #FFFFFF;
  border: none;
  box-shadow: 0 4px 14px var(--primary-glow);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 18px;
  opacity: 0;
  visibility: hidden;
  transform: translateY(12px);
  transition: all var(--transition-fast);
  z-index: 800;
}

.back-to-top.visible {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.back-to-top:hover {
  background-color: var(--primary-hover);
  transform: translateY(-2px);
}

/* Print Stylesheet */
@media print {
  #reading-progress,
  .header,
  .sidebar,
  .btn-icon,
  .back-to-top,
  .hero-glow {
    display: none !important;
  }

  body {
    background-color: #FFFFFF !important;
    color: #000000 !important;
  }

  .container {
    max-width: 100% !important;
    padding: 0 !important;
  }

  .layout-grid {
    display: block !important;
  }

  .section {
    border: 1px solid #CCCCCC !important;
    box-shadow: none !important;
    page-break-inside: avoid;
    margin-bottom: 24px !important;
    padding: 20px !important;
  }

  .hero-title {
    font-size: 2rem !important;
  }
}

/* Responsive Media Queries */
@media (max-width: 1024px) {
  .layout-grid {
    grid-template-columns: 1fr;
    gap: 32px;
  }

  .sidebar {
    position: static;
    max-height: none;
    padding-right: 0;
  }

  .toc-card {
    border-radius: var(--radius-md);
  }

  .toc-list {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 6px;
  }
}

@media (max-width: 640px) {
  .container {
    padding: 0 16px;
  }

  .hero-title {
    font-size: 2.1rem;
  }

  .section {
    padding: 24px 20px;
    border-radius: var(--radius-lg);
  }

  .section-title {
    font-size: 1.45rem;
  }

  .guarantee-card {
    grid-template-columns: 1fr;
    text-align: left;
  }

  .meta-grid {
    flex-direction: column;
    gap: 12px;
  }
}
