/* Cost Area Styling */
.cost-area {
  background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
  position: relative;
  padding: 80px 0;
}

.cost-area::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  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="50" cy="50" r="1" fill="%23000" opacity="0.02"/></pattern></defs><rect width="100" height="100" fill="url(%23grain)"/></svg>');
  pointer-events: none;
}

/* Section Title */
.section-title {
  position: relative;
  z-index: 2;
  margin-bottom: 50px;
}

.section-title h2 {
  font-size: 2.5rem;
  font-weight: 700;
  color: #2c3e50;
  margin-bottom: 20px;
  position: relative;
  display: inline-block;
}

.section-title h2::after {
  content: '';
  position: absolute;
  bottom: -10px;
  left: 50%;
  transform: translateX(-50%);
  width: 80px;
  height: 4px;
  background: linear-gradient(135deg, #ff9800, #f57c00);
  border-radius: 2px;
}

.section-title p {
  font-size: 1.1rem;
  color: #666;
  line-height: 1.6;
  max-width: 600px;
  margin: 0 auto;
}

.section-title strong {
  color: #ff9800;
  font-weight: 600;
}

/* Cost Card Styling */
.cost-card {
  background: #fff;
  border-radius: 20px;
  overflow: hidden;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.2);
  backdrop-filter: blur(10px);
  margin-bottom: 40px;
  position: relative;
  z-index: 2;
  transition: all 0.3s ease;
}

.cost-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 25px 70px rgba(0, 0, 0, 0.15);
}

.cost-card-header {
  background: linear-gradient(135deg, #1e3c72 0%, #2a5298 100%);
  padding: 25px 30px;
  position: relative;
  overflow: hidden;
}

.cost-card-header::before {
  content: '';
  position: absolute;
  top: -50%;
  right: -50%;
  width: 200%;
  height: 200%;
  background: linear-gradient(45deg, transparent, rgba(255, 255, 255, 0.1), transparent);
  transform: rotate(45deg);
  transition: all 0.6s ease;
}

.cost-card:hover .cost-card-header::before {
  transform: rotate(45deg) translate(50%, 50%);
}

.cost-card-title {
  color: #fff;
  font-size: 1.3rem;
  font-weight: 600;
  margin: 0;
  position: relative;
  z-index: 2;
  display: flex;
  align-items: center;
  gap: 12px;
}

.cost-card-title i {
  font-size: 1.4rem;
  color: #ff9800;
}

.cost-card-body {
  padding: 0;
  position: relative;
}

/* Table Styling */
.cost-table {
  width: 100%;
  border-collapse: collapse;
  font-family: 'Segoe UI', Arial, sans-serif;
  margin: 0;
}

.cost-table thead th {
  background: linear-gradient(135deg, #1e3c72 0%, #2a5298 100%);
  color: #fff;
  padding: 20px 15px;
  text-align: center;
  font-weight: 600;
  font-size: 0.95rem;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  border-bottom: 3px solid #ff9800;
  position: relative;
}

.cost-table thead th.prodi-header {
  text-align: left;
  min-width: 200px;
}

.cost-table thead th i {
  margin-right: 8px;
  font-size: 1.1rem;
  color: #ff9800;
}

.cost-table thead th::after {
  content: '';
  position: absolute;
  bottom: -3px;
  left: 0;
  width: 0;
  height: 3px;
  background: #ff9800;
  transition: width 0.3s ease;
}

.cost-table thead th:hover::after {
  width: 100%;
}

.cost-table thead th small {
  display: block;
  font-size: 0.75rem;
  font-weight: 400;
  opacity: 0.9;
  margin-top: 4px;
  text-transform: none;
  letter-spacing: normal;
}

.cost-table tbody tr {
  transition: all 0.3s ease;
  border-bottom: 1px solid #f0f0f0;
}

.cost-table tbody tr:hover {
  background: linear-gradient(135deg, #f8f9fa, #e9ecef);
  transform: translateY(-2px);
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}

.cost-table tbody tr:last-child {
  border-bottom: none;
}

.cost-table tbody td {
  padding: 20px 15px;
  vertical-align: middle;
  font-size: 0.95rem;
  position: relative;
}

.cost-table tbody td.prodi-cell {
  font-weight: 600;
  color: #2c3e50;
  text-align: left;
  background: linear-gradient(135deg, #f8f9fa, #e9ecef);
  border-right: 3px solid #ff9800;
}

.cost-table tbody td:not(.prodi-cell) {
  text-align: center;
  font-weight: 500;
  color: #555;
}

/* Price styling */
.price-cell {
  font-family: 'Segoe UI', monospace;
  font-weight: 600;
  color: #2c3e50;
  position: relative;
}

.price-cell::before {
  content: '';
  position: absolute;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 0;
  height: 2px;
  background: #ff9800;
  transition: width 0.3s ease;
}

.cost-table tbody tr:hover .price-cell::before {
  width: 80%;
}

/* Semester Headers */
.semester-headers th {
  background: linear-gradient(135deg, #1e3c72 0%, #2a5298 100%);
  font-size: 0.85rem;
  padding: 15px 10px;
}

.semester-headers th small {
  font-size: 0.7rem;
}

/* Responsive Design */
@media (max-width: 1200px) {
  .cost-card-body {
    overflow-x: auto;
  }
  
  .cost-table {
    min-width: 1000px;
  }
}

@media (max-width: 768px) {
  .cost-area {
    padding: 60px 0;
  }
  
  .section-title h2 {
    font-size: 2rem;
  }
  
  .section-title p {
    font-size: 1rem;
  }
  
  .cost-card-header {
    padding: 20px 20px;
  }
  
  .cost-card-title {
    font-size: 1.1rem;
  }
  
  .cost-table thead th,
  .cost-table tbody td {
    padding: 15px 10px;
    font-size: 0.85rem;
  }
  
  .cost-table {
    min-width: 800px;
  }
}

@media (max-width: 480px) {
  .section-title h2 {
    font-size: 1.8rem;
  }
  
  .cost-card-header {
    padding: 15px 15px;
  }
  
  .cost-table thead th,
  .cost-table tbody td {
    padding: 12px 8px;
    font-size: 0.8rem;
  }
  
  .cost-table thead th small {
    font-size: 0.65rem;
  }
}

/* Animation Effects */
@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(30px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.cost-card {
  animation: fadeInUp 0.8s ease-out;
}

.cost-card:nth-child(even) {
  animation-delay: 0.2s;
}

/* Loading Animation for Table Rows */
.cost-table tbody tr {
  animation: fadeInUp 0.6s ease-out;
}

.cost-table tbody tr:nth-child(2) { animation-delay: 0.1s; }
.cost-table tbody tr:nth-child(3) { animation-delay: 0.2s; }
.cost-table tbody tr:nth-child(4) { animation-delay: 0.3s; }
.cost-table tbody tr:nth-child(5) { animation-delay: 0.4s; }
.cost-table tbody tr:nth-child(6) { animation-delay: 0.5s; }

/* Special Effects */
.cost-card-header .icon-decoration {
  position: absolute;
  top: 50%;
  right: 20px;
  transform: translateY(-50%);
  font-size: 3rem;
  color: rgba(255, 255, 255, 0.1);
  z-index: 1;
}

/* Highlight Effect for Important Information */
.important-note {
  background: linear-gradient(135deg, #fff3cd, #ffeaa7);
  border: 1px solid #ff9800;
  border-radius: 10px;
  padding: 20px;
  margin: 30px 0;
  position: relative;
  overflow: hidden;
}

.important-note::before {
  content: '\f06a';
  font-family: 'Font Awesome 5 Free';
  font-weight: 900;
  position: absolute;
  top: 20px;
  left: 20px;
  font-size: 1.5rem;
  color: #ff9800;
}

.important-note p {
  margin: 0 0 0 50px;
  color: #856404;
  font-weight: 500;
}

/* Print Styles */
@media print {
  .cost-area::before {
    display: none;
  }
  
  .cost-card {
    box-shadow: none;
    border: 1px solid #ddd;
    page-break-inside: avoid;
    margin-bottom: 20px;
  }
  
  .cost-card-header {
    background: #2c3e50 !important;
    -webkit-print-color-adjust: exact;
    print-color-adjust: exact;
  }
  
  .cost-table thead th {
    background: #1e3c72 !important;
    -webkit-print-color-adjust: exact;
    print-color-adjust: exact;
  }
}