/* ===== FLEXIBASE PRO DEFINITIVO FUSIONADO ===== */

:root {
  --fb-primary: #2058b0;
  --fb-secondary: #44e7ee;
  --fb-accent: #ffd700;
  --fb-accent-2: #1e293b;
  --fb-text: #1a202c;
  --fb-text-soft: #5f6d7b;
  --fb-bg: #f4f7fb;
  --fb-surface: #ffffff;
  --fb-surface-2: #eef4fb;
  --fb-border: #d9e3f0;
  --fb-radius: 22px;
  --fb-shadow: 0 12px 28px rgba(32, 88, 176, 0.10);
  --fb-shadow-hover: 0 20px 40px rgba(32, 88, 176, 0.16);
  --fb-container: 1220px;
}

html { scroll-behavior: smooth; }

body {
  background: linear-gradient(180deg, #f4f7fb 0%, #eef3f8 100%);
  color: var(--fb-text);
  font-family: "Segoe UI", Arial, sans-serif;
}

.site-wrap {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

.site-main {
  flex: 1 1 auto;
}

.fb-container {
  width: min(100% - 32px, var(--fb-container));
  margin: 0 auto;
}

a {
  color: var(--fb-primary);
  text-decoration: none;
}

a:hover,
a:focus {
  text-decoration: none;
}

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

.fb-ticker {
  background: #111;
  color: #fff;
  border-bottom: 2px solid #20c7ff;
  box-shadow: 0 2px 10px rgba(0,0,0,0.08);
}

.fb-ticker-shell {
  display: flex;
  align-items: center;
  min-height: 28px;
}

.fb-ticker-label {
  color: #e53935;
  font-weight: 800;
  padding-right: 14px;
  flex-shrink: 0;
}

.fb-ticker-viewport {
  overflow: hidden;
  width: 100%;
}

.fb-ticker-track {
  display: inline-flex;
  align-items: center;
  gap: 20px;
  white-space: nowrap;
  padding: 9px 0;
  animation: fbTickerMove 28s linear infinite;
}

.fb-ticker:hover .fb-ticker-track {
  animation-play-state: paused;
}

.fb-ticker-item,
.fb-ticker-item a {
  color: #20c7ff;
  font-weight: 700;
}

.fb-ticker-item a:hover {
  color: var(--fb-accent);
}

.fb-ticker-sep {
  color: rgba(255,255,255,.4);
}

@keyframes fbTickerMove {
  0% { transform: translateX(100%); }
  100% { transform: translateX(-100%); }
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 40;
  background: linear-gradient(90deg, #2058b0 0%, #2f80ed 70%, #44e7ee 100%);
  color: #fff;
  box-shadow: 0 8px 26px rgba(32, 88, 176, 0.20);
  border-radius: 0 0 28px 28px;
}

.header-inner {
  min-height: 84px;
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 18px;
}

.logo-title {
  display: flex;
  align-items: center;
  gap: 12px;
}

.logo-img img,
.custom-logo {
  max-height: 72px;
  width: auto;
}

.site-title {
  color: var(--fb-accent);
  font-weight: 800;
  font-size: 1.35rem;
  line-height: 1.1;
  text-shadow: 0 2px 8px rgba(0,0,0,.15);
}

.site-desc {
  color: rgba(255,255,255,.86);
  font-size: .95rem;
}

.primary-nav {
  justify-self: center;
}

.main-menu-list,
.main-menu-list ul,
.menu {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  list-style: none;
  padding: 0;
  margin: 0;
}

.main-menu-list a,
.menu a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 10px 18px;
  min-height: 44px;
  border-radius: 999px;
  background: linear-gradient(180deg, #2d74dd 0%, #1e5fc2 100%);
  color: #fff;
  box-shadow: 0 6px 16px rgba(0,0,0,.12), inset 0 1px 0 rgba(255,255,255,.15);
  font-weight: 700;
  transition: transform .18s ease, box-shadow .18s ease, background .18s ease, color .18s ease;
}

.main-menu-list a:hover,
.menu a:hover {
  transform: translateY(-2px);
  background: linear-gradient(180deg, #ffe38a 0%, #ffd700 100%);
  color: #173b7a;
  box-shadow: 0 10px 20px rgba(0,0,0,.15);
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 10px;
}

.darkmode-toggle {
  border: 0;
  background: rgba(255,255,255,.14);
  color: #fff;
  min-width: 44px;
  min-height: 44px;
  border-radius: 999px;
  cursor: pointer;
  transition: transform .18s ease, background .18s ease;
}

.darkmode-toggle:hover {
  transform: translateY(-2px);
  background: rgba(255,255,255,.24);
}

.hero-fusion {
  padding: 64px 0 54px;
  background:
    radial-gradient(circle at top left, rgba(255,215,0,.20), transparent 28%),
    radial-gradient(circle at top right, rgba(68,231,238,.16), transparent 24%),
    linear-gradient(135deg, #edf5ff 0%, #f7fbff 100%);
}

.hero-layout {
  display: grid;
  grid-template-columns: 1.3fr .7fr;
  gap: 22px;
  align-items: center;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: rgba(32,88,176,.08);
  color: #1b4fa0;
  border: 1px solid rgba(32,88,176,.10);
  border-radius: 999px;
  padding: 7px 12px;
  font-size: .86rem;
  font-weight: 800;
  margin-bottom: 14px;
}

.hero h1 {
  font-size: clamp(2.2rem, 4vw, 3.4rem);
  line-height: 1.05;
  margin-bottom: 14px;
  color: #173b7a;
  letter-spacing: -0.02em;
}

.hero p {
  max-width: 720px;
  color: var(--fb-text-soft);
  font-size: 1.08rem;
  margin-bottom: 20px;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.hero-badge-card {
  background: linear-gradient(180deg, #ffffff 0%, #f8fbff 100%);
  border: 1px solid var(--fb-border);
  border-radius: 26px;
  box-shadow: var(--fb-shadow);
  padding: 24px;
}

.hero-badge-card strong {
  display: block;
  font-size: 1.2rem;
  margin-bottom: 8px;
}

.section {
  padding: 30px 0;
}

.section-head {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  align-items: end;
  margin-bottom: 18px;
}

.section-head h2,
.site-main h1 {
  margin: 0 0 8px;
  font-size: 1.8rem;
  color: #173b7a;
}

.section-head p {
  color: var(--fb-text-soft);
  max-width: 640px;
}

.grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0,1fr));
  gap: 20px;
}

.card,
.fb-placeholder {
  background: linear-gradient(180deg, #ffffff 0%, #fbfdff 100%);
  border: 1px solid var(--fb-border);
  border-radius: 24px;
  box-shadow: var(--fb-shadow);
  overflow: hidden;
}

.card {
  transition: transform .22s ease, box-shadow .22s ease, border-color .22s ease;
}

.card:hover {
  transform: translateY(-6px);
  box-shadow: var(--fb-shadow-hover);
  border-color: #c7d8ee;
}

.card img {
  width: 100%;
  height: 210px;
  object-fit: cover;
  background: #eaf0f6;
}

.card .content {
  padding: 18px 18px 22px;
}

.card h3 {
  font-size: 1.1rem;
  line-height: 1.25;
  margin: 0 0 10px;
}

.card p,
.entry-content,
.fb-ad-slot {
  color: var(--fb-text-soft);
}

.entry-content > * + * {
  margin-top: 1rem;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 46px;
  padding: 12px 18px;
  border-radius: 999px;
  background: linear-gradient(180deg, #1f2937 0%, #111827 100%);
  color: #fff;
  font-weight: 800;
  box-shadow: 0 8px 18px rgba(17,24,39,.18);
  transition: transform .18s ease, box-shadow .18s ease, filter .18s ease;
}

.btn:hover,
.btn:focus {
  transform: translateY(-2px);
  box-shadow: 0 12px 26px rgba(17,24,39,.22);
  filter: brightness(1.02);
  color: #fff;
}

.btn.alt {
  background: linear-gradient(180deg, #2f80ed 0%, #2058b0 100%);
}

.btn-ghost {
  background: linear-gradient(180deg, #ffffff 0%, #eef4fb 100%);
  color: #173b7a;
  border: 1px solid var(--fb-border);
}

.fb-ad-slot {
  background: linear-gradient(180deg, #ffffff 0%, #f5f9ff 100%);
  border: 1px dashed #bfd2ea;
  border-radius: 22px;
  box-shadow: 0 6px 18px rgba(32,88,176,.05);
  padding: 18px;
}

.fb-ad-placeholder {
  text-align: center;
  letter-spacing: .03em;
  font-weight: 700;
}

.footer-wow {
  margin-top: 40px;
  background: linear-gradient(180deg, #203455 0%, #16253f 100%);
  color: #fff;
  border-radius: 28px 28px 0 0;
}

.footer-content {
  display: grid;
  grid-template-columns: repeat(3, minmax(0,1fr));
  gap: 20px;
  padding: 34px 0 22px;
}

.footer-col h4 {
  margin: 0 0 12px;
  color: var(--fb-accent);
}

.footer-col ul {
  margin: 0;
  padding-left: 18px;
}

.footer-col li,
.footer-col a {
  color: rgba(255,255,255,.88);
}

.footer-copy {
  padding: 0 0 22px;
  color: rgba(255,255,255,.72);
  font-size: .95rem;
}

.flexibase-admin-page .nav-tab-wrapper {
  margin-top: 18px;
  margin-bottom: 20px;
}

.flexibase-admin-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(220px, 1fr));
  gap: 16px;
  margin-top: 16px;
}

.flexibase-admin-card {
  background: #ffffff;
  border: 1px solid #dcdcde;
  border-radius: 16px;
  padding: 18px;
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.04);
}

.pagination-wrap {
  margin-top: 24px;
}

body.dark-mode {
  background: linear-gradient(180deg, #0f1720 0%, #111927 100%);
  color: #eef2f7;
}

body.dark-mode .hero-fusion,
body.dark-mode .card,
body.dark-mode .fb-placeholder,
body.dark-mode .fb-ad-slot,
body.dark-mode .hero-badge-card {
  background: linear-gradient(180deg, #17212c 0%, #131b24 100%);
  color: #eef2f7;
  border-color: #263445;
  box-shadow: 0 14px 28px rgba(0,0,0,.26);
}

body.dark-mode .site-header {
  background: linear-gradient(90deg, #12233e 0%, #183a68 60%, #156f7a 100%);
}

body.dark-mode .hero h1,
body.dark-mode .section-head h2,
body.dark-mode .site-main h1,
body.dark-mode .site-title {
  color: #ffd700;
}

body.dark-mode .card p,
body.dark-mode .hero p,
body.dark-mode .section-head p,
body.dark-mode .entry-content,
body.dark-mode .site-desc,
body.dark-mode .fb-ad-slot {
  color: #c1cbd7;
}

body.dark-mode .btn-ghost {
  background: linear-gradient(180deg, #1d2630 0%, #161d26 100%);
  color: #eef2f7;
  border-color: #263445;
}

@media (max-width: 980px) {
  .header-inner,
  .hero-layout,
  .footer-content,
  .flexibase-admin-grid {
    grid-template-columns: 1fr;
  }

  .header-inner {
    padding: 14px 0;
  }

  .primary-nav {
    justify-self: start;
  }

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

@media (max-width: 680px) {
  .grid,
  .footer-content {
    grid-template-columns: 1fr;
  }

  .main-menu-list a,
  .menu a,
  .btn,
  .btn-ghost {
    width: 100%;
  }

  .header-actions,
  .hero-actions,
  .section-head {
    flex-direction: column;
    align-items: stretch;
  }

  .site-header {
    border-radius: 0 0 22px 22px;
  }
}
