/* Reset and Base Styles */
* { 
  box-sizing: border-box; 
  margin: 0;
  padding: 0;
}

body { 
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif; 
  line-height: 1.6; 
  color: #2c3e50; 
  background-image: url('../media/WB_FUNDO.png');
  background-size: cover;
  background-position: center;
  background-attachment: fixed;
  background-repeat: no-repeat;
  min-height: 100vh;
  padding: 40px 20px;
}

/* Main Container */
.container {
  max-width: 1000px;
  margin: 0 auto;
  background: rgba(255, 255, 255, 0.95);
  border-radius: 20px;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.15);
  backdrop-filter: blur(10px);
  overflow: hidden;
}

/* Congress Header */
.congress-header {
  background: linear-gradient(135deg, rgba(0, 0, 0, 0.8) 0%, rgba(0, 0, 0, 0.6) 100%);
  padding: 60px 40px;
  text-align: center;
  color: white;
  position: relative;
}

.congress-header::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-image: url('../media/WB_FUNDO.png');
  background-size: cover;
  background-position: center;
  opacity: 0.3;
  z-index: 1;
}

.congress-header > * {
  position: relative;
  z-index: 2;
}

.congress-logos {
  margin-bottom: 30px;
}

.congress-logos img {
  height: auto;
  max-height: 100px;
  width: auto;
  margin: 0 20px;
}

.congress-text h1 {
  margin: 0;
  font-size: 3.5rem;
  font-weight: 700;
  text-shadow: 2px 2px 4px rgba(0,0,0,0.7);
  line-height: 1.1;
}

.congress-text .congress-number {
  font-size: 4rem;
  color: #FFD700;
  text-shadow: 2px 2px 4px rgba(0,0,0,0.8);
  margin-right: 10px;
}

.congress-text .congress-superscript {
  font-size: 2rem;
  vertical-align: super;
}

.congress-text .congress-title {
  font-size: 1.6rem;
  font-weight: 600;
  text-shadow: 1px 1px 2px rgba(0,0,0,0.7);
  line-height: 1.3;
  margin-top: 15px;
}

.congress-date-info {
  margin-top: 25px;
  font-size: 1.3rem;
  font-weight: 500;
  text-shadow: 1px 1px 2px rgba(0,0,0,0.7);
}

.congress-right-logo {
  margin-top: 30px;
}

.congress-right-logo img {
  height: auto;
  max-height: 120px;
  width: auto;
}

/* Content Sections */
.introduction {
  padding: 50px 40px;
  background: rgba(255, 255, 255, 0.9);
  margin: 0;
}

.introduction h2 {
  color: #2c3e50;
  margin-bottom: 25px;
  font-size: 2rem;
  text-align: center;
  font-weight: 600;
}

.introduction p {
  margin-bottom: 20px;
  line-height: 1.7;
  font-size: 1.1rem;
  color: #34495e;
  text-align: center;
  max-width: 800px;
  margin-left: auto;
  margin-right: auto;
}

/* Courses Section */
.courses-section {
  padding: 50px 40px;
  background: rgba(248, 249, 250, 0.9);
}

.courses-section h2 {
  margin: 0 0 40px 0;
  text-align: center;
  color: #2c3e50;
  font-size: 2rem;
  font-weight: 600;
}

.courses-container {
  display: flex;
  flex-direction: column;
  gap: 25px;
}

.course-tab {
  background: white;
  border-radius: 12px;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.08);
  overflow: hidden;
  transition: all 0.3s ease;
  border: none;
}

.course-tab:hover {
  transform: translateY(-3px);
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.12);
}

.course-header {
  padding: 25px 30px;
  background: white;
  cursor: pointer;
  display: flex;
  flex-direction: column;
  gap: 15px;
}

.course-header h2 {
  margin: 0;
  color: #2c3e50;
  font-size: 1.5rem;
  font-weight: 600;
  text-align: center;
  line-height: 1.3;
}

.course-quick-info {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 20px;
  flex-wrap: wrap;
}

.course-quick-info span {
  background: #f8f9fa;
  color: #6c757d;
  padding: 6px 12px;
  border-radius: 20px;
  font-size: 14px;
  font-weight: 500;
  border: 1px solid #e9ecef;
}

.course-price {
  background: #e74c3c !important;
  color: white !important;
  font-weight: bold;
  border: 2px solid #c0392b !important;
}

.expand-btn {
  background: #27ae60;
  color: white;
  border: none;
  padding: 12px 25px;
  border-radius: 25px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
  white-space: nowrap;
}

.expand-btn:hover {
  background: #229954;
  transform: translateY(-2px);
}

.course-content {
  display: none;
}

.course-content.expanded {
  display: block;
}

.course-quick {
  padding: 25px 30px;
  background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
  border-bottom: 2px solid #dee2e6;
}

.course-quick h3 {
  color: #2c3e50;
  margin: 0 0 20px 0;
  font-size: 1.3rem;
  font-weight: 600;
  text-align: center;
  padding-bottom: 10px;
  border-bottom: 2px solid #3498db;
}

.course-quick ul {
  list-style: none;
  padding: 0;
  margin: 0;
}

.course-quick li {
  background: white;
  margin: 10px 0;
  padding: 15px 20px;
  border-radius: 8px;
  border-left: 4px solid #3498db;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
  transition: all 0.3s ease;
}

.course-quick li:hover {
  transform: translateX(5px);
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.15);
}

.course-full {
  padding: 40px 30px;
  background: white;
  border-top: 3px solid #3498db;
}

.course-full h3 {
  color: #2c3e50;
  margin: 30px 0 20px 0;
  font-size: 1.4rem;
  font-weight: 600;
  padding: 15px 20px;
  background: linear-gradient(135deg, #3498db 0%, #2980b9 100%);
  color: white;
  border-radius: 8px;
  text-align: center;
  box-shadow: 0 4px 10px rgba(52, 152, 219, 0.3);
}

.course-full h3:first-child {
  margin-top: 0;
}

.course-full h4 {
  color: #2c3e50;
  margin: 25px 0 15px 0;
  font-size: 1.2rem;
  font-weight: 600;
  padding: 10px 15px;
  background: #f8f9fa;
  border-left: 4px solid #e74c3c;
  border-radius: 0 8px 8px 0;
}

.course-full p {
  margin-bottom: 20px;
  line-height: 1.7;
  font-size: 1rem;
  color: #34495e;
  padding: 15px;
  background: #f8f9fa;
  border-radius: 8px;
  border: 1px solid #e9ecef;
}

.course-full ul, .course-full ol {
  margin: 20px 0;
  padding: 0;
  list-style: none;
}

.course-full li {
  margin: 12px 0;
  padding: 15px 20px;
  background: #f8f9fa;
  border-radius: 8px;
  border-left: 4px solid #27ae60;
  line-height: 1.6;
  transition: all 0.3s ease;
  position: relative;
}

.course-full li:hover {
  background: #e8f5e8;
  transform: translateX(5px);
}

.course-full li::before {
  content: "▶";
  color: #27ae60;
  font-weight: bold;
  position: absolute;
  left: 8px;
  top: 15px;
}

.course-full ol li {
  counter-increment: item;
}

.course-full ol {
  counter-reset: item;
}

.course-full ol li::before {
  content: counter(item) ".";
  counter-increment: item;
  color: #e74c3c;
  font-weight: bold;
  position: absolute;
  left: 8px;
  top: 15px;
}

/* Registration Section */
#inscricao {
  padding: 50px 40px;
  background: rgba(255, 255, 255, 0.9);
}

#inscricao h2 {
  margin: 0 0 40px 0;
  text-align: center;
  color: #2c3e50;
  font-size: 2rem;
  font-weight: 600;
}

/* Form Styling */
fieldset {
  border: 2px solid #e1e8ed;
  border-radius: 15px;
  padding: 30px;
  margin: 30px 0;
  background: rgba(255, 255, 255, 0.8);
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.08);
}

legend {
  font-weight: 600;
  color: #2c3e50;
  padding: 0 15px;
  font-size: 1.2rem;
}

#courseList {
  list-style: none;
  margin: 0;
  padding: 0;
}

#courseList li {
  margin: 15px 0;
  padding: 20px;
  background: #f8f9fa;
  border-radius: 10px;
  border: 2px solid transparent;
  transition: all 0.3s ease;
}

#courseList li:hover {
  background: #e9ecef;
  border-color: #3498db;
  transform: translateX(5px);
}

#courseList label {
  margin: 0;
  cursor: pointer;
  display: flex;
  align-items: center;
  font-weight: 500;
  font-size: 1rem;
  color: #34495e;
}

#courseList input[type="checkbox"] {
  margin-right: 15px;
  transform: scale(1.3);
}

/* Warning Message */
#courseWarning {
  background: #fff3cd;
  border: 2px solid #ffeaa7;
  padding: 20px;
  margin: 20px 0;
  border-radius: 10px;
  box-shadow: 0 3px 10px rgba(0, 0, 0, 0.1);
}

#courseWarning strong {
  color: #856404;
  display: block;
  margin-bottom: 10px;
  font-size: 1.1rem;
}

#selectedCourses {
  margin: 10px 0;
  color: #856404;
}

#totalAmount {
  margin-top: 10px;
  font-size: 1.2rem;
  color: #856404;
  font-weight: 600;
}

/* Registration Form */
.registration-form {
  background: rgba(255, 255, 255, 0.9);
  border-radius: 15px;
  padding: 40px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
  margin: 30px 0;
}

.form-section {
  margin-bottom: 40px;
  padding-bottom: 30px;
  border-bottom: 2px solid #e9ecef;
}

.form-section:last-of-type {
  border-bottom: none;
  margin-bottom: 0;
}

.form-section h3 {
  margin: 0 0 25px;
  font-size: 1.4rem;
  color: #2c3e50;
  font-weight: 600;
}

.form-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 25px;
  margin-top: 20px;
}

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

.form-group.full-width {
  grid-column: 1 / -1;
}

.form-group label {
  font-weight: 600;
  color: #495057;
  margin-bottom: 8px;
  font-size: 1rem;
}

.form-group input,
.form-group textarea {
  padding: 15px 20px;
  border: 2px solid #e9ecef;
  border-radius: 10px;
  font-size: 1rem;
  transition: all 0.3s ease;
  background: #f8f9fa;
}

.form-group input:focus,
.form-group textarea:focus {
  outline: none;
  border-color: #3498db;
  background: white;
  box-shadow: 0 0 0 3px rgba(52, 152, 219, 0.1);
}

.form-group small {
  color: #6c757d;
  font-size: 0.9rem;
  margin-top: 5px;
}

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

/* Payment Methods */
.payment-methods {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 30px;
  margin-top: 20px;
  max-width: 600px;
  margin-left: auto;
  margin-right: auto;
}

.payment-option {
  cursor: pointer;
}

.payment-option input[type="radio"] {
  display: none;
}

.payment-card {
  padding: 25px;
  border: 2px solid #e9ecef;
  border-radius: 15px;
  text-align: center;
  transition: all 0.3s ease;
  background: #f8f9fa;
}

.payment-option input[type="radio"]:checked + .payment-card {
  border-color: #3498db;
  background: linear-gradient(135deg, #3498db 0%, #2980b9 100%);
  color: white;
  transform: translateY(-5px);
  box-shadow: 0 10px 25px rgba(52, 152, 219, 0.3);
}

.payment-icon {
  font-size: 2.5rem;
  display: block;
  margin-bottom: 10px;
}

.payment-name {
  font-weight: 600;
  font-size: 1.2rem;
  display: block;
  margin-bottom: 5px;
}

.payment-desc {
  font-size: 0.95rem;
  opacity: 0.8;
}

.mbw-field {
  margin-top: 25px;
  padding: 25px;
  background: #f8f9fa;
  border-radius: 10px;
  border: 2px solid #e9ecef;
}

/* Terms and Submit */
.terms-section {
  text-align: center;
  padding: 20px 0;
}

.terms-checkbox {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 15px;
  cursor: pointer;
  font-size: 1rem;
  color: #495057;
}

.terms-checkbox input[type="checkbox"] {
  display: none;
}

.checkmark {
  width: 25px;
  height: 25px;
  border: 2px solid #e9ecef;
  border-radius: 6px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.3s ease;
}

.terms-checkbox input[type="checkbox"]:checked + .checkmark {
  background: #3498db;
  border-color: #3498db;
}

.terms-checkbox input[type="checkbox"]:checked + .checkmark::after {
  content: "✓";
  color: white;
  font-weight: bold;
  font-size: 16px;
}

.terms-checkbox a {
  color: #3498db;
  text-decoration: none;
}

.terms-checkbox a:hover {
  text-decoration: underline;
}

.form-actions {
  text-align: center;
  margin-top: 40px;
  padding-top: 30px;
  border-top: 2px solid #e9ecef;
}

.submit-btn {
  background: linear-gradient(135deg, #3498db 0%, #2980b9 100%);
  color: white;
  border: none;
  padding: 18px 50px;
  font-size: 1.2rem;
  font-weight: 600;
  border-radius: 50px;
  cursor: pointer;
  transition: all 0.3s ease;
  box-shadow: 0 8px 25px rgba(52, 152, 219, 0.3);
  position: relative;
  overflow: hidden;
}

.submit-btn:hover {
  transform: translateY(-3px);
  box-shadow: 0 12px 35px rgba(52, 152, 219, 0.4);
}

.submit-btn:active {
  transform: translateY(-1px);
}

.submit-btn:disabled {
  opacity: 0.7;
  cursor: not-allowed;
  transform: none;
}

/* Status Message */
#status {
  padding: 15px 20px;
  border-radius: 10px;
  margin: 20px 0;
  font-weight: 500;
  text-align: center;
}

#status:not(:empty) {
  background: #d4edda;
  color: #155724;
  border: 2px solid #c3e6cb;
}

/* Messages */
.message {
  padding: 20px 25px;
  margin: 25px 0;
  border-radius: 10px;
  font-weight: 500;
  border-left: 5px solid;
  text-align: center;
}

.message.success {
  background-color: #d4edda;
  color: #155724;
  border-left-color: #28a745;
}

.message.error {
  background-color: #f8d7da;
  color: #721c24;
  border-left-color: #dc3545;
}

.message.info {
  background-color: #d1ecf1;
  color: #0c5460;
  border-left-color: #17a2b8;
}

/* Footer */
footer {
  text-align: center;
  padding: 30px;
  background: rgba(0, 0, 0, 0.8);
  color: white;
  margin-top: 50px;
}

footer p {
  margin: 0;
  font-size: 0.9rem;
  opacity: 0.8;
}

/* Responsive Design */
@media (max-width: 1024px) {
  .container {
    margin: 20px;
    border-radius: 15px;
  }
  
  .congress-header {
    padding: 40px 30px;
  }
  
  .congress-text h1 {
    font-size: 3rem;
  }
  
  .congress-text .congress-number {
    font-size: 3.5rem;
  }
  
  .congress-text .congress-title {
    font-size: 1.4rem;
  }
  
  .introduction,
  .courses-section,
  #inscricao {
    padding: 40px 30px;
  }
  
  .registration-form {
    padding: 30px;
  }
}

@media (max-width: 768px) {
  body {
    padding: 20px 10px;
  }
  
  .container {
    margin: 10px;
    border-radius: 10px;
  }
  
  .congress-header {
    padding: 30px 20px;
  }
  
  .congress-logos img {
    max-height: 80px;
    margin: 0 10px;
  }
  
  .congress-text h1 {
    font-size: 2.5rem;
  }
  
  .congress-text .congress-number {
    font-size: 3rem;
  }
  
  .congress-text .congress-title {
    font-size: 1.2rem;
  }
  
  .congress-date-info {
    font-size: 1.1rem;
  }
  
  .congress-right-logo img {
    max-height: 100px;
  }
  
  .introduction,
  .courses-section,
  #inscricao {
    padding: 30px 20px;
  }
  
  .introduction h2,
  .courses-section h2,
  #inscricao h2 {
    font-size: 1.6rem;
  }
  
  .registration-form {
    padding: 25px;
  }
  
  .form-grid {
    grid-template-columns: 1fr;
    gap: 20px;
  }
  
  .payment-methods {
    grid-template-columns: 1fr;
    gap: 20px;
    max-width: none;
  }
  
  .course-header {
    padding: 20px;
  }
  
  .course-header h2 {
    font-size: 1.3rem;
  }
  
  .course-quick-info {
    gap: 15px;
  }
  
  .expand-btn {
    width: 100%;
    margin-top: 15px;
  }
  
  .submit-btn {
    padding: 15px 40px;
    font-size: 1.1rem;
    width: 100%;
  }
  
  .terms-checkbox {
    flex-direction: column;
    text-align: center;
    gap: 10px;
  }
}

@media (max-width: 480px) {
  body {
    padding: 15px 5px;
  }
  
  .container {
    margin: 5px;
    border-radius: 8px;
  }
  
  .congress-header {
    padding: 25px 15px;
  }
  
  .congress-logos img {
    max-height: 60px;
    margin: 0 5px;
  }
  
  .congress-text h1 {
    font-size: 2rem;
  }
  
  .congress-text .congress-number {
    font-size: 2.5rem;
  }
  
  .congress-text .congress-title {
    font-size: 1rem;
  }
  
  .congress-date-info {
    font-size: 1rem;
  }
  
  .congress-right-logo img {
    max-height: 80px;
  }
  
  .introduction,
  .courses-section,
  #inscricao {
    padding: 25px 15px;
  }
  
  .introduction h2,
  .courses-section h2,
  #inscricao h2 {
    font-size: 1.4rem;
  }
  
  .registration-form {
    padding: 20px;
  }
  
  .form-section {
    margin-bottom: 30px;
    padding-bottom: 25px;
  }
  
  .form-group input,
  .form-group textarea {
    padding: 12px 15px;
    font-size: 16px; /* Prevents zoom on iOS */
  }
  
  .course-header {
    padding: 20px;
  }
  
  .course-quick {
    padding: 20px;
  }
  
  .course-full {
    padding: 25px 20px;
  }
  
  .course-full h3 {
    font-size: 1.2rem;
    padding: 12px 15px;
  }
  
  .course-full h4 {
    font-size: 1.1rem;
    padding: 8px 12px;
  }
  
  .course-full p {
    padding: 12px;
    font-size: 0.95rem;
  }
  
  .course-full li {
    padding: 12px 15px;
    margin: 10px 0;
  }
  
  .course-quick-info {
    flex-direction: column;
    gap: 10px;
  }
  
  .course-quick-info span {
    width: 100%;
    text-align: center;
  }
  
  .payment-card {
    padding: 20px;
  }
  
  .payment-icon {
    font-size: 2rem;
  }
  
  .submit-btn {
    padding: 12px 30px;
    font-size: 1rem;
  }
  
  fieldset {
    padding: 20px;
  }
  
  #courseList li {
    padding: 15px;
  }
}