/* ===========================
   Keith Ceramic — Card Grids
   Complete stylesheet
   =========================== */

/* ---- Design tokens ---- */
:root{
  /* brand colors */
  --kc-navy: #0f113a;
  --kc-accent: #ff7a00;
  --kc-blue-700: #1f6aff;
  --kc-blue-400: #4ea3ff;

  /* card + media */
  --muni-radius: 16px;
  --muni-shadow: 0 12px 28px rgba(8,18,44,.12);
  --muni-shadow-hover: 0 20px 44px rgba(8,18,44,.20);
  --muni-card-h: 360px;          /* total card height */
  --muni-media-h: 220px;         /* image area height */

  /* image sizing inside media area */
  --muni-media-pad: 22px;        /* white padding around image */
  --muni-img-max: 78%;           /* max width/height of image inside media */
}

/* ---------------------------------
   Accent section heading (orange + twin blue bars)
   Reusable utility: add class="kc-accent-title" to any <h2>
   --------------------------------- */
.kc-accent-title{
  position: relative;
  margin: 0 0 12px;
  padding-left: 28px;                             /* room for blue bars */
  line-height: 1.15;
  font-weight: 800;
  color: var(--kc-accent, #ff7a00) !important;    /* force orange */
  letter-spacing: .5px;
  font-size: clamp(1.6rem, 3vw, 2.2rem);
}
.kc-accent-title::before,
.kc-accent-title::after{
  content: "";
  position: absolute;
  left: 0;
  top: .08em;
  bottom: .08em;
  border-radius: 3px;
}
.kc-accent-title::before{ width: 6px; background: var(--kc-blue-700, #1f6aff); }
.kc-accent-title::after { left: 10px; width: 4px; background: var(--kc-blue-400, #4ea3ff); }

/* (optional) small intro paragraph under a heading */
.muni-intro{
  margin: 0 0 18px;
  color: #3a475a;
  max-width: 80ch;
}

/* ---------------------------------
   Responsive grid (3 / 2 / 1)
   --------------------------------- */
.muni-grid{
  display: grid;
  grid-template-columns: repeat(3, minmax(0,1fr));
  gap: 28px;
}
@media (max-width: 1024px){
  .muni-grid{ grid-template-columns: repeat(2,1fr); }
}
@media (max-width: 640px){
  .muni-grid{ grid-template-columns: 1fr; }
}

/* ---------------------------------
   Non-clickable card with elegant hover
   --------------------------------- */
.muni-card{
  background: #fff;
  border-radius: var(--muni-radius);
  box-shadow: var(--muni-shadow);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  height: var(--muni-card-h);
  color: var(--kc-navy);
  cursor: default;
  transition: transform .22s ease, box-shadow .22s ease;
  will-change: transform, box-shadow;
}
.muni-card:hover{
  transform: translateY(-4px);
  box-shadow: var(--muni-shadow-hover);
}

/* ---------------------------------
   Media area: centered, contained
   --------------------------------- */
.muni-media{
  position: relative;
  height: var(--muni-media-h);
  background: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: var(--muni-media-pad);
  overflow: hidden;               /* hide tiny hover zoom edges */
}
.muni-media img{
  width: auto;
  height: auto;
  max-width: var(--muni-img-max);
  max-height: var(--muni-img-max);
  object-fit: contain;            /* never crop */
  object-position: center;
  display: block;

  /* gentle hover that doesn't hit the edges */
  transform: scale(0.96);
  transition: transform .28s ease;
}
.muni-card:hover .muni-media img{ transform: scale(1.0); }

/* Optional soft edge glow on hover */
.muni-card:hover .muni-media::after{
  content: "";
  position: absolute; inset: 0;
  box-shadow: inset 0 0 0 2px rgba(255,255,255,.12);
  pointer-events: none;
}

/* ---------------------------------
   Body
   --------------------------------- */
.muni-body{
  background: #f7f9fc;
  padding: 16px 18px 20px;
  border-top: 1px solid rgba(0,0,0,.04);
  display: grid;
  align-content: end;
  gap: 6px;
}
.muni-body h3{
  margin: 0;
  font-weight: 800;
  letter-spacing: .6px;
  text-transform: uppercase;
  line-height: 1.25;

  /* keep two lines max so rows stay even */
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.muni-body p{
  margin: 0;
  color: #3a475a;
  font-weight: 500;
}

/* ---------------------------------
   Section-specific image tuning (optional)
   --------------------------------- */

/* High Tension Power: a touch larger visuals */
#high-tension .muni-media img{
  max-width: 82%;
  max-height: 82%;
}
@media (max-width:640px){
  #high-tension .muni-media img{
    max-width: 76%;
    max-height: 76%;
  }
}

/* If you need Counter Weights larger as well, keep this */
#counter-weights .muni-media img{
  max-width: 82%;
  max-height: 82%;
}
@media (max-width:640px){
  #counter-weights .muni-media img{
    max-width: 76%;
    max-height: 76%;
  }
}

/* ---------------------------------
   Small-screen global tuning
   --------------------------------- */
@media (max-width: 640px){
  :root{ --muni-img-max: 72%; }
}
