/* ========================================================
   Common Styles for Fastener Material Pages
   (duplex, super-duplex, inconel, monel, nickel,
    incoloy, titanium, hastelloy, stainless-steel,
    special-ss fastener pages)
   ======================================================== */

/* --- Data Tables ---------------------------------------- */
.fp-table {
  width: 100%;
  border-collapse: collapse;
  margin-bottom: 25px;
  background: #fff;
  box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}
.fp-table th,
.fp-table td {
  border: 1px solid #ddd;
  padding: 10px 14px;
  text-align: left;
  vertical-align: top;
}
.fp-table th {
  background-color: #444;
  color: #fff;
  font-weight: bold;
}
.fp-table tr:nth-child(even) {
  background-color: #f2f2f2;
}

/* --- Info Cards ----------------------------------------- */
.info-card {
  background: #fff;
  border-left: 4px solid #ff8000;
  border-radius: 6px;
  padding: 20px 24px;
  margin-bottom: 20px;
  box-shadow: 0 2px 8px rgba(0,0,0,0.07);
  height: 100%;
}
.info-card h5 {
  color: #000;
  font-weight: 700;
  margin-bottom: 10px;
  font-size: 1rem;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}
.info-card ul {
  margin: 0;
  padding-left: 18px;
}
.info-card ul li {
  margin-bottom: 4px;
  color: #444;
}
.info-card p {
  color: #444;
  margin-bottom: 8px;
}

/* --- Footer: single row on xl -------------------------- */
@media (min-width: 1200px) {
  .wpo-upper-footer .row {
    flex-wrap: nowrap;
  }
}

/* --- Product Card Alignment ---------------------------------- */
.wpo-project-area-s2 .align-items-start {
  align-items: stretch !important;
}
.wpo-project-area-s2 .col-lg-4,
.wpo-project-area-s2 .col-md-6 {
  display: flex;
  flex-direction: column;
}
.wpo-project-area-s2 a {
  display: flex;
  flex-direction: column;
  flex: 1;
  width: 100%;
}
.wpo-project-item {
  display: flex;
  flex-direction: column;
  flex: 1;
}
.wpo-project-text {
  flex: 1;
}
.wpo-project-img {
  flex-shrink: 0;
}
.wpo-project-img img {
  width: 100%;
  height: 360px;
  object-fit: cover;
  display: block;
}

/* --- Product Card Hover --------------------------------- */
.wpo-project-item:hover h4 {
  color: #ff8000 !important;
}

/* --- Application Tags ----------------------------------- */
.app-tag {
  display: inline-block;
  background: #dadada;
  color: #000;
  border: 1px solid #aeadaf;
  border-radius: 20px;
  padding: 4px 14px;
  font-size: 0.82rem;
  font-weight: 600;
  margin: 4px 3px;
}

/* --- Section Backgrounds -------------------------------- */
.fp-bg-light {
  background: #f8f9fa;
}

/* --- Responsive Adjustments ---------------------------- */
@media (max-width: 768px) {
  .fp-table th,
  .fp-table td {
    padding: 8px 10px;
    font-size: 0.88rem;
  }
  .info-card {
    padding: 16px 18px;
  }
  .wpo-project-single-title h3 {
    font-size: 1.2rem;
  }
}

@media (max-width: 576px) {
  .fp-table {
    display: block;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
  }
  .info-card h5 {
    font-size: 0.92rem;
  }
  .app-tag {
    font-size: 0.78rem;
    padding: 3px 10px;
  }
}

/* =========================================================
   Shafts by Material table – responsive card layout
   ========================================================= */
.shafts-mat-table-wrap {
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}

/* Tablet: reduce padding & font size, keep table layout */
@media (max-width: 768px) {
  .shafts-mat-table th,
  .shafts-mat-table td {
    padding: 9px 11px;
    font-size: 0.85rem;
  }
}

/* Mobile: transform rows into stacked cards */
@media (max-width: 576px) {
  /* break table display model */
  .shafts-mat-table,
  .shafts-mat-table thead,
  .shafts-mat-table tbody,
  .shafts-mat-table tr,
  .shafts-mat-table th,
  .shafts-mat-table td {
    display: block;
    width: 100%;
    box-sizing: border-box;
  }

  /* hide desktop header row */
  .shafts-mat-table thead tr {
    display: none;
  }

  /* each data row becomes a card */
  .shafts-mat-table tbody tr {
    margin-bottom: 10px;
    border: 1px solid #ddd;
    border-radius: 6px;
    overflow: hidden;
    box-shadow: 0 1px 5px rgba(0,0,0,0.08);
    padding: 12px 14px;
    background: #fff;
  }
  .shafts-mat-table tbody tr:nth-child(even) {
    background: #f9f9f9;
  }

  /* hide Sr. No. column – not needed on mobile */
  .shafts-mat-table tbody td:nth-child(1) {
    display: none;
  }

  /* Material Type – bold heading */
  .shafts-mat-table tbody td:nth-child(2) {
    border: none;
    padding: 0 0 4px 0;
    font-size: 0.97rem;
    font-weight: 700;
    color: #1a1a2e;
  }

  /* Grades / Alloys – sub-text */
  .shafts-mat-table tbody td:nth-child(3) {
    border: none;
    padding: 0 0 10px 0;
    font-size: 0.82rem;
    color: #555;
    line-height: 1.4;
  }

  /* View Products button – left-aligned */
  .shafts-mat-table tbody td:nth-child(4) {
    border: none;
    padding: 0;
    text-align: left;
  }
}
