/* File: /css/policies.css
   Fixed:
   - Corrected custom property name (--tertiary-color)
   - Removed stray comma that invalidated the dark-mode overlay rule
   - Added safe fallbacks for custom properties
*/

/* ============================ POLICY PAGE STYLING ============================ */
/* Applies to Privacy Policy, Terms, and Cookie Policy */

/* ============================ POLICY HERO SECTION ============================ */
.policy-hero {
  position: relative;
  isolation: isolate;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 20px;
  background:
    linear-gradient(120deg, rgba(0, 0, 0, 0.6) 10%, rgba(255, 204, 0, 0.1) 90%),
    url('../assets/privacy-bg.jpg') center/cover no-repeat;
  color: #fff;
  font-family: 'Montserrat', sans-serif;
  min-height: 250px;
}

/* Updated Gradient Overlay */
.policy-hero::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, rgba(255, 204, 0, 0.85) 0%, rgba(255, 153, 0, 0.85) 100%);
  z-index: 1;
}

/* Dark Mode - Updated Background */
.dark-mode .policy-hero {
  background:
    linear-gradient(120deg, rgba(18, 18, 18, 0.9) 10%, rgba(255, 204, 0, 0.85) 90%),
    url('../assets/privacy-bg.jpg') center/cover no-repeat;
}

/* Dark Mode - Adjusted Gradient Overlay (fixed var name + stray comma) */
.dark-mode .policy-hero::before {
  background: linear-gradient(
    135deg,
    var(--highlight-dark, #0b0b0b) 0%,
    var(--tertiary-color, #ffcc00) 100%
  );
}

/* Hero Content */
.policy-hero-content {
  position: relative;
  max-width: 900px;
  margin: auto;
  z-index: 2;
}

/* Hero Title */
.policy-hero h1 {
  font-size: 3rem;
  font-weight: bold;
  text-transform: uppercase;
  color: #fff;
  text-shadow: 3px 3px 6px rgba(0, 0, 0, 0.8);
  margin-bottom: 10px;
}

/* Policy Date */
.policy-hero .policy-date {
  font-size: 1.4rem;
  font-weight: 600;
  color: #fff;
  background-color: #000;
  padding: 6px 12px;
  border-radius: 5px;
  text-shadow: 2px 2px 5px rgba(0, 0, 0, 0.7);
  display: inline-block;
  margin-top: 10px;
}

/* ============================ POLICY CONTAINER ============================ */
.policy-container {
  max-width: 900px;
  margin: 40px auto;
  padding: 20px;
  font-family: 'Montserrat', sans-serif;
  line-height: 1.7;
  color: #333;
  background: #fff;
  border-radius: 10px;
}

/* Dark Mode - Policy Container */
.dark-mode .policy-container {
  background: #121212;
  color: #f5f5f5;
}

/* Policy Content */
.policy-content {
  text-align: left;
  max-width: 800px;
  margin: auto;
}

/* Headings */
.policy-container h2 {
  font-size: 1.4rem;
  font-weight: bold;
  color: #FFCC00;
  background-color: #000;
  padding: 8px 12px;
  border-radius: 5px;
  display: inline-block;
  margin-top: 15px;
  margin-bottom: 8px;
}

/* Dark Mode - Headings */
.dark-mode .policy-container h2 {
  background-color: #ffcc00;
  color: #000;
}

/* Paragraphs */
.policy-container p {
  font-size: 1rem;
  margin-bottom: 10px;
}

/* Unordered List */
.policy-container ul {
  margin-left: 20px;
  padding-left: 10px;
}

.policy-container ul li {
  font-size: 1rem;
  margin-bottom: 5px;
}

/* Links */
.policy-container a {
  color: #FFCC00;
  font-weight: bold;
  text-decoration: none;
  transition: color 0.3s ease-in-out;
}

.policy-container a:hover {
  text-decoration: underline;
  color: #e2bd2a;
}

/* ============================ RESPONSIVE ADJUSTMENTS ============================ */
@media (max-width: 768px) {
  .policy-hero {
    padding: 60px 15px;
    min-height: 220px;
  }

  .policy-hero h1 {
    font-size: 2.2rem;
  }

  .policy-hero .policy-date {
    font-size: 1.2rem;
  }

  .policy-container h2 {
    font-size: 1.2rem;
    padding: 6px 10px;
  }
}

/* ============================ DIVIDER LINE ============================ */
.policy-divider {
  width: 60%;
  height: 3px;
  background: linear-gradient(to right, #FFCC00, #FF9900);
  margin: 30px auto 15px auto;
  border-radius: 3px;
}

/* ============================ GDPR & POPIA COMPLIANCE ============================ */
.policy-compliance {
  text-align: center;
  padding: 20px;
  font-size: 1rem;
  font-family: 'Montserrat', sans-serif;
  line-height: 1.6;
}

/* Compliance Links */
.policy-compliance a {
  color: #FFCC00;
  font-weight: bold;
  text-decoration: none;
  transition: color 0.3s ease-in-out;
}

.policy-compliance a:hover {
  text-decoration: underline;
  color: #e2bd2a;
}

/* Acknowledgment Text */
.policy-acknowledge {
  font-style: italic;
  color: #666;
  margin-top: 10px;
}

/* Dark Mode - Acknowledgment Text */
.dark-mode .policy-acknowledge {
  color: #b3b3b3;
}

/* ============================ GIVEAWAY EXTRAS (optional reuse) ============================ */
#giveaway-hero {
  background:
    linear-gradient(120deg, rgba(0, 0, 0, 0.6) 10%, rgba(255, 204, 0, 0.1) 90%),
    url('../assets/giveaway-bg.jpg') center/cover no-repeat;
}

.dark-mode #giveaway-hero {
  background:
    linear-gradient(120deg, rgba(18, 18, 18, 0.9) 10%, rgba(255, 204, 0, 0.85) 90%),
    url('../assets/giveaway-bg.jpg') center/cover no-repeat;
}

/* Giveaway Timeline Container */
.giveaway-timing {
  background-color: rgba(0, 0, 0, 0.7);
  padding: 25px;
  border-radius: 10px;
  color: #fff;
  max-width: 500px;
  margin: 20px auto;
  box-shadow: 0 8px 16px rgba(0, 0, 0, 0.3);
  font-family: 'Montserrat', sans-serif;
}

/* Title Header */
.giveaway-timing-title {
  font-size: 1.3rem;
  font-weight: 700;
  margin-bottom: 15px;
  text-align: center;
  color: var(--primary-color, #ffcc00);
}

/* Dates List */
.giveaway-dates-list {
  list-style: none;
  padding: 0;
  margin: 0;
  font-size: 1.05rem;
  line-height: 2;
  text-align: left;
}

.giveaway-dates-list li {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
  padding: 2px 0;
}

/* Highlighted Date */
.giveaway-date {
  background-color: var(--primary-color, #ffcc00);
  color: var(--button-text, #000);
  font-weight: 600;
  padding: 5px 12px;
  border-radius: 6px;
  white-space: nowrap;
}

/* Dark Mode Styling */
.dark-mode .giveaway-timing {
  background-color: rgba(255, 255, 255, 0.08);
  color: #fff;
}

.dark-mode .giveaway-date {
  background-color: #fff;
  color: #000;
}

/* Giveaway Back Button Container */
#giveaway-back-btn-container {
  text-align: center;
  margin-top: 20px;
}

/* Specific Styling for Giveaway Back Button */
#giveaway-back-btn {
  display: inline-block;
  text-decoration: none;
  padding: 12px 24px;
  font-weight: 600;
  border-radius: 6px;
  font-size: 1rem;
  font-family: 'Montserrat', sans-serif;
  background-color: var(--primary-color, #ffcc00);
  color: #000;
  transition: background-color 0.3s ease, color 0.3s ease;
}

#giveaway-back-btn:hover {
  background-color: var(--button-hover-bg, #e2bd2a);
  color: var(--button-hover-text, #000);
}
