/* 
 * Website Pelayanan MTsN 6 Majalengka - Responsive Web Design System
 * Theme: Emerald Green, Forest Green, Mint & Clean White
 */

:root {
  --primary: #059669;
  --primary-dark: #047857;
  --primary-deep: #064e3b;
  --primary-light: #d1fae5;
  --accent: #10b981;
  --accent-glow: rgba(16, 185, 129, 0.25);
  
  --bg-gradient: linear-gradient(135deg, #064e3b 0%, #059669 60%, #10b981 100%);
  --bg-app: #f4fbf7;
  --card-bg: #ffffff;
  
  --text-main: #0f172a;
  --text-muted: #64748b;
  --text-white: #ffffff;
  
  --border-light: rgba(5, 150, 105, 0.15);
  --border-active: #059669;
  
  --radius-xl: 20px;
  --radius-lg: 16px;
  --radius-md: 12px;
  --radius-sm: 8px;
  
  --shadow-sm: 0 4px 6px -1px rgba(0, 0, 0, 0.04);
  --shadow-md: 0 10px 20px -3px rgba(5, 150, 105, 0.1);
  --shadow-card: 0 12px 30px -4px rgba(15, 23, 42, 0.06);
  --font-family: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  font-family: var(--font-family);
  -webkit-tap-highlight-color: transparent;
}

body {
  background: var(--bg-app);
  color: var(--text-main);
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

/* Main Container Website */
.web-container {
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
}

/* Header & Top Navbar Website */
.web-header {
  background: var(--bg-gradient);
  color: var(--text-white);
  box-shadow: 0 10px 30px rgba(6, 78, 59, 0.2);
  position: sticky;
  top: 0;
  z-index: 100;
}

.nav-bar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 16px 0;
}

.brand-wrapper {
  display: flex;
  align-items: center;
  gap: 14px;
}

.logo-circle {
  width: 52px;
  height: 52px;
  background: #ffffff;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.2);
  padding: 6px;
  flex-shrink: 0;
}

.logo-circle svg {
  width: 34px;
  height: 34px;
  fill: var(--primary-dark);
}

.brand-text h1 {
  font-size: 1.35rem;
  font-weight: 800;
  line-height: 1.2;
  letter-spacing: -0.3px;
}

.brand-text p {
  font-size: 0.8rem;
  opacity: 0.9;
  font-weight: 500;
}

/* Menu Tabs Navbar Website */
.web-nav-tabs {
  display: flex;
  gap: 8px;
}

.web-nav-link {
  color: rgba(255, 255, 255, 0.9);
  text-decoration: none;
  padding: 10px 18px;
  border-radius: 12px;
  font-size: 0.88rem;
  font-weight: 700;
  display: flex;
  align-items: center;
  gap: 8px;
  transition: all 0.25s ease;
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.15);
}

.web-nav-link:hover {
  background: rgba(255, 255, 255, 0.25);
  color: #ffffff;
  transform: translateY(-2px);
}

.web-nav-link.active {
  background: #ffffff;
  color: var(--primary-dark);
  box-shadow: 0 4px 15px rgba(0,0,0,0.15);
}

/* Hero Section Banner */
.hero-banner {
  background: linear-gradient(180deg, rgba(5, 150, 105, 0.08) 0%, rgba(244, 251, 247, 0) 100%);
  padding: 30px 0 20px 0;
}

.hero-card {
  background: var(--card-bg);
  border-radius: var(--radius-xl);
  padding: 24px 30px;
  border: 1px solid var(--border-light);
  box-shadow: var(--shadow-sm);
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 20px;
}

.hero-info h2 {
  font-size: 1.3rem;
  color: var(--primary-deep);
  font-weight: 800;
  margin-bottom: 6px;
}

.hero-info p {
  font-size: 0.9rem;
  color: var(--text-muted);
  line-height: 1.5;
}

.hero-stats {
  display: flex;
  gap: 16px;
}

.stat-box {
  background: #f0fdf4;
  border: 1px solid #a7f3d0;
  padding: 12px 20px;
  border-radius: var(--radius-lg);
  text-align: center;
  min-width: 110px;
}

.stat-box .num {
  font-size: 1.4rem;
  font-weight: 800;
  color: var(--primary-dark);
}

.stat-box .lbl {
  font-size: 0.72rem;
  font-weight: 700;
  color: #047857;
  text-transform: uppercase;
  margin-top: 2px;
}

/* Main Content Area */
.main-content {
  flex: 1;
  padding: 24px 0 60px 0;
}

/* Section Box Card */
.card-box {
  background: var(--card-bg);
  border-radius: var(--radius-xl);
  padding: 32px 30px;
  box-shadow: var(--shadow-card);
  border: 1px solid var(--border-light);
  margin-bottom: 24px;
  animation: fadeIn 0.4s ease-out;
}

.card-title {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 24px;
  font-size: 1.25rem;
  font-weight: 800;
  color: var(--primary-deep);
  border-bottom: 2px solid var(--primary-light);
  padding-bottom: 14px;
}

.card-title .icon-badge {
  width: 40px;
  height: 40px;
  background: var(--primary-light);
  color: var(--primary);
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.25rem;
}

/* Responsive Grid Form Layout */
.form-grid-layout {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px 24px;
}

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

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

.form-group label {
  font-size: 0.88rem;
  font-weight: 700;
  color: #334155;
  margin-bottom: 8px;
}

.form-group label span.req {
  color: #ef4444;
  margin-left: 2px;
}

.form-control, .form-select {
  width: 100%;
  padding: 13px 16px;
  border-radius: var(--radius-md);
  border: 1.5px solid #cbd5e1;
  font-size: 0.92rem;
  background: #ffffff;
  color: var(--text-main);
  transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
  outline: none;
}

.form-control:focus, .form-select:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 4px var(--accent-glow);
}

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

/* Radio Button Group (Pill Buttons) */
.radio-group-pills {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  margin-top: 2px;
}

.radio-pill-item {
  position: relative;
}

.radio-pill-item input[type="radio"] {
  position: absolute;
  opacity: 0;
  width: 0;
  height: 0;
}

.radio-pill-label {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 13px;
  background: #f8fafc;
  border: 1.5px solid #cbd5e1;
  border-radius: var(--radius-md);
  font-size: 0.9rem;
  font-weight: 600;
  color: #475569;
  cursor: pointer;
  transition: all 0.2s ease;
  text-align: center;
}

.radio-pill-item input[type="radio"]:checked + .radio-pill-label {
  background: var(--primary-light);
  border-color: var(--primary);
  color: var(--primary-dark);
  font-weight: 700;
  box-shadow: 0 4px 12px rgba(5, 150, 105, 0.15);
}

/* Form Action Buttons */
.form-actions {
  display: flex;
  justify-content: flex-end;
  gap: 16px;
  margin-top: 30px;
  padding-top: 20px;
  border-top: 1px solid #e2e8f0;
}

.btn {
  padding: 14px 28px;
  border-radius: var(--radius-md);
  font-size: 0.95rem;
  font-weight: 700;
  border: none;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
  text-decoration: none;
}

.btn-primary {
  background: var(--bg-gradient);
  color: var(--text-white);
  box-shadow: 0 8px 20px rgba(5, 150, 105, 0.28);
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 12px 24px rgba(5, 150, 105, 0.35);
}

.btn-secondary {
  background: #f1f5f9;
  color: #475569;
  border: 1.5px solid #cbd5e1;
}

.btn-secondary:hover {
  background: #e2e8f0;
  color: #1e293b;
}

/* Grid Layout for Survey Questions (2 Columns on Desktop) */
.survey-grid-container {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(480px, 1fr));
  gap: 16px;
}

.survey-q-card {
  background: #ffffff;
  border: 1.5px solid #e2e8f0;
  border-radius: var(--radius-lg);
  padding: 18px 20px;
  transition: all 0.2s ease;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.survey-q-card.answered {
  border-color: var(--primary);
  background: #f0fdf4;
  box-shadow: 0 4px 12px rgba(5, 150, 105, 0.08);
}

.survey-q-title {
  font-size: 0.92rem;
  font-weight: 700;
  color: #1e293b;
  margin-bottom: 14px;
  line-height: 1.4;
}

.survey-options {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}

/* Progress Bar */
.progress-bar-wrap {
  width: 100%;
  height: 10px;
  background: #e2e8f0;
  border-radius: 10px;
  overflow: hidden;
  margin-bottom: 20px;
}

.progress-bar-fill {
  height: 100%;
  width: 0%;
  background: var(--bg-gradient);
  transition: width 0.3s ease;
}

/* Modal Popup Confirmation */
.modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(6, 78, 59, 0.7);
  backdrop-filter: blur(6px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  z-index: 1000;
  opacity: 0;
  visibility: hidden;
  transition: all 0.3s ease;
}

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

.modal-card {
  background: white;
  border-radius: 28px;
  width: 100%;
  max-width: 480px;
  padding: 30px 24px;
  text-align: center;
  box-shadow: 0 25px 50px rgba(0,0,0,0.3);
  transform: scale(0.85);
  transition: all 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
}

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

.success-icon-badge {
  width: 76px;
  height: 76px;
  background: var(--primary-light);
  color: var(--primary);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 18px auto;
  font-size: 2.4rem;
  box-shadow: 0 10px 24px rgba(5, 150, 105, 0.2);
}

.ticket-box {
  background: #f8fafc;
  border: 2px dashed #cbd5e1;
  border-radius: 18px;
  padding: 16px;
  margin: 18px 0;
  text-align: center;
}

.ticket-number {
  font-size: 1.4rem;
  font-weight: 800;
  color: var(--primary-dark);
  letter-spacing: 1px;
}

/* Footer Website */
.web-footer {
  background: var(--primary-deep);
  color: rgba(255, 255, 255, 0.8);
  padding: 24px 0;
  text-align: center;
  font-size: 0.85rem;
  margin-top: auto;
  border-top: 4px solid var(--primary);
}

.web-footer p strong {
  color: #ffffff;
}

/* Animations */
@keyframes fadeIn {
  from { opacity: 0; transform: translateY(12px); }
  to { opacity: 1; transform: translateY(0); }
}

/* Responsive Media Queries (Bisa menyesuaikan semua layar) */
@media (max-width: 992px) {
  .hero-card {
    flex-direction: column;
    align-items: flex-start;
  }
  .hero-stats {
    width: 100%;
  }
  .stat-box {
    flex: 1;
  }
  .survey-grid-container {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 768px) {
  .nav-bar {
    flex-direction: column;
    gap: 16px;
    align-items: flex-start;
  }
  .web-nav-tabs {
    width: 100%;
    justify-content: space-between;
  }
  .web-nav-link {
    flex: 1;
    justify-content: center;
    padding: 8px 12px;
    font-size: 0.8rem;
  }
  .form-grid-layout {
    grid-template-columns: 1fr;
  }
  .form-actions {
    flex-direction: column-reverse;
  }
  .btn {
    width: 100%;
  }
  .card-box {
    padding: 20px 16px;
  }
}
