/* Custom CSS for Anemia Care Website */

:root {
  --primary-color: #e91e63;
  --secondary-color: #20c997;
  --accent-color: #fd7e14;
  --success-color: #28a745;
  --warning-color: #ffc107;
  --danger-color: #dc3545;
  --info-color: #17a2b8;
  --dark-color: #343a40;
  --light-color: #f8f9fa;
}

/* Body and General */
body {
  font-family: "Inter", "Segoe UI", Tahoma, Geneva, Verdana, sans-serif;
  line-height: 1.6;
  padding-top: 76px;
  background-color: var(--light-color);
  color: var(--dark-color);
}

.card {
  border: none;
  border-radius: 15px;
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.08);
}

.daftar {
  text-align: center;
}

.card-title {
  color: var(--primary-color);
  font-weight: 600;
}

.form-label {
  font-size: 0.9rem;
  color: var(--dark-color);
}

.form-control {
  border-radius: 10px;
  border: 1px solid #dee2e6;
  padding: 10px 15px;
  transition: border-color 0.3s ease;
}

.form-control:focus {
  border-color: var(--secondary-color);
  box-shadow: 0 0 0 0.25rem rgba(32, 201, 151, 0.25); /* Menggunakan warna secondary */
}

/* Hero Section */
.hero-section {
  min-height: 100vh;
  background: linear-gradient(
      135deg,
      rgba(233, 30, 99, 0.8),
      rgba(32, 201, 151, 0.8)
    ),
    url("img/bg.jpg");
  background-size: cover;
  background-position: center;
  background-attachment: fixed;
  display: flex;
  align-items: center;
}

.hero-section::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><defs><pattern id="grain" width="100" height="100" patternUnits="userSpaceOnUse"><circle cx="25" cy="25" r="1" fill="white" opacity="0.1"/><circle cx="75" cy="75" r="1" fill="white" opacity="0.1"/><circle cx="50" cy="10" r="0.5" fill="white" opacity="0.1"/><circle cx="10" cy="60" r="0.5" fill="white" opacity="0.1"/><circle cx="90" cy="40" r="0.5" fill="white" opacity="0.1"/></pattern></defs><rect width="100" height="100" fill="url(%23grain)"/></svg>');
  opacity: 0.3;
}

.hero-image {
  text-align: center;
  padding: 4rem 0;
}

/* Page Headers */
.page-header {
  background: linear-gradient(
    135deg,
    var(--primary-color) 0%,
    var(--secondary-color) 100%
  );
  padding: 150px 0 100px;
  margin-top: -76px;
  position: relative;
}

.bg-success-gradient {
  background: linear-gradient(
    135deg,
    var(--success-color) 0%,
    var(--secondary-color) 100%
  ) !important;
}

.bg-warning-gradient {
  background: linear-gradient(
    135deg,
    var(--warning-color) 0%,
    var(--accent-color) 100%
  ) !important;
}

.bg-info-gradient {
  background: linear-gradient(
    135deg,
    var(--info-color) 0%,
    var(--secondary-color) 100%
  ) !important;
}

.bg-danger-gradient {
  background: linear-gradient(
    135deg,
    var(--danger-color) 0%,
    var(--primary-color) 100%
  ) !important;
}

/* Cards */
.hover-card {
  transition: all 0.3s ease;
}

.hover-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 1rem 2rem rgba(0, 0, 0, 0.15) !important;
}

.card {
  border-radius: 15px;
  overflow: hidden;
}

.card-header {
  border-radius: 15px 15px 0 0 !important;
}

/* Info Boxes */
.info-box,
.symptom-card,
.food-card,
.complication-card,
.tip-card,
.treatment-box {
  transition: all 0.3s ease;
  border-radius: 10px;
}

.info-box:hover,
.symptom-card:hover,
.food-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 0.5rem 1rem rgba(0, 0, 0, 0.1);
}

/* Navigation */
.navbar-brand {
  font-size: 1.5rem;
}

.nav-link {
  font-weight: 500;
  transition: all 0.3s ease;
  position: relative;
}

.nav-link:hover,
.nav-link.active {
  color: var(--primary-color) !important;
}

.nav-link.active::after {
  content: "";
  position: absolute;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 30px;
  height: 2px;
  background: var(--primary-color);
  border-radius: 1px;
}

/* Buttons */
.btn {
  border-radius: 25px;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  transition: all 0.3s ease;
  padding: 0.75rem 1.5rem;
}

.btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 0.5rem 1rem rgba(0, 0, 0, 0.15);
}

/* Alerts */
.alert {
  border-radius: 10px;
  border: none;
}

/* Lists */
.list-unstyled li {
  margin-bottom: 0.5rem;
}

/* Colors */
.text-primary {
  color: var(--primary-color) !important;
}

.bg-primary {
  background-color: var(--primary-color) !important;
}

.btn-primary {
  background-color: var(--primary-color);
  border-color: var(--primary-color);
}

.btn-primary:hover {
  background-color: darken(var(#e91e63), 10%);
  border-color: darken(var(--primary-color), 10%);
}

/* Responsive Design */
@media (max-width: 768px) {
  .hero-section {
    padding: 2rem 0;
  }

  .display-4 {
    font-size: 2rem;
  }

  .hero-image {
    padding: 2rem 0;
  }

  .page-header {
    padding: 120px 0 80px;
  }

  .card-body {
    padding: 2rem 1rem !important;
  }
}

/* Smooth Scrolling */
html {
  scroll-behavior: smooth;
}

/* Loading Animation */
.fade-in {
  animation: fadeIn 0.6s ease-in;
}

@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Step Cards */
.step-card {
  animation: slideInUp 0.6s ease forwards;
  opacity: 0;
  transform: translateY(20px);
}

.step-card:nth-child(1) {
  animation-delay: 0.1s;
}
.step-card:nth-child(2) {
  animation-delay: 0.2s;
}
.step-card:nth-child(3) {
  animation-delay: 0.3s;
}
.step-card:nth-child(4) {
  animation-delay: 0.4s;
}
.step-card:nth-child(5) {
  animation-delay: 0.5s;
}

@keyframes slideInUp {
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Food and Info Cards Grid */
.meal-card {
  transition: all 0.3s ease;
}

.meal-card:hover {
  background-color: #ffffff !important;
  box-shadow: 0 0.25rem 0.5rem rgba(0, 0, 0, 0.1);
  transform: translateY(-2px);
}

/* Footer */
footer {
  margin-top: 3rem;
}

/* Utility Classes */
.border-radius-lg {
  border-radius: 15px;
}

.shadow-custom {
  box-shadow: 0 0.5rem 2rem rgba(0, 0, 0, 0.1);
}

/* Custom Spacing */
.py-6 {
  padding-top: 4rem;
  padding-bottom: 4rem;
}

/* Focus States */
.btn:focus,
.form-control:focus {
  box-shadow: 0 0 0 0.2rem rgba(233, 30, 99, 0.25);
}

/* Custom Icons */
.display-6 {
  font-size: 3rem;
}

/* Navigation Buttons */
.navigation-buttons .btn {
  min-width: 150px;
}

@media (max-width: 576px) {
  .navigation-buttons {
    flex-direction: column;
    gap: 1rem;
  }

  .navigation-buttons .btn {
    width: 100%;
  }
}
