/* =====================================================================
   Green City SEZ — Property Due-Diligence Scorecard Stylesheet
   Unique Prefix: .pds-
   Slim Height Edition (Width Preserved, Ultra-Compact Vertical Height)
   Theme: Deep Emerald (#08362A) & Luxury Rose Gold (#E8B4A8)
   ===================================================================== */

:root {
  /* Green City SEZ Theme Tokens */
  --pds-color-rose: #E8B4A8;
  --pds-color-rose-light: #f7ded8;
  --pds-color-rose-dark: #c48b7e;
  --pds-color-rose-border: rgba(232, 180, 168, 0.4);
  --pds-color-rose-glow: rgba(232, 180, 168, 0.28);
  --pds-color-rose-bg: rgba(232, 180, 168, 0.1);

  --pds-emerald-deep: #08362A;
  --pds-emerald-dark: #05241c;
  --pds-emerald-card: #082d22;
  --pds-emerald-inner: #0b382b;
  --pds-emerald-mid: #125C46;

  --pds-cream-bg: #F6EFDD;
  --pds-cream-alt: #FBF7EC;
  --pds-cream-soft: #FAF8F5;

  --pds-text-dark: #20231F;
  --pds-text-muted: #95ADA5;
  --pds-text-bright: #FAF8F5;

  /* Dynamic Alert State Colors */
  --pds-danger-bg: linear-gradient(135deg, rgba(80, 15, 25, 0.45) 0%, rgba(40, 8, 12, 0.7) 100%);
  --pds-danger-border: rgba(239, 68, 68, 0.55);
  --pds-danger-text: #FCA5A5;

  --pds-warning-bg: linear-gradient(135deg, rgba(80, 50, 10, 0.45) 0%, rgba(40, 25, 5, 0.7) 100%);
  --pds-warning-border: rgba(245, 158, 11, 0.55);
  --pds-warning-text: #FDE68A;

  --pds-success-bg: linear-gradient(135deg, rgba(14, 68, 52, 0.6) 0%, rgba(8, 44, 34, 0.8) 100%);
  --pds-success-border: #E8B4A8;
  --pds-success-text: #FAF8F5;
}

/* Fullscreen Confetti Canvas */
#pdsConfettiCanvas {
  position: fixed;
  inset: 0;
  width: 100vw;
  height: 100vh;
  pointer-events: none;
  z-index: 99999;
}

/* Outer Single-Page Wrapper (Width preserved) */
.pds-wrapper {
  width: 100%;
  max-width: 95%;
  margin: 10px auto;
  box-sizing: border-box;
  font-family: var(--font-body, "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif);
  color: var(--pds-text-bright);
}

/* Master Scorecard Container (Slim Height) */
.pds-scorecard-card {
  position: relative;
  background: radial-gradient(circle at 85% 15%, rgba(18, 92, 70, 0.35) 0%, transparent 60%),
              radial-gradient(circle at 15% 85%, rgba(8, 54, 42, 0.45) 0%, transparent 55%),
              linear-gradient(165deg, #072e24 0%, #05221a 60%, #03140f 100%);
  border: 1px solid var(--pds-color-rose-border);
  border-radius: 12px !important;
  padding: 0.6rem 1rem;
  box-shadow: 0 12px 35px rgba(0, 0, 0, 0.5),
              0 0 0 1px rgba(232, 180, 168, 0.1),
              inset 0 1px 0 rgba(232, 180, 168, 0.2);
  overflow: hidden;
}

/* Subtle blueprint background grid */
.pds-scorecard-card::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image: 
    linear-gradient(rgba(232, 180, 168, 0.03) 1px, transparent 1px),
    linear-gradient(90deg, rgba(232, 180, 168, 0.03) 1px, transparent 1px);
  background-size: 18px 18px;
  pointer-events: none;
}

/* Top Indicator Dots */
.pds-top-indicators {
  display: flex;
  align-items: center;
  gap: 5px;
  margin-bottom: 0.25rem;
}

.pds-indicator-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%  !important;
  background: var(--pds-color-rose);
  box-shadow: 0 0 6px rgba(232, 180, 168, 0.8);
  border: 1px solid rgba(255, 255, 255, 0.5);
}

.pds-indicator-dot:nth-child(2) {
  background: var(--pds-color-rose-light);
  box-shadow: 0 0 6px rgba(247, 222, 216, 0.8);
}

/* Main Grid Layout */
.pds-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.55fr) minmax(0, 1fr);
  gap: 0.85rem;
  align-items: stretch;
  position: relative;
  z-index: 2;
}

/* =========================================================
   LEFT COLUMN: CHECKLIST & SLIM HEADERS
   ========================================================= */
.pds-left-col {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.pds-header-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
  margin-bottom: 0.1rem;
}

.pds-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  font-size: 0.65rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--pds-color-rose) !important;
  margin-bottom: 0.05rem;
}

.pds-eyebrow::before {
  content: "";
  width: 12px;
  height: 1.5px;
  background: var(--pds-color-rose);
  display: inline-block;
  border-radius: 1px !important;
}

.pds-title {
  font-family: var(--font-display, "Playfair Display", Georgia, serif);
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--pds-cream-soft);
  line-height: 1.15;
  margin: 0;
  letter-spacing: -0.01em;
}

/* Slim Reset Button */
.pds-btn-reset {
  display: inline-flex;
  align-items: center;
  gap: 0.25rem;
  background: rgba(8, 54, 42, 0.7);
  border: 1px solid var(--pds-color-rose-border);
  color: var(--pds-color-rose-light);
  font-size: 0.68rem;
  font-weight: 600;
  padding: 0.2rem 0.5rem;
  border-radius: 5px !important;
  cursor: pointer;
  transition: all 0.2s ease;
  white-space: nowrap;
}

.pds-btn-reset:hover {
  background: var(--pds-color-rose-bg);
  border-color: var(--pds-color-rose);
  color: #FFFFFF;
  box-shadow: 0 0 8px rgba(232, 180, 168, 0.3);
}

.pds-btn-reset svg {
  transition: transform 0.3s ease;
}

.pds-btn-reset:hover svg {
  transform: rotate(-180deg);
}

.pds-intro-desc {
  font-size: 0.72rem;
  line-height: 1.35;
  color: #c4d4cc;
  margin: 0.05rem 0 0.35rem;
}

/* Checklist Items Container */
.pds-checklist {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

/* Individual Milestone Card (Ultra Slim Height) */
.pds-card-item {
  position: relative;
  display: flex;
  align-items: center;
  gap: 0.55rem;
  background: rgba(11, 56, 43, 0.75);
  border: 1px solid rgba(232, 180, 168, 0.2);
  border-radius: 7px !important;
  padding: 0.32rem 0.65rem;
  cursor: pointer;
  user-select: none;
  transition: all 0.18s cubic-bezier(0.4, 0, 0.2, 1);
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.15);
}

.pds-card-item:hover {
  border-color: rgba(232, 180, 168, 0.55);
  background: rgba(14, 68, 52, 0.9);
  transform: translateX(2px);
}

/* Checked State */
.pds-card-item.is-checked {
  background: linear-gradient(135deg, rgba(16, 75, 58, 0.95) 0%, rgba(9, 44, 34, 0.95) 100%);
  border-color: var(--pds-color-rose);
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.3),
              0 0 8px var(--pds-color-rose-glow),
              inset 0 0 0 1px rgba(232, 180, 168, 0.25);
}

/* Circular Rose Gold Checkbox Badge */
.pds-checkbox {
  width: 18px;
  height: 18px;
  min-width: 18px;
  border-radius: 50% !important;
  border: 1.5px solid rgba(232, 180, 168, 0.5);
  background: rgba(4, 20, 15, 0.6);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.18s ease;
}

.pds-card-item:hover .pds-checkbox {
  border-color: var(--pds-color-rose);
}

.pds-card-item.is-checked .pds-checkbox {
  background: linear-gradient(135deg, #f7ded8 0%, #E8B4A8 100%);
  border-color: var(--pds-color-rose);
  box-shadow: 0 0 6px var(--pds-color-rose-glow);
  transform: scale(1.04);
}

.pds-checkbox svg {
  width: 10px;
  height: 10px;
  stroke: #08362A;
  stroke-width: 3.5;
  opacity: 0;
  transform: scale(0.5);
  transition: all 0.18s ease;
}

.pds-card-item.is-checked .pds-checkbox svg {
  opacity: 1;
  transform: scale(1);
}

/* Card Text Elements */
.pds-card-content {
  flex: 1;
  min-width: 0;
}

.pds-card-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.3rem;
  margin-bottom: 0.05rem;
}

.pds-card-category {
  font-size: 0.63rem;
  font-weight: 800;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--pds-color-rose);
}

.pds-card-points {
  font-size: 0.66rem;
  font-weight: 800;
  letter-spacing: 0.02em;
  color: #92aba0;
  transition: color 0.2s ease;
}

.pds-card-item.is-checked .pds-card-points {
  color: var(--pds-color-rose-light);
}

.pds-card-title {
  font-size: 0.77rem;
  font-weight: 600;
  color: #FFFFFF;
  line-height: 1.25;
  margin: 0;
}

.pds-card-desc {
  font-size: 0.68rem;
  line-height: 1.25;
  color: #b3c7bd;
  margin: 0.05rem 0 0;
}

/* =========================================================
   RIGHT COLUMN: SLIM SAFETY RATING GAUGE & ALERT BOX
   ========================================================= */
.pds-right-col {
  display: flex;
  flex-direction: column;
}

.pds-gauge-card {
  background: linear-gradient(165deg, rgba(8, 48, 38, 0.95) 0%, rgba(5, 30, 24, 0.95) 100%);
  border: 1px solid var(--pds-color-rose-border);
  border-radius: 10px !important;
  padding: 0.55rem 0.85rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: space-between;
  height: 100%;
  box-sizing: border-box;
  box-shadow: 0 6px 16px rgba(0, 0, 0, 0.3);
}

.pds-gauge-eyebrow {
  font-size: 0.66rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--pds-color-rose);
  margin-bottom: 0.15rem;
  text-align: center;
}

/* SVG Circular Gauge (Compact) */
.pds-gauge-wrap {
  position: relative;
  width: 200px;
  height: 200px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0.1rem 0 0.3rem;
}

.pds-gauge-svg {
  width: 100%;
  height: 100%;
  transform: rotate(-90deg);
  filter: drop-shadow(0 0 6px rgba(232, 180, 168, 0.25));
}

.pds-gauge-track {
  fill: none;
  stroke: rgba(232, 180, 168, 0.14);
  stroke-width: 8.5;
}

.pds-gauge-fill {
  fill: none;
  stroke: url(#pdsRoseGoldGrad);
  stroke-width: 8.5;
  stroke-linecap: round;
  stroke-dasharray: 440;
  stroke-dashoffset: 440;
  transition: stroke-dashoffset 0.55s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.pds-gauge-center {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
}

.pds-gauge-number {
  font-family: var(--font-display, "Playfair Display", Georgia, serif);
  font-size: 2.7rem;
  font-weight: 800;
  color: #FFFFFF;
  line-height: 1;
  margin-bottom: 0.05rem;
  text-shadow: 0 2px 6px rgba(0, 0, 0, 0.6);
}

.pds-gauge-label {
  font-size: 1rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--pds-color-rose);
}

/* Dynamic Risk Status Box (Slim) */
.pds-risk-box {
  width: 100%;
  border-radius: 7px !important;
  padding: 0.35rem 0.6rem;
  margin-bottom: 0.3rem;
  box-sizing: border-box;
  transition: all 0.2s ease;
}

.pds-risk-box.is-danger {
  background: var(--pds-danger-bg);
  border: 1px solid var(--pds-danger-border);
  color: var(--pds-danger-text);
}

.pds-risk-box.is-warning {
  background: var(--pds-warning-bg);
  border: 1px solid var(--pds-warning-border);
  color: var(--pds-warning-text);
}

.pds-risk-box.is-success {
  background: var(--pds-success-bg);
  border: 1px solid var(--pds-success-border);
  color: var(--pds-success-text);
  box-shadow: 0 0 10px rgba(232, 180, 168, 0.25);
}

.pds-risk-head {
  display: flex;
  align-items: center;
  gap: 0.3rem;
  font-size: 0.67rem;
  font-weight: 800;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  margin-bottom: 0.1rem;
}

.pds-risk-box.is-success .pds-risk-head {
  color: var(--pds-color-rose);
}

.pds-risk-icon svg {
  width: 12px;
  height: 12px;
  flex-shrink: 0;
}

.pds-risk-desc {
  font-size: 0.66rem;
  line-height: 1.3;
  margin: 0;
  opacity: 0.95;
  color:var(--pds-success-text)
}

/* Institutional Standard Footnote */
.pds-footnote {
  width: 100%;
  padding-top: 0.35rem;
  border-top: 1px solid rgba(232, 180, 168, 0.18);
}

.pds-footnote-row {
  display: flex;
  align-items: flex-start;
  gap: 0.3rem;
  font-size: 0.65rem;
  line-height: 1.25;
  color: #c4d4cc;
  margin-bottom: 0.1rem;
}

.pds-footnote-row strong {
  color: var(--pds-color-rose);
}

.pds-footnote-note {
  font-size: 0.62rem;
  line-height: 1.2;
  color: #92aba0;
  margin: 0;
  padding-left: 0.75rem;
}

/* =========================================================
   RESPONSIVE BREAKPOINTS (Mobile & Tablet)
   ========================================================= */
@media (max-width: 840px) {
  .pds-grid {
    grid-template-columns: 1fr;
    gap: 0.75rem;
  }
}

@media (max-width: 500px) {
  .pds-scorecard-card {
    padding: 0.6rem;
  }
  .pds-header-bar {
    flex-direction: column;
    align-items: flex-start;
    gap: 0.25rem;
  }
  .pds-btn-reset {
    align-self: flex-start;
  }
  .pds-card-item {
    padding: 0.35rem 0.55rem;
  }
  .pds-gauge-wrap {
    width: 195px;
    height: 195px;
  }
  .pds-gauge-number {
    font-size: 1.4rem;
  }
}

.pds-gauge {
  position: relative;
  width: 260px;
  height: 260px;
}

.pds-gauge-svg {
  width: 100%;
  height: 100%;
  transform: rotate(-90deg);
  overflow: visible;
}

.pds-gauge-track,
.pds-gauge-fill {
  fill: none;
  stroke-width: 10;
}

.pds-gauge-track {
  stroke: #f1e7e5;
}

.pds-gauge-fill {
  stroke: url(#pdsSafetyGradient);
  stroke-linecap: round;

  /* r = 70, circumference ≈ 439.82 */
  stroke-dasharray: 439.82;
  stroke-dashoffset: 439.82;

  transition:
    stroke-dashoffset 0.7s cubic-bezier(0.22, 1, 0.36, 1);
}

.pds-gauge-center {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
}

.pds-gauge-number {
  font-size: 42px;
  line-height: 1;
  font-weight: 700;
  /* color: #183c32; */
  transition: color 0.35s ease;
}

.pds-gauge-label {
  margin-top: 8px;
  font-size: 14px;
  font-weight: 600;
}

/* clickable cards */
.pds-card-item {
  cursor: pointer;
}

.pds-checkbox {
  transition: all 0.3s ease;
}

.pds-checkbox svg {
  opacity: 0;
  transform: scale(0.5);
  transition:
    opacity 0.25s ease,
    transform 0.25s ease;
}

.pds-card-item.is-checked .pds-checkbox svg {
  opacity: 1;
  transform: scale(1);
}