:root{
  --tc-banner-bg:#fff;
  --tc-modal-bg:#fff;
  --tc-overlay:rgba(2,6,23,.58);
  --tc-title:#0f172a;
  --tc-text:#334155;
  --tc-label:#0f172a;
  --tc-border:#dbe3ee;
  --tc-muted-bg:#f8fafc;
  --tc-muted-text:#475569;
  --tc-focus:#1d4ed8;
  --tc-primary:#1d4ed8;
  --tc-secondary:#e2e8f0;
  --tc-btn-text:#fff;
  --tc-primary-hover:#1e40af;
  --tc-secondary-hover:#d4deeb;
  --tc-floating-hover:#111827;
  --tc-primary-hover-text:#fff;
  --tc-secondary-hover-text:#0f172a;
  --tc-floating-hover-text:#fff;
  --tc-title-size:1.35rem;
  --tc-text-size:.96rem;
  --tc-btn-size:.9rem;
  --tc-radius:18px;
  --tc-max-width:780px;
  --tc-padding:22px;
}

#tconsent-root{position:fixed;z-index:99999;font-family:Inter,system-ui,-apple-system,Segoe UI,Roboto,Arial,sans-serif;color:var(--tc-text);pointer-events:none}
.tconsent-lock-scroll{overflow:hidden}
#tconsent-root .tconsent-overlay{position:fixed;inset:0;background:var(--tc-overlay);backdrop-filter:blur(4px);z-index:1}

.tconsent-banner,
.tconsent-preferences{
  position:relative;
  z-index:2;
  background:var(--tc-banner-bg);
  border:1px solid var(--tc-border);
  border-radius:var(--tc-radius);
  box-shadow:0 24px 64px rgba(15,23,42,.2);
  padding:var(--tc-padding);
  max-width:var(--tc-max-width);
  margin:0 auto;
  pointer-events:auto;
}
.tconsent-preferences{background:var(--tc-modal-bg)}
.tconsent-preferences{display:flex;flex-direction:column;max-height:min(88vh,780px)}

.tconsent-banner-head h2,
.tconsent-preferences h3{
  margin:0;
  color:var(--tc-title);
  font-size:var(--tc-title-size);
  font-weight:700;
  line-height:1.2;
  letter-spacing:-.01em;
}
.tconsent-banner-head p,
.tconsent-pref-item p,
.tconsent-pref-description{
  font-size:var(--tc-text-size);
  line-height:1.55;
  color:var(--tc-text);
}
.tconsent-banner-head p{margin:10px 0 0}

.tconsent-learn-more{margin-top:14px;border:1px solid var(--tc-border);border-radius:12px;background:var(--tc-muted-bg);padding:10px 12px}
.tconsent-learn-more summary{cursor:pointer;color:var(--tc-title);font-weight:600;font-size:.88rem}
.tconsent-learn-more p{margin:8px 0 0;font-size:.86rem;color:var(--tc-muted-text)}

.tconsent-context{margin:14px 0 0;font-size:.76rem;color:#64748b}

.tconsent-pref-head{display:flex;align-items:flex-start;justify-content:space-between;gap:12px;margin-bottom:14px}
.tconsent-pref-close{appearance:none;border:1px solid var(--tc-border);background:#f8fafc;color:#1e293b;width:34px;height:34px;border-radius:999px;cursor:pointer;font-size:1.2rem;line-height:1;display:inline-flex;align-items:center;justify-content:center}
.tconsent-pref-close:hover,.tconsent-pref-close:focus-visible{background:#e2e8f0;outline:2px solid var(--tc-focus);outline-offset:2px}

.tconsent-pref-scroll{overflow:auto;min-height:0;padding-right:2px}
.tconsent-preference-list{display:grid;gap:10px}
.tconsent-pref-item{padding:14px;border:1px solid var(--tc-border);border-radius:14px;background:var(--tc-muted-bg)}
.tconsent-pref-item label{display:grid;grid-template-columns:22px 1fr;gap:10px;align-items:flex-start;color:var(--tc-label);margin:0}
.tconsent-pref-item input[type="checkbox"]{margin:2px 0 0;width:18px;height:18px;accent-color:#1d4ed8}
.tconsent-pref-item strong{display:block;font-size:.96rem;color:#0f172a}
.tconsent-pref-item small{display:block;margin-top:2px;font-size:.74rem;color:#64748b;text-transform:uppercase;letter-spacing:.03em}
.tconsent-pref-item p{margin:8px 0 0 32px;font-size:.88rem}

.tconsent-banner-actions{display:flex;flex-wrap:wrap;gap:10px;margin-top:16px}
.tconsent-pref-actions{position:sticky;bottom:0;background:linear-gradient(to top,var(--tc-modal-bg) 75%,rgba(255,255,255,0));padding-top:10px}
.tconsent-banner-actions .button,
.tconsent-pref-close,
.tconsent-floating{transition:all .18s ease}
.tconsent-banner-actions .button{
  font-size:var(--tc-btn-size);
  min-height:42px;
  border-radius:12px;
  padding:10px 14px;
  border:1px solid transparent;
  font-weight:600;
}
.tconsent-btn-neutral{background:#fff;border-color:var(--tc-border);color:#1e293b}
.tconsent-btn-equal{flex:1 1 180px}
.tconsent-btn-equal[data-tconsent-action="accept_all"]{background:var(--tc-primary);border-color:var(--tc-primary);color:var(--tc-btn-text)}
.tconsent-btn-equal[data-tconsent-action="reject_all"],
.tconsent-btn-equal[data-tconsent-action="save_preferences"]{background:#eff4fb;border-color:#c9d9f0;color:#1e3a8a}

.tconsent-btn-neutral:hover,.tconsent-btn-neutral:focus-visible{background:#f1f5f9;border-color:#cbd5e1;color:#0f172a;outline:none}
.tconsent-btn-equal[data-tconsent-action="accept_all"]:hover,
.tconsent-btn-equal[data-tconsent-action="accept_all"]:focus-visible{background:var(--tc-primary-hover);border-color:var(--tc-primary-hover);color:var(--tc-primary-hover-text);outline:none}
.tconsent-btn-equal[data-tconsent-action="reject_all"]:hover,
.tconsent-btn-equal[data-tconsent-action="reject_all"]:focus-visible,
.tconsent-btn-equal[data-tconsent-action="save_preferences"]:hover,
.tconsent-btn-equal[data-tconsent-action="save_preferences"]:focus-visible{background:#dbe8fa;border-color:#bcd0ed;color:#1e3a8a;outline:none}

.tconsent-floating{
  position:fixed;
  bottom:20px;
  right:20px;
  background:#0f172a;
  color:#fff;
  border:1px solid rgba(255,255,255,.2);
  border-radius:999px;
  min-height:44px;
  padding:8px 14px;
  cursor:pointer;
  box-shadow:0 14px 34px rgba(15,23,42,.35);
  z-index:3;
  display:inline-flex;
  align-items:center;
  gap:8px;
  font-size:.84rem;
  font-weight:600;
  pointer-events:auto;
}
.tconsent-floating:focus-visible,.tconsent-floating:hover{background:var(--tc-floating-hover);color:var(--tc-floating-hover-text);outline:none;transform:translateY(-1px)}
.tconsent-floating-icon{font-size:1rem;line-height:1}
.tconsent-floating-label{line-height:1.1}

.tconsent-preferences[hidden],.tconsent-overlay[hidden]{display:none}
.tconsent-position-bottom_center{left:16px;right:16px;bottom:16px}
.tconsent-position-bottom_left{left:16px;bottom:16px;right:auto;width:min(100% - 32px,var(--tc-max-width))}
.tconsent-position-bottom_right{right:16px;bottom:16px;left:auto;width:min(100% - 32px,var(--tc-max-width))}
.tconsent-position-top_bar,.tconsent-position-bottom_bar{left:0;right:0}
.tconsent-position-top_bar{top:0}
.tconsent-position-bottom_bar{bottom:0}
.tconsent-position-top_bar .tconsent-banner,.tconsent-position-bottom_bar .tconsent-banner{border-radius:0;max-width:none}
.tconsent-position-center_modal{inset:0;display:flex;align-items:center;justify-content:center;padding:16px}
.tconsent-position-center_modal .tconsent-banner{display:block}
.tconsent-position-center_modal .tconsent-preferences{display:none}
.tconsent-position-center_modal .tconsent-preferences:not([hidden]){display:block}

@media (max-width: 700px){
  #tconsent-root{left:8px!important;right:8px!important;bottom:8px!important;top:auto}
  .tconsent-banner,.tconsent-preferences{padding:16px;border-radius:14px}
  .tconsent-preferences{
    max-height:min(100dvh - 16px, calc(100vh - 16px));
    min-height:min(70dvh, 540px);
  }
  .tconsent-pref-head{position:sticky;top:0;background:var(--tc-modal-bg);z-index:5;padding-bottom:8px}
  .tconsent-pref-actions{position:sticky;bottom:0;background:var(--tc-modal-bg);padding-bottom:2px;z-index:5}
  .tconsent-banner-actions .button{flex:1;min-width:100%}
  .tconsent-pref-item{padding:12px}
  .tconsent-pref-item p{margin-left:0}
  .tconsent-floating-label{display:none}
  .tconsent-floating{width:46px;justify-content:center;padding:0}
}
