:root {
    --primary: #3a4ee5;
    --primary-light: #eef0fd;
    --primary-dark: #2a3bc0;
    --primary-muted: rgba(58, 78, 229, 0.08);
    --text-main: #1a1d2e;
    --text-muted: #6b7280;
    --border: #e5e7f0;
    --radius: 12px;
  }

  .tos-hero {
    background: linear-gradient(135deg, var(--primary) 0%, #6c7ff0 100%);
    color: white;
    padding: 56px 0 48px;
    position: relative;
    overflow: hidden;
  }

  .tos-hero::before {
    content: '';
    position: absolute;
    width: 320px;
    height: 320px;
    border-radius: 50%;
    background: rgba(255,255,255,0.07);
    top: -80px;
    right: -60px;
  }

  .tos-hero::after {
    content: '';
    position: absolute;
    width: 180px;
    height: 180px;
    border-radius: 50%;
    background: rgba(255,255,255,0.05);
    bottom: -40px;
    left: 10%;
  }

  .tos-hero .badge-pill {
    background: rgba(255,255,255,0.18);
    color: white;
    border-radius: 50px;
    padding: 6px 16px;
    font-size: 0.8rem;
    font-weight: 600;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    backdrop-filter: blur(8px);
    border: 1px solid rgba(255,255,255,0.2);
    margin-bottom: 16px;
  }

  .tos-hero h1 {
    font-size: clamp(1.8rem, 4vw, 2.6rem);
    font-weight: 800;
    letter-spacing: -0.02em;
    margin-bottom: 12px;
  }

  .tos-hero p {
    opacity: 0.85;
    font-size: 1rem;
    max-width: 520px;
  }

  .tos-meta {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.82rem;
    opacity: 0.75;
    margin-top: 16px;
  }

  /* Table of contents */
  .tos-toc {
    background: white;
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 24px 28px;
    position: sticky;
    top: 80px;
  }

  .tos-toc h6 {
    font-weight: 700;
    color: var(--text-main);
    font-size: 0.78rem;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    margin-bottom: 14px;
    display: flex;
    align-items: center;
    gap: 8px;
  }

  .tos-toc h6 i {
    color: var(--primary);
  }

  .tos-toc-list {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-direction: column;
    gap: 2px;
  }

  .tos-toc-list li a {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 7px 10px;
    border-radius: 8px;
    color: var(--text-muted);
    text-decoration: none;
    font-size: 0.875rem;
    font-weight: 500;
    transition: all 0.18s ease;
  }

  .tos-toc-list li a:hover {
    background: var(--primary-muted);
    color: var(--primary);
  }

  .tos-toc-list li a .toc-num {
    background: var(--primary-light);
    color: var(--primary);
    width: 22px;
    height: 22px;
    border-radius: 6px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 0.7rem;
    font-weight: 700;
    flex-shrink: 0;
  }

  /* Section cards */
  .tos-section {
    background: white;
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 32px 36px;
    margin-bottom: 20px;
    transition: box-shadow 0.2s ease;
  }

  .tos-section:hover {
    box-shadow: 0 4px 24px rgba(58,78,229,0.07);
  }

  .tos-section-header {
    display: flex;
    align-items: flex-start;
    gap: 16px;
    margin-bottom: 20px;
    padding-bottom: 18px;
    border-bottom: 1px solid var(--border);
  }

  .section-icon-wrap {
    width: 44px;
    height: 44px;
    border-radius: 10px;
    background: var(--primary-muted);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
  }

  .section-icon-wrap i {
    font-size: 1.1rem;
    color: var(--primary);
  }

  .tos-section-header h2 {
    font-size: 1.15rem;
    font-weight: 700;
    color: var(--text-main);
    margin: 0 0 4px;
    letter-spacing: -0.01em;
  }

  .tos-section-header .section-num {
    font-size: 0.75rem;
    color: var(--primary);
    font-weight: 600;
  }

  .tos-section p {
    color: #4b5563;
    font-size: 0.925rem;
    line-height: 1.75;
    margin-bottom: 12px;
  }

  .tos-section p:last-child {
    margin-bottom: 0;
  }

  .tos-list {
    list-style: none;
    padding: 0;
    margin: 0 0 12px;
    display: flex;
    flex-direction: column;
    gap: 8px;
  }

  .tos-list li {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    color: #4b5563;
    font-size: 0.925rem;
    line-height: 1.6;
  }

  .tos-list li i {
    color: var(--primary);
    margin-top: 3px;
    flex-shrink: 0;
    font-size: 0.85rem;
  }

  .tos-list li i.text-danger {
    color: #ef4444 !important;
  }

  /* Highlight box */
  .tos-highlight {
    background: var(--primary-muted);
    border-left: 3px solid var(--primary);
    border-radius: 0 8px 8px 0;
    padding: 14px 18px;
    margin: 16px 0;
    font-size: 0.9rem;
    color: var(--primary-dark);
    display: flex;
    gap: 10px;
    align-items: flex-start;
  }

  .tos-highlight i {
    color: var(--primary);
    margin-top: 2px;
    flex-shrink: 0;
  }

  .tos-warn {
    background: #fff7ed;
    border-left: 3px solid #f59e0b;
    border-radius: 0 8px 8px 0;
    padding: 14px 18px;
    margin: 16px 0;
    font-size: 0.9rem;
    color: #92400e;
    display: flex;
    gap: 10px;
    align-items: flex-start;
  }

  .tos-warn i {
    color: #f59e0b;
    margin-top: 2px;
    flex-shrink: 0;
  }

  /* Responsive */
  @media (max-width: 767px) {
    .tos-section {
      padding: 22px 20px;
    }
    .tos-hero {
      padding: 40px 0 36px;
    }
    .tos-toc {
      position: static;
      margin-bottom: 20px;
    }
  }