/**
 * Tree-Ripe Footer Styles (Standalone)
 * Version: 1.1.0 - Seasonal Color Theming
 * 
 * COLOR SYSTEM:
 * - Static brand colors use --tr-* variables
 * - Seasonal accent colors use --tr-season-* variables (injected by PHP)
 */

/* ============================================
   CSS VARIABLES
   ============================================ */
:root {
  /* Brand Colors (Static - from Brand Book 2022) */
  --tr-forest-green: #0F5E41;
  --tr-forest-deep: #0A3A28;
  --tr-forest-light: #1A7A56;
  --tr-medium-green: #408469;
  --tr-mint: #BBE0C6;
  --tr-mint-soft: #D5EBE0;
  --tr-cream: #F0E8E0;
  --tr-cream-soft: #F5EEE6;
  --tr-peach: #F1CCB6;

  /* Seasonal Colors (fallback defaults - overridden by tr-shared.php !important) */
  --tr-season-accent: #E78825;
  --tr-season-accent-hover: #D67A1F;
  --tr-season-accent-soft: #FEF3E6;
  --tr-season-accent-glow: rgba(231, 136, 37, 0.3);

  /* Typography - Brand Book 2022 */
  --tr-font-headline: Georgia, 'Times New Roman', serif;
  --tr-font-body: 'Avenir', 'Avenir Next', -apple-system, BlinkMacSystemFont, sans-serif;
  --tr-font-ui: 'Avenir Next', 'Avenir', -apple-system, BlinkMacSystemFont, sans-serif;
  
  /* Transitions */
  --tr-transition-smooth: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  --tr-transition-fast: all 0.2s ease;
}

/* ============================================
   FOOTER - BASE
   ============================================ */
.tr-footer {
  background-color: var(--tr-forest-green);
  color: white;
  font-family: var(--tr-font-body);
}

/* ============================================
   NEWSLETTER SECTION
   ============================================ */
.tr-footer__newsletter {
  background-color: var(--tr-newsletter-bg, var(--tr-forest-deep));
  padding: 48px 24px;
}

.tr-footer__newsletter-inner {
  max-width: 600px;
  margin: 0 auto;
  text-align: center;
}

.tr-footer__newsletter-eyebrow {
  font-size: 14px;
  text-transform: uppercase;
  color: var(--tr-season-accent);
  margin-bottom: 8px;
  font-weight: 600;
}

.tr-footer__newsletter-title {
  font-family: var(--tr-font-headline);
  font-size: 32px;
  margin-bottom: 12px;
  font-weight: 700;
  color: white;
}

.tr-footer__newsletter-subtitle {
  font-size: 16px;
  color: var(--tr-peach);
  margin-bottom: 24px;
  line-height: 1.5;
}

/* Spring/Summer: border to visually separate newsletter from green footer */
.tr-footer.tr-season--spring .tr-footer__newsletter,
.tr-footer.tr-season--summer .tr-footer__newsletter {
  border-bottom: 1px solid var(--tr-season-accent);
}

/* Newsletter text color by season */
/* Newsletter text uses seasonal variables for proper contrast */
.tr-footer__newsletter-title {
  color: var(--tr-season-newsletter-title, #0F5E41);
}

.tr-footer__newsletter-subtitle {
  color: var(--tr-season-newsletter-text, #3a3a3a);
}

.tr-footer__newsletter-form {
  display: flex;
  gap: 12px;
  max-width: 440px;
  margin: 0 auto;
}

.tr-footer__newsletter-form.is-hidden {
  display: none;
}

.tr-footer__newsletter-input,
.tr-footer__newsletter-form input[type="email"].tr-footer__newsletter-input {
  -webkit-appearance: none;
  appearance: none;
  flex: 1;
  padding: 14px 24px !important;
  font-size: 15px;
  font-family: var(--tr-font-body);
  border: 2px solid var(--tr-season-accent) !important;
  border-radius: 999px !important;
  background: rgba(255, 255, 255, 0.1) !important;
  color: var(--tr-season-newsletter-input, #333333) !important;
  outline: none;
  box-shadow: none !important;
  transition: var(--tr-transition-fast);
  max-width: 100%;
}

.tr-footer__newsletter-input::placeholder,
.tr-footer__newsletter-form input[type="email"]::placeholder {
  color: var(--tr-season-newsletter-placeholder, #666666) !important;
}

.tr-footer__newsletter-input:focus,
.tr-footer__newsletter-form input[type="email"]:focus {
  background: rgba(255, 255, 255, 0.15) !important;
  border-color: var(--tr-season-accent) !important;
  box-shadow: none !important;
}

/* SEASONAL: Newsletter Button */
.tr-footer__newsletter-btn {
  padding: 14px 28px;
  font-size: 15px;
  font-weight: 600;
  font-family: var(--tr-font-body);
  background-color: var(--tr-season-accent);
  color: white;
  border: none;
  border-radius: 999px;
  cursor: pointer;
  transition: var(--tr-transition-fast);
}

.tr-footer__newsletter-btn:hover {
  background-color: var(--tr-season-accent-hover);
  transform: translateY(-1px);
}

/* Spring/Summer: dark text on light accent backgrounds */
.tr-footer.tr-season--spring .tr-footer__newsletter-btn,
.tr-footer.tr-season--summer .tr-footer__newsletter-btn {
  color: var(--tr-forest-green);
}

.tr-footer__newsletter-message {
  display: none;
  margin-top: 16px;
  font-size: 15px;
  font-weight: 600;
  color: var(--tr-mint);
}

.tr-footer__newsletter-message.is-visible {
  display: block;
}

.tr-footer__newsletter-message.is-error {
  color: var(--tr-peach);
}

.tr-footer__newsletter-btn.is-loading {
  opacity: 0.85;
  cursor: progress;
}

/* ============================================
   MAIN FOOTER CONTENT
   ============================================ */
.tr-footer__main {
  padding: 64px 24px 48px;
}

.tr-footer__grid {
  max-width: 1200px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1.5fr repeat(3, 1fr) 1.2fr;
  gap: 48px;
}

/* Brand Column */
.tr-footer__brand-logo {
  display: block;
  margin-bottom: 16px;
  text-decoration: none;
}

.tr-footer__brand-logo-img {
  max-width: 180px;
  height: auto;
}

.tr-footer__brand-logo:hover {
  opacity: 0.9;
}

.tr-footer__brand-tagline {
  font-size: 16px;
  color: var(--tr-mint);
  line-height: 1.7;
  margin-bottom: 24px;
}

.tr-footer__social {
  display: flex;
  gap: 14px;
}

/* SEASONAL: Social Link Hover */
.tr-footer__social-link {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background-color: rgba(255, 255, 255, 0.1);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: var(--tr-transition-fast);
  text-decoration: none;
  color: white;
}

.tr-footer__social-link:hover {
  background-color: var(--tr-season-accent);
  color: white;
}

.tr-footer.tr-season--spring .tr-footer__social-link:hover,
.tr-footer.tr-season--summer .tr-footer__social-link:hover {
  color: var(--tr-forest-green);
}

.tr-footer__social-link svg {
  width: 22px;
  height: 22px;
}

/* Footer Link Columns */
.tr-footer__column-title {
  font-size: 14px;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  margin-bottom: 20px;
  font-weight: 700;
  font-family: var(--tr-font-ui);
  color: white;
}

.tr-footer__links {
  list-style: none;
  padding: 0;
  margin: 0;
}

.tr-footer__links li {
  margin-bottom: 14px;
}

.tr-footer__links li a {
  color: var(--tr-mint);
  text-decoration: none;
  font-size: 17px;
  line-height: 1.4;
  transition: var(--tr-transition-fast);
}

.tr-footer__links li a:hover {
  color: white;
}

/* ============================================
   SEASON CARD
   ============================================ */
/* SEASONAL: Card has accent border */
.tr-footer__season-card {
  background-color: rgba(255, 255, 255, 0.1);
  border-radius: 12px;
  padding: 20px;
  border-left: 4px solid var(--tr-season-accent);
}

.tr-footer__season-emoji {
  font-size: 36px;
  margin-bottom: 10px;
}

.tr-footer__season-title {
  font-family: var(--tr-font-headline);
  font-size: 20px;
  margin-bottom: 6px;
  color: white;
}

.tr-footer__season-dates {
  font-size: 15px;
  color: var(--tr-mint);
  margin-bottom: 14px;
}

/* SEASONAL: Shop Now Button */
.tr-footer__season-cta {
  display: inline-block;
  padding: 10px 12px;
  font-size: 15px;
  font-weight: 600;
  background-color: var(--tr-season-accent);
  color: white;
  text-decoration: none;
  border-radius: 999px;
  transition: var(--tr-transition-fast);
}

.tr-footer__season-cta:hover {
  background-color: var(--tr-season-accent-hover);
  color: white;
  transform: translateY(-1px);
}

/* Spring/Summer: dark text on light accent backgrounds */
.tr-footer.tr-season--spring .tr-footer__season-cta,
.tr-footer.tr-season--spring .tr-footer__season-cta:hover,
.tr-footer.tr-season--summer .tr-footer__season-cta,
.tr-footer.tr-season--summer .tr-footer__season-cta:hover {
  color: var(--tr-forest-green);
}

/* ============================================
   FOOTER BOTTOM BAR
   ============================================ */
.tr-footer__bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  padding: 24px;
}

.tr-footer__bottom-inner {
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  font-size: 14px;
  color: var(--tr-mint);
}

.tr-footer__legal-links {
  display: flex;
  gap: 24px;
}

.tr-footer__legal-links a {
  color: var(--tr-mint);
  text-decoration: none;
  transition: var(--tr-transition-fast);
}

.tr-footer__legal-links a:hover {
  color: white;
}

/* ============================================
   RESPONSIVE STYLES
   ============================================ */

/* Tablet */
@media (max-width: 1024px) {
  .tr-footer__grid {
    grid-template-columns: repeat(2, 1fr);
  }
  
  .tr-footer__brand {
    grid-column: span 2;
  }
}

/* Mobile */
@media (max-width: 640px) {

  .tr-footer__brand-logo {
  display: flex;
  justify-content: center;
}

.tr-footer__brand-logo-img {
  max-width: 220px;
}
  .tr-footer__newsletter {
    padding: 40px 20px;
  }
  
  .tr-footer__newsletter-title {
    font-size: 26px;
  }
  
  .tr-footer__newsletter-form {
    flex-direction: column;
  }
  
  .tr-footer__main {
    padding: 48px 20px 40px;
  }
  
  .tr-footer__grid {
    grid-template-columns: 1fr;
    gap: 32px;
  }
  
  .tr-footer__brand {
    grid-column: span 1;
    text-align: center;
  }
  
  .tr-footer__social {
    justify-content: center;
  }
  
  .tr-footer__column {
    text-align: center;
  }
  
  .tr-footer__column-title {
    font-size: 15px;
    margin-bottom: 16px;
  }
  
  .tr-footer__links li {
    margin-bottom: 16px;
  }
  
  .tr-footer__links li a {
    font-size: 18px;
  }
  
  .tr-footer__season-title {
    font-size: 22px;
  }
  
  .tr-footer__season-dates {
    font-size: 16px;
  }
  
  .tr-footer__season-cta {
    font-size: 16px;
    padding: 12px 24px;
  }
  
  .tr-footer__bottom-inner {
    flex-direction: column;
    text-align: center;
  }
  
  .tr-footer__legal-links {
    flex-wrap: wrap;
    justify-content: center;
    gap: 16px;
  }
  
  .tr-footer__legal-links a {
    font-size: 15px;
  }
  
  .tr-footer__copyright {
    font-size: 14px;
  }
}
