/* ===================================
   EchtVital - Educational Website CSS
   ===================================
   Brand Colors:
   Primary: #F9FEFD (off-white background)
   Accent 1: #3E7066 (teal-green)
   Accent 2: #76B6A8 (light teal)
   Accent 3: #D4C03A (warm yellow)
*/

/* ===== BASE STYLES ===== */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: 'Karla', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  background-color: #F9FEFD;
  color: #333;
  font-size: 17px;
  line-height: 1.74;
  overflow-x: hidden;
}

h1, h2, h3, h4, h5, h6 {
  font-family: 'Karla', sans-serif;
  font-weight: 700;
  margin-top: 30px;
  margin-bottom: 20px;
  color: #1a1a1a;
  letter-spacing: -0.5px;
}

h1 {
  font-size: 3.2rem;
  line-height: 1.2;
  font-weight: 700;
}

h2 {
  font-size: 2.4rem;
  line-height: 1.3;
}

h3 {
  font-size: 1.8rem;
  line-height: 1.4;
  font-weight: 600;
}

h4 {
  font-size: 1.4rem;
  font-weight: 600;
}

p {
  margin-bottom: 18px;
  line-height: 1.74;
}

a {
  color: #3E7066;
  text-decoration: none;
  transition: color 0.3s ease;
}

a:hover {
  color: #76B6A8;
}

em, i {
  font-style: italic;
  color: #3E7066;
}

/* ===== HEADER STYLES ===== */
header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  background-color: rgba(249, 254, 253, 0.95);
  backdrop-filter: blur(8px);
  z-index: 1000;
  transition: box-shadow 0.3s ease;
  border-bottom: 1px solid rgba(62, 112, 102, 0.1);
}

header.scrolled {
  box-shadow: 0 2px 12px rgba(62, 112, 102, 0.08);
  background-color: rgba(249, 254, 253, 0.98);
}

.header-container {
  max-width: 1320px;
  margin: 0 auto;
  padding: 0 40px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  height: 80px;
}

.logo {
  font-size: 1.5rem;
  font-weight: 700;
  color: #3E7066;
  text-decoration: none;
  letter-spacing: 0.5px;
  transition: color 0.3s ease;
}

.logo:hover {
  color: #76B6A8;
}

nav a {
  color: #3E7066;
  font-size: 0.95rem;
  margin-left: 35px;
  font-weight: 500;
  transition: color 0.3s ease, border-bottom 0.3s ease;
  border-bottom: 2px solid transparent;
  padding-bottom: 5px;
}

nav a:hover {
  color: #D4C03A;
  border-bottom-color: #D4C03A;
}

/* ===== MAIN CONTENT ===== */
main {
  margin-top: 80px;
  width: 100%;
}

.container {
  max-width: 1320px;
  margin: 0 auto;
  padding: 0 40px;
}

.full-width {
  width: 100%;
}

/* ===== SECTION STYLES ===== */
section {
  padding: 145px 0;
  position: relative;
}

section.hero {
  padding: 0;
  margin-top: 80px;
  height: 100vh;
  background-size: cover;
  background-position: center;
  background-attachment: fixed;
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
}

section.hero::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(249, 254, 253, 0.15);
}

section.hero .content {
  position: relative;
  z-index: 2;
  text-align: center;
  color: #fff;
  text-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
}

section.hero h1 {
  color: #fff;
  font-size: 3.8rem;
  margin-bottom: 20px;
}

section.hero p {
  color: rgba(255, 255, 255, 0.95);
  font-size: 1.3rem;
}

section:not(.hero) {
  background-color: #F9FEFD;
}

section.alt-bg {
  background-color: rgba(62, 112, 102, 0.04);
}

section.alt-bg-2 {
  background-color: rgba(118, 182, 168, 0.05);
}

/* ===== CARD & GRID STYLES ===== */
.card {
  background: #fff;
  border-radius: 8px;
  padding: 35px;
  box-shadow: 0 4px 12px rgba(62, 112, 102, 0.08);
  transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
  border: 1px solid rgba(62, 112, 102, 0.1);
}

.card:hover {
  transform: translateY(-8px);
  box-shadow: 0 12px 28px rgba(62, 112, 102, 0.15);
  border-color: #76B6A8;
}

.card h3 {
  margin-top: 0;
  color: #3E7066;
}

.grid-3 {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 30px;
  margin: 40px 0;
}

.grid-2 {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 40px;
  margin: 40px 0;
  align-items: center;
}

/* ===== IMAGE STYLES ===== */
img {
  max-width: 100%;
  height: auto;
  display: block;
  border-radius: 6px;
}

.img-container {
  overflow: hidden;
  border-radius: 8px;
  box-shadow: 0 4px 12px rgba(62, 112, 102, 0.1);
  transition: transform 0.4s ease;
}

.img-container:hover img {
  transform: scale(1.02);
}

.img-small {
  max-width: 250px;
  margin: 0 auto;
}

.img-medium {
  max-width: 400px;
  margin: 20px auto;
}

.img-large {
  max-width: 100%;
  width: 100%;
}

/* ===== BUTTON STYLES ===== */
.btn {
  display: inline-block;
  padding: 14px 32px;
  border: none;
  border-radius: 6px;
  font-size: 1rem;
  font-weight: 600;
  text-decoration: none;
  cursor: pointer;
  transition: all 0.3s ease;
  text-align: center;
  font-family: 'Karla', sans-serif;
  letter-spacing: 0.3px;
}

.btn-primary {
  background: linear-gradient(135deg, #3E7066 0%, #2d5450 100%);
  color: #fff;
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 20px rgba(62, 112, 102, 0.3);
}

.btn-secondary {
  background: #76B6A8;
  color: #fff;
}

.btn-secondary:hover {
  background: #5fa393;
  transform: translateY(-2px);
}

.btn-outline {
  background: transparent;
  border: 2px solid #3E7066;
  color: #3E7066;
}

.btn-outline:hover {
  background: #3E7066;
  color: #fff;
}

/* ===== TABLE STYLES ===== */
table {
  width: 100%;
  border-collapse: collapse;
  margin: 30px 0;
  box-shadow: 0 4px 12px rgba(62, 112, 102, 0.08);
  border-radius: 6px;
  overflow: hidden;
}

thead {
  background: linear-gradient(135deg, #3E7066 0%, #2d5450 100%);
  color: #fff;
}

thead th {
  padding: 18px;
  text-align: left;
  font-weight: 700;
  border: none;
}

tbody td {
  padding: 16px 18px;
  border-bottom: 1px solid #e0e0e0;
}

tbody tr:hover {
  background-color: rgba(118, 182, 168, 0.08);
}

tbody tr:last-child td {
  border-bottom: none;
}

/* ===== QUOTE/CITATION STYLES ===== */
blockquote {
  font-style: italic;
  color: #3E7066;
  border-left: 4px solid #D4C03A;
  padding-left: 25px;
  margin: 30px 0;
  font-size: 1.1rem;
  line-height: 1.8;
}

/* ===== FAQ STYLES ===== */
.faq-item {
  background: #fff;
  border: 1px solid rgba(62, 112, 102, 0.1);
  border-radius: 6px;
  padding: 25px;
  margin-bottom: 20px;
  transition: all 0.3s ease;
}

.faq-item:hover {
  border-color: #76B6A8;
  box-shadow: 0 4px 12px rgba(62, 112, 102, 0.08);
}

.faq-question {
  font-weight: 700;
  color: #3E7066;
  cursor: pointer;
  display: flex;
  justify-content: space-between;
  align-items: center;
  user-select: none;
  transition: color 0.3s ease;
}

.faq-question:hover {
  color: #D4C03A;
}

.faq-toggle {
  width: 24px;
  height: 24px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  color: #D4C03A;
  transition: transform 0.3s ease;
}

.faq-item.active .faq-toggle {
  transform: rotate(180deg);
}

.faq-answer {
  display: none;
  margin-top: 15px;
  padding-top: 15px;
  border-top: 1px solid rgba(62, 112, 102, 0.1);
  line-height: 1.74;
}

.faq-item.active .faq-answer {
  display: block;
  animation: fadeIn 0.4s ease;
}

/* ===== FORM STYLES ===== */
.form-group {
  margin-bottom: 25px;
}

label {
  display: block;
  font-weight: 600;
  color: #3E7066;
  margin-bottom: 8px;
  font-size: 0.95rem;
}

input[type="text"],
input[type="email"],
input[type="tel"],
textarea {
  width: 100%;
  padding: 14px 16px;
  border: 1px solid rgba(62, 112, 102, 0.2);
  border-radius: 6px;
  font-family: 'Karla', sans-serif;
  font-size: 1rem;
  line-height: 1.5;
  transition: all 0.3s ease;
  background-color: #fff;
}

input[type="text"]:focus,
input[type="email"]:focus,
input[type="tel"]:focus,
textarea:focus {
  outline: none;
  border-color: #3E7066;
  box-shadow: 0 0 0 3px rgba(62, 112, 102, 0.1);
  background-color: #fff;
}

textarea {
  min-height: 120px;
  resize: vertical;
}

/* ===== FOOTER STYLES ===== */
footer {
  background: linear-gradient(135deg, #3E7066 0%, #2d5450 100%);
  color: rgba(255, 255, 255, 0.95);
  padding: 60px 0 40px;
  margin-top: 145px;
}

footer .container {
  max-width: 1320px;
}

.footer-content {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 50px;
  margin-bottom: 50px;
  padding-bottom: 30px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.2);
}

.footer-section h4 {
  color: #fff;
  margin-top: 0;
  margin-bottom: 15px;
}

.footer-section p {
  font-size: 0.95rem;
  line-height: 1.8;
  margin-bottom: 10px;
}

.footer-section a {
  color: rgba(255, 255, 255, 0.9);
  text-decoration: none;
  display: block;
  padding: 5px 0;
  transition: color 0.3s ease;
  cursor: pointer;
}

.footer-section a:hover {
  color: #D4C03A;
}

.footer-disclaimer {
  font-size: 0.85rem;
  color: rgba(255, 255, 255, 0.8);
  text-align: center;
  padding: 20px 0;
}

.footer-bottom {
  text-align: center;
  padding-top: 20px;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  font-size: 0.85rem;
  color: rgba(255, 255, 255, 0.75);
}

/* ===== MODAL STYLES ===== */
.modal {
  display: none;
  position: fixed;
  z-index: 2000;
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.5);
  animation: fadeIn 0.3s ease;
  overflow-y: auto;
}

.modal.active {
  display: flex;
  align-items: flex-start;
  justify-content: center;
  padding-top: 60px;
}

.modal-content {
  background-color: #F9FEFD;
  padding: 50px;
  border-radius: 8px;
  width: 90%;
  max-width: 700px;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.3);
  animation: slideUp 0.4s ease;
  position: relative;
  max-height: calc(100vh - 120px);
  overflow-y: auto;
}

.modal-close {
  position: absolute;
  top: 20px;
  right: 20px;
  width: 36px;
  height: 36px;
  background: #3E7066;
  color: #fff;
  border: none;
  border-radius: 50%;
  font-size: 24px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.3s ease;
}

.modal-close:hover {
  background: #D4C03A;
  color: #333;
}

.modal h2 {
  margin-top: 0;
  color: #3E7066;
  border-bottom: 2px solid #D4C03A;
  padding-bottom: 15px;
}

/* ===== COOKIE CONSENT STYLES ===== */
.cookie-banner {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  background: linear-gradient(135deg, #3E7066 0%, #2d5450 100%);
  color: #fff;
  padding: 25px 40px;
  z-index: 1500;
  box-shadow: 0 -2px 15px rgba(0, 0, 0, 0.2);
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 30px;
  animation: slideUp 0.4s ease;
  display: none;
}

.cookie-banner.active {
  display: flex;
}

.cookie-text {
  flex: 1;
  font-size: 0.95rem;
  line-height: 1.6;
}

.cookie-buttons {
  display: flex;
  gap: 15px;
  flex-shrink: 0;
}

.cookie-btn {
  padding: 10px 22px;
  border: none;
  border-radius: 6px;
  cursor: pointer;
  font-weight: 600;
  font-size: 0.95rem;
  transition: all 0.3s ease;
  font-family: 'Karla', sans-serif;
}

.cookie-btn-accept {
  background: #D4C03A;
  color: #333;
}

.cookie-btn-accept:hover {
  background: #e5d650;
}

.cookie-btn-decline {
  background: rgba(255, 255, 255, 0.2);
  color: #fff;
  border: 1px solid rgba(255, 255, 255, 0.4);
}

.cookie-btn-decline:hover {
  background: rgba(255, 255, 255, 0.3);
}

.cookie-btn-learn {
  background: transparent;
  color: #D4C03A;
  border: 1px solid #D4C03A;
}

.cookie-btn-learn:hover {
  background: #D4C03A;
  color: #333;
}

/* ===== ANIMATIONS ===== */
@keyframes fadeIn {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}

@keyframes slideUp {
  from {
    transform: translateY(30px);
    opacity: 0;
  }
  to {
    transform: translateY(0);
    opacity: 1;
  }
}

@keyframes scaleIn {
  from {
    transform: scale(0.98);
    opacity: 0;
  }
  to {
    transform: scale(1);
    opacity: 1;
  }
}

/* ===== RESPONSIVE DESIGN ===== */
@media (max-width: 1024px) {
  .header-container {
    padding: 0 25px;
  }

  .container {
    padding: 0 25px;
  }

  h1 {
    font-size: 2.4rem;
  }

  h2 {
    font-size: 2rem;
  }

  h3 {
    font-size: 1.5rem;
  }

  section {
    padding: 100px 0;
  }

  .grid-3 {
    grid-template-columns: repeat(2, 1fr);
  }

  .grid-2 {
    grid-template-columns: 1fr;
  }

  .footer-content {
    grid-template-columns: repeat(2, 1fr);
    gap: 30px;
  }

  nav a {
    margin-left: 20px;
    font-size: 0.9rem;
  }
}

@media (max-width: 768px) {
  body {
    font-size: 16px;
  }

  .header-container {
    padding: 0 15px;
    height: 70px;
  }

  header {
    position: relative;
  }

  main {
    margin-top: 0;
  }

  section {
    padding: 70px 0;
  }

  section.hero {
    height: 70vh;
    margin-top: 0;
  }

  h1 {
    font-size: 2rem;
  }

  h2 {
    font-size: 1.6rem;
  }

  h3 {
    font-size: 1.3rem;
  }

  .container {
    padding: 0 15px;
  }

  .grid-3 {
    grid-template-columns: 1fr;
    gap: 20px;
  }

  .grid-2 {
    gap: 20px;
  }

  nav a {
    display: none;
  }

  .modal-content {
    width: 95%;
    padding: 30px;
  }

  .footer-content {
    grid-template-columns: 1fr;
    gap: 25px;
  }

  .cookie-banner {
    flex-direction: column;
    align-items: flex-start;
    padding: 20px;
    gap: 15px;
  }

  .cookie-buttons {
    width: 100%;
    flex-direction: column;
  }

  .cookie-btn {
    width: 100%;
  }

  .card {
    padding: 25px;
  }
}

@media (max-width: 480px) {
  body {
    font-size: 15px;
  }

  h1 {
    font-size: 1.6rem;
    line-height: 1.3;
  }

  h2 {
    font-size: 1.4rem;
  }

  h3 {
    font-size: 1.2rem;
  }

  .header-container {
    height: 60px;
  }

  section {
    padding: 50px 0;
  }

  section.hero h1 {
    font-size: 2rem;
  }

  section.hero p {
    font-size: 1.1rem;
  }

  .btn {
    padding: 12px 24px;
    font-size: 0.95rem;
  }

  table {
    font-size: 0.9rem;
  }

  thead th,
  tbody td {
    padding: 12px 10px;
  }

  .footer-section h4 {
    font-size: 1.1rem;
  }

  .modal-content {
    padding: 20px;
  }
}
