:root {
  --bg-dark: #071526;
  --bg-surface: rgba(10, 26, 47, 0.65);
  --bg-glass: rgba(14, 34, 62, 0.48);
  --bg-glass-card: rgba(16, 40, 72, 0.52);
  --bg-glass-hover: rgba(22, 54, 96, 0.65);
  --border-glass: rgba(255, 255, 255, 0.12);
  --border-glass-hover: rgba(153, 204, 51, 0.5);
  --green-main: #1b5e20;
  --green-accent: #2e7d32;
  --green-lime: #a3e635;
  --amber-accent: #fbbf24;
  --text-primary: #f8fafc;
  --text-secondary: #cbd5e1;
  --text-muted: #94a3b8;
  --radius-md: 16px;
  --radius-lg: 24px;
  --glass-blur: blur(16px);
  --shadow-glass: 0 10px 30px 0 rgba(0, 0, 0, 0.35);
  --shadow-glass-hover: 0 16px 40px 0 rgba(0, 0, 0, 0.45);
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
  background-color: var(--bg-dark);
  color: var(--text-primary);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  position: relative;
  min-height: 100vh;
  overflow-x: hidden;
}

/* Fundo Agrícola Fixo com Desfoque e Overlay */
.agri-background {
  position: fixed;
  top: -20px;
  left: -20px;
  right: -20px;
  bottom: -20px;
  z-index: -2;
  background-image: url('assets/prototipo/prototipo-armadilha.jpg');
  background-position: center center;
  background-size: cover;
  background-repeat: no-repeat;
  filter: blur(18px) brightness(0.65) saturate(1.25);
  transform: scale(1.05); /* Evita bordas brancas geradas pelo blur */
  pointer-events: none;
}

/* Camada de Gradiente e Luz Orgânica (Ambient Mesh) */
.agri-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: -1;
  background: 
    radial-gradient(circle at 15% 20%, rgba(46, 125, 50, 0.32) 0%, transparent 45%),
    radial-gradient(circle at 85% 70%, rgba(163, 230, 53, 0.15) 0%, transparent 50%),
    linear-gradient(180deg, rgba(6, 17, 33, 0.82) 0%, rgba(7, 21, 38, 0.88) 50%, rgba(4, 11, 20, 0.94) 100%);
  pointer-events: none;
}

.container {
  width: 100%;
  max-width: 1160px;
  margin: 0 auto;
  padding: 0 24px;
}

/* Navbar com Glassmorphism */
.navbar {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(7, 21, 38, 0.65);
  backdrop-filter: var(--glass-blur);
  -webkit-backdrop-filter: var(--glass-blur);
  border-bottom: 1px solid var(--border-glass);
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.25);
  transition: background 0.3s ease;
}

.nav-content {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 72px;
  gap: 16px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
  color: var(--text-primary);
  font-weight: 700;
  font-size: 1.25rem;
  letter-spacing: -0.02em;
}

.brand-logo {
  height: 38px;
  width: auto;
  filter: drop-shadow(0 2px 8px rgba(0,0,0,0.4));
}

.nav-links {
  display: flex;
  gap: 28px;
}

.nav-links a {
  color: var(--text-secondary);
  text-decoration: none;
  font-weight: 500;
  font-size: 0.95rem;
  transition: color 0.2s ease;
}

.nav-links a:hover {
  color: var(--green-lime);
}

/* Botões */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px 24px;
  border-radius: 999px;
  font-weight: 600;
  text-decoration: none;
  transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
  cursor: pointer;
  border: none;
  font-size: 0.95rem;
}

.btn-primary {
  background: linear-gradient(135deg, #2e7d32 0%, #1b5e20 100%);
  color: #fff;
  box-shadow: 0 4px 18px rgba(46, 125, 50, 0.45);
  border: 1px solid rgba(163, 230, 53, 0.3);
}

.btn-primary:hover {
  background: linear-gradient(135deg, #388e3c 0%, #2e7d32 100%);
  transform: translateY(-2px);
  box-shadow: 0 6px 24px rgba(46, 125, 50, 0.6);
}

.btn-outline {
  background: rgba(255, 255, 255, 0.06);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  border: 1px solid var(--border-glass);
  color: var(--text-primary);
}

.btn-outline:hover {
  background: rgba(255, 255, 255, 0.12);
  border-color: var(--green-lime);
  color: #fff;
  transform: translateY(-2px);
}

.btn-sm {
  padding: 8px 18px;
  font-size: 0.88rem;
}

/* Badge */
.badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 14px;
  border-radius: 999px;
  background: rgba(163, 230, 53, 0.12);
  backdrop-filter: blur(8px);
  border: 1px solid rgba(163, 230, 53, 0.3);
  color: var(--green-lime);
  font-size: 0.82rem;
  font-weight: 600;
  margin-bottom: 20px;
}

/* HERO SECTION */
.hero {
  padding: 80px 0 90px;
  position: relative;
}

.hero-grid {
  display: grid;
  grid-template-columns: 1.15fr 0.85fr;
  gap: 48px;
  align-items: center;
}

.hero-text h1 {
  font-size: clamp(2.3rem, 4.2vw, 3.4rem);
  line-height: 1.15;
  font-weight: 800;
  letter-spacing: -0.03em;
  margin-bottom: 18px;
  text-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
}

.hero-subtitle {
  font-size: 1.12rem;
  color: var(--text-secondary);
  line-height: 1.7;
  margin-bottom: 32px;
}

.hero-subtitle strong {
  color: #ffffff;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  margin-bottom: 40px;
}

.hero-stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
  padding-top: 24px;
  border-top: 1px solid var(--border-glass);
}

.stat-item {
  background: var(--bg-glass);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border: 1px solid var(--border-glass);
  border-radius: var(--radius-md);
  padding: 14px 16px;
  transition: all 0.25s ease;
}

.stat-item:hover {
  border-color: rgba(163, 230, 53, 0.4);
  transform: translateY(-2px);
}

.stat-item strong {
  display: block;
  font-size: 1.05rem;
  color: var(--green-lime);
  margin-bottom: 2px;
}

.stat-item span {
  font-size: 0.84rem;
  color: var(--text-muted);
}

.hero-card {
  background: var(--bg-glass-card);
  backdrop-filter: var(--glass-blur);
  -webkit-backdrop-filter: var(--glass-blur);
  border: 1px solid var(--border-glass);
  border-radius: var(--radius-lg);
  padding: 12px;
  box-shadow: var(--shadow-glass);
  position: relative;
  transition: transform 0.3s ease, border-color 0.3s ease;
}

.hero-card:hover {
  border-color: rgba(255, 255, 255, 0.25);
  transform: translateY(-4px);
}

.hero-banner {
  width: 100%;
  height: auto;
  border-radius: calc(var(--radius-lg) - 6px);
  display: block;
}

/* SECTIONS */
.section {
  padding: 90px 0;
  position: relative;
}

.section-alt {
  background: rgba(6, 17, 33, 0.45);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  border-top: 1px solid var(--border-glass);
  border-bottom: 1px solid var(--border-glass);
}

.section-header {
  text-align: center;
  max-width: 700px;
  margin: 0 auto 52px;
}

.section-tag {
  display: inline-block;
  color: var(--green-lime);
  font-size: 0.84rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  margin-bottom: 10px;
}

.section-header h2 {
  font-size: clamp(1.8rem, 3.2vw, 2.5rem);
  letter-spacing: -0.02em;
  margin-bottom: 14px;
}

.section-header p {
  color: var(--text-secondary);
  font-size: 1.05rem;
}

/* FEATURES GRID (GLASSMORPHISM CARDS) */
.features-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 24px;
}

.feature-card {
  background: var(--bg-glass-card);
  backdrop-filter: var(--glass-blur);
  -webkit-backdrop-filter: var(--glass-blur);
  border: 1px solid var(--border-glass);
  border-radius: var(--radius-md);
  padding: 30px;
  box-shadow: var(--shadow-glass);
  transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.feature-card:hover {
  transform: translateY(-6px);
  background: var(--bg-glass-hover);
  border-color: var(--border-glass-hover);
  box-shadow: var(--shadow-glass-hover);
}

.feature-icon {
  font-size: 2rem;
  margin-bottom: 16px;
  display: inline-block;
  padding: 12px;
  background: rgba(255, 255, 255, 0.05);
  border-radius: 12px;
  border: 1px solid var(--border-glass);
}

.feature-card h3 {
  font-size: 1.2rem;
  margin-bottom: 10px;
  color: #fff;
}

.feature-card p {
  color: var(--text-secondary);
  font-size: 0.95rem;
  line-height: 1.6;
}

/* POLOS REGIONAIS */
.polos-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(340px, 1fr));
  gap: 28px;
}

.polo-card {
  background: var(--bg-glass-card);
  backdrop-filter: var(--glass-blur);
  -webkit-backdrop-filter: var(--glass-blur);
  border: 1px solid var(--border-glass);
  border-radius: var(--radius-lg);
  padding: 36px;
  box-shadow: var(--shadow-glass);
  transition: all 0.3s ease;
}

.polo-card:hover {
  transform: translateY(-5px);
  border-color: rgba(255, 255, 255, 0.25);
}

.polo-card-highlight {
  border-color: rgba(163, 230, 53, 0.4);
  box-shadow: 0 12px 36px rgba(46, 125, 50, 0.2);
}

.polo-badge {
  display: inline-block;
  padding: 5px 14px;
  border-radius: 999px;
  background: rgba(163, 230, 53, 0.15);
  border: 1px solid rgba(163, 230, 53, 0.35);
  color: var(--green-lime);
  font-size: 0.8rem;
  font-weight: 700;
  text-transform: uppercase;
  margin-bottom: 16px;
}

.polo-card h3 {
  font-size: 1.35rem;
  margin-bottom: 18px;
}

.polo-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 12px;
  color: var(--text-secondary);
  font-size: 0.98rem;
}

.polo-list strong {
  color: #fff;
}

/* PROTÓTIPO IOT (HARDWARE + APP) */
.prototype-grid {
  display: grid;
  grid-template-columns: 1.15fr 0.85fr;
  gap: 32px;
  align-items: stretch;
}

.prototype-media-card,
.prototype-info-card {
  background: var(--bg-glass-card);
  backdrop-filter: var(--glass-blur);
  -webkit-backdrop-filter: var(--glass-blur);
  border: 1px solid var(--border-glass);
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-glass);
  display: flex;
  flex-direction: column;
}

.media-label {
  padding: 16px 22px;
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--green-lime);
  border-bottom: 1px solid var(--border-glass);
  background: rgba(6, 17, 33, 0.5);
  display: flex;
  align-items: center;
  gap: 8px;
}

.prototype-video {
  width: 100%;
  height: 100%;
  min-height: 340px;
  max-height: 480px;
  background: #000;
  object-fit: cover;
}

.prototype-image {
  width: 100%;
  height: 250px;
  object-fit: cover;
  border-bottom: 1px solid var(--border-glass);
  transition: transform 0.4s ease;
}

.prototype-info-card:hover .prototype-image {
  transform: scale(1.02);
}

.prototype-details {
  padding: 28px;
}

.prototype-details h3 {
  font-size: 1.3rem;
  margin-bottom: 12px;
  color: #fff;
}

.prototype-details p {
  color: var(--text-secondary);
  font-size: 0.98rem;
  margin-bottom: 20px;
}

.check-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 10px;
  font-size: 0.95rem;
  color: var(--text-primary);
}

.check-list li {
  display: flex;
  align-items: center;
  gap: 8px;
}

.check-list li::before {
  content: "✔";
  color: var(--green-lime);
  font-weight: bold;
}

/* ROLES RBAC */
.roles-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 20px;
}

.role-card {
  background: var(--bg-glass-card);
  backdrop-filter: var(--glass-blur);
  -webkit-backdrop-filter: var(--glass-blur);
  border: 1px solid var(--border-glass);
  border-radius: var(--radius-md);
  padding: 26px;
  box-shadow: var(--shadow-glass);
  transition: all 0.25s ease;
}

.role-card:hover {
  transform: translateY(-4px);
  background: var(--bg-glass-hover);
  border-color: rgba(255, 255, 255, 0.22);
}

.role-card h4 {
  font-size: 1.12rem;
  margin-bottom: 10px;
  color: #fff;
}

.role-card p {
  color: var(--text-secondary);
  font-size: 0.92rem;
  line-height: 1.55;
}

/* CTA BOX */
.cta-section {
  padding: 90px 0;
}

.cta-box {
  background: linear-gradient(135deg, rgba(27, 94, 32, 0.5) 0%, rgba(14, 34, 62, 0.8) 100%);
  backdrop-filter: var(--glass-blur);
  -webkit-backdrop-filter: var(--glass-blur);
  border: 1px solid rgba(163, 230, 53, 0.4);
  border-radius: var(--radius-lg);
  padding: 56px 32px;
  text-align: center;
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.4);
  position: relative;
  overflow: hidden;
}

.cta-box h2 {
  font-size: clamp(1.8rem, 3.4vw, 2.6rem);
  letter-spacing: -0.02em;
  margin-bottom: 14px;
}

.cta-box p {
  color: var(--text-secondary);
  max-width: 620px;
  margin: 0 auto 32px;
  font-size: 1.08rem;
}

/* FOOTER */
.footer {
  border-top: 1px solid var(--border-glass);
  padding: 32px 0;
  background: rgba(4, 11, 20, 0.85);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
}

.footer-content {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
}

.footer-brand {
  display: flex;
  align-items: center;
  gap: 12px;
  font-weight: 600;
  font-size: 0.98rem;
}

.footer-logo {
  height: 30px;
}

.footer-meta {
  font-size: 0.88rem;
  color: var(--text-muted);
}

.footer-meta code {
  color: var(--green-lime);
  background: rgba(255, 255, 255, 0.08);
  padding: 2px 6px;
  border-radius: 4px;
}

/* RESPONSIVIDADE */
@media (max-width: 920px) {
  .hero-grid,
  .prototype-grid {
    grid-template-columns: 1fr;
    gap: 36px;
  }

  .nav-links {
    display: none;
  }

  .hero {
    padding: 52px 0 64px;
  }

  .hero-stats {
    grid-template-columns: 1fr;
    gap: 12px;
  }
}
