/* ===== Basic Reset ===== */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

/* ===== Color Palette Variables ===== */
:root {
  --primary-color: #E63946;
  --secondary-color: #1D3557;
  --background-color: #F1FAEE;
  --highlight-color: #457B9D;
  --light-blue: #A8DADC;
}

/* ===== Global Styles ===== */
html {
  scroll-behavior: smooth;
}

body {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
  font-family: 'Nunito', Arial, Helvetica, sans-serif;
  line-height: 1.6;
  color: var(--secondary-color);
  background-color: var(--background-color);
  margin: 0 auto;
  padding: 1rem;
  position: relative;
  align-items: center;
  justify-content: center;
}

/* ===== Homepage Specific ===== */
body.homepage {
  display: flex;
  align-items: center;
  text-align: center;
  padding: 0;
  margin: 0;
}

body.homepage p {
  color: var(--highlight-color);
  font-weight: 300;
  margin: 0.5rem 0 1rem;
}

/* ===== Body style for project pages ===== */
body.projects-page {
  display: flex;
  flex-direction: column;
  align-items: center;
  min-height: 100vh;
  text-align: center;
  padding: 0;
}

/* ===== Typography ===== */
h1 {
  margin: 1.5rem 0 0.5em;
  line-height: 1.2;
  color: var(--primary-color);
  font-size: 2.5rem;
  font-weight: 300;
}

h2, h3 {
  margin-bottom: 0.5em;
  line-height: 1.2;
  color: var(--secondary-color);
}

p {
  margin: 0.5rem 0 1rem;
  font-size: 1rem;
  color: var(--secondary-color);
}

code {
  background-color: #eee;
  padding: 2px 4px;
  border-radius: 4px;
  font-family: monospace;
}

.folder, .file {
  font-family: monospace;
  color: #555;
}

hr {
  border: none;
  border-top: 1px solid #ccc;
  margin: 2em 0;
}

/* ===== Reusable Button ===== */
.btn {
  display: inline-block;
  background-color: var(--primary-color);
  color: #fff;
  padding: 0.8rem 1.2rem;
  border: none;
  border-radius: 8px;
  text-decoration: none;
  font-size: 1rem;
  transition: background 0.3s;
}

.btn:hover {
  background-color: var(--highlight-color);
}

/* ===== Project Container & Cards ===== */
.project-container {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 30px;
  padding: 2rem;
  width: 100%;
  max-width: 1200px;
  box-sizing: border-box;
  margin: 0 auto;
}

.project-card {
  width: 100%;
  height: 250px;
  border: 1px solid var(--light-blue);
  border-radius: 10px;
  overflow: hidden;
  box-shadow: 0 4px 8px rgba(29, 53, 87, 0.1);
  background-color: #fff;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.project-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 8px 16px rgba(29, 53, 87, 0.15);
}

.project-title {
  margin: 20px 0 5px;
  font-size: 1.25rem;
  font-weight: 600;
  color: var(--primary-color);
  text-align: center;
  padding: 0 10px;
}

.project-description {
  font-size: 1rem;
  color: var(--highlight-color);
  text-align: center;
  margin: 0 0 20px;
  padding: 10px;
  line-height: 1.4;
  word-wrap: break-word;
  flex-grow: 1;
}

.card-wrapper {
  width: 100%;
  max-width: 300px;
  display: flex;
  flex-direction: column;
  align-items: center;
}

/* ===== Footer ===== */
footer {
  margin-top: 3rem;
  padding: 1.5rem 1rem;
  text-align: center;
  font-size: 0.9rem;
  color: var(--secondary-color);
  background-color: var(--background-color);
  border-top: 1px solid var(--light-blue);
  line-height: 1.4;
}

footer a {
  color: var(--highlight-color);
  text-decoration: none;
  font-weight: 600;
}

footer a:hover {
  text-decoration: underline;
}

/* ===== Responsive Adjustments ===== */
@media (max-width: 768px) {
  body {
    padding: 0 20px;
  }

  h1 {
    font-size: 1.5rem;
  }

  .btn {
    width: 100%;
    text-align: center;
  }

  footer {
    font-size: 0.85rem;
    padding: 1rem 0.5rem;
  }

  .project-container {
    padding: 1rem;
  }
}

@media (max-width: 600px) {
  footer .footer-container {
    flex-direction: column;
    gap: 1rem;
  }
}

.tasks-section h3, .tasks-section p, .tasks-section ul {
  text-align: left;
  margin-left: 0;
  margin-right: 0;
}

body.week-page {
  align-items: stretch !important;
  justify-content: flex-start !important;
  padding: 2rem 0 !important;
}

/* Container para centralizar e limitar largura, alinhando conteúdo à esquerda */
.week-content {
  width: 100%;
  max-width: 800px;
  margin: 0 auto;
  padding: 0 1rem 2rem 1rem;
}

.week-content h1,
.week-content h2,
.week-content h3,
.week-content h4,
.week-content p,
.week-content ul {
  text-align: left;
}

.social-icons {
  display: flex;
  gap: 1rem;
  align-items: center;
  justify-content: center;
  margin-bottom: 0.5rem;
}

.social-icons a {
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--secondary-color);
  opacity: 0.85;
  transition: opacity 0.2s, color 0.2s;
  font-size: 1.5rem;
}
.social-icons a:hover {
  color: var(--primary-color);
  opacity: 1;
}

.social-icons svg {
  width: 24px;
  height: 24px;
  display: block;
}