/* ══════════════════════════════════════════════════════════════
   PAGE DETAIL — Legal / Info content pages
   Prefix: cp-
   Layout: 3-column (sidebar + content + TOC) on desktop
           Single column with dropdown on mobile
   ══════════════════════════════════════════════════════════════ */

/* ══════════════════════════════════════
   THEME TOKENS
   ══════════════════════════════════════ */
.cp-body {
  --cp-bg: #ffffff;
  --cp-bg-soft: #fafaf7;
  --cp-bg-tint: #f5f4ef;
  --cp-line: #ececea;
  --cp-line-soft: #f3f3f0;
  --cp-text: #0a0a0a;
  --cp-text-muted: #6b6b6b;
  --cp-text-faint: #a8a8a5;
  --cp-accent: #0a0a0a;
  --cp-radius: 10px;
  --cp-radius-lg: 14px;
  --cp-header-h: 72px;
  --cp-font-display: 'Montserrat', 'Inter', system-ui, sans-serif;
  background: var(--cp-bg);
}

/* ══════════════════════════════════════
   HEADER override — solid white
   ══════════════════════════════════════ */
.cp-body .site-header.site-header--solid {
  --header-progress: 1 !important;
  --header-bg: 1 !important;
  --header-border: 0.08 !important;
  --header-blur: 16px !important;
}

.cp-body .site-header.site-header--solid .main-nav {
  background: #fff !important;
  box-shadow: 0 1px 0 rgba(0, 0, 0, 0.06), 0 4px 16px rgba(0, 0, 0, 0.04);
}

.cp-body .site-header.site-header--solid .brand-logo::before {
  background-color: #000 !important;
}

.cp-body .menu-toggle { display: none; }

/* ══════════════════════════════════════
   READING PROGRESS BAR
   ══════════════════════════════════════ */
.cp-progress {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: 2px;
  background: transparent;
  z-index: 1100;
  pointer-events: none;
}

.cp-progress-bar {
  height: 100%;
  width: 0%;
  background: linear-gradient(90deg, #111 0%, #444 100%);
  transition: width 0.08s ease-out;
}

/* ══════════════════════════════════════
   MOBILE HEADER META (hidden on desktop)
   ══════════════════════════════════════ */
.cp-mobile-meta { display: none; }

/* ══════════════════════════════════════
   HERO BANNER
   ══════════════════════════════════════ */
.cp-hero {
  position: relative;
  background:
    radial-gradient(1200px 400px at 80% -10%, rgba(0,0,0,0.04), transparent 60%),
    linear-gradient(180deg, #f8f7f3 0%, #fdfcfa 100%);
  border-bottom: 1px solid var(--cp-line);
  padding-top: calc(var(--cp-header-h) + 28px);
  padding-bottom: 48px;
  overflow: hidden;
}

.cp-hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(0,0,0,0.025) 1px, transparent 1px),
    linear-gradient(90deg, rgba(0,0,0,0.025) 1px, transparent 1px);
  background-size: 56px 56px;
  background-position: center;
  mask-image: radial-gradient(ellipse at center, rgba(0,0,0,0.4) 0%, transparent 75%);
  pointer-events: none;
}

.cp-hero-inner {
  position: relative;
  max-width: 1240px;
  margin: 0 auto;
  padding: 0 clamp(20px, 4vw, 40px);
  z-index: 1;
}

/* Breadcrumb */
.cp-breadcrumb {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.02em;
  color: var(--cp-text-faint);
  margin-bottom: 28px;
}

.cp-breadcrumb a {
  color: var(--cp-text-muted);
  text-decoration: none;
  transition: color 0.18s ease;
}

.cp-breadcrumb a:hover { color: var(--cp-text); }

.cp-breadcrumb span[aria-current="page"] {
  color: var(--cp-text);
  font-weight: 600;
}

.cp-breadcrumb-sep { color: var(--cp-text-faint); flex-shrink: 0; }

.cp-hero-body { max-width: 720px; }

.cp-hero-eyebrow {
  display: inline-flex;
  align-items: center;
  padding: 5px 10px;
  font-family: var(--cp-font-display);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--cp-text);
  background: rgba(0, 0, 0, 0.05);
  border: 1px solid rgba(0, 0, 0, 0.08);
  border-radius: 999px;
  margin-bottom: 16px;
}

.cp-hero-title {
  font-family: var(--cp-font-display);
  font-size: clamp(1.85rem, 4vw, 2.85rem);
  font-weight: 800;
  letter-spacing: -0.035em;
  line-height: 1.05;
  color: var(--cp-text);
  margin: 0 0 14px;
}

.cp-hero-lead {
  font-size: clamp(13.5px, 1.3vw, 15.5px);
  line-height: 1.65;
  color: var(--cp-text-muted);
  margin: 0 0 22px;
  max-width: 640px;
}

.cp-hero-meta {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px;
  font-size: 12px;
  color: var(--cp-text-muted);
}

.cp-meta-item {
  display: inline-flex;
  align-items: center;
  gap: 7px;
}

.cp-meta-item svg { color: var(--cp-text-faint); flex-shrink: 0; }

.cp-meta-item strong {
  color: var(--cp-text);
  font-weight: 600;
}

.cp-meta-dot {
  width: 3px;
  height: 3px;
  border-radius: 50%;
  background: var(--cp-text-faint);
  flex-shrink: 0;
}

/* ══════════════════════════════════════
   MAIN LAYOUT (3-column grid)
   ══════════════════════════════════════ */
.cp-main {
  background: var(--cp-bg);
  min-height: 50vh;
}

.cp-layout {
  display: grid;
  grid-template-columns: 240px minmax(0, 1fr) 220px;
  max-width: 1240px;
  margin: 0 auto;
  padding: 56px clamp(20px, 4vw, 40px) 96px;
  gap: 56px;
  align-items: start;
}

/* ══════════════════════════════════════
   SIDEBAR — page navigation
   ══════════════════════════════════════ */
.cp-sidebar {
  position: sticky;
  top: calc(var(--cp-header-h) + 24px);
  max-height: calc(100vh - var(--cp-header-h) - 48px);
  overflow-y: auto;
  scrollbar-width: thin;
  padding-right: 8px;
}

.cp-sidebar::-webkit-scrollbar { width: 4px; }
.cp-sidebar::-webkit-scrollbar-thumb { background: #e5e5e2; border-radius: 4px; }

.cp-sidebar-group { margin-bottom: 28px; }
.cp-sidebar-group:last-child { margin-bottom: 0; }

.cp-sidebar-title {
  font-family: var(--cp-font-display);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--cp-text-faint);
  margin: 0 0 14px;
  padding-left: 14px;
}

.cp-sidebar-list {
  list-style: none;
  margin: 0;
  padding: 0;
}

.cp-sidebar-link {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding: 10px 14px;
  font-size: 13px;
  font-weight: 500;
  color: var(--cp-text-muted);
  text-decoration: none;
  border-radius: 8px;
  line-height: 1.35;
  transition: background-color 0.18s ease, color 0.18s ease, transform 0.18s ease;
  position: relative;
}

.cp-sidebar-link-icon {
  font-size: 14px;
  opacity: 0;
  transform: translateX(-4px);
  transition: opacity 0.2s ease, transform 0.2s ease;
  color: var(--cp-text-faint);
}

.cp-sidebar-link:hover {
  color: var(--cp-text);
  background: var(--cp-bg-soft);
}

.cp-sidebar-link:hover .cp-sidebar-link-icon {
  opacity: 1;
  transform: translateX(0);
}

.cp-sidebar-link.is-active {
  color: var(--cp-text);
  font-weight: 600;
  background: var(--cp-bg-tint);
}

.cp-sidebar-link.is-active::before {
  content: '';
  position: absolute;
  left: -1px;
  top: 8px;
  bottom: 8px;
  width: 2px;
  background: var(--cp-text);
  border-radius: 2px;
}

.cp-sidebar-link.is-active .cp-sidebar-link-icon {
  opacity: 1;
  transform: translateX(0);
  color: var(--cp-text);
}

/* Sidebar CTA card */
.cp-sidebar-cta {
  margin-top: 32px;
  padding: 22px 18px;
  background: var(--cp-text);
  color: #fff;
  border-radius: var(--cp-radius-lg);
  position: relative;
  overflow: hidden;
}

.cp-sidebar-cta::before {
  content: '';
  position: absolute;
  right: -30px;
  top: -30px;
  width: 120px;
  height: 120px;
  background: radial-gradient(circle, rgba(255,255,255,0.07), transparent 70%);
}

.cp-sidebar-cta-icon {
  width: 36px;
  height: 36px;
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.1);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 14px;
  color: #fff;
}

.cp-sidebar-cta-title {
  font-family: var(--cp-font-display);
  font-size: 13.5px;
  font-weight: 700;
  letter-spacing: -0.005em;
  margin: 0 0 6px;
  color: #fff;
  position: relative;
}

.cp-sidebar-cta-text {
  font-size: 11.5px;
  line-height: 1.55;
  color: rgba(255, 255, 255, 0.65);
  margin: 0 0 14px;
  position: relative;
}

.cp-sidebar-cta-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 12px;
  font-family: var(--cp-font-display);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--cp-text);
  background: #fff;
  border-radius: 6px;
  text-decoration: none;
  transition: transform 0.15s ease, background 0.15s ease;
  position: relative;
}

.cp-sidebar-cta-btn:hover {
  background: #f3f3f0;
}

.cp-sidebar-cta-btn i { font-size: 14px; }

/* ══════════════════════════════════════
   MOBILE PAGE SELECT (hidden on desktop)
   ══════════════════════════════════════ */
.cp-mobile-select { display: none; }

/* ══════════════════════════════════════
   CONTENT
   ══════════════════════════════════════ */
.cp-content {
  min-width: 0;
}

.cp-body-text {
  font-size: 14px;
  line-height: 1.78;
  color: #3a3a3a;
}

.cp-body-text > *:first-child { margin-top: 0; }

/* Sections */
.cp-section {
  position: relative;
  padding: 32px 0 36px;
  border-bottom: 1px solid var(--cp-line-soft);
  scroll-margin-top: 100px;
}

.cp-section:first-child { padding-top: 0; }

.cp-section:last-child {
  border-bottom: none;
  padding-bottom: 0;
}

.cp-section-num {
  display: inline-block;
  font-family: var(--cp-font-display);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.14em;
  color: var(--cp-text-faint);
  margin-bottom: 8px;
}

.cp-body-text h2 {
  font-family: var(--cp-font-display);
  font-size: clamp(1.15rem, 1.6vw, 1.4rem);
  font-weight: 700;
  color: var(--cp-text);
  letter-spacing: -0.018em;
  line-height: 1.2;
  margin: 0 0 16px;
}

.cp-body-text h2,
.cp-body-text h3 { scroll-margin-top: 100px; }

.cp-body-text h3 {
  font-family: var(--cp-font-display);
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--cp-text);
  letter-spacing: -0.01em;
  margin: 24px 0 10px;
}

.cp-body-text p {
  font-size: 14px;
  color: #3a3a3a;
  line-height: 1.78;
  margin: 0 0 14px;
}

.cp-body-text p:last-child { margin-bottom: 0; }

.cp-body-text strong {
  color: var(--cp-text);
  font-weight: 700;
}

.cp-body-text a {
  color: var(--cp-text);
  text-decoration: underline;
  text-underline-offset: 3px;
  text-decoration-color: rgba(0, 0, 0, 0.25);
  text-decoration-thickness: 1px;
  transition: text-decoration-color 0.2s;
}

.cp-body-text a:hover { text-decoration-color: var(--cp-text); }

.cp-body-text ul,
.cp-body-text ol {
  margin: 0 0 16px;
  padding-left: 22px;
}

.cp-body-text li {
  font-size: 14px;
  color: #3a3a3a;
  line-height: 1.78;
  margin-bottom: 6px;
}

.cp-body-text li::marker { color: var(--cp-text-faint); }

.cp-body-text blockquote {
  margin: 18px 0;
  padding: 4px 0 4px 18px;
  border-left: 2px solid var(--cp-text);
  font-size: 15px;
  font-style: italic;
  color: var(--cp-text-muted);
}

.cp-body-text table {
  width: 100%;
  border-collapse: collapse;
  margin: 16px 0 20px;
  font-size: 13px;
}

.cp-body-text th,
.cp-body-text td {
  padding: 10px 12px;
  text-align: left;
  border-bottom: 1px solid var(--cp-line-soft);
}

.cp-body-text th {
  font-family: var(--cp-font-display);
  font-size: 10.5px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--cp-text);
  background: var(--cp-bg-soft);
  border-bottom: 1px solid var(--cp-line);
}

.cp-body-text img {
  max-width: 100%;
  height: auto;
  border-radius: var(--cp-radius);
  margin: 16px 0;
}

/* Callout blocks */
.cp-callout {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 14px 16px;
  border-radius: var(--cp-radius);
  margin: 16px 0;
  font-size: 13px;
  line-height: 1.65;
}

.cp-callout i {
  font-size: 18px;
  flex-shrink: 0;
  margin-top: 1px;
}

.cp-callout p { margin: 0; font-size: 13px; }

.cp-callout--info {
  background: #f5f7fa;
  border: 1px solid #e7ecf2;
  color: #2a3a4a;
}

.cp-callout--info i { color: #4a6a8a; }

.cp-callout--warn {
  background: #fdf6e7;
  border: 1px solid #f0e3bc;
  color: #6a5300;
}

.cp-callout--warn i { color: #b08800; }

/* Contact card (rich) */
.cp-contact-card {
  margin-top: 18px;
  padding: 22px 24px;
  background: var(--cp-bg-soft);
  border: 1px solid var(--cp-line);
  border-radius: var(--cp-radius-lg);
}

.cp-contact-head {
  display: flex;
  align-items: center;
  gap: 14px;
  padding-bottom: 16px;
  margin-bottom: 16px;
  border-bottom: 1px solid var(--cp-line);
}

.cp-contact-icon {
  width: 42px;
  height: 42px;
  border-radius: 10px;
  background: var(--cp-text);
  color: #fff;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.cp-contact-name {
  font-family: var(--cp-font-display);
  font-size: 14px;
  font-weight: 700;
  color: var(--cp-text);
  margin: 0 0 2px;
  letter-spacing: -0.01em;
}

.cp-contact-sub {
  font-size: 11px;
  color: var(--cp-text-faint);
  margin: 0;
  letter-spacing: 0.02em;
  text-transform: uppercase;
  font-weight: 600;
}

.cp-contact-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.cp-contact-list li {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  font-size: 13px;
  color: var(--cp-text-muted);
  line-height: 1.55;
  margin: 0;
}

.cp-contact-list li i {
  font-size: 16px;
  color: var(--cp-text);
  width: 18px;
  flex-shrink: 0;
  margin-top: 1px;
}

.cp-contact-list a {
  color: var(--cp-text);
  text-decoration: none;
  font-weight: 500;
}

.cp-contact-list a:hover { text-decoration: underline; }

/* Empty state */
.cp-empty {
  padding: 80px 24px;
  text-align: center;
  border: 1px dashed var(--cp-line);
  border-radius: var(--cp-radius-lg);
  background: var(--cp-bg-soft);
}

.cp-empty i {
  font-size: 32px;
  color: var(--cp-text-faint);
  margin-bottom: 12px;
}

.cp-empty p {
  font-size: 13px;
  color: var(--cp-text-muted);
  margin: 0;
}

/* ══════════════════════════════════════
   CONTENT FOOTER (meta + actions)
   ══════════════════════════════════════ */
.cp-content-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  flex-wrap: wrap;
  margin-top: 48px;
  padding: 22px 24px;
  background: var(--cp-bg-soft);
  border: 1px solid var(--cp-line);
  border-radius: var(--cp-radius-lg);
}

.cp-content-footer-meta {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  flex: 1;
  min-width: 220px;
}

.cp-content-footer-meta > i {
  font-size: 22px;
  color: var(--cp-text);
  margin-top: 2px;
}

.cp-content-footer-title {
  font-size: 13px;
  color: var(--cp-text);
  margin: 0 0 2px;
  line-height: 1.45;
}

.cp-content-footer-sub {
  font-size: 11.5px;
  color: var(--cp-text-faint);
  margin: 0;
  line-height: 1.45;
}

.cp-content-footer-actions {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.cp-action-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 9px 14px;
  font-family: var(--cp-font-display);
  font-size: 11.5px;
  font-weight: 600;
  letter-spacing: 0.02em;
  color: var(--cp-text);
  background: #fff;
  border: 1px solid var(--cp-line);
  border-radius: 8px;
  cursor: pointer;
  transition: background 0.15s, border-color 0.15s, transform 0.15s;
}

.cp-action-btn:hover {
  background: var(--cp-text);
  color: #fff;
  border-color: var(--cp-text);
}

.cp-action-btn i { font-size: 14px; }

/* ══════════════════════════════════════
   RELATED PAGES
   ══════════════════════════════════════ */
.cp-related {
  margin-top: 56px;
  padding-top: 40px;
  border-top: 1px solid var(--cp-line);
}

.cp-related-head { margin-bottom: 22px; }

.cp-related-eyebrow {
  display: block;
  font-family: var(--cp-font-display);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--cp-text-faint);
  margin-bottom: 6px;
}

.cp-related-title {
  font-family: var(--cp-font-display);
  font-size: clamp(1.1rem, 1.6vw, 1.35rem);
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--cp-text);
  margin: 0;
}

.cp-related-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 14px;
}

.cp-related-card {
  display: flex;
  flex-direction: column;
  padding: 22px;
  background: #fff;
  border: 1px solid var(--cp-line);
  border-radius: var(--cp-radius-lg);
  text-decoration: none;
  color: inherit;
  transition: transform 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease;
  position: relative;
  overflow: hidden;
}

.cp-related-card::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, transparent 60%, rgba(0,0,0,0.015));
  pointer-events: none;
  opacity: 0;
  transition: opacity 0.2s ease;
}

.cp-related-card:hover {
  border-color: rgba(0, 0, 0, 0.18);
  box-shadow: 0 12px 28px -16px rgba(0, 0, 0, 0.18);
}

.cp-related-card:hover::after { opacity: 1; }

.cp-related-card-tag {
  display: inline-block;
  font-family: var(--cp-font-display);
  font-size: 9.5px;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--cp-text-muted);
  padding: 3px 8px;
  background: var(--cp-bg-tint);
  border-radius: 4px;
  margin-bottom: 12px;
  width: fit-content;
}

.cp-related-card-title {
  font-family: var(--cp-font-display);
  font-size: 14.5px;
  font-weight: 700;
  letter-spacing: -0.01em;
  color: var(--cp-text);
  margin: 0 0 8px;
  line-height: 1.3;
}

.cp-related-card-text {
  font-size: 12.5px;
  color: var(--cp-text-muted);
  line-height: 1.55;
  margin: 0 0 14px;
  flex: 1;
}

.cp-related-card-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-family: var(--cp-font-display);
  font-size: 11.5px;
  font-weight: 700;
  letter-spacing: 0.02em;
  color: var(--cp-text);
  margin-top: auto;
}

.cp-related-card-link i {
  font-size: 14px;
  transition: transform 0.2s ease;
}


/* ══════════════════════════════════════
   TOC (right rail)
   ══════════════════════════════════════ */
.cp-toc {
  position: sticky;
  top: calc(var(--cp-header-h) + 24px);
  max-height: calc(100vh - var(--cp-header-h) - 48px);
  overflow-y: auto;
  scrollbar-width: thin;
}

.cp-toc::-webkit-scrollbar { width: 4px; }
.cp-toc::-webkit-scrollbar-thumb { background: #e5e5e2; border-radius: 4px; }

.cp-toc-inner {
  padding-left: 18px;
  border-left: 1px solid var(--cp-line);
}

.cp-toc-title {
  font-family: var(--cp-font-display);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--cp-text-faint);
  margin: 0 0 14px;
}

.cp-toc-list {
  list-style: none;
  margin: 0;
  padding: 0;
  counter-reset: toc;
}

.cp-toc-list li { margin-bottom: 2px; }

.cp-toc-link {
  display: flex;
  align-items: baseline;
  gap: 8px;
  padding: 7px 0 7px 12px;
  font-size: 12px;
  font-weight: 500;
  color: var(--cp-text-faint);
  text-decoration: none;
  line-height: 1.4;
  border-left: 2px solid transparent;
  margin-left: -19px;
  padding-left: 17px;
  transition: color 0.18s ease, border-color 0.18s ease;
}

.cp-toc-num {
  font-family: var(--cp-font-display);
  font-size: 10px;
  font-weight: 600;
  color: var(--cp-text-faint);
  letter-spacing: 0.05em;
  flex-shrink: 0;
}

.cp-toc-link:hover {
  color: var(--cp-text-muted);
}

.cp-toc-link.is-active {
  color: var(--cp-text);
  font-weight: 600;
  border-left-color: var(--cp-text);
}

.cp-toc-link.is-active .cp-toc-num { color: var(--cp-text); }

/* ══════════════════════════════════════
   BACK TO TOP (FAB)
   ══════════════════════════════════════ */
.cp-fab-top {
  position: fixed;
  right: 24px;
  bottom: 24px;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  border: 1px solid var(--cp-line);
  background: #fff;
  color: var(--cp-text);
  font-size: 18px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  box-shadow: 0 10px 26px -10px rgba(0, 0, 0, 0.18);
  opacity: 0;
  visibility: hidden;
  transform: translateY(8px);
  transition: opacity 0.25s ease, transform 0.25s ease, background 0.18s ease, color 0.18s ease, visibility 0.25s;
  z-index: 90;
}

.cp-fab-top.is-visible {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.cp-fab-top:hover {
  background: var(--cp-text);
  color: #fff;
}

/* ══════════════════════════════════════
   FOOTER
   ══════════════════════════════════════ */
.cp-footer {
  border-top: 1px solid var(--cp-line);
  padding: 32px 0;
  background: var(--cp-bg-soft);
}

.cp-footer-inner {
  max-width: 1240px;
  margin: 0 auto;
  padding: 0 clamp(20px, 4vw, 40px);
  text-align: center;
}

.cp-footer-links {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  flex-wrap: wrap;
  margin-bottom: 10px;
}

.cp-footer-link {
  font-size: 10.5px;
  font-weight: 600;
  color: var(--cp-text-muted);
  text-decoration: none;
  letter-spacing: 0.04em;
  padding: 4px 10px;
  transition: color 0.2s;
}

.cp-footer-link:hover { color: var(--cp-text); }

.cp-footer-dot {
  width: 3px;
  height: 3px;
  border-radius: 50%;
  background: #ddd;
  flex-shrink: 0;
}

.cp-footer-copy {
  font-size: 10px;
  color: var(--cp-text-faint);
  letter-spacing: 0.04em;
  margin: 0;
}

/* ══════════════════════════════════════
   RESPONSIVE — < 1100px: hide TOC
   ══════════════════════════════════════ */
@media (max-width: 1100px) {
  .cp-layout {
    grid-template-columns: 220px minmax(0, 1fr);
    gap: 44px;
  }
  .cp-toc { display: none; }
}

/* ══════════════════════════════════════
   RESPONSIVE — TABLET (< 900px)
   ══════════════════════════════════════ */
@media (max-width: 900px) {
  .cp-hero { padding-bottom: 36px; }
  .cp-layout {
    grid-template-columns: 200px minmax(0, 1fr);
    gap: 32px;
    padding: 40px clamp(16px, 4vw, 32px) 72px;
  }
  .cp-sidebar { padding-right: 0; }
  .cp-sidebar-cta { padding: 18px 16px; }
}

/* ══════════════════════════════════════
   RESPONSIVE — MOBILE (< 768px)
   Header & mob-bar: cart/kategori pattern
   ══════════════════════════════════════ */
@media (max-width: 768px) {
  /* Hide desktop nav on mobile */
  .cp-body .site-header.site-header--solid .nav-links,
  .cp-body .site-header.site-header--solid .nav-actions,
  .cp-body .site-header.site-header--solid .menu-toggle {
    display: none !important;
  }

  /* Header bar: başlangıçta şeffaf — kaydırınca page bg + ince border + progress */
  .cp-body .site-header.site-header--solid {
    background: transparent !important;
    box-shadow: none !important;
    border: none !important;
    transition: background 0.25s ease;
  }

  .cp-body .site-header.site-header--solid .main-nav {
    position: relative;
    min-height: 60px;
    justify-content: flex-start;
    align-items: flex-start;
    gap: 0.55rem;
    background: transparent !important;
    box-shadow: none !important;
    border: none !important;
    backdrop-filter: none !important;
    padding: 0 0 0 var(--page-gutter, 16px);
    transition: background-color 0.25s ease;
  }

  /* Mobilde varsayılan üst progress bar gizli (scrolled state'te header altında belirir) */
  .cp-progress { display: none; }

  /* ── Scrolled state ── */
  /* Brand 60px yüksekliğinde ve clip-path %86 → kısa kenar ~52px.
     Header altı border ve progress bar tam bu hizada belirir.
     Header self bg saydam tutulur; sadece nav 0-52px arası beyaz dolar →
     progress bar (z-index 70, header z-index 80) brand'in altında kalır,
     brand'ın sağ tarafında ise nav transparan olduğu için görünür. */
  .cp-body.cp-scrolled .site-header.site-header--solid {
    background: transparent !important;
    -webkit-backdrop-filter: none !important;
    backdrop-filter: none !important;
  }

  .cp-body.cp-scrolled .site-header.site-header--solid .main-nav {
    background: linear-gradient(
      to bottom,
      #ffffff 0,
      #ffffff 52px,
      transparent 52px,
      transparent 100%
    ) !important;
  }

  /* Border line tam 52px'de (brand'in clip kısa kenarı hizası) */
  .cp-body.cp-scrolled .site-header.site-header--solid .main-nav::after {
    content: '';
    position: absolute;
    top: 52px;
    left: 0;
    right: 0;
    height: 1px;
    background: var(--cp-line);
    pointer-events: none;
  }

  /* Reading progress bar: kısa kenar hizasında, border'ın üzerinde ince çubuk.
     z-index header'ın altında → siyah brand div progress'in üzerinde kalır */
  .cp-body.cp-scrolled .cp-progress {
    display: block;
    position: fixed;
    top: 52px;
    left: 0;
    right: 0;
    height: 2px;
    z-index: 70; /* header z-index'inden düşük → brand üstte */
    background: transparent;
  }

  .cp-body.cp-scrolled .cp-progress .cp-progress-bar {
    height: 100%;
    background: linear-gradient(90deg, #111 0%, #444 100%);
    transition: width 0.08s ease-out;
  }

  /* Black brand container with angled clip (cart pattern) */
  .cp-body .site-header.site-header--solid .brand {
    margin: 0;
    position: relative !important;
    display: inline-flex;
    align-items: center;
    flex-shrink: 0;
    padding: 10px var(--brand-plate-pad-x, 0px) 14px;
    background: var(--brand-900, #0a1f19) !important;
    border-radius: 0;
    box-shadow: none;
    overflow: hidden;
    opacity: 1 !important;
    pointer-events: auto !important;
    clip-path: polygon(0% 0%, 100% 0%, 100% 86%, 0% 100%);
  }

  .cp-body .site-header.site-header--solid .brand-logo::before {
    background-color: #fff !important;
  }

  /* Mobile header meta (breadcrumb + başlık) — brand'in 52px kısa kenarında ortala */
  .cp-mobile-meta {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-self: stretch;
    flex: 1;
    min-width: 0;
    margin-left: 0.7rem;
    line-height: 1.1;
    gap: 3px;
    padding-bottom: 12px; /* 60px nav, içerik 52px görünür kısımda ortalı */
  }

  .cp-mobile-crumb {
    display: flex;
    align-items: center;
    gap: 5px;
    font-size: 10px;
    color: var(--cp-text-faint);
    line-height: 1;
    min-width: 0;
  }

  .cp-mobile-crumb-link {
    color: var(--cp-text-muted);
    text-decoration: none;
    font-weight: 500;
    transition: color 0.15s ease;
    white-space: nowrap;
  }

  .cp-mobile-crumb-link:hover { color: var(--cp-text); }

  .cp-mobile-crumb-text {
    color: var(--cp-text);
    font-weight: 600;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    min-width: 0;
  }

  .cp-mobile-crumb-sep {
    color: var(--cp-text-faint);
    flex-shrink: 0;
  }

  .cp-mobile-meta-title {
    margin: 0;
    font-family: var(--cp-font-display);
    font-size: 14px;
    font-weight: 700;
    color: var(--cp-text);
    letter-spacing: -0.015em;
    line-height: 1.2;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
  }

  /* Mob-bar: zemin/ikon rengi style.css'teki tek tip çubuktan gelir */

  /* Hero — tighter (mobilde başlık/eyebrow/breadcrumb header'a taşındı) */
  .cp-hero {
    padding-top: calc(60px + 18px);
    padding-bottom: 24px;
  }
  .cp-breadcrumb,
  .cp-hero-eyebrow,
  .cp-hero-title,
  .cp-hero-lead { display: none; }
  .cp-hero-meta { gap: 10px; font-size: 11.5px; }

  /* Layout → single column */
  .cp-layout {
    grid-template-columns: 1fr;
    gap: 0;
    padding: 0 0 80px;
  }

  /* Hide sidebar, show dropdown */
  .cp-sidebar { display: none; }

  .cp-mobile-select {
    display: block;
    padding: 20px 18px 4px;
  }

  .cp-mobile-select-label {
    display: block;
    font-family: var(--cp-font-display);
    font-size: 10px;
    font-weight: 700;
    letter-spacing: 0.16em;
    text-transform: uppercase;
    color: var(--cp-text-faint);
    margin-bottom: 8px;
  }

  .cp-mobile-select-wrap {
    position: relative;
  }

  .cp-page-select {
    width: 100%;
    padding: 13px 40px 13px 14px;
    font-family: var(--cp-font-display);
    font-size: 13px;
    font-weight: 600;
    color: var(--cp-text);
    background: var(--cp-bg-soft);
    border: 1px solid var(--cp-line);
    border-radius: 10px;
    appearance: none;
    -webkit-appearance: none;
    cursor: pointer;
    transition: border-color 0.2s;
  }

  .cp-page-select:focus {
    outline: none;
    border-color: var(--cp-text);
  }

  .cp-select-icon {
    position: absolute;
    right: 14px;
    top: 50%;
    transform: translateY(-50%);
    pointer-events: none;
    color: var(--cp-text-muted);
  }

  /* Content */
  .cp-content { padding: 24px 18px 0; }

  .cp-section { padding: 24px 0 26px; }
  .cp-section:first-child { padding-top: 0; }

  .cp-content-footer { flex-direction: column; align-items: stretch; padding: 18px; }
  .cp-content-footer-actions { justify-content: flex-start; }

  .cp-related-grid { grid-template-columns: 1fr; }

  .cp-contact-card { padding: 18px; }
  .cp-contact-head { gap: 12px; }

  .cp-fab-top { bottom: 76px; right: 16px; width: 40px; height: 40px; font-size: 16px; }

  .cp-footer { padding-bottom: 84px; }

  /* Mob bar */
  .cp-mobbar-default {
    display: flex;
    align-items: center;
    justify-content: space-around;
    width: 100%;
    min-height: var(--mob-bar-content-height, 58px);
  }
}

/* ══════════════════════════════════════
   PRINT
   ══════════════════════════════════════ */
@media print {
  .site-header, .cp-sidebar, .cp-toc, .cp-mobile-select,
  .cp-fab-top, .cp-footer, .mob-bar,
  .cp-content-footer-actions, .cp-related, .cp-progress { display: none !important; }
  .cp-hero { padding-top: 0; background: none; border: none; }
  .cp-hero::before { display: none; }
  .cp-layout { display: block; padding: 0; }
  .cp-section { page-break-inside: avoid; }
  .cp-body-text { font-size: 11pt; line-height: 1.6; color: #000; }
  .cp-body-text h2 { color: #000; }
  a { color: #000 !important; text-decoration: underline; }
}

/* ══════════════════════════════════════
   REDUCED MOTION
   ══════════════════════════════════════ */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    transition-duration: 0.01ms !important;
  }
}
