/* Main styles */
:root {
  --primary-color: #ff6600;
  --primary-hover: #e55a00;
  --secondary-color: #2c3e50;
  --accent-color: #3498db;
  --text-dark: #2c3e50;
  --text-light: #7f8c8d;
  --text-white: #ffffff;
  --bg-light: #f8f9fa;
  --bg-white: #ffffff;
  --border-color: #e9ecef;
  --shadow: 0 2px 10px rgba(0,0,0,0.1);
  --shadow-hover: 0 4px 20px rgba(0,0,0,0.15);
  
  --font-primary: 'Open Sans', 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
  --font-secondary: 'Roboto Slab', serif;
  
  --container-width: 1200px;
  --border-radius: 8px;
  --transition: all 0.3s ease;
}

body {
  font-family: var(--font-primary);
  font-size: 16px;
  line-height: 1.6;
  color: var(--text-dark);
  background-color: var(--bg-light);
}

.container {
  max-width: var(--container-width);
  margin: 0 auto;
  padding: 0 20px;
}

/* Typography */
h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-secondary);
  font-weight: 700;
  margin-bottom: 1rem;
  color: var(--text-dark);
}

h1 {
  font-size: 2.5rem;
  line-height: 1.2;
}

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

h3 {
  font-size: 1.5rem;
}

p {
  margin-bottom: 1rem;
}

/* Buttons */
.btn {
  display: inline-block;
  padding: 12px 24px;
  border-radius: var(--border-radius);
  font-weight: 600;
  text-align: center;
  transition: var(--transition);
  cursor: pointer;
  border: 2px solid transparent;
  min-width: 120px;
}

.btn-primary {
  background-color: var(--primary-color);
  color: var(--text-white);
  border-color: var(--primary-color);
}

.btn-primary:hover {
  background-color: var(--primary-hover);
  border-color: var(--primary-hover);
  transform: translateY(-2px);
  box-shadow: var(--shadow-hover);
}

.btn-secondary {
  background-color: var(--bg-white);
  color: var(--primary-color);
  border-color: var(--primary-color);
}

.btn-secondary:hover {
  background-color: var(--primary-color);
  color: var(--text-white);
  transform: translateY(-2px);
  box-shadow: var(--shadow-hover);
}

.btn-outline {
  background-color: transparent;
  color: var(--accent-color);
  border-color: var(--accent-color);
}

.btn-outline:hover {
  background-color: var(--accent-color);
  color: var(--text-white);
  transform: translateY(-2px);
  box-shadow: var(--shadow-hover);
}

/* Cards */
.card {
  background-color: var(--bg-white);
  border-radius: var(--border-radius);
  box-shadow: var(--shadow);
  padding: 1.5rem;
  transition: var(--transition);
}

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

/* Scroll to top button */
.scroll-to-top {
  position: fixed;
  bottom: 30px;
  right: 30px;
  background-color: var(--primary-color);
  color: var(--text-white);
  border: none;
  border-radius: 50%;
  width: 50px;
  height: 50px;
  font-size: 1.2rem;
  cursor: pointer;
  transition: var(--transition);
  opacity: 0;
  visibility: hidden;
  z-index: 1000;
}

.scroll-to-top.visible {
  opacity: 1;
  visibility: visible;
}

.scroll-to-top:hover {
  background-color: var(--primary-hover);
  transform: scale(1.1);
}

/* Modal/Popup styles */
.modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.6);
  z-index: 10000;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  visibility: hidden;
  transition: all 0.3s ease;
}

.modal-overlay.active {
  opacity: 1;
  visibility: visible;
}

.modal {
  background-color: var(--bg-white);
  border-radius: var(--border-radius);
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.3);
  width: 90%;
  max-width: 500px;
  max-height: 90vh;
  overflow-y: auto;
  transform: scale(0.8) translateY(-50px);
  transition: all 0.3s ease;
}

.modal-overlay.active .modal {
  transform: scale(1) translateY(0);
}

.modal-header {
  padding: 20px 25px 15px;
  border-bottom: 1px solid var(--border-color);
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.modal-title {
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--text-dark);
  margin: 0;
}

.modal-close {
  background: none;
  border: none;
  font-size: 24px;
  color: var(--text-light);
  cursor: pointer;
  padding: 5px;
  border-radius: 50%;
  width: 35px;
  height: 35px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: var(--transition);
}

.modal-close:hover {
  background-color: var(--bg-light);
  color: var(--text-dark);
}

.modal-body {
  padding: 25px;
}

.modal-form {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.form-label {
  font-weight: 600;
  color: var(--text-dark);
  font-size: 0.9rem;
}

.form-label.required::after {
  content: ' *';
  color: #e74c3c;
}

.form-input,
.form-textarea,
.form-select {
  padding: 12px 15px;
  border: 2px solid var(--border-color);
  border-radius: var(--border-radius);
  font-size: 16px;
  transition: var(--transition);
  font-family: inherit;
}

.form-input:focus,
.form-textarea:focus,
.form-select:focus {
  outline: none;
  border-color: var(--primary-color);
  box-shadow: 0 0 0 3px rgba(255, 102, 0, 0.1);
}

.form-textarea {
  resize: vertical;
  min-height: 100px;
}

.form-input.error,
.form-textarea.error,
.form-select.error {
  border-color: #e74c3c;
  background-color: #fdf2f2;
}

.error-message {
  color: #e74c3c;
  font-size: 0.85rem;
  margin-top: 5px;
}

.form-checkbox-group {
  display: flex;
  align-items: flex-start;
  gap: 10px;
}

.form-checkbox {
  margin-top: 3px;
}

.checkbox-label {
  font-size: 0.85rem;
  color: var(--text-light);
  line-height: 1.4;
}

.modal-submit {
  background-color: var(--primary-color);
  color: var(--text-white);
  border: none;
  padding: 14px 25px;
  border-radius: var(--border-radius);
  font-size: 16px;
  font-weight: 600;
  cursor: pointer;
  transition: var(--transition);
  margin-top: 10px;
}

.modal-submit:hover {
  background-color: var(--primary-hover);
  transform: translateY(-2px);
  box-shadow: var(--shadow-hover);
}

.modal-submit:disabled {
  background-color: var(--text-light);
  cursor: not-allowed;
  transform: none;
}

/* Button groups */
.buttons-group {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
  gap: 15px;
}

@media (max-width: 480px) {
  .buttons-group {
    flex-direction: column;
    gap: 12px;
  }
  
  .buttons-group .btn {
    width: 100%;
    max-width: 280px;
  }
}

/* Utilities */
.text-center { text-align: center; }
.text-left { text-align: left; }
.text-right { text-align: right; }

.mb-0 { margin-bottom: 0; }
.mb-1 { margin-bottom: 0.5rem; }
.mb-2 { margin-bottom: 1rem; }
.mb-3 { margin-bottom: 1.5rem; }
.mb-4 { margin-bottom: 2rem; }

.mt-0 { margin-top: 0; }
.mt-1 { margin-top: 0.5rem; }
.mt-2 { margin-top: 1rem; }
.mt-3 { margin-top: 1.5rem; }
.mt-4 { margin-top: 2rem; }

.d-none { display: none; }
.d-block { display: block; }
.d-flex { display: flex; }
.d-grid { display: grid; }

.justify-center { justify-content: center; }
.align-center { align-items: center; }
.gap-1 { gap: 0.5rem; }
.gap-2 { gap: 1rem; }
.gap-3 { gap: 1.5rem; }

/* Modal responsive */
@media (max-width: 768px) {
  .modal {
    width: 95%;
    margin: 10px;
  }
  
  .modal-header {
    padding: 15px 20px 10px;
  }
  
  .modal-body {
    padding: 20px;
  }
  
  .modal-title {
    font-size: 1.1rem;
  }
  
  .form-input,
  .form-textarea,
  .form-select {
    padding: 10px 12px;
  }
}

/* Responsive design */
@media (max-width: 768px) {
  h1 { font-size: 2rem; }
  h2 { font-size: 1.5rem; }
  h3 { font-size: 1.25rem; }
  
  .container {
    padding: 0 15px;
  }
  
  .btn {
    padding: 10px 20px;
    font-size: 14px;
  }
}

@media (max-width: 480px) {
  h1 { font-size: 1.75rem; }
  h2 { font-size: 1.25rem; }
  
  .scroll-to-top {
    bottom: 20px;
    right: 20px;
    width: 45px;
    height: 45px;
    font-size: 1rem;
  }
}
