/* ClipBlend blog — mirrors landing design tokens; loaded only on /blog pages. */
* {
  box-sizing: border-box;
}

:root {
  --bg: #0c0b10;
  --surface: #17151e;
  --surface-2: #1c1a25;
  --ink: #f3f1f7;
  --body: #b4aec0;
  --muted: #837c91;
  --border: rgba(255, 255, 255, 0.1);
  --border-strong: rgba(255, 255, 255, 0.2);
  --accent: #7c3aed;
  --accent-soft: #a78bfa;
  --tint: rgba(139, 92, 246, 0.16);
  --tint-strong: rgba(124, 58, 237, 0.22);
  --nav-bg: rgba(12, 11, 16, 0.82);
  --btn-bg: #f3f1f7;
  --btn-fg: #15131a;
  --soft-shadow: 0 6px 22px -12px rgba(0, 0, 0, 0.6);
  --card-shadow: 0 18px 50px -26px rgba(0, 0, 0, 0.75);
}

html {
  background: var(--bg);
  scroll-padding-top: 88px;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: 'Hanken Grotesk', system-ui, sans-serif;
  -webkit-font-smoothing: antialiased;
  line-height: 1.5;
  overflow-x: hidden;
}

a {
  color: inherit;
  text-decoration: none;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  backdrop-filter: blur(14px);
  background: var(--nav-bg);
  border-bottom: 1px solid var(--border);
}

.site-nav {
  position: relative;
  max-width: 1200px;
  margin: 0 auto;
  padding: 14px 26px;
  display: flex;
  align-items: center;
  gap: 16px;
}

.site-nav__brand {
  display: flex;
  align-items: center;
  gap: 5px;
  flex-shrink: 0;
}

.site-nav__logo-img {
  width: 38px;
  height: 38px;
  border-radius: 11px;
  display: block;
  flex-shrink: 0;
  object-fit: cover;
}

.site-nav__brand-text {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
}

.site-nav__logo-text {
  font-weight: 800;
  font-size: 16px;
  line-height: 1.1;
  letter-spacing: -0.02em;
  color: var(--ink);
}

.site-nav__logo-accent,
.accent {
  color: var(--accent);
}

.site-nav__tagline {
  font-size: 10px;
  line-height: 1.25;
  color: var(--body);
  opacity: 0.72;
}

.site-nav__panel {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 2px;
  flex-wrap: wrap;
}

.site-nav__link {
  padding: 8px 13px;
  border-radius: 9px;
  font-size: 14.5px;
  font-weight: 500;
  color: var(--body);
  white-space: nowrap;
  transition:
    color 0.15s ease,
    background 0.15s ease;
}

.site-nav__link:hover,
.site-nav__link.is-active {
  color: var(--ink);
  background: var(--tint);
}

.site-nav__actions {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-shrink: 0;
}

.site-nav__cta {
  padding: 10px 18px;
  border-radius: 11px;
  font-size: 14.5px;
  font-weight: 700;
  color: var(--btn-fg);
  background: var(--btn-bg);
  white-space: nowrap;
  transition: opacity 0.15s ease;
}

.site-nav__cta:hover {
  opacity: 0.92;
}

.site-nav__menu-toggle {
  display: none;
  width: 40px;
  height: 40px;
  border-radius: 10px;
  border: 1px solid var(--border);
  background: transparent;
  color: var(--body);
  cursor: pointer;
  padding: 0;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.site-nav__menu-toggle:hover {
  color: var(--ink);
  border-color: var(--border-strong);
}

.site-nav__menu-icon {
  position: relative;
  display: block;
  width: 18px;
  height: 2px;
  background: currentColor;
  border-radius: 1px;
  transition: background 0.2s ease;
}

.site-nav__menu-icon::before,
.site-nav__menu-icon::after {
  content: '';
  position: absolute;
  left: 0;
  width: 18px;
  height: 2px;
  background: currentColor;
  border-radius: 1px;
  transition:
    transform 0.2s ease,
    top 0.2s ease;
}

.site-nav__menu-icon::before {
  top: -6px;
}

.site-nav__menu-icon::after {
  top: 6px;
}

.site-nav__menu-toggle.is-open .site-nav__menu-icon {
  background: transparent;
}

.site-nav__menu-toggle.is-open .site-nav__menu-icon::before {
  top: 0;
  transform: rotate(45deg);
}

.site-nav__menu-toggle.is-open .site-nav__menu-icon::after {
  top: 0;
  transform: rotate(-45deg);
}

@media (max-width: 890px) {
  .site-nav {
    flex-wrap: nowrap;
    padding: 12px 16px;
  }

  .site-nav__menu-toggle {
    display: flex;
  }

  .site-nav__panel {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    flex-direction: column;
    align-items: stretch;
    gap: 4px;
    padding: 12px 20px 18px;
    background: var(--nav-bg);
    border-bottom: 1px solid var(--border);
    backdrop-filter: blur(14px);
    box-shadow: var(--soft-shadow);
  }

  .site-nav__panel.is-open {
    display: flex;
  }

  .site-nav__link {
    padding: 12px 14px;
    font-size: 15px;
  }

  .site-nav__actions {
    margin-left: auto;
  }

  .site-nav__brand {
    min-width: 0;
    flex: 1;
  }

  .site-nav__tagline {
    display: block;
    font-size: clamp(8px, 2.4vw, 10px);
    line-height: 1.2;
  }

  .site-nav__cta {
    padding: 10px 14px;
    font-size: 13px;
  }
}

.blog-main {
  max-width: 1200px;
  margin: 0 auto;
  padding: clamp(28px, 5vw, 72px) clamp(16px, 4vw, 26px) 80px;
  overflow-x: clip;
}

.blog-index-header {
  max-width: 640px;
  margin: 0 0 40px;
}

.blog-eyebrow {
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--accent);
  margin: 0 0 14px;
}

.blog-eyebrow a {
  color: var(--accent);
}

.blog-eyebrow a:hover {
  text-decoration: underline;
}

.blog-index-header h1,
.article-header h1 {
  font-family: 'Newsreader', serif;
  font-weight: 500;
  font-size: clamp(28px, 6.5vw, 48px);
  line-height: 1.15;
  letter-spacing: -0.02em;
  margin: 0 0 18px;
  color: var(--ink);
  overflow-wrap: anywhere;
  hyphens: auto;
}

.blog-intro,
.article-dek {
  font-size: clamp(16px, 2.4vw, 18px);
  line-height: 1.7;
  color: var(--body);
  margin: 0;
}

.blog-grid {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: 1fr;
  gap: 20px;
  align-items: start;
}

.blog-card {
  display: flex;
  flex-direction: column;
  border-radius: 18px;
  background: var(--surface);
  border: 1px solid var(--border);
  box-shadow: var(--soft-shadow);
  overflow: hidden;
  transition: border-color 0.15s ease;
  color: inherit;
  text-decoration: none;
  min-width: 0;
}

.blog-card:hover {
  border-color: var(--border-strong);
}

.blog-card__media {
  width: 100%;
  aspect-ratio: 16 / 9;
  overflow: hidden;
  flex-shrink: 0;
  background: #110f18;
}

.blog-card__image {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: contain;
  object-position: center;
}

.blog-card__body {
  padding: 16px 16px 18px;
  display: flex;
  flex-direction: column;
  gap: 6px;
  min-width: 0;
}

.blog-card__date {
  font-size: 12.5px;
  color: var(--muted);
}

.blog-card__title {
  font-size: 18px;
  font-weight: 700;
  line-height: 1.3;
  margin: 0;
  color: var(--ink);
  overflow-wrap: anywhere;
}

.blog-card__desc {
  font-size: 14px;
  line-height: 1.5;
  color: var(--body);
  margin: 0;
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 3;
  overflow: hidden;
}

/* 2 columns on tablet / typical laptop widths. */
@media (min-width: 640px) {
  .blog-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 20px;
  }

  .blog-card__media {
    /* Cap image height so cards stay compact;
       contain keeps the full 16:9 cover (all three phones) visible. */
    aspect-ratio: 16 / 9;
    max-height: 168px;
  }

  .blog-card__body {
    padding: 16px 18px 18px;
    gap: 5px;
  }

  .blog-card__title {
    font-size: 18px;
  }

  .blog-card__desc {
    font-size: 13.5px;
    line-height: 1.45;
  }
}

/* 3 columns on large desktop. Incomplete rows keep normal column width. */
@media (min-width: 1100px) {
  .blog-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 22px;
  }

  .blog-card__media {
    max-height: 148px;
  }

  .blog-card__body {
    padding: 16px 16px 18px;
  }

  .blog-card__title {
    font-size: 18px;
  }

  .blog-card__desc {
    font-size: 13px;
  }
}

.blog-empty {
  padding: 40px 28px;
  border-radius: 18px;
  background: var(--surface);
  border: 1px solid var(--border);
  text-align: center;
}

.blog-empty h2 {
  margin: 0 0 10px;
  font-size: 22px;
}

.blog-empty p {
  margin: 0;
  color: var(--body);
}

.blog-empty a {
  color: var(--accent);
  text-decoration: underline;
}

.article {
  max-width: 680px;
  margin: 0 auto;
}

.article-header {
  margin-bottom: 8px;
}

.article-meta {
  font-size: 14px;
  color: var(--muted);
  margin: 0 0 14px;
}

.article-featured {
  margin: 28px 0 32px;
  border-radius: 16px;
  overflow: hidden;
  border: 1px solid var(--border);
  aspect-ratio: 1200 / 630;
  background: var(--surface);
}

.article-featured img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.article-body {
  font-size: clamp(16px, 2.2vw, 17.5px);
  line-height: 1.7;
  color: var(--body);
  margin-top: 28px;
}

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

.article-body h2 {
  font-family: 'Newsreader', serif;
  font-weight: 500;
  font-size: clamp(24px, 4.5vw, 32px);
  line-height: 1.25;
  letter-spacing: -0.015em;
  color: var(--ink);
  margin: 2.6em 0 0.8em;
  padding-top: 0.35em;
  padding-left: 14px;
  border-left: 3px solid var(--accent);
  scroll-margin-top: 88px;
  overflow-wrap: anywhere;
}

.article-body h2:first-of-type {
  margin-top: 1.75em;
}

.article-body h3:not(.article-method) {
  font-size: clamp(1.05rem, 2.8vw, 1.2rem);
  font-weight: 700;
  line-height: 1.35;
  color: var(--accent-soft);
  margin: 1.85em 0 0.55em;
  scroll-margin-top: 88px;
  overflow-wrap: anywhere;
}

.article-body h4 {
  font-size: 1.02rem;
  font-weight: 700;
  color: var(--ink);
  margin: 1.5em 0 0.5em;
}

.article-body p {
  margin: 0 0 1.2em;
}

.article-body a {
  color: var(--accent-soft);
  text-decoration: underline;
  text-underline-offset: 2px;
  text-decoration-thickness: 1px;
}

.article-body a:hover {
  color: #c4b5fd;
}

.article-body ul,
.article-body ol {
  margin: 0 0 1.35em;
  padding-left: 1.3em;
}

.article-body li {
  margin-bottom: 0.7em;
  padding-left: 0.15em;
}

.article-body li::marker {
  color: var(--accent-soft);
}

.article-body li strong {
  color: var(--ink);
  font-weight: 700;
}

.article-body blockquote {
  margin: 0 0 1.4em;
  padding: 12px 16px;
  border-left: 3px solid var(--accent);
  background: var(--tint);
  border-radius: 0 12px 12px 0;
  color: var(--ink);
}

.article-body img {
  display: block;
  max-width: 100%;
  height: auto;
  margin: 1.6em auto;
  border-radius: 12px;
  border: 1px solid var(--border);
}

/* Portrait app screenshots — large enough to inspect UI, no overflow.
   Aspect ratio comes from intrinsic width/height attrs (per-image). */
.article-body img.article-screenshot {
  width: 100%;
  max-width: min(100%, 420px);
  height: auto;
  margin-left: auto;
  margin-right: auto;
  object-fit: contain;
  background: var(--surface);
}

.article-body pre {
  overflow-x: auto;
  padding: 16px 18px;
  border-radius: 12px;
  background: var(--surface);
  border: 1px solid var(--border);
  font-size: 0.9em;
  margin: 0 0 1.25em;
  max-width: 100%;
}

.article-body code {
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 0.92em;
}

.article-body :not(pre) > code {
  padding: 0.15em 0.4em;
  border-radius: 6px;
  background: var(--tint);
  color: var(--ink);
}

/* —— Table of contents —— */
.article-toc {
  margin: 0 0 2em;
}

.article-toc__panel {
  border: 1px solid rgba(124, 58, 237, 0.45);
  background: linear-gradient(180deg, rgba(124, 58, 237, 0.12), rgba(23, 21, 30, 0.9));
  border-radius: 14px;
  padding: 0;
  overflow: hidden;
}

.article-toc__summary {
  cursor: pointer;
  list-style: none;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 14px 16px;
  font-size: 14px;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--ink);
  min-height: 44px;
}

.article-toc__summary::-webkit-details-marker {
  display: none;
}

.article-toc__summary::after {
  content: '';
  width: 8px;
  height: 8px;
  border-right: 2px solid var(--accent-soft);
  border-bottom: 2px solid var(--accent-soft);
  transform: rotate(45deg);
  transition: transform 0.15s ease;
  flex-shrink: 0;
}

.article-toc__panel[open] > .article-toc__summary::after {
  transform: rotate(-135deg);
  margin-top: 4px;
}

.article-toc__list {
  --toc-font-size: 15px;
  --toc-line-height: 1.45;
  margin: 0;
  padding: 0 16px 16px;
  list-style: none;
  counter-reset: toc-item;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.article-toc__list li {
  counter-increment: toc-item;
  display: flex;
  align-items: flex-start;
  gap: 10px;
}

.article-toc__list li::before {
  content: counter(toc-item) ".";
  flex: 0 0 auto;
  min-width: 1.35em;
  margin-top: 2px;
  font-size: var(--toc-font-size);
  font-weight: 600;
  line-height: var(--toc-line-height);
  color: var(--accent-soft);
  text-align: right;
  font-variant-numeric: tabular-nums;
}

.article-toc__list a {
  flex: 1;
  min-width: 0;
  color: var(--accent-soft);
  text-decoration: none;
  font-size: var(--toc-font-size);
  font-weight: 500;
  line-height: var(--toc-line-height);
  text-transform: none;
  letter-spacing: 0;
  padding: 2px 0;
  overflow-wrap: anywhere;
}

.article-toc__list a:hover,
.article-toc__list a:focus-visible {
  color: #c4b5fd;
  text-decoration: underline;
  outline: none;
}

/* —— Light notes (Best for) —— */
.article-note {
  margin: 0 0 0.85em;
  padding: 10px 0 10px 12px;
  border-left: 2px solid rgba(167, 139, 250, 0.45);
  color: var(--body);
  font-size: 0.95em;
  line-height: 1.55;
}

.article-note__label {
  display: inline;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--accent-soft);
  margin-right: 6px;
}

/* —— Strong callouts (Limitation) —— */
.article-callout {
  margin: 0 0 1.15em;
  padding: 12px 14px;
  border-radius: 12px;
  border: 1px solid rgba(124, 58, 237, 0.4);
  background: rgba(124, 58, 237, 0.12);
}

.article-callout--limit {
  border-color: rgba(167, 139, 250, 0.35);
  background: rgba(23, 21, 30, 0.95);
}

.article-callout__label {
  margin: 0 0 4px;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--accent-soft);
}

.article-callout__text {
  margin: 0;
  font-size: 0.95em;
  line-height: 1.55;
  color: var(--ink);
}

.article-note + .article-callout {
  margin-top: 0.15em;
}

.article-callout + .article-method,
.article-callout + h3 {
  margin-top: 2.1em;
}

/* —— Play Store CTA —— */
.article-cta {
  margin: 1.75em 0 2em;
  padding: 20px 18px;
  border-radius: 16px;
  border: 1px solid rgba(124, 58, 237, 0.45);
  background: rgba(124, 58, 237, 0.1);
}

.article-cta__title {
  margin: 0 0 8px;
  font-family: 'Newsreader', serif;
  font-weight: 500;
  font-size: clamp(1.25rem, 3.5vw, 1.45rem);
  line-height: 1.25;
  letter-spacing: -0.015em;
  color: var(--ink);
}

.article-cta__text {
  margin: 0 0 16px;
  font-size: 0.95em;
  line-height: 1.55;
  color: var(--body);
}

.article-cta__button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  padding: 12px 20px;
  border-radius: 12px;
  background: #7c3aed;
  color: #ffffff !important;
  font-size: 15.5px;
  font-weight: 700;
  line-height: 1.2;
  text-decoration: none !important;
  text-align: center;
  border: 1px solid transparent;
  transition:
    background 0.15s ease,
    outline-offset 0.15s ease;
}

.article-cta__button:hover {
  background: #6d28d9;
  color: #ffffff !important;
}

.article-cta__button:focus-visible {
  outline: 2px solid #c4b5fd;
  outline-offset: 3px;
}

@media (max-width: 720px) {
  .article-cta__button {
    width: 100%;
  }
}

@media (prefers-reduced-motion: reduce) {
  .article-cta__button {
    transition: none;
  }
}

/* —— Numbered method headings —— */
.article-method {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  margin: 2.35em 0 0.75em;
  scroll-margin-top: 88px;
}

.article-method__num {
  flex: 0 0 auto;
  width: 28px;
  height: 28px;
  margin-top: 1px;
  border-radius: 9px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 13px;
  font-weight: 800;
  color: #fff;
  background: var(--accent);
  line-height: 1;
}

.article-method__title {
  flex: 1;
  min-width: 0;
  font-size: clamp(1.08rem, 3vw, 1.25rem);
  font-weight: 700;
  line-height: 1.35;
  color: var(--accent-soft);
  overflow-wrap: anywhere;
}

/* —— Comparison table / mobile cards —— */
.article-compare,
.article-table-wrap {
  margin: 0 0 1.6em;
  max-width: 100%;
}

.article-compare__table,
.article-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.95em;
}

.article-compare__table th,
.article-compare__table td,
.article-table th,
.article-table td {
  text-align: left;
  vertical-align: top;
  padding: 12px 14px;
  border: 1px solid var(--border);
}

.article-compare__table th,
.article-table th {
  background: var(--surface);
  color: var(--ink);
  font-weight: 700;
}

.article-compare__table td,
.article-table td {
  color: var(--body);
}

.article-compare__method {
  color: var(--ink);
  font-weight: 700;
}

@media (max-width: 720px) {
  .article-compare__table thead {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
  }

  .article-compare__table,
  .article-compare__table tbody {
    display: block;
    width: 100%;
  }

  .article-compare__row {
    display: block;
    margin: 0 0 12px;
    padding: 14px 16px;
    border: 1px solid rgba(124, 58, 237, 0.35);
    border-radius: 14px;
    background: var(--surface);
  }

  .article-compare__row td {
    display: block;
    border: 0;
    padding: 0 0 12px;
  }

  .article-compare__row td:last-child {
    padding-bottom: 0;
  }

  .article-compare__row td::before {
    content: attr(data-label);
    display: block;
    margin-bottom: 4px;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--accent-soft);
  }

  .article-compare__method {
    font-size: 1.05rem;
    color: var(--ink);
    padding-bottom: 14px;
    margin-bottom: 4px;
    border-bottom: 1px solid var(--border);
  }

  .article-table-wrap {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
  }
}

@media (prefers-reduced-motion: reduce) {
  .article-toc__summary::after {
    transition: none;
  }
}

.site-footer {
  border-top: 1px solid var(--border);
  background: var(--surface);
}

.site-footer__top {
  max-width: 1200px;
  margin: 0 auto;
  padding: 48px 26px 40px;
  display: flex;
  flex-wrap: wrap;
  gap: 40px;
  justify-content: space-between;
}

.site-footer__brand-col {
  max-width: 340px;
}

.site-footer__brand {
  display: flex;
  align-items: center;
  gap: 5px;
  margin-bottom: 16px;
}

.site-footer__logo-img {
  width: 36px;
  height: 36px;
  border-radius: 11px;
  display: block;
  flex-shrink: 0;
  object-fit: cover;
}

.site-footer__brand-text {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
}

.site-footer__logo-text {
  font-weight: 800;
  font-size: 16px;
  line-height: 1.1;
  letter-spacing: -0.02em;
  color: var(--ink);
}

.site-footer__tagline {
  font-size: 10px;
  line-height: 1.25;
  color: var(--body);
  opacity: 0.72;
}

.site-footer__logo-accent {
  color: var(--accent);
}

.site-footer__desc {
  font-size: 14px;
  line-height: 1.6;
  color: var(--body);
  margin: 0 0 6px;
}

.site-footer__meta {
  font-size: 13px;
  line-height: 1.6;
  color: var(--muted);
  margin: 0 0 6px;
}

.site-footer__meta:last-child {
  margin-bottom: 0;
}

.site-footer__columns {
  display: flex;
  gap: 56px;
  flex-wrap: wrap;
}

.site-footer__heading {
  font-size: 12.5px;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--muted);
  margin: 0 0 14px;
}

.site-footer__col-links {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.site-footer__link {
  font-size: 14px;
  color: var(--body);
}

.site-footer__link:hover {
  color: var(--ink);
}

.site-footer__bottom-wrap {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 26px 36px;
}

.site-footer__bottom {
  border-top: 1px solid var(--border);
  padding-top: 24px;
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  justify-content: space-between;
  align-items: center;
}

.site-footer__legal {
  font-size: 13px;
  color: var(--muted);
  margin: 0;
}

/* —— Cookie consent (blog-only; shares localStorage with homepage) —— */
.cookie-modal {
  position: fixed;
  inset: 0;
  z-index: 200;
  display: grid;
  place-items: center;
  padding: 20px;
}

.cookie-modal__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(8, 7, 12, 0.72);
  backdrop-filter: blur(4px);
}

.cookie-modal__dialog {
  position: relative;
  width: min(100%, 520px);
  max-height: min(92vh, 760px);
  overflow: auto;
  padding: clamp(24px, 4vw, 32px);
  border-radius: 20px;
  background: var(--surface);
  border: 1px solid var(--border-strong);
  box-shadow: var(--card-shadow);
}

.cookie-modal__dialog--preferences {
  width: min(100%, 540px);
  max-height: 90vh;
  display: flex;
  flex-direction: column;
  padding: clamp(18px, 3vw, 24px);
  overflow: auto;
}

.cookie-modal__eyebrow {
  margin: 0 0 10px;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--accent);
}

.cookie-modal__title {
  margin: 0 0 12px;
  font-family: 'Newsreader', serif;
  font-weight: 500;
  font-size: clamp(24px, 4vw, 30px);
  line-height: 1.1;
  color: var(--ink);
}

.cookie-modal__text {
  margin: 0 0 22px;
  font-size: 15px;
  line-height: 1.65;
  color: var(--body);
}

.cookie-modal__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.cookie-modal__actions--stack {
  flex-direction: column;
}

.cookie-modal__button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 46px;
  padding: 12px 18px;
  border-radius: 12px;
  border: 1px solid transparent;
  font-family: inherit;
  font-size: 15px;
  font-weight: 700;
  cursor: pointer;
}

.cookie-modal__button--primary {
  color: #fff;
  background: linear-gradient(140deg, #6d28d9, #7c3aed);
  box-shadow: 0 12px 28px -12px rgba(109, 40, 217, 0.65);
}

.cookie-modal__button--secondary {
  color: var(--ink);
  background: var(--surface-2);
  border-color: var(--border-strong);
}

.cookie-modal__button--ghost {
  color: var(--body);
  background: transparent;
  border-color: var(--border);
}

.cookie-modal__button:hover {
  opacity: 0.94;
}

.cookie-modal__button:focus-visible {
  outline: 2px solid #c4b5fd;
  outline-offset: 2px;
}

.cookie-pref__list {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-bottom: 22px;
}

.cookie-pref__row {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  padding: 16px;
  border-radius: 14px;
  background: var(--surface-2);
  border: 1px solid var(--border);
}

.cookie-pref__copy {
  min-width: 0;
}

.cookie-pref__title {
  margin: 0 0 6px;
  font-size: 15px;
  font-weight: 700;
  color: var(--ink);
}

.cookie-pref__text {
  margin: 0;
  font-size: 13.5px;
  line-height: 1.55;
  color: var(--body);
}

.cookie-pref__control {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 8px;
  flex-shrink: 0;
  align-self: center;
}

.cookie-pref__status {
  flex-shrink: 0;
  padding: 4px 10px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 600;
  line-height: 1.3;
  color: var(--body);
  background: var(--surface);
  border: 1px solid var(--border);
  white-space: nowrap;
}

.cookie-pref__toggle {
  position: relative;
  flex-shrink: 0;
  width: 46px;
  height: 28px;
  cursor: pointer;
}

.cookie-pref__toggle input {
  position: absolute;
  opacity: 0;
  width: 0;
  height: 0;
}

.cookie-pref__toggle-ui {
  position: absolute;
  inset: 0;
  border-radius: 999px;
  background: var(--border-strong);
}

.cookie-pref__toggle-ui::after {
  content: '';
  position: absolute;
  top: 3px;
  left: 3px;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: #fff;
}

.cookie-pref__toggle input:checked + .cookie-pref__toggle-ui {
  background: linear-gradient(140deg, #6d28d9, #7c3aed);
}

.cookie-pref__toggle input:checked + .cookie-pref__toggle-ui::after {
  transform: translateX(18px);
}

.cookie-pref__toggle input:disabled + .cookie-pref__toggle-ui {
  opacity: 0.55;
  cursor: not-allowed;
}

.cookie-pref__sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.cookie-modal__legal-note {
  margin: 16px 0 0;
  font-size: 12.5px;
  line-height: 1.55;
  color: var(--muted);
  text-align: center;
}

.cookie-modal__legal-link {
  color: var(--accent);
  text-decoration: underline;
  text-underline-offset: 2px;
}

@media (max-width: 720px) {
  .cookie-modal {
    place-items: end center;
    padding: 12px;
  }

  .cookie-modal__dialog {
    width: 100%;
    max-height: min(88vh, 720px);
    border-radius: 18px 18px 14px 14px;
  }

  .cookie-pref__row {
    flex-direction: column;
    gap: 12px;
  }

  .cookie-pref__control {
    align-items: flex-start;
    flex-direction: row;
    flex-wrap: wrap;
  }
}
