* {
  box-sizing: border-box;
}

html {
  font-size: clamp(14px, 1vw + 12px, 16px);
}

body {
  font-family: 'Quicksand', 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
  padding: 15px;
  padding-top: max(15px, env(safe-area-inset-top));
  padding-bottom: max(15px, env(safe-area-inset-bottom));
  padding-left: max(15px, env(safe-area-inset-left));
  padding-right: max(15px, env(safe-area-inset-right));
  color: #333;
  line-height: 1.6;
  min-height: 100vh;
  background-image: url('https://i.ibb.co.com/LDfnfSSB/656194745-18136204372519641-8207755366623819830-n.jpg');
  background-size: cover;
  background-position: center;
  background-attachment: fixed;
  background-repeat: no-repeat;
}

.card {
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  padding: clamp(15px, 3vw, 30px);
  border-radius: 12px;
  box-shadow: 0 10px 30px rgba(0,0,0,0.3);
  width: 100%;
  max-width: 700px;
  margin: 0 auto;
}

h2 {
  text-align: center;
  color: #00bfa5;
  margin-top: 0;
  margin-bottom: 25px;
  text-transform: uppercase;
  letter-spacing: 1px;
  font-weight: 800;
  font-size: clamp(18px, 4vw, 24px);
}

h3 {
  border-bottom: 2px solid #00bfa5;
  padding-bottom: 5px;
  color: #2c3e50;
  font-size: clamp(15px, 3vw, 18px);
  margin-top: 30px;
}

.form-group { margin-bottom: 15px; }

label {
  display: block;
  margin-bottom: 6px;
  font-weight: 600;
  font-size: 0.9rem;
}

input, select, textarea {
  width: 100%;
  padding: 12px;
  border: 1px solid #ddd;
  border-radius: 6px;
  font-family: inherit;
  font-size: max(16px, 0.95rem);
}

textarea { min-height: 70px; resize: vertical; }

input[type="date"] {
  width: 100%;
  min-width: 100%;
  -webkit-min-logical-width: 100%;
  appearance: none;
  -webkit-appearance: none;
  background-color: #fff;
}
input[type="date"]::-webkit-date-and-time-value {
  text-align: left;
}

input:focus, select:focus, textarea:focus {
  outline: none;
  border-color: #00bfa5;
  box-shadow: 0 0 5px rgba(0,191,165,0.2);
}

input[type="tel"]::-webkit-outer-spin-button,
input[type="tel"]::-webkit-inner-spin-button {
  -webkit-appearance: none;
  margin: 0;
}

.input-locked {
  background-color: #e9ecef;
  color: #2c3e50;
  cursor: not-allowed;
  pointer-events: none;
  border-color: #ced4da;
  font-weight: bold;
}

button {
  width: 100%;
  padding: 14px;
  background: #00bfa5;
  color: white;
  border: none;
  border-radius: 6px;
  font-size: 1rem;
  font-weight: bold;
  cursor: pointer;
  margin-top: 25px;
  transition: 0.3s;
  box-shadow: 0 4px 6px rgba(0, 191, 165, 0.3);
  min-height: 48px;
}
button:hover { background: #009688; transform: translateY(-2px); }
button:disabled { background: #ccc; cursor: not-allowed; transform: none; box-shadow: none; }

#pesanStatus {
  text-align: center;
  margin-top: 15px;
  font-weight: bold;
  font-size: 0.95rem;
  padding: 10px;
  border-radius: 6px;
}
.sukses { background-color: #e8f8f5; color: #27ae60; border: 1px solid #27ae60; }
.gagal { background-color: #fdedec; color: #e74c3c; border: 1px solid #e74c3c; }
.note { font-size: 0.8rem; color: #7f8c8d; font-weight: normal; margin-left: 5px; }

@media screen and (min-width: 1025px) {
  .card { max-width: 760px; }
  .form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 15px;
  }
  .form-row .form-group { margin-bottom: 0; }
}

@media screen and (max-width: 1024px) {
  .card { max-width: 90vw; }
}

@media screen and (max-width: 768px) {
  body {
    padding: 10px;
    padding-top: max(10px, env(safe-area-inset-top));
    padding-bottom: max(10px, env(safe-area-inset-bottom));
    background-attachment: scroll;
  }
  .card {
    padding: 15px;
    border-radius: 10px;
    max-width: 100%;
  }
  button { padding: 15px; }
}

@media screen and (max-width: 380px) {
  body { padding: 8px; }
  .card { padding: 12px; border-radius: 8px; }
  h2 { letter-spacing: 0.5px; }
  input, select, textarea { padding: 10px; }
}

@media screen and (max-height: 500px) and (orientation: landscape) {
  h3 { margin-top: 18px; }
  .form-group { margin-bottom: 10px; }
  button { margin-top: 15px; }
}
