/* Credit Score Repair - Ad-Optimized Stylesheet */

:root {
  --primary: #1a5f7a;
  --primary-dark: #134b61;
  --accent: #e8f4f8;
  --text: #2d3436;
  --text-light: #636e72;
  --border: #dfe6e9;
  --white: #ffffff;
  --sidebar-bg: #f8f9fa;
  --ad-bg: #f4f4f4;
  --success: #27ae60;
  --shadow: 0 2px 8px rgba(0,0,0,0.08);
}

* { margin: 0; padding: 0; box-sizing: border-box; }

body {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
  font-size: 17px;
  line-height: 1.7;
  color: var(--text);
  background: var(--white);
}

/* Layout with sidebar for ads */
.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
}

.content-wrapper {
  display: flex;
  gap: 32px;
  margin-top: 24px;
}

.main-content {
  flex: 1;
  max-width: 760px;
}

.sidebar {
  width: 336px;
  flex-shrink: 0;
}

/* Header */
.header {
  background: var(--primary);
  padding: 20px 0;
  box-shadow: var(--shadow);
  position: sticky;
  top: 0;
  z-index: 100;
}

.header .container {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.logo {
  font-size: 24px;
  font-weight: 700;
  color: var(--white);
  text-decoration: none;
}

.logo span {
  color: #ffd700;
}

.nav a {
  color: var(--white);
  text-decoration: none;
  margin-left: 24px;
  font-size: 15px;
  font-weight: 500;
  opacity: 0.9;
  transition: opacity 0.2s;
}

.nav a:hover { opacity: 1; }

/* Hero Section */
.hero {
  background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
  color: var(--white);
  padding: 60px 0 50px;
  text-align: center;
}

.hero h1 {
  font-size: 38px;
  font-weight: 700;
  margin-bottom: 16px;
  line-height: 1.2;
}

.hero p {
  font-size: 18px;
  opacity: 0.9;
  max-width: 600px;
  margin: 0 auto;
}

/* Ad Containers */
.ad-container {
  background: var(--ad-bg);
  border: 1px dashed #ccc;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  color: #999;
  font-size: 13px;
  margin: 24px 0;
  min-height: 90px;
}

.ad-container.leaderboard {
  width: 100%;
  min-height: 90px;
}

.ad-container.sidebar-ad {
  width: 336px;
  min-height: 280px;
  margin-bottom: 24px;
}

.ad-container.in-article {
  min-height: 250px;
  margin: 32px 0;
}

.ad-container.sticky-sidebar {
  position: sticky;
  top: 80px;
}

/* Content */
.content {
  padding: 48px 0;
}

.content h1 {
  font-size: 34px;
  margin-bottom: 16px;
  line-height: 1.3;
  color: var(--primary-dark);
}

.content h2 {
  font-size: 26px;
  margin: 48px 0 20px;
  color: var(--primary-dark);
  padding-bottom: 10px;
  border-bottom: 2px solid var(--accent);
}

.content h3 {
  font-size: 21px;
  margin: 32px 0 14px;
  color: var(--text);
}

.content p {
  margin-bottom: 20px;
}

.content ul, .content ol {
  margin: 20px 0;
  padding-left: 30px;
}

.content li {
  margin-bottom: 12px;
}

.content a {
  color: var(--primary);
  text-decoration: none;
  border-bottom: 1px solid transparent;
  transition: border-color 0.2s;
}

.content a:hover {
  border-bottom-color: var(--primary);
}

.content strong {
  color: var(--text);
  font-weight: 600;
}

/* Tables */
table {
  width: 100%;
  border-collapse: collapse;
  margin: 28px 0;
  font-size: 15px;
}

th, td {
  padding: 14px 16px;
  text-align: left;
  border-bottom: 1px solid var(--border);
}

th {
  background: var(--accent);
  font-weight: 600;
  color: var(--primary-dark);
}

tr:hover { background: #f8f9fa; }

/* Cards / Silos */
.silos {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 28px;
  margin: 48px 0;
}

.silo-card {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 32px;
  transition: box-shadow 0.2s, transform 0.2s;
}

.silo-card:hover {
  box-shadow: var(--shadow);
  transform: translateY(-2px);
}

.silo-card h3 {
  font-size: 22px;
  color: var(--primary);
  margin-bottom: 14px;
}

.silo-card p {
  font-size: 15px;
  color: var(--text-light);
  margin-bottom: 18px;
}

.silo-card a {
  display: inline-block;
  color: var(--primary);
  font-weight: 600;
  font-size: 14px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

/* FAQ Section */
.faq-item {
  margin-bottom: 28px;
  padding-bottom: 24px;
  border-bottom: 1px solid var(--border);
}

.faq-item:last-child {
  border-bottom: none;
}

.faq-item h3 {
  font-size: 18px;
  color: var(--primary-dark);
  margin-bottom: 10px;
  cursor: pointer;
}

.faq-item p {
  font-size: 16px;
  color: var(--text-light);
}

/* Related Links */
.related-links {
  background: var(--accent);
  padding: 32px;
  border-radius: 12px;
  margin: 48px 0;
}

.related-links h3 {
  font-size: 20px;
  margin-bottom: 16px;
  color: var(--primary-dark);
}

.related-links ul {
  list-style: none;
  padding: 0;
}

.related-links li {
  margin-bottom: 10px;
}

.related-links a {
  color: var(--primary);
  font-weight: 500;
}

/* Metadata */
.meta {
  display: flex;
  gap: 24px;
  font-size: 14px;
  color: var(--text-light);
  margin-bottom: 28px;
  padding-bottom: 20px;
  border-bottom: 1px solid var(--border);
}

/* Breadcrumb */
.breadcrumb {
  font-size: 14px;
  color: var(--text-light);
  margin-bottom: 24px;
}

.breadcrumb a {
  color: var(--primary);
}

/* Sidebar */
.sidebar-widget {
  background: var(--sidebar-bg);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 24px;
  margin-bottom: 24px;
}

.sidebar-widget h3 {
  font-size: 18px;
  color: var(--primary-dark);
  margin-bottom: 16px;
}

.sidebar-widget ul {
  list-style: none;
  padding: 0;
}

.sidebar-widget li {
  margin-bottom: 10px;
  font-size: 15px;
}

.sidebar-widget a {
  color: var(--primary);
  text-decoration: none;
}

.sidebar-widget a:hover {
  text-decoration: underline;
}

/* Footer */
.footer {
  background: var(--primary-dark);
  color: var(--white);
  padding: 48px 0;
  margin-top: 60px;
}

.footer .container {
  text-align: center;
}

.footer p {
  opacity: 0.8;
  font-size: 15px;
  margin-bottom: 10px;
}

.footer a {
  color: #ffd700;
  text-decoration: none;
}

/* Buttons */
.btn {
  display: inline-block;
  padding: 14px 32px;
  background: var(--primary);
  color: var(--white);
  text-decoration: none;
  border-radius: 8px;
  font-weight: 600;
  font-size: 16px;
  transition: background 0.2s;
  border: none;
  cursor: pointer;
}

.btn:hover {
  background: var(--primary-dark);
}

/* Responsive */
@media (max-width: 900px) {
  .content-wrapper {
    flex-direction: column;
  }
  
  .sidebar {
    width: 100%;
    order: 2;
  }
  
  .main-content {
    max-width: 100%;
    order: 1;
  }
  
  .ad-container.sidebar-ad {
    width: 100%;
    min-height: 250px;
  }
}

@media (max-width: 600px) {
  .hero h1 { font-size: 28px; }
  .hero p { font-size: 16px; }
  .content h1 { font-size: 28px; }
  .content h2 { font-size: 22px; }
  .header .container { flex-direction: column; gap: 12px; }
  .nav a { margin: 0 10px; }
  table { font-size: 13px; }
  th, td { padding: 10px 12px; }
}

/* Article list on homepage */
.article-list {
  list-style: none;
  padding: 0;
}

.article-list li {
  padding: 18px 0;
  border-bottom: 1px solid var(--border);
}

.article-list li:last-child {
  border-bottom: none;
}

.article-list a {
  font-size: 19px;
  font-weight: 600;
  color: var(--primary);
  text-decoration: none;
}

.article-list p {
  font-size: 15px;
  color: var(--text-light);
  margin-top: 6px;
}

/* Ezoic optimization classes */
.ezoic-ad {
  display: block;
  margin: 24px auto;
  text-align: center;
}

.ad-placeholder {
  background: repeating-linear-gradient(
    45deg,
    #f0f0f0,
    #f0f0f0 10px,
    #e8e8e8 10px,
    #e8e8e8 20px
  );
  border: 2px dashed #ccc;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 13px;
  color: #888;
}

/* Affiliate CTA button contrast fix - 2026-05-24
   Keep button text readable inside article content. Generic .content a styles are more specific
   than .btn, so these scoped rules intentionally override article link styling. */
.content a.btn,
.content a.btn:visited,
.affiliate-cta a.btn,
.affiliate-cta a.btn:visited {
  color: #ffffff !important;
  background: var(--primary);
  border-bottom: 0 !important;
  text-decoration: none !important;
}

.content a.btn:hover,
.content a.btn:focus,
.affiliate-cta a.btn:hover,
.affiliate-cta a.btn:focus {
  color: #ffffff !important;
  background: var(--primary-dark);
  border-bottom: 0 !important;
  text-decoration: none !important;
  outline: 3px solid rgba(26, 95, 122, 0.24);
  outline-offset: 2px;
}
