.custom-modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background: rgba(0, 0, 0, 0.4);
  z-index: 9999;
  display: none; /* for fadeIn */
}

@keyframes fadeInOnly {
  0% { opacity: 0; }
  100% { opacity: 1; }
}

/* centering */
.custom-modal {
  position: fixed;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  background: #fff;
  max-width: 600px;
  width: 90%;
  border-radius: 8px;
  box-shadow: 0 15px 40px rgba(0, 0, 0, 0.2);
  font-family: "Raleway", sans-serif;
  overflow: hidden;
  border: 1px solid #e1e1e1;
  opacity: 0;
  animation: fadeInOnly 0.4s ease forwards;
  z-index: 10000;
}


@keyframes slideDownFade {
  0% { transform: translateY(-30px); opacity: 0; }
  100% { transform: translateY(0); opacity: 1; }
}

.custom-modal-header,
.custom-modal-body,
.custom-modal-footer {
  text-align: center;
  background: #fff;
}

.custom-modal-header {
  padding: 16px 24px;
  border-bottom: 1px solid #eee;
  position: relative;
}

.custom-modal-title {
  font-size: 1.3rem;
  font-weight: 600;
  color: #b59f7b;
}

.custom-close {
  position: absolute;
  top: 16px;
  right: 20px;
  font-size: 20px;
  color: #000;
  background: none;
  border: none;
  cursor: pointer;
}

.custom-modal-body {
  padding: 20px 24px;
  font-size: 0.95rem;
  color: #333;
  line-height: 1.6;
}

.custom-modal-body p {
  margin-bottom: 10px;
}

.custom-modal-body a.custom-modal-link {
  color: #b59f7b;
  font-weight: 600;
  text-decoration: underline;
  font-size: 1.05rem;
  transition: color 0.3s ease;
}

.custom-modal-body a.custom-modal-link:hover {
  color: #8a7759;
}

.custom-modal-footer {
  padding: 20px 24px;
  border-top: 1px solid #eee;
}

/* ✅ Κουμπιά: responsive flex layout */
.modal-buttons {
  display: flex;
  flex-direction: column;
  gap: 12px;
  justify-content: center;
  align-items: center;
}

/* Desktop layout: row */
@media (min-width: 768px) {
  .modal-buttons {
    flex-direction: row;
  }
}

.modal-buttons a,
.modal-buttons button {
  padding: 10px 24px;
  font-size: 0.95rem;
  border-radius: 4px;
  cursor: pointer;
  font-family: "Raleway", sans-serif;
  letter-spacing: 0.5px;
  text-transform: uppercase;
  transition: all 0.3s ease;
  min-width: 220px;
  text-align: center;
}

/* Primary CTA */
.modal-buttons .btn-primary {
  background-color: #b59f7b;
  border: 1px solid #b59f7b;
  color: #fff;
  text-decoration: none;
}

.modal-buttons .btn-primary:hover {
  background-color: #9c8463;
  border-color: #9c8463;
}

/* Secondary button */
.modal-buttons .btn-secondary {
  background-color: transparent;
  border: 1px solid #333;
  color: #333;
}

.modal-buttons .btn-secondary:hover {
  background-color: #333;
  color: #fff;
}


@media (max-width: 767.98px) {
  .modal-buttons {
    flex-direction: column;
    gap: 10px;
    width: 100%;
  }

  .modal-buttons a,
  .modal-buttons button {
    width: 100%;
    max-width: 280px;
  }
}
