/* 
 * Layout Styles - Pixel-faithful implementation of the wireframe prompt
 * Project 1 - Engineering Site Showcase
 */

:root {
  --canvas-bg: #b71c1c;
  /* Bold red site background */
  --product-panel-bg: #ffd9dc;
  /* Light red background for product section */
  --product-panel-border: #f5b7bc;
  --panel-bg: #dfdfdf;
  --panel-border: #cccccc;
  --dark-element: #000000;
  --text-light: #ffffff;
  --text-dark: #111111;
  --card-radius: 16px;
  --panel-radius: 14px;
  --pill-radius: 9999px;
  --font-main: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  padding: 0;
  background-color: var(--canvas-bg);
  font-family: var(--font-main);
  color: var(--text-dark);
  min-height: 100vh;
  display: flex;
  justify-content: center;
  align-items: flex-start;
}

/* Master Layout Frame */
.wireframe-container {
  width: 100%;
  max-width: 1320px;
  padding: 24px;
  display: flex;
  flex-direction: column;
  gap: 20px;
}

/* ==========================================================================
   1. HEADER SECTION
   ========================================================================== */
.header-panel {
  border-radius: var(--panel-radius);
  padding: 14px 28px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.06);
}

.brand-section {
  display: flex;
  align-items: center;
  gap: 16px;
  text-decoration: none;
  color: var(--text-dark);
}

.brand-logo-circle {
  width: 54px;
  height: 54px;
  border-radius: 50%;
  overflow: hidden;
  background-color: var(--dark-element);
  border: 2px solid var(--dark-element);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.15);
}

.brand-logo-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.brand-name {
  font-size: 1.45rem;
  font-weight: 700;
  letter-spacing: -0.3px;
  margin: 0;
  color: var(--text-dark);
}

.nav-pills-list {
  display: flex;
  align-items: center;
  gap: 12px;
  list-style: none;
  margin: 0;
  padding: 0;
}

.nav-pill-link {
  background-color: var(--dark-element);
  color: var(--text-light);
  border-radius: var(--pill-radius);
  padding: 6px 22px;
  font-size: 0.95rem;
  font-weight: 600;
  text-decoration: none;
  display: inline-block;
  transition: transform 0.2s ease, background-color 0.2s ease, box-shadow 0.2s ease;
  cursor: pointer;
}

.nav-pill-link:hover {
  background-color: #242424;
  color: var(--text-light);
  transform: translateY(-2px);
  box-shadow: 0 3px 8px rgba(0, 0, 0, 0.25);
}

.nav-pill-link.active {
  background-color: #1a1a1a;
  outline: 2px solid rgba(255, 255, 255, 0.6);
}

/* ==========================================================================
   HERO SECTION (100% width, 150px height)
   ========================================================================== */
.hero-section {
  width: 100%;
  height: 250px;
  border-radius: var(--panel-radius);
  overflow: hidden;
  position: relative;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
  border: 1px solid rgba(255, 255, 255, 0.25);
}

.hero-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 40%;
  display: block;
}

.hero-overlay {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(90deg, rgba(0, 0, 0, 0.8) 0%, rgba(0, 0, 0, 0.42) 65%, transparent 100%);
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 0 32px;
  color: #ffffff;
}

.hero-title {
  font-size: 1.55rem;
  font-weight: 800;
  margin: 0;
  letter-spacing: -0.3px;
  text-shadow: 0 2px 5px rgba(0, 0, 0, 0.7);
  color: #ffffff;
}

.hero-subtitle {
  font-size: 0.9rem;
  margin: 6px 0 0 0;
  color: rgba(255, 255, 255, 0.9);
  font-weight: 500;
  text-shadow: 0 1px 3px rgba(0, 0, 0, 0.7);
}

/* ==========================================================================
   2. MAIN CONTENT (Products on left, Ads on right)
   ========================================================================== */
.main-grid {
  display: grid;
  grid-template-columns: 2.3fr 1fr;
  gap: 20px;
  align-items: stretch;
}

/* Products Panel (Left) */
.products-panel {
  /* background-color: var(--product-panel-bg); */
  /* border-radius: var(--panel-radius); */
  padding: 24px;
  /* border: 1px solid var(--product-panel-border); */
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.12);
  display: flex;
  flex-direction: column;
}

.products-row {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
  height: 100%;
}

.product-unit {
  display: flex;
  flex-direction: column;
  align-items: center;
}

.product-card {
  width: 100%;
  aspect-ratio: 9 / 13;
  min-height: 290px;
  /* background-color: var(--dark-element); */
  /* border-radius: var(--card-radius); */
  padding: 10px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.2);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  cursor: pointer;
}

.product-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 8px 18px rgba(0, 0, 0, 0.3);
}

.product-image-container {
  width: 100%;
  height: 100%;
  background-color: #ffffff;
  border-radius: calc(var(--card-radius) - 4px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 14px;
  overflow: hidden;
}

.product-image {
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
  transition: transform 0.35s ease;
}

.product-card:hover .product-image {
  transform: scale(1.08);
}

.product-name-pill {
  margin-top: 14px;
  background-color: var(--dark-element);
  color: var(--text-light);
  border-radius: var(--pill-radius);
  padding: 7px 22px;
  font-size: 0.95rem;
  font-weight: 600;
  text-align: center;
  min-width: 120px;
  display: inline-block;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.18);
  transition: background-color 0.2s ease, transform 0.2s ease;
  cursor: pointer;
  user-select: none;
}

.product-name-pill:hover {
  background-color: #242424;
  transform: translateY(-1px);
}

/* Ads Panel (Right) */
.ads-panel {
  /* background-color: var(--panel-bg); */
  border-radius: var(--panel-radius);
  padding: 24px;
  /* border: 1px solid var(--panel-border); */
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.06);
  display: flex;
  flex-direction: column;
}

.ad-card {
  width: 100%;
  height: 100%;
  min-height: 360px;
  background-color: var(--dark-element);
  border-radius: var(--card-radius);
  position: relative;
  overflow: hidden;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.2);
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
}

.ad-badge {
  position: absolute;
  top: 14px;
  left: 50%;
  transform: translateX(-50%);
  background-color: rgba(0, 0, 0, 0.8);
  backdrop-filter: blur(4px);
  color: var(--text-light);
  padding: 5px 18px;
  border-radius: var(--pill-radius);
  font-size: 0.85rem;
  font-weight: 700;
  letter-spacing: 0.4px;
  border: 1px solid rgba(255, 255, 255, 0.25);
  z-index: 3;
}

.ad-media-box {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

.ad-gif {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.4s ease;
}

.ad-card:hover .ad-gif {
  transform: scale(1.04);
}

.ad-overlay-text {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  background: linear-gradient(to top, rgba(0, 0, 0, 0.85) 0%, rgba(0, 0, 0, 0.3) 70%, transparent 100%);
  color: var(--text-light);
  padding: 28px 16px 14px 16px;
  text-align: center;
  z-index: 2;
}

.ad-overlay-text h4 {
  margin: 0;
  font-size: 1.15rem;
  font-weight: 700;
}

.ad-overlay-text p {
  margin: 4px 0 0 0;
  font-size: 0.85rem;
  opacity: 0.85;
}

/* ==========================================================================
   3. FOOTER SECTION
   ========================================================================== */
.footer-panel {
  /* background-color: var(--panel-bg); */
  /* border-radius: var(--panel-radius); */
  padding: 20px 24px;
  /* border: 1px solid var(--panel-border); */
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.06);
}

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

.footer-box {
  background-color: var(--dark-element);
  color: var(--text-light);
  border-radius: var(--card-radius);
  min-height: 110px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 16px 20px;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.2);
  transition: transform 0.25s ease, background-color 0.25s ease;
  text-align: center;
  cursor: pointer;
}

.footer-box:hover {
  background-color: #1a1a1a;
  transform: translateY(-3px);
  box-shadow: 0 6px 14px rgba(197, 168, 168, 0.3);
}

.footer-box-title {
  font-size: 1.7rem;
  font-weight: 700;
  margin: 0;
  letter-spacing: 0.5px;
  color: var(--text-light);
}

.footer-box-desc {
  font-size: 0.85rem;
  color: rgba(255, 255, 255, 0.7);
  margin-top: 5px;
}

/* ==========================================================================
   4. RESPONSIVE MEDIA QUERIES
   ========================================================================== */
@media (max-width: 992px) {
  .main-grid {
    grid-template-columns: 1fr;
  }

  .ad-card {
    min-height: 320px;
    aspect-ratio: 16 / 9;
  }
}

@media (max-width: 768px) {
  .wireframe-container {
    padding: 12px;
    gap: 14px;
  }

  .hero-section {
    height: 130px;
  }

  .hero-overlay {
    padding: 0 16px;
  }

  .hero-title {
    font-size: 1.15rem;
  }

  .hero-subtitle {
    font-size: 0.78rem;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
  }

  .header-panel {
    flex-direction: column;
    gap: 14px;
    padding: 16px;
    text-align: center;
  }

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

  .product-card {
    aspect-ratio: 4 / 3;
    min-height: 230px;
  }

  .footer-grid {
    grid-template-columns: 1fr;
    gap: 14px;
  }

  .footer-box {
    min-height: 85px;
  }

  .footer-box-title {
    font-size: 1.4rem;
  }

  .team-grid {
    grid-template-columns: 1fr;
    gap: 16px;
  }
}

/* ==========================================================================
   LEADERSHIP / EMPLOYEE CARDS SECTION
   ========================================================================== */
.team-panel {
  background-color: var(--panel-bg);
  border-radius: var(--panel-radius);
  padding: 24px;
  border: 1px solid var(--panel-border);
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.06);
}

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

.employee-card {
  background-color: var(--dark-element);
  color: var(--text-light);
  border-radius: var(--card-radius);
  padding: 26px 22px;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.2);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  border: 1px solid rgba(255, 255, 255, 0.08);
}

.employee-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.35);
}

.employee-avatar {
  width: 64px;
  height: 64px;
  border-radius: 50%;
  background: #1a1a1a;
  border: 2px solid rgba(255, 255, 255, 0.15);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.8rem;
  margin-bottom: 14px;
  flex-shrink: 0;
}

.employee-role-badge {
  display: inline-block;
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.8px;
  color: rgba(255, 255, 255, 0.6);
  margin-bottom: 4px;
  font-weight: 600;
}

.employee-role {
  font-size: 1.6rem;
  font-weight: 800;
  letter-spacing: 0.5px;
  margin: 0 0 6px 0;
  color: #ffffff;
}

.employee-name {
  font-size: 1.05rem;
  font-weight: 600;
  color: #ffd9dc;
  margin: 0 0 12px 0;
}

.employee-qualifications {
  font-size: 0.86rem;
  line-height: 1.55;
  color: rgba(255, 255, 255, 0.82);
  margin: 0;
  text-align: center;
}


/* ==========================================================================
   LEADERSHIP / EMPLOYEE CARDS SECTION
   ========================================================================== */
.team-panel {
  background-color: var(--panel-bg);
  border-radius: var(--panel-radius);
  padding: 24px;
  border: 1px solid var(--panel-border);
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.06);
}

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

.employee-card {
  background-color: var(--dark-element);
  color: var(--text-light);
  border-radius: var(--card-radius);
  padding: 26px 22px;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.2);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  border: 1px solid rgba(255, 255, 255, 0.08);
}

.employee-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.35);
}

.employee-avatar {
  width: 64px;
  height: 64px;
  border-radius: 50%;
  background: #1a1a1a;
  border: 2px solid rgba(255, 255, 255, 0.15);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.8rem;
  margin-bottom: 14px;
  flex-shrink: 0;
}

.employee-role-badge {
  display: inline-block;
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.8px;
  color: rgba(255, 255, 255, 0.6);
  margin-bottom: 4px;
  font-weight: 600;
}

.employee-role {
  font-size: 1.6rem;
  font-weight: 800;
  letter-spacing: 0.5px;
  margin: 0 0 6px 0;
  color: #ffffff;
}

.employee-name {
  font-size: 1.05rem;
  font-weight: 600;
  color: #ffd9dc;
  margin: 0 0 12px 0;
}

.employee-qualifications {
  font-size: 0.86rem;
  line-height: 1.55;
  color: rgba(255, 255, 255, 0.82);
  margin: 0;
  text-align: center;
}