/* PC Footer Styles
   Accessible, responsive footer using a 12-col style container and CSS custom properties
   Text Domain: pc-footer
*/
:root {
  --pc-gap-xs: 0.25rem;
  --pc-gap-sm: 0.5rem;
  --pc-gap-md: 1rem;
  --pc-gap-lg: 1.5rem;
  --pc-gap-xl: 2rem;
}

.pc-footer {
  position: relative;
  width: 100%;
  background: #f9f9f9;
  color: #333;
  --pc-gap-xs: 4px;
  --pc-gap-sm: 8px;
  --pc-gap-md: 16px;
  --pc-gap-lg: 24px;
  --pc-gap-xl: 32px;
}

.pc-footer__container {
  margin: 0 auto;
  padding: var(--pc-gap-xl) var(--pc-gap-lg);
  display: grid;
  grid-template-columns: 1fr; /* mobile: stack */
  gap: var(--pc-gap-xl);
  align-items: start;
}

.pc-footer__brand,
.pc-footer__menu,
.pc-footer__copy {
  display: flex;
  align-items: center;
}

.pc-footer__brand { display: flex; flex-direction: column; gap: var(--pc-gap-md); }
.pc-footer__site-name { font-weight: 700; font-size: 1.125rem; }
.pc-footer__blurb { max-width: 30ch; line-height: 1.6; opacity: .9; }

.pc-footer__col { min-width: 0; }
.pc-footer__heading { font-weight: 700; margin: 0 0 var(--pc-gap-md); display: inline-block; position: relative; }
.pc-footer__heading::after { content: ""; display: block; width: 28px; height: 3px; background: var(--pc-accent, #1366d6); margin-top: var(--pc-gap-sm); }
.pc-footer ul, .pc-footer ol { list-style: none; margin: 0; padding: 0; }
.pc-footer__list { display: grid; gap: var(--pc-gap-sm); }
.pc-footer__list a { text-decoration: none; opacity: .9; }
.pc-footer__list a:hover, .pc-footer__list a:focus { opacity: 1; }
.pc-footer__contact li { display: grid; grid-template-columns: 1.25rem auto; align-items: start; gap: var(--pc-gap-sm); }

.pc-footer__copy { display: none; }

/* Tablet Layout - 2 columns */
@media (min-width: 768px) and (max-width: 1023px) {
  .pc-footer {
    padding: var(--pc-gap-lg) 0;
  }
  
  .pc-footer__container { 
    grid-template-columns: 1fr 1fr; 
    gap: var(--pc-gap-lg);
    align-items: start;
    align-content: start;
    padding: 0 var(--pc-gap-lg);
  }
  
  .pc-footer__brand, 
  .pc-footer__col { 
    align-self: start; 
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
  }
  
  .pc-footer__brand {
    max-width: none;
  }
  
  .pc-footer__blurb {
    max-width: none;
  }
}

/* Desktop and TV Layout - 4 Equal Columns */
@media (min-width: 1024px) {
  .pc-footer {
    /* Remove excessive min-height, let content determine size */
    padding: var(--pc-gap-xl) 0;
  }
  
  .pc-footer__container { 
    grid-template-columns: 1fr 1fr 1fr 1fr; 
    gap: var(--pc-gap-lg);
    align-items: start;
    align-content: start;
    padding: 0 var(--pc-gap-lg);
  }
  
  .pc-footer__brand, 
  .pc-footer__col { 
    align-self: start; 
    /* Remove height: 100% to prevent excessive stretching */
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
  }
  
  /* Equal width and consistent spacing for all columns */
  .pc-footer__brand {
    max-width: none;
  }
  
  .pc-footer__blurb {
    max-width: none;
    /* Remove flex-grow to prevent excessive stretching */
  }
  
  /* Remove flex-grow from lists */
  .pc-footer__list {
    /* Let content determine height naturally */
  }
}

/* Large TV and Ultra-wide Display Optimization */
@media (min-width: 1280px) {
  .pc-footer__container {
    max-width: 1400px;
    margin: 0 auto;
  }
  
  /* Larger fonts for TV viewing distance */
  .pc-footer {
    font-size: 16px;
  }
  
  .pc-footer__heading {
    font-size: 18px;
  }
  
  .pc-footer__list a,
  .pc-footer__contact {
    font-size: 15px;
  }
}

/* Ultra-large screens (4K TVs) */
@media (min-width: 1920px) {
  .pc-footer__container {
    max-width: 1600px;
  }
  
  .pc-footer {
    font-size: 18px;
  }
  
  .pc-footer__heading {
    font-size: 22px;
  }
  
  .pc-footer__list a,
  .pc-footer__contact {
    font-size: 16px;
  }
  
  .pc-footer__container {
    gap: var(--pc-gap-xl);
  }
}

/* Smart TV Specific Optimizations */
@media screen and (min-width: 1280px) and (max-width: 1280px) {
  /* This targets exactly 1280px width screens like ONN Smart TV 720p */
  .pc-footer {
    font-size: 15px !important;
    padding: 30px 0 !important;
  }
  
  .pc-footer__container {
    max-width: 1200px !important;
    grid-template-columns: 1fr 1fr 1fr 1fr !important;
    gap: 20px !important;
    padding: 0 20px !important;
  }
  
  .pc-footer__heading {
    font-size: 17px !important;
    margin-bottom: 15px !important;
  }
  
  .pc-footer__list a,
  .pc-footer__contact {
    font-size: 14px !important;
    line-height: 1.5 !important;
  }
  
  .pc-footer__blurb {
    font-size: 13px !important;
    line-height: 1.5 !important;
  }
}

/* Force proper display for TV browsers */
@media (pointer: coarse) and (min-width: 1024px) {
  .pc-footer__container {
    display: grid !important;
    grid-template-columns: 1fr 1fr 1fr 1fr !important;
  }
  
  .pc-footer__brand,
  .pc-footer__col {
    display: flex !important;
    flex-direction: column !important;
  }
}

/* Bottom bar */
.pc-footer__bottom { border-top: 1px solid rgba(0,0,0,0.1); }
.pc-footer__bottom .pc-footer__container { display: flex; gap: var(--pc-gap-lg); align-items: center; justify-content: space-between; padding-top: var(--pc-gap-lg); padding-bottom: var(--pc-gap-lg); }
.pc-footer__bottom small { opacity: .85; }
