/* ==========================================================================
   SEAMOU PRIVACY CENTRE - META / FACEBOOK FULL DESIGN SYSTEM
   CÔNG TY TNHH CÔNG NGHỆ VÀ KỸ THUẬT SEAMOU (MST: 2902252464)
   ========================================================================== */

:root {
  --bg-page: #ffffff;
  --bg-sidebar: #ffffff;
  --bg-card: #ffffff;
  --bg-card-hover: #f7f8fa;
  --bg-pill-active: #1c1e21;
  --text-pill-active: #ffffff;
  --bg-pill-hover: #f0f2f5;
  --bg-badge: #f0f2f5;
  --bg-input: #f0f2f5;
  
  --border-subtle: #e4e6eb;
  --border-strong: #ced0d4;
  
  --text-primary: #1c1e21;
  --text-secondary: #65676b;
  --text-tertiary: #8a8d91;
  
  --meta-blue: #0064e0;
  --meta-blue-hover: #0056bd;
  --meta-blue-bg: #e7f3ff;
  
  --font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
  --font-mono: 'JetBrains Mono', Consolas, Monaco, monospace;
  
  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 20px;
  --radius-full: 9999px;
  
  --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.05);
  --shadow-card: 0 4px 16px rgba(0, 0, 0, 0.06);
  --shadow-drawer: -4px 0 24px rgba(0, 0, 0, 0.15);
}

[data-theme="dark"] {
  --bg-page: #18191a;
  --bg-sidebar: #18191a;
  --bg-card: #242526;
  --bg-card-hover: #3a3b3c;
  --bg-pill-active: #3a3b3c;
  --text-pill-active: #e4e6eb;
  --bg-pill-hover: #303031;
  --bg-badge: #3a3b3c;
  --bg-input: #3a3b3c;
  
  --border-subtle: #393a3b;
  --border-strong: #4e4f50;
  
  --text-primary: #e4e6eb;
  --text-secondary: #b0b3b8;
  --text-tertiary: #8a8d91;
  
  --meta-blue: #2d88ff;
  --meta-blue-hover: #4599ff;
  --meta-blue-bg: rgba(45, 136, 255, 0.15);
  
  --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.2);
  --shadow-card: 0 4px 16px rgba(0, 0, 0, 0.3);
  --shadow-drawer: -4px 0 24px rgba(0, 0, 0, 0.4);
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  font-family: var(--font-family);
  background-color: var(--bg-page);
  color: var(--text-primary);
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  min-height: 100vh;
  overflow-x: hidden;
}

/* ==================== MOBILE TOP BAR ==================== */
.mobile-top-bar {
  display: none;
  position: sticky;
  top: 0;
  z-index: 150;
  background-color: var(--bg-sidebar);
  border-bottom: 1px solid var(--border-subtle);
  padding: 12px 16px;
  align-items: center;
  justify-content: space-between;
}

.mobile-brand-group {
  display: flex;
  align-items: center;
  gap: 10px;
}

.mobile-icon-btn {
  background: none;
  border: none;
  color: var(--text-primary);
  cursor: pointer;
  padding: 6px;
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
}

.mobile-icon-btn:hover {
  background-color: var(--bg-pill-hover);
}

/* ==================== MAIN FULL-WIDTH LAYOUT ==================== */
.meta-layout {
  display: flex;
  width: 100%;
  min-height: 100vh;
}

/* Left Sidebar */
.meta-sidebar {
  width: 320px;
  flex-shrink: 0;
  background-color: var(--bg-sidebar);
  border-right: 1px solid var(--border-subtle);
  position: sticky;
  top: 0;
  height: 100vh;
  overflow-y: auto;
  padding: 28px 20px;
  display: flex;
  flex-direction: column;
  z-index: 100;
  transition: transform 0.25s ease-in-out;
}

.sidebar-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background-color: rgba(0, 0, 0, 0.5);
  z-index: 90;
  opacity: 0;
  transition: opacity 0.25s ease;
}

.meta-logo-header {
  padding: 0 12px 20px 12px;
  border-bottom: 1px solid var(--border-subtle);
  margin-bottom: 16px;
}

.meta-brand-link {
  text-decoration: none;
  color: var(--text-primary);
  display: flex;
  align-items: center;
  gap: 12px;
}

.meta-brand-icon {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: linear-gradient(135deg, #0064e0 0%, #00c6ff 100%);
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  flex-shrink: 0;
}

.meta-brand-title {
  font-size: 18px;
  font-weight: 700;
  line-height: 1.2;
}

.meta-brand-subtitle {
  font-size: 12px;
  color: var(--text-secondary);
  font-weight: 500;
}

.nav-section {
  display: flex;
  flex-direction: column;
  gap: 4px;
  margin-bottom: 24px;
}

.nav-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 14px;
  border-radius: var(--radius-md);
  color: var(--text-primary);
  text-decoration: none;
  font-size: 14.5px;
  font-weight: 500;
  transition: background 0.15s ease;
  cursor: pointer;
  border: none;
  background: transparent;
  width: 100%;
  text-align: left;
}

.nav-item:hover {
  background-color: var(--bg-pill-hover);
}

.nav-item.active {
  background-color: var(--bg-pill-active);
  color: var(--text-pill-active);
  font-weight: 600;
}

.nav-item.active .nav-icon {
  color: var(--text-pill-active);
}

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

.nav-icon {
  color: var(--text-secondary);
  display: flex;
  align-items: center;
}

.nav-chevron {
  color: var(--text-tertiary);
  transition: transform 0.2s ease;
}

.nav-submenu {
  display: none;
  flex-direction: column;
  gap: 2px;
  padding-left: 36px;
  margin-top: 2px;
  margin-bottom: 6px;
}

.nav-submenu.open {
  display: flex;
}

.submenu-item {
  padding: 8px 12px;
  font-size: 13.5px;
  color: var(--text-secondary);
  text-decoration: none;
  border-radius: var(--radius-sm);
  transition: all 0.15s ease;
}

.submenu-item:hover {
  color: var(--text-primary);
  background-color: var(--bg-pill-hover);
}

.submenu-item.active {
  color: var(--meta-blue);
  font-weight: 600;
  background-color: var(--meta-blue-bg);
}

.sidebar-footer {
  margin-top: auto;
  padding: 16px 12px 0 12px;
  border-top: 1px solid var(--border-subtle);
  font-size: 12px;
  color: var(--text-secondary);
  line-height: 1.5;
}

.theme-toggle-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  width: 100%;
  padding: 8px 12px;
  border-radius: var(--radius-full);
  border: 1px solid var(--border-subtle);
  background: var(--bg-card);
  color: var(--text-primary);
  font-size: 13px;
  font-weight: 500;
  cursor: pointer;
  margin-top: 12px;
}

/* ==================== FULL-WIDTH MAIN CONTENT ==================== */
.meta-main-wrapper {
  flex: 1;
  display: flex;
  min-width: 0;
  width: 100%;
}

.meta-main {
  flex: 1;
  padding: 40px 56px 80px 56px;
  min-width: 0;
  width: 100%;
  max-width: 100%;
}

/* ==================== HEADINGS & SECTIONS ==================== */
.meta-page-header {
  margin-bottom: 36px;
}

.meta-page-title {
  font-size: 36px;
  font-weight: 700;
  color: var(--text-primary);
  letter-spacing: -0.6px;
  margin-bottom: 12px;
  line-height: 1.25;
}

.meta-page-desc {
  font-size: 16.5px;
  color: var(--text-secondary);
  line-height: 1.6;
}

.section-block {
  margin-bottom: 44px;
}

.section-title {
  font-size: 22px;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 16px;
  letter-spacing: -0.3px;
}

.section-desc {
  font-size: 15px;
  color: var(--text-secondary);
  margin-bottom: 20px;
  line-height: 1.55;
}

/* ==================== CARDS & MEDIA ILLUSTRATIONS ==================== */
.cards-grid-2 {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 24px;
  margin-bottom: 28px;
}

@media (max-width: 900px) {
  .cards-grid-2 {
    grid-template-columns: 1fr;
  }
}

.meta-card {
  background-color: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  padding: 28px;
  transition: all 0.2s ease;
  text-decoration: none;
  color: inherit;
  display: flex;
  flex-direction: column;
  cursor: pointer;
}

.meta-card:hover {
  border-color: var(--border-strong);
  box-shadow: var(--shadow-card);
  transform: translateY(-2px);
}

.card-img-badge {
  width: 60px;
  height: 60px;
  border-radius: 50%;
  overflow: hidden;
  margin-bottom: 20px;
  flex-shrink: 0;
}

.card-img-badge img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.card-title {
  font-size: 18.5px;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 10px;
  line-height: 1.3;
}

.card-text {
  font-size: 14.5px;
  color: var(--text-secondary);
  line-height: 1.6;
}

/* Topic Banner Cards with SVG Art */
.topic-banner-card {
  border-radius: var(--radius-lg);
  border: 1px solid var(--border-subtle);
  background: var(--bg-card);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: all 0.2s ease;
  cursor: pointer;
}

.topic-banner-card:hover {
  border-color: var(--border-strong);
  box-shadow: var(--shadow-card);
  transform: translateY(-2px);
}

.topic-banner-media {
  width: 100%;
  height: 180px;
  overflow: hidden;
  background-color: var(--bg-badge);
  display: flex;
  align-items: center;
  justify-content: center;
}

.topic-banner-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.topic-banner-body {
  padding: 22px;
  display: flex;
  flex-direction: column;
  flex: 1;
}

.topic-tag {
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  color: var(--meta-blue);
  margin-bottom: 6px;
  letter-spacing: 0.5px;
}

/* ==================== LIST CARDS (META STYLE) ==================== */
.meta-list-container {
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  overflow: hidden;
  background-color: var(--bg-card);
}

.meta-list-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 18px 22px;
  text-decoration: none;
  color: inherit;
  border-bottom: 1px solid var(--border-subtle);
  transition: background 0.15s ease;
  cursor: pointer;
}

.meta-list-row:last-child {
  border-bottom: none;
}

.meta-list-row:hover {
  background-color: var(--bg-pill-hover);
}

.list-row-left {
  display: flex;
  align-items: center;
  gap: 16px;
}

.list-row-icon {
  width: 44px;
  height: 44px;
  border-radius: var(--radius-md);
  background-color: var(--bg-badge);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-primary);
  flex-shrink: 0;
}

.list-row-title {
  font-size: 15.5px;
  font-weight: 600;
  color: var(--text-primary);
}

.list-row-subtitle {
  font-size: 13.5px;
  color: var(--text-secondary);
  margin-top: 2px;
}

/* ==================== DOCUMENT VIEWER ==================== */
.policy-update-banner {
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  padding: 22px 26px;
  background-color: var(--bg-card);
  margin-bottom: 28px;
}

.policy-update-date {
  font-size: 16.5px;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 6px;
}

.policy-update-text {
  font-size: 14.5px;
  color: var(--text-secondary);
  margin-bottom: 14px;
  line-height: 1.5;
}

.policy-meta-links {
  display: flex;
  gap: 20px;
  font-size: 14px;
  color: var(--meta-blue);
  font-weight: 600;
}

.policy-meta-links a, .policy-meta-links button {
  color: var(--meta-blue);
  text-decoration: none;
  background: none;
  border: none;
  cursor: pointer;
  font-family: inherit;
  font-size: inherit;
  font-weight: inherit;
  padding: 0;
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.policy-meta-links a:hover, .policy-meta-links button:hover {
  text-decoration: underline;
}

/* Highlights Box */
.highlights-card {
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 18px 22px;
  background-color: var(--bg-card);
  margin-bottom: 30px;
  cursor: pointer;
}

.highlights-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 15.5px;
  font-weight: 600;
  color: var(--text-primary);
}

.highlights-content {
  display: none;
  margin-top: 14px;
  padding-top: 14px;
  border-top: 1px solid var(--border-subtle);
  font-size: 14.5px;
  color: var(--text-secondary);
  line-height: 1.65;
}

.highlights-content.open {
  display: block;
}

/* Clean Accordion Sections */
.accordion-block {
  border-bottom: 1px solid var(--border-subtle);
  padding: 22px 0;
}

.accordion-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 19px;
  font-weight: 700;
  color: var(--text-primary);
  cursor: pointer;
  user-select: none;
  gap: 16px;
}

.accordion-header:hover {
  color: var(--meta-blue);
}

.accordion-body {
  margin-top: 16px;
  font-size: 15px;
  color: var(--text-secondary);
  line-height: 1.7;
}

.accordion-body h3 {
  font-size: 16px;
  font-weight: 700;
  color: var(--text-primary);
  margin: 18px 0 8px 0;
}

.accordion-body p {
  margin-bottom: 14px;
}

.accordion-body ul, .accordion-body ol {
  padding-left: 24px;
  margin-bottom: 16px;
}

.accordion-body li {
  margin-bottom: 8px;
}

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

.accordion-body a {
  color: var(--meta-blue);
  text-decoration: none;
}

.accordion-body a:hover {
  text-decoration: underline;
}

.meta-divider {
  border: none;
  border-top: 1px solid var(--border-subtle);
  margin: 20px 0;
}

/* ==================== BUTTONS & FORMS ==================== */
.btn-meta {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 10px 22px;
  border-radius: var(--radius-full);
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  border: none;
  transition: background 0.15s ease;
  text-decoration: none;
}

.btn-meta.primary {
  background-color: var(--meta-blue);
  color: #fff;
}

.btn-meta.primary:hover {
  background-color: var(--meta-blue-hover);
}

.search-input-wrapper {
  position: relative;
  width: 100%;
  margin-bottom: 24px;
}

.search-input {
  width: 100%;
  padding: 12px 18px 12px 46px;
  border-radius: var(--radius-full);
  border: 1px solid var(--border-subtle);
  background-color: var(--bg-input);
  color: var(--text-primary);
  font-size: 14.5px;
  outline: none;
  transition: border-color 0.2s ease, background 0.2s ease;
}

.search-input:focus {
  border-color: var(--meta-blue);
  background-color: var(--bg-card);
}

.search-icon-pos {
  position: absolute;
  left: 16px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--text-tertiary);
  pointer-events: none;
}

/* ==================== RESPONSIVE BREAKPOINTS ==================== */
@media (max-width: 1100px) {
  .meta-toc-sidebar {
    display: none;
  }
}

@media (max-width: 860px) {
  .mobile-top-bar {
    display: flex;
  }

  .meta-sidebar {
    position: fixed;
    top: 0;
    left: 0;
    height: 100vh;
    transform: translateX(-100%);
    box-shadow: var(--shadow-drawer);
  }

  .meta-sidebar.drawer-open {
    transform: translateX(0);
  }

  .sidebar-overlay.active {
    display: block;
    opacity: 1;
  }

  .meta-main {
    padding: 24px 16px;
    max-width: 100%;
  }

  .meta-page-title {
    font-size: 26px;
  }
}
