:root {
  --primary-color: #2563eb;
  --secondary-color: #64748b;
  --success-color: #059669;
  --warning-color: #d97706;
  --danger-color: #dc2626;
  --info-color: #0891b2;
  --light-bg: #f8fafc;
  --card-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1),
    0 2px 4px -1px rgba(0, 0, 0, 0.06);
  --card-shadow-hover: 0 20px 25px -5px rgba(0, 0, 0, 0.1),
    0 10px 10px -5px rgba(0, 0, 0, 0.04);
}

body {
  font-family: "Kanit", sans-serif;
  /* background: linear-gradient(135deg, #667eea 0%, #764ba2 100%); */
  min-height: 100vh;
}

.hero-section {
  background: linear-gradient(
    135deg,
    rgba(37, 99, 235, 0.9),
    rgba(59, 130, 246, 0.8)
  );
  color: white;
  padding: 4rem 0;
  margin-bottom: 3rem;
}

.service-card {
  background: white;
  border-radius: 16px;
  padding: 2rem;
  box-shadow: var(--card-shadow);
  transition: all 0.3s ease;
  height: 100%;
  border: none;
  position: relative;
  overflow: hidden;
  display: flex;
  flex-direction: column;
}

.service-card::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 4px;
  background: linear-gradient(90deg, var(--primary-color), var(--info-color));
}

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

.card-header-content {
  flex: 0 0 auto;
}

.card-news-section {
  flex: 1;
  margin-top: 1rem;
  padding-top: 1rem;
  border-top: 1px solid #e2e8f0;
}

.time-window {
  background: linear-gradient(135deg, #f0f9ff, #e0f2fe);
  border: 1px solid #0891b2;
  border-radius: 8px;
  padding: 1rem;
  margin-bottom: 1rem;
  position: relative;
}

.time-window.open {
  background: linear-gradient(135deg, #f0fdf4, #dcfce7);
  border-color: var(--success-color);
}

.time-window.closed {
  background: linear-gradient(135deg, #fef2f2, #fee2e2);
  border-color: var(--danger-color);
}

.time-window-title {
  font-size: 0.875rem;
  font-weight: 600;
  margin-bottom: 0.5rem;
}

.time-window-dates {
  font-size: 0.8rem;
  color: var(--secondary-color);
}

.window-status {
  position: absolute;
  top: 0.5rem;
  right: 0.5rem;
  padding: 0.25rem 0.5rem;
  border-radius: 12px;
  font-size: 0.75rem;
  font-weight: 500;
}

.card-news-item {
  background: #f8fafc;
  border-left: 3px solid var(--primary-color);
  padding: 0.75rem;
  margin-bottom: 0.75rem;
  border-radius: 0 6px 6px 0;
  font-size: 0.875rem;
}

.card-news-item.important {
  border-left-color: var(--danger-color);
}

.card-news-item.warning {
  border-left-color: var(--warning-color);
}

.card-news-item.info {
  border-left-color: var(--info-color);
}

.card-news-title {
  font-weight: 600;
  margin-bottom: 0.25rem;
  font-size: 0.85rem;
  color: #1e293b;
}

.card-news-content {
  color: var(--secondary-color);
  font-size: 0.8rem;
  line-height: 1.4;
}

.card-news-date {
  color: var(--secondary-color);
  font-size: 0.75rem;
  margin-bottom: 0.25rem;
}

.card-news-link {
  margin-top: 0.5rem;
}

.card-news-link a {
  font-size: 0.75rem;
  text-decoration: none;
  font-weight: 500;
}

.card-news-link a:hover {
  text-decoration: underline;
}

.service-icon {
  width: 64px;
  height: 64px;
  background: linear-gradient(135deg, var(--primary-color), var(--info-color));
  border-radius: 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 1.5rem;
}

.service-icon i {
  font-size: 2rem;
  color: white;
}

.status-badge {
  position: absolute;
  top: 1rem;
  right: 1rem;
  padding: 0.5rem 1rem;
  border-radius: 20px;
  font-size: 0.875rem;
  font-weight: 500;
}

.status-open {
  background: rgba(5, 150, 105, 0.1);
  color: var(--success-color);
  border: 1px solid rgba(5, 150, 105, 0.2);
}

.status-closed {
  background: rgba(220, 38, 38, 0.1);
  color: var(--danger-color);
  border: 1px solid rgba(220, 38, 38, 0.2);
}

.news-section {
  background: white;
  border-radius: 16px;
  padding: 2rem;
  box-shadow: var(--card-shadow);
  margin-top: 3rem;
}

.news-item {
  border-left: 4px solid var(--primary-color);
  padding: 1.5rem;
  margin-bottom: 1.5rem;
  background: var(--light-bg);
  border-radius: 0 8px 8px 0;
  transition: all 0.3s ease;
}

.news-item:hover {
  background: #f1f5f9;
  transform: translateX(4px);
}

.news-item.important {
  border-left-color: var(--danger-color);
}

.news-item.warning {
  border-left-color: var(--warning-color);
}

.news-item.info {
  border-left-color: var(--info-color);
}

.news-date {
  color: var(--secondary-color);
  font-size: 0.875rem;
  margin-bottom: 0.5rem;
}

.news-title {
  font-weight: 600;
  margin-bottom: 0.75rem;
  color: #1e293b;
}

.news-content {
  color: var(--secondary-color);
  line-height: 1.6;
}

.btn-primary-custom {
  background: linear-gradient(135deg, var(--primary-color), var(--info-color));
  border: none;
  border-radius: 12px;
  padding: 0.75rem 1.5rem;
  font-weight: 500;
  transition: all 0.3s ease;
}

.btn-primary-custom:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 15px rgba(37, 99, 235, 0.3);
}

.time-info {
  background: rgba(255, 255, 255, 0.1);
  border-radius: 12px;
  padding: 1.5rem;
  margin-top: 2rem;
  backdrop-filter: blur(10px);
}

.pulse {
  animation: pulse 2s infinite;
}

@keyframes pulse {
  0% {
    opacity: 1;
  }

  50% {
    opacity: 0.7;
  }

  100% {
    opacity: 1;
  }
}

.gradient-text {
  background: linear-gradient(135deg, var(--primary-color), var(--info-color));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

@media (max-width: 768px) {
  .hero-section {
    padding: 2rem 0;
  }

  .service-card {
    margin-bottom: 1.5rem;
  }
  
  /* Navbar responsive improvements */
  .navbar-brand {
    max-width: calc(100% - 60px);
  }
  
  .navbar-toggler {
    flex-shrink: 0;
  }
  
  .navbar-nav .nav-link {
    font-size: 0.95rem;
  }
  
  .dropdown-menu {
    font-size: 0.9rem;
  }
}

/* Additional responsive improvements for navbar */
@media (max-width: 576px) {
  .btn {
    font-size: 0.85rem;
    padding: 0.5rem 0.75rem;
  }
  
  .navbar-brand img {
    width: 3em !important;
  }
}

@media (max-width: 480px) {
  .navbar-nav-actions .d-flex {
    flex-direction: column;
    width: 100%;
  }
  
  .navbar-nav-actions .btn {
    width: 100%;
    margin-bottom: 0.5rem;
  }
  
  .navbar-nav-actions .btn:last-child {
    margin-bottom: 0;
  }
}
