/* Imparcialista links page (theme-aware) */
:root {
  --text-light: #f8f9fa;
  --text-dark: #212529;
  --bg-light: #f8f9fa;
  --bg-dark: #212529;
  --shadow-color: rgba(0, 0, 0, 0.1);
  --shadow-hover: rgba(0, 0, 0, 0.2);
}

[data-bs-theme="dark"] {
  --text-light: #f8f9fa;
  --text-dark: #e9ecef;
  --bg-light: #2b3035;
  --bg-dark: #212529;
  --shadow-color: rgba(0, 0, 0, 0.3);
  --shadow-hover: rgba(0, 0, 0, 0.5);
}

.main-container { 
  padding: 50px 0;
  min-height: calc(100vh - 56px); /* Ajuste para o header */
  background-color: var(--bg-light);
  color: var(--text-dark);
}

.header { 
  text-align: center; 
  margin-bottom: 40px; 
  padding: 0 15px;
}

.header h1 { 
  font-size: 2.5rem; 
  color: var(--primary);
  margin-bottom: 0.5rem;
}

.header h2 { 
  font-size: 1.5rem; 
  color: var(--secondary);
  margin-bottom: 1rem;
}

.link-list { 
  list-style-type: none; 
  padding: 0;
  max-width: 800px;
  margin: 0 auto;
  padding: 0 15px;
}

.link-list li { 
  margin-bottom: 20px; 
  transition: transform 0.2s ease;
}

.link-list li:hover {
  transform: scale(1.02);
}

.link-list a {
  text-decoration: none;
  color: var(--text-light);
  display: flex;
  align-items: center;
  padding: 15px 20px;
  border-radius: 12px;
  transition: all 0.3s ease;
  box-shadow: 0 2px 10px var(--shadow-color);
  border: 1px solid transparent;
  font-weight: 500;
}

.link-list a:hover { 
  transform: translateY(-3px); 
  box-shadow: 0 6px 16px var(--shadow-hover);
  text-decoration: none;
}

.link-icon { 
  margin-right: 15px; /* Increased margin */
  font-size: 1.5rem; /* Bigger icon */
  width: 30px;
  text-align: center;
}

/* Brand blocks */
.apoia-se { 
  background-color: #ff7f50;
  border-color: #e67347 !important;
}

.discord { 
  background-color: #7289da;
  border-color: #5b6eae !important;
}

.telegram { 
  background-color: #0088cc;
  border-color: #0077b3 !important;
}

.whatsapp { 
  background-color: #25d366;
  border-color: #20bd5a !important;
}

.twitch { 
  background-color: #6441a5;
  border-color: #563d7c !important;
}

.github { 
  background-color: #333333;
  border-color: #1a1a1a !important;
}

.youtube { 
  background-color: #ff0000;
  border-color: #cc0000 !important;
}

.linkedin { 
  background-color: #0e76a8;
  border-color: #0c5d84 !important;
}

.instagram { 
  background: linear-gradient(45deg, #405de6, #5851db, #833ab4, #c13584, #e1306c, #fd1d1d);
  border: none !important;
}

.app { 
  background-color: #ff8c00;
  border-color: #e67e00 !important;
}

.marketplace-links { 
  background-color: #ff4500;
  border-color: #e63e00 !important;
}

/* Dark mode adjustments */
[data-bs-theme="dark"] .link-list a {
  border-color: rgba(255, 255, 255, 0.1);
}

/* Responsive adjustments */
@media (max-width: 768px) {
  .main-container {
    padding: 30px 0;
  }
  
  .header h1 {
    font-size: 2rem;
  }
  
  .header h2 {
    font-size: 1.25rem;
  }
  
  .link-list a {
    padding: 12px 15px;
  }
}

/* --- Grouped Links Styling --- */
.link-group {
  background-color: var(--bg-light);
  border-radius: 12px;
  padding: 0;
  box-shadow: 0 2px 10px var(--shadow-color);
  border: 1px solid rgba(0, 0, 0, 0.05);
  transition: transform 0.2s ease; /* Add transition for hover effect */
}

[data-bs-theme="dark"] .link-group {
  background-color: var(--bg-dark);
  border-color: rgba(255, 255, 255, 0.1);
}

.link-group .group-header {
  display: flex;
  align-items: center;
  font-size: 1rem; /* Match the font size of other links */
  font-weight: 500;
  color: var(--text-light); /* Use light text as it's on a colored background */
  padding: 15px 20px;
  border-radius: 12px 12px 0 0;
}

.link-group .group-header .link-icon {
  margin-right: 15px;
  font-size: 1.5rem;
}

.link-group .sub-link-list {
  list-style: none;
  padding: 15px;
  margin: 0;
}

.link-group .sub-link-list .sub-link {
  display: block;
  padding: 10px 15px;
  margin-bottom: 8px;
  background-color: var(--bg-light);
  border: 1px solid var(--shadow-color);
  border-radius: 8px;
  color: var(--text-dark);
  text-decoration: none;
  text-align: center;
  transition: transform 0.2s ease, background-color 0.2s ease;
}

.link-group .sub-link-list li:last-child {
    margin-bottom: 0;
}

[data-bs-theme="dark"] .link-group .sub-link-list .sub-link {
    background-color: var(--bg-light);
    color: var(--text-dark);
}

.link-group .sub-link-list .sub-link:hover {
  transform: scale(1.03);
  background-color: var(--bs-gray-200);
}

[data-bs-theme="dark"] .link-group .sub-link-list .sub-link:hover {
  background-color: var(--bs-gray-700);
}

/* --- Profile Picture --- */
.profile-picture {
  width: 120px;
  height: 120px;
  border-radius: 50%;
  object-fit: cover;
  margin-bottom: 20px;
  border: 4px solid var(--bg-dark);
  box-shadow: 0 4px 12px var(--shadow-color);
}

[data-bs-theme="dark"] .profile-picture {
  border-color: var(--bg-light);
}

/* --- Marketing Block --- */
.marketing-block {
  max-width: 800px;
  margin: 0 auto 40px auto;
  padding: 25px;
  background-color: var(--bg-dark);
  color: var(--text-light);
  border-radius: 12px;
  text-align: center;
  box-shadow: 0 4px 15px var(--shadow-color);
}

[data-bs-theme="dark"] .marketing-block {
  background-color: var(--bg-light);
  color: var(--text-dark);
}

.marketing-block h3 {
  font-size: 1.5rem;
  font-weight: 600;
  margin-bottom: 10px;
  color: var(--primary);
}

.marketing-block .subtitle {
  font-size: 1.1rem;
  line-height: 1.6;
  opacity: 0.9;
  margin-bottom: 20px;
  font-style: italic;
  color: var(--secondary);
}

.marketing-block .marketing-button {
    margin-top: 15px;
    font-weight: 600;
    padding: 12px 30px;
    border-radius: 30px;
}

/* --- Link Text & Description Styling --- */
.link-text {
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: flex-start;
  flex-grow: 1;
}

.link-text span {
  font-weight: 500;
  font-size: 1rem;
}

.link-text .link-description {
  font-size: 0.85rem;
  font-weight: 400;
  opacity: 0.8;
  margin-top: 2px;
}

/* Adjust group header text alignment */
.link-group .group-header .link-text {
    align-items: flex-start;
}

/* --- Category Header Styling --- */
.link-category-header {
  max-width: 800px;
  margin: 40px auto 15px auto;
  padding: 0 15px;
  font-size: 1.2rem;
  font-weight: 600;
  color: var(--text-dark);
  border-bottom: 2px solid var(--primary);
  padding-bottom: 8px;
}

.main-container > .link-category-header:first-of-type {
    margin-top: 0;
}