/**
 * Platform Section Styles
 * 
 * Styles for the Platform Section Elementor widget
 * Extracted from agrovue-landing-html/css/style.css
 * 
 * @package Meridian_Africa
 * @since 1.0.0
 */

/* ===========================
   PLATFORM SECTION
   =========================== */

.platform {
  padding: 120px 0;
  background: linear-gradient(180deg, #f0fdf4 0%, #ffffff 30%, #f8fdf9 70%, #ecfdf5 100%);
  position: relative;
  overflow: hidden;
}

/* Animated Background Shapes */
.platform-background-shapes {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  overflow: hidden;
  pointer-events: none;
  z-index: 0;
}

.platform-background-shapes .shape {
  position: absolute;
  border-radius: 50%;
  opacity: 0.08;
  animation: float 20s infinite ease-in-out;
}

@keyframes float {
  0%, 100% {
    transform: translate(0, 0) rotate(0deg);
  }
  33% {
    transform: translate(30px, -30px) rotate(120deg);
  }
  66% {
    transform: translate(-20px, 20px) rotate(240deg);
  }
}

.platform-background-shapes .shape-1 {
  width: 400px;
  height: 400px;
  background: linear-gradient(135deg, #2e8f33, #25a244);
  top: -100px;
  left: -100px;
  animation-delay: 0s;
}

.platform-background-shapes .shape-2 {
  width: 300px;
  height: 300px;
  background: linear-gradient(135deg, #25a244, #2e8f33);
  bottom: -80px;
  right: -80px;
  animation-delay: 5s;
}

.platform-background-shapes .shape-3 {
  width: 250px;
  height: 250px;
  background: linear-gradient(135deg, #2e8f33, #1f7a2a);
  top: 50%;
  right: 10%;
  animation-delay: 10s;
}

.platform .container {
  position: relative;
  z-index: 1;
}

.platform .section-header {
  text-align: center;
  max-width: 900px;
  margin: 0 auto 70px;
}

.badge-pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: linear-gradient(135deg, rgba(46, 143, 51, 0.1), rgba(37, 162, 68, 0.1));
  color: #2e8f33;
  padding: 10px 24px;
  border-radius: 50px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 1.8px;
  margin-bottom: 24px;
  border: 2px solid #2e8f33;
  text-transform: uppercase;
  backdrop-filter: blur(10px);
  transition: all 0.3s ease;
}

.badge-pill:hover {
  background: linear-gradient(135deg, rgba(46, 143, 51, 0.15), rgba(37, 162, 68, 0.15));
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(46, 143, 51, 0.2);
}

.badge-icon {
  display: flex;
  align-items: center;
  justify-content: center;
}

.badge-icon svg {
  width: 16px;
  height: 16px;
  stroke: #2e8f33;
}

.platform .section-header h2 {
  font-size: 48px;
  font-weight: 800;
  color: #0a2e0d;
  margin-bottom: 20px;
  line-height: 1.2;
  background: linear-gradient(135deg, #0a2e0d 0%, #2e8f33 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.platform .section-header p {
  font-size: 17px;
  color: #4a5568;
  line-height: 1.8;
  max-width: 820px;
  margin: 0 auto;
  font-weight: 400;
}

.platform-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
  margin-top: 70px;
}

.platform-card {
  background: linear-gradient(145deg, #ffffff 0%, #f8fdf9 100%);
  border-radius: 24px;
  padding: 0;
  border: 1px solid rgba(46, 143, 51, 0.1);
  transition: all 0.6s cubic-bezier(0.34, 1.56, 0.64, 1);
  position: relative;
  overflow: hidden;
  box-shadow: 0 8px 30px rgba(46, 143, 51, 0.06),
              0 2px 8px rgba(0, 0, 0, 0.04);
  display: flex;
  flex-direction: column;
  min-height: 520px;
  cursor: pointer;
}

/* Animated Gradient Border */
.platform-card::before {
  content: '';
  position: absolute;
  top: -2px;
  left: -2px;
  right: -2px;
  bottom: -2px;
  background: linear-gradient(135deg, #2e8f33, #4ade80, #2e8f33, #10b981);
  background-size: 300% 300%;
  border-radius: 24px;
  z-index: -1;
  opacity: 0;
  transition: opacity 0.6s ease;
  animation: gradientShift 4s ease infinite;
}

@keyframes gradientShift {
  0%, 100% {
    background-position: 0% 50%;
  }
  50% {
    background-position: 100% 50%;
  }
}

.platform-card:hover::before {
  opacity: 1;
}

/* Glow Effect */
.platform-card::after {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  width: 0;
  height: 0;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(46, 143, 51, 0.15), transparent 70%);
  transform: translate(-50%, -50%);
  transition: width 0.6s ease, height 0.6s ease;
  z-index: 0;
  pointer-events: none;
}

.platform-card:hover::after {
  width: 500px;
  height: 500px;
}

/* Card Content Wrapper */
.card-content-verification {
  padding: 40px 32px;
  position: relative;
  z-index: 2;
  flex: 1;
  display: flex;
  flex-direction: column;
  transition: transform 0.6s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.platform-card:hover .card-content-verification {
  transform: translateY(-8px);
}

/* Background Image - New Design */
.card-background-image {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-size: cover;
  background-position: center;
  transition: all 0.8s cubic-bezier(0.34, 1.56, 0.64, 1);
  z-index: 1;
  opacity: 0;
  filter: blur(2px);
}

.card-background-image::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(135deg, rgba(46, 143, 51, 0.92), rgba(16, 185, 129, 0.88));
  opacity: 0;
  transition: opacity 0.6s ease;
}

.platform-card:hover .card-background-image {
  opacity: 1;
  transform: scale(1.05);
  filter: blur(0px);
}

.platform-card:hover .card-background-image::before {
  opacity: 1;
}

/* Corner Accent - Redesigned */
.card-corner-accent {
  position: absolute;
  top: -50px;
  right: -50px;
  width: 150px;
  height: 150px;
  background: radial-gradient(circle, rgba(46, 143, 51, 0.08), transparent 70%);
  border-radius: 50%;
  transition: all 0.6s cubic-bezier(0.34, 1.56, 0.64, 1);
  z-index: 1;
}

.platform-card:hover .card-corner-accent {
  top: -30px;
  right: -30px;
  width: 200px;
  height: 200px;
  background: radial-gradient(circle, rgba(46, 143, 51, 0.15), transparent 70%);
}

.platform-card:hover {
  transform: translateY(-16px) scale(1.02);
  box-shadow: 0 30px 80px rgba(46, 143, 51, 0.25),
              0 10px 30px rgba(0, 0, 0, 0.1);
  border-color: rgba(46, 143, 51, 0.3);
}

/* Shimmer Overlay Effect */
.platform-card .card-shimmer {
  position: absolute;
  top: -100%;
  left: -100%;
  width: 300%;
  height: 300%;
  background: linear-gradient(
    45deg,
    transparent 30%,
    rgba(255, 255, 255, 0.1) 50%,
    transparent 70%
  );
  transform: rotate(45deg);
  transition: all 0.8s ease;
  pointer-events: none;
  z-index: 10;
}

.platform-card:hover .card-shimmer {
  left: 100%;
  top: 100%;
}

/* Capability Header */
.capability-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 28px;
  position: relative;
  z-index: 3;
}

.capability-number {
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 1.5px;
  color: #2e8f33;
  background: rgba(46, 143, 51, 0.08);
  padding: 8px 16px;
  border-radius: 8px;
  border: 1px solid rgba(46, 143, 51, 0.2);
  transition: all 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.platform-card:hover .capability-number {
  background: rgba(46, 143, 51, 0.15);
  border-color: rgba(46, 143, 51, 0.4);
  transform: translateX(-5px);
  color: #ffffff;
  background: linear-gradient(135deg, #2e8f33, #25a244);
}

.capability-icon {
  width: 56px;
  height: 56px;
  background: linear-gradient(135deg, #2e8f33, #4ade80);
  border-radius: 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 8px 24px rgba(46, 143, 51, 0.25);
  transition: all 0.6s cubic-bezier(0.34, 1.56, 0.64, 1);
  position: relative;
  overflow: hidden;
}

.capability-icon::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.3), transparent);
  transition: left 0.6s ease;
}

.platform-card:hover .capability-icon {
  transform: rotate(360deg) scale(1.15);
  box-shadow: 0 12px 40px rgba(46, 143, 51, 0.4);
  background: linear-gradient(135deg, #4ade80, #2e8f33);
}

.platform-card:hover .capability-icon::before {
  left: 100%;
}

.capability-icon svg {
  width: 28px;
  height: 28px;
  stroke: white;
  position: relative;
  z-index: 1;
}

.platform-card h3 {
  font-size: 26px;
  font-weight: 800;
  margin-bottom: 16px;
  color: #0a2e0d;
  line-height: 1.3;
  transition: all 0.4s ease;
  position: relative;
  z-index: 3;
}

.platform-card:hover h3 {
  color: #ffffff;
  transform: translateX(5px);
}

.platform-card p {
  font-size: 15px;
  color: #4a5568;
  margin-bottom: 24px;
  line-height: 1.8;
  font-weight: 400;
  transition: all 0.4s ease;
  position: relative;
  z-index: 3;
}

.platform-card:hover p {
  color: rgba(255, 255, 255, 0.95);
}

.platform-technical {
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding: 20px;
  background: rgba(46, 143, 51, 0.05);
  border-radius: 16px;
  border: 1px solid rgba(46, 143, 51, 0.1);
  position: relative;
  z-index: 3;
  margin-top: auto;
  transition: all 0.4s ease;
  backdrop-filter: blur(10px);
}

.platform-card:hover .platform-technical {
  background: rgba(255, 255, 255, 0.15);
  border-color: rgba(255, 255, 255, 0.3);
  transform: translateY(-5px);
}

.tech-detail {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 14px;
  padding: 0;
  transition: all 0.3s ease;
}

.platform-card:hover .tech-detail {
  transform: translateX(3px);
}

.tech-label {
  font-weight: 600;
  color: #2e8f33;
  transition: color 0.3s ease;
}

.platform-card:hover .tech-label {
  color: rgba(255, 255, 255, 0.9);
}

.tech-value {
  font-weight: 500;
  color: #4a5568;
  transition: color 0.3s ease;
}

.platform-card:hover .tech-value {
  color: rgba(255, 255, 255, 0.85);
}

/* Learn More Button */
.learn-more-btn {
  margin-top: 20px;
  padding: 16px 32px;
  background: rgba(255, 255, 255, 0.1);
  color: #2e8f33;
  border: 2px solid #2e8f33;
  border-radius: 14px;
  font-size: 15px;
  font-weight: 700;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  transition: all 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
  position: relative;
  z-index: 3;
  overflow: hidden;
  opacity: 0;
  transform: translateY(10px) scale(0.95);
  pointer-events: none;
}

.platform-card:hover .learn-more-btn {
  opacity: 1;
  transform: translateY(0) scale(1);
  pointer-events: auto;
  background: #ffffff;
  color: #2e8f33;
  border-color: #ffffff;
  box-shadow: 0 8px 30px rgba(255, 255, 255, 0.3);
}

.learn-more-btn::before {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  width: 0;
  height: 0;
  border-radius: 50%;
  background: rgba(46, 143, 51, 0.1);
  transform: translate(-50%, -50%);
  transition: width 0.6s ease, height 0.6s ease;
}

.learn-more-btn:hover::before {
  width: 300px;
  height: 300px;
}

.learn-more-btn svg {
  transition: transform 0.3s ease;
}

.learn-more-btn:hover svg {
  transform: translateX(6px);
}

/* Platform Modal */
.platform-modal {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 10000;
  animation: fadeIn 0.3s ease;
}

@keyframes fadeIn {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}

.platform-modal.active {
  display: flex;
  align-items: center;
  justify-content: center;
}

.platform-modal-overlay {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(10, 46, 13, 0.85);
  backdrop-filter: blur(8px);
}

.platform-modal-content {
  position: relative;
  background: white;
  border-radius: 24px;
  max-width: 900px;
  width: 90%;
  max-height: 90vh;
  overflow-y: auto;
  box-shadow: 0 25px 50px rgba(0, 0, 0, 0.3);
  animation: slideUp 0.4s cubic-bezier(0.4, 0, 0.2, 1);
  z-index: 10001;
}

@keyframes slideUp {
  from {
    opacity: 0;
    transform: translateY(50px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.platform-modal-close {
  position: absolute;
  top: 20px;
  right: 20px;
  width: 44px;
  height: 44px;
  background: rgba(255, 255, 255, 0.95);
  border: none;
  border-radius: 50%;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.3s ease;
  z-index: 10002;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
}

.platform-modal-close:hover {
  background: white;
  transform: rotate(90deg);
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.3);
}

.platform-modal-close svg {
  stroke: #0a2e0d;
}

.platform-modal-header {
  position: relative;
  height: 300px;
  border-radius: 24px 24px 0 0;
  overflow: hidden;
}

.modal-header-image {
  width: 100%;
  height: 100%;
  background-size: cover;
  background-position: center;
  position: relative;
}

.modal-header-overlay {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  padding: 40px;
  background: linear-gradient(to top, rgba(10, 46, 13, 0.95), rgba(10, 46, 13, 0.7), transparent);
  color: white;
}

.modal-header-overlay h2 {
  font-size: 36px;
  font-weight: 800;
  margin-bottom: 12px;
  color: white;
}

.modal-header-overlay p {
  font-size: 16px;
  color: rgba(255, 255, 255, 0.9);
  line-height: 1.6;
}

.platform-modal-body {
  padding: 50px;
}

.modal-section {
  margin-bottom: 40px;
}

.modal-section h3 {
  font-size: 24px;
  font-weight: 700;
  color: #0a2e0d;
  margin-bottom: 16px;
}

.modal-section p {
  font-size: 16px;
  color: #4a5568;
  line-height: 1.8;
}

.modal-highlight {
  background: linear-gradient(135deg, rgba(46, 143, 51, 0.05), rgba(37, 162, 68, 0.05));
  padding: 30px;
  border-radius: 16px;
  border-left: 4px solid #2e8f33;
}

.modal-image-section {
  margin-top: 30px;
}

.modal-image-section img {
  width: 100%;
  border-radius: 16px;
  box-shadow: 0 8px 30px rgba(0, 0, 0, 0.1);
}

.platform-stats {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
  padding-top: 20px;
  border-top: 1px solid #e0e0e0;
}

.platform-stats .stat-item {
  display: flex;
  flex-direction: column;
}

.platform-stats .stat-value {
  font-size: 18px;
  font-weight: 700;
  color: #2e8f33;
}

.platform-stats .stat-label {
  font-size: 11px;
  color: #4a5568;
  font-weight: 600;
  letter-spacing: 0.5px;
  margin-top: 4px;
}

/* ===========================
   RESPONSIVE STYLES
   =========================== */

/* Tablet - max-width: 1024px */
@media (max-width: 1024px) {
  .platform {
    padding: 70px 0;
  }

  .platform-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 24px;
  }

  .platform .section-header h2 {
    font-size: 38px;
  }

  .platform-card {
    min-height: 420px;
  }

  .card-content-verification {
    padding: 32px 28px;
  }

  .capability-header {
    margin-bottom: 16px;
  }

  .capability-number {
    font-size: 9px;
    padding: 5px 12px;
  }

  .capability-icon {
    width: 42px;
    height: 42px;
  }

  .capability-icon svg {
    width: 20px;
    height: 20px;
  }

  .platform-card h3 {
    font-size: 20px;
  }

  .platform-card p {
    font-size: 14px;
    margin-bottom: 24px;
  }

  .platform-technical {
    gap: 12px;
    padding-top: 20px;
  }

  .tech-detail {
    font-size: 13px;
    padding: 6px 0;
  }

  .tech-label {
    min-width: 80px;
    font-size: 12px;
  }

  .tech-value {
    font-size: 12px;
  }

  .card-corner-accent {
    width: 60px;
    height: 60px;
  }
}

/* Mobile - max-width: 768px */
@media (max-width: 768px) {
  .platform {
    padding: 60px 0;
  }

  .platform-grid {
    grid-template-columns: 1fr;
    gap: 24px;
  }

  .platform-card {
    min-height: 400px;
  }

  .card-content-verification {
    padding: 28px 24px;
  }

  .capability-number {
    font-size: 11px;
  }

  .platform-card h3 {
    font-size: 20px;
  }

  .platform-card p {
    font-size: 14px;
  }

  .platform-technical {
    flex-direction: column;
    gap: 12px;
  }

  .tech-detail {
    font-size: 13px;
  }

  .learn-more-btn {
    padding: 12px 24px;
    font-size: 14px;
  }

  .platform-modal-content {
    width: 95%;
    max-height: 95vh;
  }

  .platform-modal-header {
    height: 220px;
  }

  .modal-header-overlay {
    padding: 24px;
  }

  .modal-header-overlay h2 {
    font-size: 26px;
  }

  .modal-header-overlay p {
    font-size: 14px;
  }

  .platform-modal-body {
    padding: 28px 20px;
  }

  .modal-section h3 {
    font-size: 18px;
  }

  .modal-section p {
    font-size: 14px;
  }

  .modal-highlight {
    padding: 20px;
  }

  .platform .section-header {
    margin-bottom: 40px;
  }

  .platform .section-header h2 {
    font-size: 30px;
    line-height: 1.3;
  }

  .platform .section-header p {
    font-size: 14px;
    line-height: 1.7;
  }

  .badge-pill {
    font-size: 9px;
    padding: 8px 16px;
    gap: 6px;
  }

  .badge-icon svg {
    width: 14px;
    height: 14px;
  }

  .platform-grid {
    gap: 24px;
    margin-top: 40px;
  }

  .card-corner-accent {
    width: 50px;
    height: 50px;
    border-radius: 0 16px 0 80%;
  }

  .platform-card:hover {
    transform: translateY(-6px) scale(1.01);
  }

  .learn-more-btn {
    padding: 11px 22px;
    font-size: 13px;
  }

  .platform-modal-content {
    width: 92%;
  }

  .platform-modal-header {
    height: 200px;
  }

  .modal-header-overlay h2 {
    font-size: 24px;
  }

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

/* Extra Small Devices - max-width: 360px */
@media (max-width: 360px) {
  .platform {
    padding: 50px 0;
  }

  .platform .section-header h2 {
    font-size: 26px;
  }

  .platform .section-header p {
    font-size: 13px;
  }

  .badge-pill {
    font-size: 8px;
    padding: 6px 14px;
  }

  .platform-grid {
    gap: 20px;
  }

  .platform-card {
    min-height: 380px;
  }

  .card-content-verification {
    padding: 24px 20px;
  }

  .capability-number {
    font-size: 7px;
    padding: 4px 8px;
  }

  .capability-icon {
    width: 36px;
    height: 36px;
  }

  .capability-icon svg {
    width: 16px;
    height: 16px;
  }

  .platform-card h3 {
    font-size: 17px;
  }

  .platform-card p {
    font-size: 13px;
  }

  .tech-label,
  .tech-value {
    font-size: 10px;
  }

  .tech-label {
    min-width: 70px;
  }

  .learn-more-btn {
    padding: 10px 20px;
    font-size: 12px;
  }

  .platform-modal-close {
    width: 38px;
    height: 38px;
    top: 15px;
    right: 15px;
  }

  .platform-modal-header {
    height: 180px;
  }

  .modal-header-overlay {
    padding: 20px;
  }

  .modal-header-overlay h2 {
    font-size: 22px;
  }

  .modal-header-overlay p {
    font-size: 13px;
  }

  .platform-modal-body {
    padding: 24px 18px;
  }

  .modal-section h3 {
    font-size: 17px;
  }

  .modal-section p {
    font-size: 13px;
  }

  .modal-highlight {
    padding: 18px;
  }
}

