/* ==========================================================================
   MÁXIMA COMÉRCIO EXTERIOR - 3D STYLES & WIDGETS (Three.js WebGL Integration)
   ========================================================================== */

/* --- Hero 3D Stage Section --- */
.hero-3d-section {
  position: relative;
  width: 100%;
  min-height: 640px;
  height: 80vh;
  max-height: 850px;
  background: radial-gradient(circle at 76% 48%, #075780 0%, #002a50 24%, #001226 58%, #000814 100%);
  overflow: hidden;
  display: flex;
  align-items: center;
  color: #ffffff;
}

/* 3D WebGL Canvas Layer */
#hero-3d-canvas {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 1;
  outline: none;
  cursor: grab;
}

#hero-3d-canvas:active {
  cursor: grabbing;
}

/* Content Overlay Layer */
.hero-3d-overlay {
  position: relative;
  z-index: 2;
  width: 100%;
  pointer-events: none;
}

.hero-3d-overlay * {
  pointer-events: auto;
}

.hero-grid {
  display: grid;
  grid-template-columns: 1.2fr 0.8fr;
  gap: 40px;
  align-items: center;
}

.hero-content-panel {
  position: relative;
  width: 100%;
  max-width: 760px;
  box-sizing: border-box;
  padding: 38px 40px;
  border: 1px solid rgba(142, 219, 242, .16);
  border-radius: 24px;
  background: linear-gradient(135deg, rgba(0, 20, 43, .72), rgba(0, 45, 77, .32));
  box-shadow: 0 30px 70px rgba(0, 5, 18, .32), inset 0 1px rgba(255,255,255,.08);
  backdrop-filter: blur(13px);
}

.hero-content-panel::before {
  content: '';
  position: absolute;
  inset: 22px auto 22px 0;
  width: 4px;
  border-radius: 0 5px 5px 0;
  background: linear-gradient(180deg, #24ddeb, #0378bf);
  box-shadow: 0 0 20px rgba(36, 221, 235, .4);
}

@media (max-width: 992px) {
  .hero-grid {
    grid-template-columns: 1fr;
    text-align: center;
  }
}

/* Floating Status Pill */
.hero-badge-pill {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  background: rgba(0, 229, 255, 0.1);
  border: 1px solid rgba(0, 229, 255, 0.35);
  padding: 8px 18px;
  border-radius: 9999px;
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--accent-cyan);
  margin-bottom: 24px;
  backdrop-filter: blur(10px);
  box-shadow: 0 0 20px rgba(0, 229, 255, 0.15);
}

.pulse-dot {
  width: 8px;
  height: 8px;
  background-color: var(--accent-cyan);
  border-radius: 50%;
  box-shadow: 0 0 10px var(--accent-cyan);
  animation: pulseGlow 1.8s infinite;
}

@keyframes pulseGlow {
  0% { transform: scale(0.95); box-shadow: 0 0 0 0 rgba(0, 229, 255, 0.7); }
  70% { transform: scale(1); box-shadow: 0 0 0 10px rgba(0, 229, 255, 0); }
  100% { transform: scale(0.95); box-shadow: 0 0 0 0 rgba(0, 229, 255, 0); }
}

/* Hero Typography */
.hero-title {
  font-size: 3.2rem;
  font-weight: 800;
  line-height: 1.15;
  margin-bottom: 20px;
  letter-spacing: -1px;
  background: linear-gradient(135deg, #ffffff 30%, #b0d8ff 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.hero-subtitle {
  font-size: 1.2rem;
  color: #94a3b8;
  margin-bottom: 36px;
  max-width: 600px;
  line-height: 1.6;
  font-weight: 300;
}

/* Hero CTA Group */
.hero-cta-group {
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
}

.hero-assurance {
  display: flex;
  flex-wrap: wrap;
  gap: 12px 24px;
  margin-top: 27px;
  padding-top: 20px;
  border-top: 1px solid rgba(255,255,255,.1);
  color: #b9cad9;
  font-size: .82rem;
  font-weight: 600;
}

.hero-assurance strong { margin-right: 6px; color: var(--accent-cyan); }

.home-proof {
  position: relative;
  z-index: 5;
  margin-top: -36px;
  padding: 0 24px;
}

.home-proof-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1px;
  padding: 0;
  overflow: hidden;
  border: 1px solid #dbe7f0;
  border-radius: 18px;
  background: #dbe7f0;
  box-shadow: 0 18px 45px rgba(8, 44, 75, .13);
}

.home-proof article {
  display: flex;
  align-items: center;
  gap: 17px;
  min-height: 118px;
  padding: 24px 28px;
  background: rgba(255,255,255,.98);
}

.home-proof-icon {
  width: 48px;
  height: 48px;
  flex: none;
  display: grid;
  place-items: center;
  border-radius: 14px;
  background: linear-gradient(145deg, #e5f7fb, #d9eff8);
  color: #0676a8;
}

.home-proof-icon svg { width: 25px; height: 25px; }
.home-proof h3 { margin: 0 0 5px; color: #073d68; font-size: 1rem; }
.home-proof p { margin: 0; color: #657688; font-size: .84rem; line-height: 1.5; }

.home-quality-image {
  width: min(38%, 390px);
  max-width: none;
  height: 230px;
  margin: 0 28px 14px 0;
  object-fit: cover;
  object-position: center;
  border: 1px solid #d4e5ef;
  border-radius: 15px;
  box-shadow: 0 14px 30px rgba(4, 45, 79, .16);
}

@media (max-width: 900px) {
  .hero-content-panel { margin: 0 auto; }
  .home-proof-grid { grid-template-columns: 1fr; }
  .home-proof article { min-height: 90px; }
}

@media (max-width: 600px) {
  .hero-3d-section { min-height: 650px; height: auto; }
  .hero-content-panel { padding: 28px 24px; border-radius: 18px; }
  .hero-title { font-size: 2.15rem; }
  .hero-subtitle { font-size: 1rem; margin-bottom: 26px; }
  .hero-cta-group { flex-direction: column; }
  .hero-cta-group .btn { width: 100%; }
  .hero-assurance { align-items: flex-start; flex-direction: column; }
  .hero-3d-hint { display: none; }
  .home-proof { margin-top: -22px; padding: 0 14px; }
  .home-proof article { padding: 20px; }
  .home-quality-image {
    float: none;
    width: 100%;
    height: 210px;
    margin: 0 0 22px;
  }
}

@media (max-width: 992px) {
  .hero-cta-group {
    justify-content: center;
  }
}

/* Floating 3D Controls hint */
.hero-3d-hint {
  position: absolute;
  bottom: 24px;
  right: 36px;
  z-index: 3;
  background: rgba(0, 18, 38, 0.7);
  backdrop-filter: blur(12px);
  border: 1px solid rgba(255, 255, 255, 0.15);
  padding: 10px 18px;
  border-radius: 9999px;
  font-size: 0.82rem;
  color: #cbd5e1;
  display: flex;
  align-items: center;
  gap: 8px;
  pointer-events: none;
}

.hero-3d-hint svg {
  width: 18px;
  height: 18px;
  color: var(--accent-cyan);
}

/* --- Interactive 3D Cargo Load Estimator / Calculator Widget --- */
.cargo-calculator-section {
  padding: 80px 0;
  background: linear-gradient(180deg, #001226 0%, #001f3f 100%);
  color: #ffffff;
  position: relative;
}

.cargo-calc-card {
  background: rgba(255, 255, 255, 0.04);
  backdrop-filter: blur(16px);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: var(--radius-lg);
  padding: 40px;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 40px;
  box-shadow: 0 30px 60px rgba(0, 0, 0, 0.3);
}

@media (max-width: 992px) {
  .cargo-calc-card {
    grid-template-columns: 1fr;
  }
}

.calc-canvas-wrapper {
  position: relative;
  width: 100%;
  height: 380px;
  background: #000a17;
  border-radius: var(--radius-md);
  overflow: hidden;
  border: 1px solid rgba(0, 229, 255, 0.2);
}

#cargo-3d-canvas {
  width: 100%;
  height: 100%;
  outline: none;
  cursor: grab;
}

.calc-info h3 {
  font-size: 1.8rem;
  font-weight: 700;
  margin-bottom: 12px;
  color: #ffffff;
}

.calc-info p {
  color: #94a3b8;
  margin-bottom: 24px;
  font-size: 0.98rem;
}

.form-group {
  margin-bottom: 18px;
}

.form-group label {
  display: block;
  font-size: 0.85rem;
  font-weight: 600;
  color: #cbd5e1;
  margin-bottom: 6px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.form-control {
  width: 100%;
  padding: 12px 16px;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: var(--radius-sm);
  color: #ffffff;
  font-family: inherit;
  font-size: 0.95rem;
  transition: var(--transition);
}

.form-control:focus {
  outline: none;
  border-color: var(--accent-cyan);
  background: rgba(255, 255, 255, 0.15);
}

.calc-results-box {
  background: rgba(0, 229, 255, 0.08);
  border: 1px solid rgba(0, 229, 255, 0.25);
  border-radius: var(--radius-sm);
  padding: 16px 20px;
  margin-top: 20px;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.result-item span {
  display: block;
  font-size: 0.8rem;
  color: #94a3b8;
}

.result-item strong {
  font-size: 1.4rem;
  color: var(--accent-cyan);
  font-weight: 800;
}
