/* ==========================================================
   ESG ARTICLE STYLES
   ========================================================== */

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --color-text: #333333;
  --color-text-secondary: #666666;
  --color-accent: #10069f;
  --color-accent-dark: #007a7d;
  --color-heading: #1a1f29;
  --color-border: #e8e8e8;
  --color-bg: #ffffff;
  --color-bg-light: #f8f9fa;
  --color-note-bg: #f0f7f7;
  --color-note-border: #009598;
  --font: 'Montserrat', Arial, sans-serif;
}

/* ===== PAGE ===== */
.esg__page-wrapper { max-width: 1200px; margin: 0 auto; padding: 0 20px; }
.esg__article-content { min-width: 0; }

/* ===== TYPOGRAPHY ===== */
.esg__article-h1 {
  font-family: var(--font); font-size: 28px; font-weight: 400;
  color: var(--color-heading); line-height: 1.3; margin-bottom: 32px;
}
.esg__article-intro {
  font-size: 16px; color: var(--color-text-secondary);
  line-height: 1.7; margin-bottom: 40px;
}
.esg__article-h2 {
  font-family: var(--font); font-size: 20px; font-weight: 700;
  color: var(--color-heading); margin-top: 40px; margin-bottom: 16px;
  padding-bottom: 12px; border-bottom: 2px solid var(--color-accent);
  display: inline-block;
}
.esg__article-p {
  font-size: 15px; color: var(--color-text-secondary);
  line-height: 1.75; margin-bottom: 16px;
}

/* ===== STEP BLOCKS ===== */
.esg__step-block {
  display: grid;
  grid-template-columns: 1fr 300px;
  gap: 32px;
  align-items: center;
  background: var(--color-bg-light);
  border-left: 4px solid var(--color-accent);
  border-radius: 0 8px 8px 0;
  padding: 28px 28px 28px 24px;
  margin: 32px 0;
}
.esg__step-block--reversed {
  grid-template-columns: 300px 1fr;
  border-left: none;
  border-right: 4px solid var(--color-accent);
  border-radius: 8px 0 0 8px;
}
.esg__step-block--reversed .esg__step-block-content { order: 2; }
.esg__step-block--reversed .esg__step-visual { order: 1; }

.esg__step-block--vertical {
  grid-template-columns: 1fr;
  border-left: 4px solid var(--color-accent);
  border-right: none;
  border-radius: 0 8px 8px 0;
}
.esg__step-block--vertical .esg__step-block-content { order: 1; }
.esg__step-block--vertical .esg__step-img-wrap { order: 2; text-align: center; margin-top: 8px; }
.esg__step-block--reversed .esg__step-img-wrap img { max-width: 350px; width: 100%; height: auto; border-radius: 8px; }

.esg__step-block-content { min-width: 0; }
.esg__step-number {
  font-size: 13px; font-weight: 700; color: var(--color-accent);
  text-transform: uppercase; letter-spacing: 1px; margin-bottom: 6px;
}
.esg__step-block .esg__article-h2 {
  margin-top: 0; margin-bottom: 12px; font-size: 18px;
  border-bottom: none; padding-bottom: 0;
}
.esg__step-block .esg__article-p { margin-bottom: 12px; max-width: 100%; }

/* ===== NOTE BLOCK ===== */
.esg__note-block {
  background: var(--color-note-bg); border-left: 4px solid var(--color-note-border);
  padding: 14px 18px; border-radius: 0 6px 6px 0; margin: 12px 0 20px;
  font-size: 14px; color: #555; line-height: 1.6; max-width: 680px;
}
.esg__note-block strong { color: var(--color-accent-dark); }

/* ===== BULLET LIST ===== */
.esg__article-list { list-style: none; margin: 12px 0 20px 0; padding: 0; max-width: 680px; }
.esg__article-list li {
  position: relative; padding-left: 20px; margin-bottom: 10px;
  font-size: 15px; color: var(--color-text-secondary); line-height: 1.6;
}
.esg__article-list li::before {
  content: '' !important; margin: 0 !important;
  position: absolute; left: 0; top: 9px; width: 8px; height: 2px;
  background: var(--color-accent);
}

/* ===== TABLE ===== */
.esg__table-section { margin: 40px 0; }
.esg__table-title { font-size: 17px; font-weight: 700; color: var(--color-heading); margin-bottom: 16px; }
.esg__rms-table {
  width: 100%; border-collapse: collapse; font-size: 14px;
  overflow: hidden; border-radius: 8px; border: 1px solid var(--color-border);
}
.esg__rms-table thead tr { background: var(--color-accent); color: #fff; }
.esg__rms-table thead th {
  padding: 13px 14px; text-align: left; font-weight: 600; font-size: 13px;
  border-right: 1px solid rgba(255,255,255,0.1);
}
.esg__rms-table thead th:last-child { border-right: none; }
.esg__rms-table tbody tr { border-bottom: 1px solid var(--color-border); transition: background 0.15s; }
.esg__rms-table tbody tr:last-child { border-bottom: none; }
.esg__rms-table tbody tr:hover { background: #f5fafa; }
.esg__rms-table tbody td {
  padding: 11px 14px; color: var(--color-text-secondary);
  vertical-align: top; border-right: 1px solid var(--color-border); line-height: 1.5;
}
.esg__rms-table tbody td:last-child { border-right: none; }
.esg__rms-table tbody tr:nth-child(even) td { background: #fafafa; }
.esg__rms-table tbody tr:nth-child(even):hover td { background: #f5fafa; }
.esg__rms-table .esg__material-tag {
  display: inline-block; background: #e8f5f5; color: var(--color-accent-dark);
  padding: 2px 8px; border-radius: 4px; font-size: 12px; font-weight: 600; white-space: nowrap;
}
.esg__table-note { font-size: 13px; color: #888; margin-top: 10px; font-style: italic; }


/* ==========================================================
   VISUAL BLOCKS — floating cards
   ========================================================== */

.esg__step-visual {
  width: 300px;
  height: 320px;
  flex-shrink: 0;
  position: relative;
  align-self: center;
}

/* --- Glow backgrounds --- */
.esg__vis-glow {
  position: absolute;
  border-radius: 50%;
  filter: blur(45px);
  pointer-events: none;
  z-index: 0;
}
.esg__vis-glow--1 { width: 120px; height: 120px; background: rgba(16,6,159,0.07); top: 10%; left: 5%; animation: esgGlow1 8s ease-in-out infinite; }
.esg__vis-glow--2 { width: 100px; height: 100px; background: rgba(0,122,125,0.07); bottom: 15%; right: 5%; animation: esgGlow2 10s ease-in-out infinite; }

/* --- Connector lines --- */
.esg__vis-lines { position: absolute; inset: 0; pointer-events: none; z-index: 1; }
.esg__vis-lines svg { width: 100%; height: 100%; }

/* --- Floating card base --- */
.esg__vis-card {
  position: absolute;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 16px;
  background: #fff;
  border: 1px solid rgba(0,0,0,0.06);
  border-radius: 14px;
  box-shadow: 0 4px 16px rgba(0,0,0,0.07);
  font-family: var(--font);
  font-size: 13px;
  font-weight: 500;
  color: var(--color-heading);
  white-space: nowrap;
  z-index: 2;
}

/* --- Icon square --- */
.esg__vis-icon {
  width: 36px; height: 36px;
  display: flex; align-items: center; justify-content: center;
  border-radius: 10px; flex-shrink: 0;
}
.esg__vis-icon svg { width: 18px; height: 18px; }
.esg__vis-icon--accent { background: var(--color-accent); color: #fff; }
.esg__vis-icon--teal { background: var(--color-accent-dark); color: #fff; }
.esg__vis-icon--light { background: #eef0ff; color: var(--color-accent); }
.esg__vis-icon--teal-light { background: #e6f5f5; color: var(--color-accent-dark); }

.esg__vis-icon--sm { width: 28px; height: 28px; border-radius: 8px; }
.esg__vis-icon--sm svg { width: 14px; height: 14px; }

/* --- Badge --- */
.esg__vis-badge {
  display: inline-block; padding: 2px 10px;
  border-radius: 100px; font-size: 11px; font-weight: 600;
}
.esg__vis-badge--green { background: #dcfce7; color: #16a34a; }
.esg__vis-badge--accent { background: #eef0ff; color: var(--color-accent); }
.esg__vis-badge--teal { background: #e6f5f5; color: var(--color-accent-dark); }

/* --- Main card (featured) --- */
.esg__vis-card--main {
  padding: 16px 20px;
  border: 2px solid var(--color-accent);
  border-radius: 18px;
  box-shadow: 0 8px 28px rgba(16,6,159,0.12);
  z-index: 3;
}
.esg__vis-card--main-teal {
  border-color: var(--color-accent-dark);
  box-shadow: 0 8px 28px rgba(0,122,125,0.12);
}

/* --- Micro pill card --- */
.esg__vis-card--pill {
  padding: 6px 12px;
  font-size: 11px;
  border-radius: 100px;
}

/* =============================================
   STEP 1 positions
   ============================================= */
.esg__s1-main { top: 20px; left: 50%; margin-left: -110px; /* half of ~220px card */ }
.esg__s1-metal { bottom: 20px; left: 0; }
.esg__s1-plastic { bottom: 70px; left: 50%; margin-left: -70px; }
.esg__s1-other { bottom: 20px; right: 0; }

/* =============================================
   STEP 2 positions
   ============================================= */
.esg__s2-main { top: 20px; left: 50%; margin-left: -100px; }
.esg__s2-paper { bottom: 20px; left: 0; }
.esg__s2-film { bottom: 75px; left: 50%; margin-left: -67px; }
.esg__s2-metal { bottom: 20px; right: 0; }
.esg__s2-recycle { top: 110px; right: 0; }

/* =============================================
   STEP 3 positions
   ============================================= */
.esg__s3-main { top: 50%; left: 50%; margin-top: -28px; margin-left: -118px; }
.esg__s3-pill1 { top: 60px; left: 5px; }
.esg__s3-pill2 { top: 15px; right: 5px; }
.esg__s3-pill3 { bottom: 50px; left: 50%; margin-left: -62px; }


/* ==========================================================
   ANIMATIONS
   ========================================================== */
@keyframes esgFloat1 {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-10px); }
}
@keyframes esgFloat2 {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-7px); }
}
@keyframes esgFloat3 {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-12px); }
}
@keyframes esgPulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.5; }
}
@keyframes esgGlow1 {
  0%, 100% { transform: translate(0, 0) scale(1); }
  50% { transform: translate(10px, -10px) scale(1.1); }
}
@keyframes esgGlow2 {
  0%, 100% { transform: translate(0, 0) scale(1); }
  50% { transform: translate(-10px, 10px) scale(1.15); }
}

.esg__float1 { animation: esgFloat1 4s ease-in-out infinite; }
.esg__float2 { animation: esgFloat2 4.5s ease-in-out infinite 0.6s; }
.esg__float3 { animation: esgFloat3 5s ease-in-out infinite 1.2s; }
.esg__pulse  { animation: esgPulse 2s ease-in-out infinite; }


/* ==========================================================
   RESPONSIVE
   ========================================================== */
@media (max-width: 900px) {
  .esg__step-block,
  .esg__step-block--reversed { grid-template-columns: 1fr; }
  .esg__step-block--reversed .esg__step-block-content { order: 1; }
  .esg__step-block--reversed .esg__step-visual { order: 2; }
  .esg__step-visual { width: 280px; height: 280px; margin: 0 auto; }
  .esg__article-h1 { font-size: 22px; }
  .esg__rms-table { font-size: 12px; }
  .esg__rms-table thead th,
  .esg__rms-table tbody td { padding: 9px 10px; }
}