/* SEO AI + Cork horizontal-light-menu bridge v2 */
:root {
  --seo-cork-brand: #4361ee;
  --seo-cork-brand-dark: #3b55d9;
  --seo-cork-ink: #0e1726;
  --seo-cork-muted: #888ea8;
  --seo-cork-border: #e0e6ed;
  --seo-cork-surface: #f1f2f3;
  --seo-cork-card: #ffffff;
  --seo-cork-shadow: 0 1px 2px rgba(14, 23, 38, 0.04), 0 6px 18px rgba(14, 23, 38, 0.06);
}

body.seoai-cork {
  font-family: "Montserrat", system-ui, sans-serif !important;
  background: var(--seo-cork-surface) !important;
  background-image: none !important;
  color: #515365 !important;
}
body.seoai-cork #root {
  min-height: 100vh;
}
#load_screen {
  display: none !important;
}

/* ——— Shell ——— */
.seoai-cork-shell .header-container {
  position: sticky;
  top: 0;
  z-index: 100;
  background: transparent;
}
.seoai-cork-shell .header.navbar {
  background: var(--seo-cork-card);
  border-bottom: 1px solid var(--seo-cork-border);
  box-shadow: 0 4px 12px rgba(14, 23, 38, 0.04);
  min-height: 68px;
  padding: 0.65rem 1.5rem;
  display: flex;
  align-items: center;
  gap: 1rem;
}
.seoai-cork-shell .theme-brand {
  display: flex;
  align-items: center;
  gap: 0.7rem;
  list-style: none;
  margin: 0;
  padding: 0;
}
.seoai-cork-shell .theme-text a {
  font-weight: 700;
  font-size: 1.1rem;
  letter-spacing: -0.02em;
  color: var(--seo-cork-ink);
  text-decoration: none;
}
.seoai-cork-shell .navbar-logo {
  height: 30px;
  width: auto;
}
.seoai-cork-shell .seoai-topnav {
  display: flex;
  flex-wrap: wrap;
  gap: 0.25rem;
  margin-left: 1.25rem;
  flex: 1;
}
.seoai-cork-shell .seoai-topnav a {
  padding: 0.5rem 0.95rem;
  border-radius: 8px;
  font-size: 0.82rem;
  font-weight: 600;
  color: #506690;
  text-decoration: none;
  transition: background 0.15s, color 0.15s;
}
.seoai-cork-shell .seoai-topnav a.active,
.seoai-cork-shell .seoai-topnav a:hover {
  background: rgba(67, 97, 238, 0.12);
  color: var(--seo-cork-brand);
}
.seoai-cork-shell .seoai-userbox {
  margin-left: auto;
  display: flex;
  align-items: center;
  gap: 0.85rem;
  font-size: 0.78rem;
  color: var(--seo-cork-muted);
}
.seoai-cork-shell .seoai-main {
  padding: 1.5rem 1.5rem 2.5rem;
  max-width: 1440px;
  margin: 0 auto;
}

/* ——— Auth ——— */
.seoai-auth-cover {
  min-height: 100vh;
  display: grid;
  place-items: center;
  padding: 2rem 1rem;
  background:
    linear-gradient(135deg, rgba(67, 97, 238, 0.88), rgba(67, 97, 238, 0.55)),
    url("/cork/src/assets/img/pages/auth/bg-auth.jpg") center / cover no-repeat;
}
.seoai-auth-card {
  width: 100%;
  max-width: 440px;
  background: #fff;
  border-radius: 14px;
  padding: 2.1rem 2rem 2rem;
  box-shadow: 0 18px 50px rgba(14, 23, 38, 0.22);
}
.seoai-auth-card h1 {
  font-size: 1.55rem;
  font-weight: 700;
  color: var(--seo-cork-ink);
  margin: 0 0 0.35rem;
}
.seoai-auth-card .seoai-auth-sub {
  color: var(--seo-cork-muted);
  font-size: 0.9rem;
  margin-bottom: 1.35rem;
}

/* ——— Cards / panels (Tailwind Panel → Cork widget) ——— */
body.seoai-cork section.rounded-2xl,
body.seoai-cork .rounded-2xl.border.border-slate-200\/80,
body.seoai-cork section[class*="rounded-2xl"] {
  background: var(--seo-cork-card) !important;
  border: 1px solid var(--seo-cork-border) !important;
  border-radius: 12px !important;
  box-shadow: var(--seo-cork-shadow) !important;
  padding: 1.35rem 1.4rem !important;
}
body.seoai-cork section h2 {
  font-size: 1.05rem !important;
  font-weight: 700 !important;
  color: var(--seo-cork-ink) !important;
  letter-spacing: -0.01em;
}
body.seoai-cork header h1 {
  font-size: 1.65rem !important;
  font-weight: 700 !important;
  color: var(--seo-cork-ink) !important;
  letter-spacing: -0.02em;
}

/* ——— Forms ——— */
body.seoai-cork .field {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
  font-size: 0.78rem;
  font-weight: 600;
  color: #3b3f5c;
  margin-bottom: 0.15rem;
}
body.seoai-cork .field input,
body.seoai-cork .field select,
body.seoai-cork .field textarea {
  width: 100%;
  border: 1px solid var(--seo-cork-border) !important;
  border-radius: 8px !important;
  background: #fff !important;
  padding: 0.7rem 0.85rem !important;
  font-size: 0.875rem !important;
  font-weight: 500 !important;
  color: var(--seo-cork-ink) !important;
  font-family: inherit !important;
  box-shadow: none !important;
  transition: border-color 0.15s, box-shadow 0.15s;
}
body.seoai-cork .field input:focus,
body.seoai-cork .field select:focus,
body.seoai-cork .field textarea:focus {
  border-color: var(--seo-cork-brand) !important;
  box-shadow: 0 0 0 3px rgba(67, 97, 238, 0.15) !important;
  outline: none !important;
}
body.seoai-cork .field textarea.min-h-80,
body.seoai-cork .field textarea[rows="18"] {
  min-height: 22rem;
  line-height: 1.55 !important;
  font-family: ui-monospace, "IBM Plex Mono", Menlo, monospace !important;
  font-size: 0.8rem !important;
  background: #fafbfc !important;
}

/* Editor form: tighter rhythm */
body.seoai-cork form.space-y-4 > * + * {
  margin-top: 0.95rem !important;
}
body.seoai-cork .grid.gap-6 {
  gap: 1.25rem !important;
}

/* ——— Buttons ——— */
body.seoai-cork button.bg-brand,
body.seoai-cork button[class*="bg-brand"] {
  background: var(--seo-cork-brand) !important;
  border: none !important;
  color: #fff !important;
  border-radius: 8px !important;
  font-weight: 600 !important;
  box-shadow: 0 4px 10px rgba(67, 97, 238, 0.25) !important;
  padding: 0.55rem 1rem !important;
}
body.seoai-cork button.bg-brand:hover,
body.seoai-cork button[class*="bg-brand"]:hover {
  background: var(--seo-cork-brand-dark) !important;
}
body.seoai-cork button.border.border-slate-200,
body.seoai-cork button[class*="border-slate-200"] {
  background: #fff !important;
  border: 1px solid var(--seo-cork-border) !important;
  color: #3b3f5c !important;
  border-radius: 8px !important;
  font-weight: 600 !important;
  padding: 0.55rem 1rem !important;
}
body.seoai-cork button.border.border-slate-200:hover {
  border-color: var(--seo-cork-brand) !important;
  color: var(--seo-cork-brand) !important;
  background: rgba(67, 97, 238, 0.04) !important;
}
body.seoai-cork .flex.flex-wrap.gap-2 {
  gap: 0.55rem !important;
  padding-top: 0.35rem;
}

/* ——— SEO score widget ——— */
body.seoai-cork aside .text-4xl {
  font-size: 2.75rem !important;
  font-weight: 700 !important;
  color: var(--seo-cork-brand) !important;
  letter-spacing: -0.03em;
  line-height: 1.1;
}
body.seoai-cork aside .text-xs.font-semibold.uppercase {
  color: var(--seo-cork-brand) !important;
  letter-spacing: 0.12em !important;
  font-size: 0.7rem !important;
}
body.seoai-cork aside ul li {
  padding: 0.55rem 0 !important;
}
body.seoai-cork aside ul li strong {
  color: var(--seo-cork-ink) !important;
  font-variant-numeric: tabular-nums;
}

/* ——— Alerts / badges ——— */
body.seoai-cork .rounded-xl.border.px-3\.5,
body.seoai-cork div[class*="border-emerald-200"],
body.seoai-cork div[class*="border-red-200"],
body.seoai-cork div[class*="border-sky"] {
  border-radius: 10px !important;
  font-size: 0.875rem !important;
}
body.seoai-cork span[class*="rounded-md"][class*="ring-1"] {
  border-radius: 6px !important;
  font-weight: 600 !important;
}

/* ——— Progress modal ——— */
body.seoai-cork [role="dialog"] > div {
  border-radius: 14px !important;
  box-shadow: 0 20px 50px rgba(14, 23, 38, 0.25) !important;
}
body.seoai-cork [role="dialog"] .bg-gradient-to-r {
  background: linear-gradient(90deg, #4361ee, #805dca) !important;
}

/* ——— Project navy menu strip → Cork soft bar ——— */
body.seoai-cork .rounded-2xl.bg-navy {
  background: #fff !important;
  border: 1px solid var(--seo-cork-border) !important;
  box-shadow: var(--seo-cork-shadow) !important;
  color: var(--seo-cork-ink) !important;
}
body.seoai-cork .rounded-2xl.bg-navy .text-sky,
body.seoai-cork .rounded-2xl.bg-navy p {
  color: var(--seo-cork-muted) !important;
}
body.seoai-cork .rounded-2xl.bg-navy button {
  border-radius: 8px !important;
}
body.seoai-cork .rounded-2xl.bg-navy button.bg-brand {
  background: var(--seo-cork-brand) !important;
  color: #fff !important;
}
body.seoai-cork .rounded-2xl.bg-navy button.bg-white\/10 {
  background: var(--seo-cork-surface) !important;
  color: #3b3f5c !important;
}

/* Soften old navy/brand accents site-wide */
body.seoai-cork .text-navy {
  color: var(--seo-cork-ink) !important;
}
body.seoai-cork .text-brand {
  color: var(--seo-cork-brand) !important;
}
body.seoai-cork .bg-surface {
  background: var(--seo-cork-surface) !important;
}

/* Kairo logo */
.seoai-cork-shell .navbar-logo {
  height: 36px !important;
  width: 36px !important;
  object-fit: contain;
  border-radius: 8px;
}
.seoai-cork-shell .theme-text a {
  background: linear-gradient(135deg, #00d2ff, #9d50bb);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent !important;
}

/* ——— Kai progress modal (v6) ——— */
.seoai-progress-overlay {
  position: fixed !important;
  inset: 0 !important;
  z-index: 10050 !important; /* above Cork header (100) and page buttons */
  background:
    radial-gradient(ellipse 80% 60% at 50% 40%, rgba(67, 97, 238, 0.12), transparent 55%),
    rgba(10, 16, 28, 0.62) !important;
  backdrop-filter: blur(12px) saturate(1.1);
  -webkit-backdrop-filter: blur(12px) saturate(1.1);
  isolation: isolate;
}
.seoai-progress-card {
  position: relative;
  z-index: 1;
  border-radius: 20px !important;
  border: 1px solid rgba(224, 230, 237, 0.95) !important;
  background: #ffffff !important;
  box-shadow:
    0 1px 0 rgba(255, 255, 255, 0.9) inset,
    0 28px 64px rgba(10, 16, 28, 0.28),
    0 8px 20px rgba(10, 16, 28, 0.12) !important;
  animation: seoai-progress-in 0.32s cubic-bezier(0.22, 1, 0.36, 1);
}
@keyframes seoai-progress-in {
  from { opacity: 0; transform: translateY(14px) scale(0.97); }
  to { opacity: 1; transform: none; }
}
.seoai-progress-accent {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: linear-gradient(90deg, #4361ee 0%, #5b7cfa 55%, #25d5e4 100%);
  border-radius: 20px 20px 0 0;
}
.seoai-progress-head {
  display: flex;
  gap: 1rem;
  align-items: flex-start;
  padding: 1.45rem 1.45rem 1rem;
  background: linear-gradient(180deg, #fafbff 0%, #ffffff 100%);
  border-bottom: 1px solid #eef1f6;
}
.seoai-progress-orb {
  position: relative;
  flex: 0 0 auto;
  width: 3rem;
  height: 3rem;
  border-radius: 999px;
  display: grid;
  place-items: center;
}
.seoai-progress-orb__ring {
  position: absolute;
  inset: 0;
  border-radius: 999px;
  border: 2px solid transparent;
  border-top-color: #4361ee;
  border-right-color: rgba(67, 97, 238, 0.25);
  animation: seoai-orb-spin 1.1s linear infinite;
}
.seoai-progress-orb.is-done .seoai-progress-orb__ring {
  animation: none;
  border-color: #00ab55;
}
.seoai-progress-orb__core {
  width: 2.2rem;
  height: 2.2rem;
  border-radius: 999px;
  display: grid;
  place-items: center;
  font-size: 0.95rem;
  font-weight: 700;
  color: #fff;
  background: linear-gradient(145deg, #4361ee 0%, #3b55d9 100%);
  box-shadow: 0 6px 14px rgba(67, 97, 238, 0.28);
}
.seoai-progress-orb.is-done .seoai-progress-orb__core {
  background: linear-gradient(145deg, #00ab55 0%, #009a4c 100%);
  box-shadow: 0 6px 14px rgba(0, 171, 85, 0.28);
}
@keyframes seoai-orb-spin {
  to { transform: rotate(360deg); }
}
.seoai-progress-copy {
  min-width: 0;
  flex: 1;
  padding-top: 0.1rem;
}
.seoai-progress-kicker {
  margin: 0 0 0.3rem !important;
  display: inline-flex !important;
  align-items: center;
  gap: 0.35rem;
  font-size: 0.7rem !important;
  font-weight: 700 !important;
  letter-spacing: 0.1em !important;
  text-transform: uppercase !important;
  color: #4361ee !important;
}
.seoai-progress-dots {
  display: inline-flex;
  align-items: center;
  gap: 3px;
  height: 6px;
  margin-left: 2px;
}
.seoai-progress-dots i {
  width: 4px;
  height: 4px;
  border-radius: 999px;
  background: #4361ee;
  opacity: 0.3;
  animation: seoai-dot 1.2s ease-in-out infinite;
  font-style: normal;
}
.seoai-progress-dots i:nth-child(2) { animation-delay: 0.2s; }
.seoai-progress-dots i:nth-child(3) { animation-delay: 0.4s; }
@keyframes seoai-dot {
  0%, 80%, 100% { opacity: 0.25; transform: translateY(0); }
  40% { opacity: 1; transform: translateY(-2px); }
}
.seoai-progress-title {
  margin: 0 !important;
  font-size: 1.25rem !important;
  line-height: 1.3 !important;
  font-weight: 700 !important;
  color: #0e1726 !important;
  letter-spacing: -0.025em;
}
.seoai-progress-sub {
  margin: 0.4rem 0 0 !important;
  font-size: 0.875rem !important;
  line-height: 1.5 !important;
  color: #607080 !important;
}
.seoai-progress-body {
  padding: 1.15rem 1.45rem 1.4rem;
  background: #fff;
}
.seoai-progress-meta {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 0.75rem;
  margin-bottom: 0.65rem;
}
.seoai-progress-pct {
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
  font-size: 1.5rem !important;
  font-weight: 700 !important;
  color: #0e1726 !important;
  letter-spacing: -0.04em;
  line-height: 1 !important;
}
.seoai-progress-eta {
  font-size: 0.8rem !important;
  font-weight: 600 !important;
  color: #607080 !important;
  background: #f4f6fa;
  border: 1px solid #e8ecf2;
  border-radius: 999px;
  padding: 0.28rem 0.7rem;
  white-space: nowrap;
  flex-shrink: 0;
}
.seoai-progress-track {
  height: 0.55rem !important;
  border-radius: 999px !important;
  background: #eef1f6 !important;
  overflow: hidden !important;
  box-shadow: inset 0 1px 2px rgba(14, 23, 38, 0.05);
  position: relative;
  z-index: 0;
}
.seoai-progress-fill {
  height: 100%;
  border-radius: 999px;
  background: linear-gradient(90deg, #4361ee 0%, #5b7cfa 60%, #25d5e4 100%) !important;
  transition: width 0.28s cubic-bezier(0.22, 1, 0.36, 1);
  position: relative;
}
.seoai-progress-fill--pulse::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(
    90deg,
    transparent 0%,
    rgba(255, 255, 255, 0.5) 50%,
    transparent 100%
  );
  transform: translateX(-100%);
  animation: seoai-shimmer 1.5s ease-in-out infinite;
}
@keyframes seoai-shimmer {
  100% { transform: translateX(100%); }
}
.seoai-progress-footer {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 0.75rem;
  margin-top: 0.85rem;
  padding-top: 0.75rem;
  border-top: 1px solid #eef1f6;
}
.seoai-progress-note {
  margin: 0 !important;
  font-size: 0.72rem !important;
  line-height: 1.45 !important;
  color: #8895a7 !important;
  flex: 1;
  min-width: 0;
}
.seoai-progress-status {
  flex-shrink: 0;
  font-size: 0.72rem !important;
  font-weight: 700 !important;
  letter-spacing: 0.02em;
  color: #4361ee !important;
  background: rgba(67, 97, 238, 0.1);
  border: 1px solid rgba(67, 97, 238, 0.18);
  border-radius: 999px;
  padding: 0.28rem 0.65rem;
  white-space: nowrap;
}

/* Searchable keyword select */
.seoai-kw-select {
  position: relative;
  width: 100%;
}
.seoai-kw-select__trigger {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
  border: 1px solid var(--seo-cork-border) !important;
  border-radius: 8px !important;
  background: #fff !important;
  padding: 0.7rem 0.85rem !important;
  font-size: 0.875rem !important;
  font-weight: 500 !important;
  color: var(--seo-cork-ink) !important;
  font-family: inherit !important;
  text-align: left;
  cursor: pointer;
  box-shadow: none !important;
  transition: border-color 0.15s, box-shadow 0.15s;
}
.seoai-kw-select__trigger:focus,
.seoai-kw-select__trigger:hover {
  border-color: var(--seo-cork-brand) !important;
  box-shadow: 0 0 0 3px rgba(67, 97, 238, 0.12) !important;
  outline: none !important;
}
.seoai-kw-select__value {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  flex: 1;
  min-width: 0;
}
.seoai-kw-select__chev {
  color: #8895a7;
  font-size: 0.75rem;
  flex-shrink: 0;
}
.seoai-kw-select__panel {
  position: absolute;
  z-index: 60;
  left: 0;
  right: 0;
  top: calc(100% + 4px);
  background: #fff;
  border: 1px solid var(--seo-cork-border);
  border-radius: 10px;
  box-shadow: 0 12px 28px rgba(14, 23, 38, 0.12);
  overflow: hidden;
}
.seoai-kw-select__search {
  width: 100% !important;
  border: 0 !important;
  border-bottom: 1px solid #eef1f6 !important;
  border-radius: 0 !important;
  padding: 0.7rem 0.85rem !important;
  font-size: 0.875rem !important;
  font-weight: 500 !important;
  box-shadow: none !important;
  outline: none !important;
}
.seoai-kw-select__search:focus {
  box-shadow: none !important;
  border-color: #eef1f6 !important;
}
.seoai-kw-select__list {
  max-height: 240px;
  overflow-y: auto;
  padding: 0.35rem;
}
.seoai-kw-select__opt {
  display: block;
  width: 100%;
  text-align: left;
  border: 0;
  background: transparent;
  border-radius: 6px;
  padding: 0.55rem 0.7rem;
  font-size: 0.85rem;
  font-weight: 500;
  color: var(--seo-cork-ink);
  cursor: pointer;
}
.seoai-kw-select__opt:hover {
  background: #f3f6ff;
}
.seoai-kw-select__opt.is-active {
  background: #e8eeff;
  color: #4361ee;
  font-weight: 600;
}
.seoai-kw-select__empty {
  padding: 0.75rem 0.7rem;
  font-size: 0.8rem;
  color: #8895a7;
}

/* ——— Autopilot history ——— */
.seoai-ap-history {
  margin-top: 1.25rem;
  padding-top: 1.1rem;
  border-top: 1px solid #eef1f6;
}
.seoai-ap-history__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  margin-bottom: 0.75rem;
}
.seoai-ap-history__title {
  margin: 0;
  font-size: 0.95rem;
  font-weight: 700;
  color: #0e1726;
}
.seoai-ap-history__sub {
  margin: 0.15rem 0 0;
  font-size: 0.75rem;
  color: #8895a7;
}
.seoai-ap-history__empty {
  padding: 0.9rem 1rem;
  border: 1px dashed #e0e6ed;
  border-radius: 10px;
  font-size: 0.82rem;
  color: #607080;
  background: #fafbff;
}
.seoai-ap-history__list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 0.55rem;
}
.seoai-ap-history__item {
  border: 1px solid #e8ecf2;
  border-radius: 12px;
  background: #fff;
  padding: 0.8rem 0.95rem;
}
.seoai-ap-history__row {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  justify-content: space-between;
  gap: 0.5rem 0.75rem;
}
.seoai-ap-history__meta {
  min-width: 0;
  flex: 1;
}
.seoai-ap-history__title-line {
  margin: 0;
  font-size: 0.9rem;
  font-weight: 650;
  color: #0e1726;
  line-height: 1.35;
}
.seoai-ap-history__kw {
  margin: 0.2rem 0 0;
  font-size: 0.75rem;
  color: #607080;
}
.seoai-ap-history__badges {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
  justify-content: flex-end;
}
.seoai-ap-badge {
  display: inline-flex;
  align-items: center;
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.02em;
  border-radius: 999px;
  padding: 0.22rem 0.55rem;
  border: 1px solid transparent;
  text-transform: lowercase;
}
.seoai-ap-badge--run { color: #4361ee; background: rgba(67,97,238,.1); border-color: rgba(67,97,238,.18); }
.seoai-ap-badge--pub { color: #009688; background: rgba(0,150,136,.1); border-color: rgba(0,150,136,.18); }
.seoai-ap-badge--art { color: #515365; background: #f1f2f3; border-color: #e0e6ed; }
.seoai-ap-badge--slot { color: #805dca; background: rgba(128,93,202,.1); border-color: rgba(128,93,202,.18); }
.seoai-ap-badge--fail { color: #e7515a; background: rgba(231,81,90,.1); border-color: rgba(231,81,90,.2); }
.seoai-ap-history__foot {
  margin-top: 0.45rem;
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem 0.85rem;
  font-size: 0.72rem;
  color: #8895a7;
}
.seoai-ap-history__foot a {
  color: #4361ee;
  font-weight: 600;
  text-decoration: none;
}
.seoai-ap-history__foot a:hover { text-decoration: underline; }
.seoai-ap-history__err {
  margin: 0.35rem 0 0;
  font-size: 0.72rem;
  color: #e7515a;
}

/* Autopilot editorial calendar — professional month grid */
body.seoai-cork .seoai-cal {
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
}
body.seoai-cork .seoai-cal__toolbar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.85rem 1rem;
  padding-bottom: 0.15rem;
}
body.seoai-cork .seoai-cal__nav {
  display: inline-flex;
  align-items: center;
  gap: 0.25rem;
  background: #f8fafc;
  border: 1px solid var(--seo-cork-border);
  border-radius: 0.75rem;
  padding: 0.2rem;
}
body.seoai-cork .seoai-cal__nav button {
  min-width: 2.25rem;
  height: 2.25rem;
  padding: 0 !important;
  border-radius: 0.55rem !important;
  font-size: 1.1rem;
  line-height: 1;
}
body.seoai-cork .seoai-cal__month {
  margin: 0;
  min-width: 12.5rem;
  text-align: center;
  font-size: 1.15rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--seo-cork-ink);
}
body.seoai-cork .seoai-cal__legend {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.55rem 0.85rem;
}
body.seoai-cork .seoai-cal-dot {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.72rem;
  font-weight: 600;
  color: #6b7280;
}
body.seoai-cork .seoai-cal-dot::before {
  content: "";
  width: 0.55rem;
  height: 0.55rem;
  border-radius: 999px;
  flex-shrink: 0;
  background: #c2c9d1;
}
body.seoai-cork .seoai-cal-dot--scheduled::before { background: #805dca; }
body.seoai-cork .seoai-cal-dot--running::before { background: #4361ee; }
body.seoai-cork .seoai-cal-dot--published::before { background: #009688; }
body.seoai-cork .seoai-cal-dot--failed::before { background: #e7515a; }

body.seoai-cork .seoai-cal__body {
  display: grid !important;
  grid-template-columns: minmax(0, 1.65fr) minmax(280px, 0.95fr);
  gap: 1.15rem;
  align-items: start;
}
@media (max-width: 960px) {
  body.seoai-cork .seoai-cal__body {
    grid-template-columns: 1fr;
  }
}

body.seoai-cork .seoai-cal__grid {
  display: grid !important;
  grid-template-columns: repeat(7, minmax(0, 1fr)) !important;
  gap: 0.4rem;
  padding: 0.85rem;
  background: linear-gradient(180deg, #fbfcfe 0%, #f4f6f9 100%);
  border: 1px solid var(--seo-cork-border);
  border-radius: 1rem;
  box-shadow: inset 0 1px 0 rgba(255,255,255,.8);
}
body.seoai-cork .seoai-cal__dow {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 1.75rem;
  text-align: center;
  font-size: 0.68rem;
  font-weight: 700;
  color: #8895a7;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  padding: 0.15rem;
}
body.seoai-cork .seoai-cal__cell {
  appearance: none;
  -webkit-appearance: none;
  display: flex !important;
  flex-direction: column;
  align-items: stretch;
  justify-content: flex-start;
  gap: 0.35rem;
  min-height: 5.1rem;
  width: 100%;
  margin: 0;
  border: 1px solid #e5e9f0;
  border-radius: 0.7rem;
  background: #fff;
  padding: 0.45rem 0.45rem 0.4rem;
  text-align: left;
  cursor: pointer;
  box-shadow: 0 1px 1px rgba(14,23,38,.03);
  transition: border-color .15s ease, box-shadow .15s ease, transform .12s ease, background .15s ease;
}
body.seoai-cork .seoai-cal__cell:hover {
  border-color: #a5b4fc;
  box-shadow: 0 4px 14px rgba(67,97,238,.12);
  transform: translateY(-1px);
}
body.seoai-cork .seoai-cal__cell--empty {
  visibility: hidden;
  pointer-events: none;
  border: none;
  background: transparent;
  box-shadow: none;
  min-height: 5.1rem;
}
body.seoai-cork .seoai-cal__cell--today {
  border-color: #4361ee;
  box-shadow: 0 0 0 1px rgba(67,97,238,.28), 0 4px 12px rgba(67,97,238,.1);
}
body.seoai-cork .seoai-cal__cell--sel {
  border-color: #009688;
  background: linear-gradient(180deg, #f3fffd 0%, #fff 70%);
  box-shadow: 0 0 0 1px rgba(0,150,136,.25), 0 6px 16px rgba(0,150,136,.1);
}
body.seoai-cork .seoai-cal__daynum {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 1.55rem;
  height: 1.55rem;
  border-radius: 999px;
  font-size: 0.78rem;
  font-weight: 700;
  color: var(--seo-cork-ink);
  line-height: 1;
}
body.seoai-cork .seoai-cal__cell--today .seoai-cal__daynum {
  background: #4361ee;
  color: #fff;
}
body.seoai-cork .seoai-cal__cell--sel .seoai-cal__daynum {
  background: #009688;
  color: #fff;
}
body.seoai-cork .seoai-cal__pips {
  display: flex;
  flex-direction: column;
  gap: 0.22rem;
  margin-top: auto;
}
body.seoai-cork .seoai-cal-pip {
  display: block;
  width: 100%;
  height: 0.28rem;
  border-radius: 999px;
  background: #e5e9f0;
}
body.seoai-cork .seoai-cal-pip--scheduled { background: #c4b5fd; }
body.seoai-cork .seoai-cal-pip--running { background: #818cf8; }
body.seoai-cork .seoai-cal-pip--succeeded,
body.seoai-cork .seoai-cal-pip--published { background: #2dd4bf; }
body.seoai-cork .seoai-cal-pip--failed { background: #fb7185; }
body.seoai-cork .seoai-cal-pip--empty { background: #eef1f5; }
body.seoai-cork .seoai-cal__count {
  font-size: 0.62rem;
  font-weight: 600;
  color: #8895a7;
  line-height: 1.2;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

body.seoai-cork .seoai-cal__detail {
  border: 1px solid var(--seo-cork-border);
  border-radius: 1rem;
  padding: 1rem 1.05rem 1.1rem;
  background: #fff;
  box-shadow: var(--seo-cork-shadow);
  position: sticky;
  top: 5.5rem;
}
body.seoai-cork .seoai-cal__detail-title {
  margin: 0 0 0.2rem;
  font-size: 1rem;
  font-weight: 700;
  letter-spacing: -0.01em;
  color: var(--seo-cork-ink);
}
body.seoai-cork .seoai-cal__hint {
  margin: 0 0 0.85rem;
  font-size: 0.74rem;
  line-height: 1.45;
  color: #8895a7;
}
body.seoai-cork .seoai-cal__slots {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}
body.seoai-cork .seoai-cal__slot {
  border: 1px solid #e8ecf2;
  border-radius: 0.8rem;
  padding: 0.8rem 0.85rem;
  background: #fbfcfe;
  transition: border-color .15s ease;
}
body.seoai-cork .seoai-cal__slot--published,
body.seoai-cork .seoai-cal__slot--succeeded {
  border-color: rgba(0,150,136,.35);
  background: linear-gradient(180deg, #f2fffb 0%, #fff 55%);
}
body.seoai-cork .seoai-cal__slot--failed {
  border-color: rgba(231,81,90,.35);
  background: linear-gradient(180deg, #fff5f5 0%, #fff 55%);
}
body.seoai-cork .seoai-cal__slot--running {
  border-color: rgba(67,97,238,.35);
  background: linear-gradient(180deg, #f5f7ff 0%, #fff 55%);
}
body.seoai-cork .seoai-cal__slot--scheduled {
  border-color: rgba(128,93,202,.28);
}
body.seoai-cork .seoai-cal__slot-head {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.4rem 0.65rem;
  font-size: 0.8rem;
  margin-bottom: 0.4rem;
}
body.seoai-cork .seoai-cal__slot-head strong {
  color: var(--seo-cork-ink);
  font-weight: 700;
}
body.seoai-cork .seoai-cal__slot-title {
  margin: 0;
  font-size: 0.84rem;
  color: #3b3f5c;
  line-height: 1.4;
  font-weight: 500;
}
body.seoai-cork .seoai-cal__slot-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  align-items: center;
  margin-top: 0.65rem;
}
body.seoai-cork .seoai-cal__slot-actions a {
  font-size: 0.75rem;
  font-weight: 600;
  color: #4361ee;
  text-decoration: none;
}
body.seoai-cork .seoai-cal__slot-actions a:hover { text-decoration: underline; }

/* —— Plugins y configuración —— */
body.seoai-cork .seoai-plugins {
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
}
body.seoai-cork .seoai-plugins__grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 0.75rem;
}
body.seoai-cork .seoai-plugin-card {
  text-align: left;
  border: 1px solid #e0e6ed;
  background: #fff;
  border-radius: 10px;
  padding: 0.9rem 1rem;
  cursor: pointer;
  transition: border-color 0.15s ease, box-shadow 0.15s ease, background 0.15s ease;
  color: #3b3f5c;
}
body.seoai-cork .seoai-plugin-card:hover {
  border-color: #4361ee;
  box-shadow: 0 4px 14px rgba(67, 97, 238, 0.08);
}
body.seoai-cork .seoai-plugin-card.is-selected {
  border-color: #4361ee;
  background: #f4f6ff;
  box-shadow: 0 0 0 1px #4361ee;
}
body.seoai-cork .seoai-plugin-card.is-active {
  border-color: #00ab55;
}
body.seoai-cork .seoai-plugin-card.is-active.is-selected {
  border-color: #4361ee;
  box-shadow: 0 0 0 1px #4361ee, inset 3px 0 0 #00ab55;
}
body.seoai-cork .seoai-plugin-card__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
  margin-bottom: 0.35rem;
}
body.seoai-cork .seoai-plugin-card__head strong {
  font-size: 0.95rem;
  font-weight: 700;
  color: #0e1726;
}
body.seoai-cork .seoai-plugin-card__badge {
  font-size: 0.65rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: #00ab55;
  background: rgba(0, 171, 85, 0.12);
  padding: 0.15rem 0.45rem;
  border-radius: 4px;
}
body.seoai-cork .seoai-plugin-card p {
  margin: 0;
  font-size: 0.78rem;
  line-height: 1.45;
  color: #888ea8;
}
body.seoai-cork .seoai-plugins__config {
  border: 1px solid #e0e6ed;
  border-radius: 12px;
  padding: 1.1rem 1.25rem 1.25rem;
  background: #fff;
}
body.seoai-cork .seoai-plugins__config h3 {
  margin: 0 0 0.35rem;
  font-size: 1.05rem;
  font-weight: 700;
  color: #0e1726;
}
body.seoai-cork .seoai-plugins__hint {
  margin: 0 0 1rem;
  font-size: 0.82rem;
  color: #888ea8;
}
body.seoai-cork .seoai-plugins__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.65rem;
  margin-top: 1rem;
  align-items: center;
}
body.seoai-cork .seoai-plugins__msg {
  margin-top: 0.85rem;
  padding: 0.65rem 0.85rem;
  border-radius: 8px;
  font-size: 0.85rem;
}
body.seoai-cork .seoai-plugins__msg.is-ok {
  background: rgba(0, 171, 85, 0.1);
  color: #007a3d;
  border: 1px solid rgba(0, 171, 85, 0.25);
}
body.seoai-cork .seoai-plugins__msg.is-bad {
  background: rgba(231, 81, 90, 0.1);
  color: #e7515a;
  border: 1px solid rgba(231, 81, 90, 0.25);
}
@media (max-width: 640px) {
  body.seoai-cork .seoai-plugins__grid {
    grid-template-columns: 1fr;
  }
}

body.seoai-cork .seoai-auth-switch {
  margin: 0;
  text-align: center;
  font-size: 0.875rem;
  color: #888ea8;
}
body.seoai-cork .seoai-auth-link {
  border: 0;
  background: none;
  padding: 0;
  color: #4361ee;
  font-weight: 600;
  cursor: pointer;
  text-decoration: underline;
}

/* Keyword research — saved searches pool */
body.seoai-cork .seoai-kw-searches {
  margin-top: 1.1rem;
  padding: 0.95rem 1rem;
  border: 1px solid #e0e6ed;
  border-radius: 0.75rem;
  background: #fafbfc;
}
body.seoai-cork .seoai-kw-searches__head {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: space-between;
  gap: 0.35rem 1rem;
  margin-bottom: 0.75rem;
}
body.seoai-cork .seoai-kw-searches__head h3 {
  margin: 0;
  font-size: 0.95rem;
  font-weight: 700;
  color: #0e1726;
}
body.seoai-cork .seoai-kw-searches__head span {
  font-size: 0.75rem;
  color: #888ea8;
}
body.seoai-cork .seoai-kw-searches__empty {
  margin: 0;
  font-size: 0.85rem;
  color: #888ea8;
}
body.seoai-cork .seoai-kw-searches__list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
}
body.seoai-cork .seoai-kw-searches__item {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  justify-content: space-between;
  gap: 0.65rem 1rem;
  padding: 0.7rem 0.8rem;
  border-radius: 0.55rem;
  background: #fff;
  border: 1px solid #e0e6ed;
}
body.seoai-cork .seoai-kw-searches__main {
  display: flex;
  flex-direction: column;
  gap: 0.3rem;
  min-width: 0;
  flex: 1;
}
body.seoai-cork .seoai-kw-searches__main strong {
  font-size: 0.9rem;
  color: #0e1726;
}
body.seoai-cork .seoai-kw-searches__main > span {
  font-size: 0.72rem;
  color: #888ea8;
}
body.seoai-cork .seoai-kw-searches__terms {
  display: flex;
  flex-wrap: wrap;
  gap: 0.3rem;
}
body.seoai-cork .seoai-kw-searches__terms code {
  font-size: 0.68rem;
  padding: 0.12rem 0.4rem;
  border-radius: 0.3rem;
  background: #f1f2f3;
  color: #3b3f5c;
}
body.seoai-cork .seoai-kw-searches__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
}
body.seoai-cork .seoai-kw-searches__btn {
  border: 1px solid #e0e6ed;
  background: #fff;
  color: #4361ee;
  font-size: 0.72rem;
  font-weight: 600;
  padding: 0.28rem 0.55rem;
  border-radius: 0.4rem;
  cursor: pointer;
}
body.seoai-cork .seoai-kw-searches__btn:hover {
  border-color: #4361ee;
  background: rgba(67, 97, 238, 0.06);
}
body.seoai-cork .seoai-kw-searches__btn--danger {
  color: #e7515a;
}
body.seoai-cork .seoai-kw-searches__btn--danger:hover {
  border-color: #e7515a;
  background: rgba(231, 81, 90, 0.06);
}

/* Keyword pool table pagination */
body.seoai-cork .seoai-kw-pager {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.85rem 1.25rem;
  margin-top: 1rem;
  padding: 0.85rem 1rem;
  border: 1px solid #e0e6ed;
  border-radius: 0.75rem;
  background: linear-gradient(180deg, #fbfcfd 0%, #f4f6f9 100%);
  box-shadow: 0 1px 2px rgba(14, 23, 38, 0.04);
}
body.seoai-cork .seoai-kw-pager__meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.65rem 0.85rem;
}
body.seoai-cork .seoai-kw-pager__range {
  display: inline-flex;
  align-items: center;
  min-height: 2rem;
  padding: 0.3rem 0.7rem;
  border-radius: 999px;
  background: #fff;
  border: 1px solid #e0e6ed;
  font-size: 0.78rem;
  font-weight: 600;
  color: #3b3f5c;
  letter-spacing: 0.01em;
}
body.seoai-cork .seoai-kw-pager__size {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  margin: 0;
  font-size: 0.75rem;
  font-weight: 600;
  color: #888ea8;
}
body.seoai-cork .seoai-kw-pager__size select {
  appearance: none;
  -webkit-appearance: none;
  min-width: 3.4rem;
  height: 2rem;
  border: 1px solid #dce3ec;
  border-radius: 0.5rem;
  background: #fff url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%23888ea8' d='M3 4.5L6 8l3-3.5'/%3E%3C/svg%3E") no-repeat right 0.55rem center;
  padding: 0 1.6rem 0 0.65rem;
  font-size: 0.8rem;
  font-weight: 600;
  color: #0e1726;
  cursor: pointer;
  box-shadow: 0 1px 1px rgba(14, 23, 38, 0.03);
}
body.seoai-cork .seoai-kw-pager__size select:focus {
  outline: none;
  border-color: #4361ee;
  box-shadow: 0 0 0 3px rgba(67, 97, 238, 0.15);
}
body.seoai-cork .seoai-kw-pager__nav {
  display: inline-flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.3rem;
  padding: 0.2rem;
  border-radius: 0.65rem;
  background: rgba(255, 255, 255, 0.7);
  border: 1px solid #e8edf3;
}
body.seoai-cork .seoai-kw-pager__btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 2rem;
  margin: 0;
  border: 1px solid transparent;
  background: transparent;
  color: #4361ee;
  font-family: inherit;
  font-size: 0.75rem;
  font-weight: 600;
  line-height: 1;
  padding: 0.4rem 0.75rem;
  border-radius: 0.45rem;
  cursor: pointer;
  transition: background 0.15s ease, color 0.15s ease, border-color 0.15s ease, box-shadow 0.15s ease;
}
body.seoai-cork .seoai-kw-pager__btn--icon {
  min-width: 2rem;
  padding-left: 0.55rem;
  padding-right: 0.55rem;
  font-size: 0.9rem;
}
body.seoai-cork .seoai-kw-pager__btn--num {
  min-width: 2rem;
  padding-left: 0.45rem;
  padding-right: 0.45rem;
  color: #515365;
}
body.seoai-cork .seoai-kw-pager__btn:hover:not(:disabled) {
  background: rgba(67, 97, 238, 0.08);
  border-color: rgba(67, 97, 238, 0.18);
  color: #2f49c3;
}
body.seoai-cork .seoai-kw-pager__btn.is-active,
body.seoai-cork .seoai-kw-pager__btn--num.is-active {
  background: #4361ee;
  border-color: #4361ee;
  color: #fff;
  box-shadow: 0 2px 6px rgba(67, 97, 238, 0.28);
  cursor: default;
}
body.seoai-cork .seoai-kw-pager__btn:disabled {
  opacity: 0.35;
  cursor: not-allowed;
  color: #888ea8;
  background: transparent;
  border-color: transparent;
  box-shadow: none;
}
body.seoai-cork .seoai-kw-pager__page {
  display: none;
}

/* Keyword quality tiers */
body.seoai-cork .seoai-kw-legend {
  display: inline-flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.35rem;
  margin: 0 0.15rem;
  vertical-align: middle;
}
body.seoai-cork .seoai-kw-tier {
  display: inline-flex;
  align-items: center;
  gap: 0.2rem;
  font-size: 0.72rem;
  font-weight: 700;
  line-height: 1.2;
  padding: 0.22rem 0.5rem;
  border-radius: 0.4rem;
  border: 1px solid transparent;
  white-space: nowrap;
}
body.seoai-cork .seoai-kw-tier--good {
  color: #1b7a3d;
  background: rgba(0, 171, 85, 0.12);
  border-color: rgba(0, 171, 85, 0.28);
}
body.seoai-cork .seoai-kw-tier--ok {
  color: #9a6700;
  background: rgba(255, 193, 7, 0.16);
  border-color: rgba(255, 193, 7, 0.4);
}
body.seoai-cork .seoai-kw-tier--bad {
  color: #c0392b;
  background: rgba(231, 81, 90, 0.1);
  border-color: rgba(231, 81, 90, 0.28);
}
body.seoai-cork tr.seoai-kw-row--good > td:first-child {
  box-shadow: inset 3px 0 0 #00ab55;
}
body.seoai-cork tr.seoai-kw-row--ok > td:first-child {
  box-shadow: inset 3px 0 0 #f0ad4e;
}
body.seoai-cork tr.seoai-kw-row--bad > td:first-child {
  box-shadow: inset 3px 0 0 #e7515a;
}
body.seoai-cork tr.seoai-kw-row--good {
  background: rgba(0, 171, 85, 0.035);
}
body.seoai-cork tr.seoai-kw-row--ok {
  background: rgba(255, 193, 7, 0.04);
}
body.seoai-cork tr.seoai-kw-row--bad {
  background: rgba(231, 81, 90, 0.035);
}
body.seoai-cork tr.seoai-kw-row--bad .font-semibold {
  color: #c0392b;
}

