:root {
  --agdc-primary: #f98a50;
  --agdc-primary-dark: #f16e2c;
  --agdc-primary-soft: #fff1e9;
  --agdc-white: #fff;
  --agdc-text: #2f2f2f;
  --agdc-muted: #777;
  --agdc-border: #f3d2c2;
}

.agdc-register,
.agdc-login,
.agdc-profile {
  max-width: 1080px;
  margin: 22px auto;
  padding: 24px;
  border-radius: 20px;
  background: linear-gradient(165deg, #ffffff 0%, #fff8f4 100%);
  border: 1px solid var(--agdc-border);
  box-shadow: 0 12px 40px rgba(249, 138, 80, 0.14);
  color: var(--agdc-text);
}

.agdc-register h3,
.agdc-login h3,
.agdc-profile h3 {
  margin-bottom: 18px;
  font-weight: 700;
  color: #2a2a2a;
}

.agdc-register h4,
.agdc-profile h4 {
  margin: 18px 0 10px;
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--agdc-primary-dark);
}

.agdc-register hr,
.agdc-profile hr {
  border: 0;
  border-top: 1px dashed #f3cab5;
  opacity: 1;
}

.agdc-register label,
.agdc-login label,
.agdc-profile label,
.agdc-register .form-label,
.agdc-login .form-label,
.agdc-profile .form-label {
  display: block;
  margin-bottom: 8px;
  font-weight: 600;
  color: #3a3a3a;
}

.agdc-register .form-control,
.agdc-register .form-select,
.agdc-register textarea,
.agdc-login .form-control,
.agdc-login .form-select,
.agdc-login textarea,
.agdc-profile .form-control,
.agdc-profile .form-select,
.agdc-profile textarea {
  border-radius: 12px;
  border: 1px solid #ebd1c4;
  min-height: 46px;
  padding: 10px 12px;
  background: #fff;
  transition: border-color .24s ease, box-shadow .24s ease, transform .24s ease;
}

.agdc-register textarea,
.agdc-profile textarea {
  min-height: 100px;
  resize: vertical;
}

.agdc-register .form-control:focus,
.agdc-register .form-select:focus,
.agdc-register textarea:focus,
.agdc-login .form-control:focus,
.agdc-login .form-select:focus,
.agdc-login textarea:focus,
.agdc-profile .form-control:focus,
.agdc-profile .form-select:focus,
.agdc-profile textarea:focus {
  border-color: var(--agdc-primary);
  box-shadow: 0 0 0 3px rgba(249, 138, 80, .17);
  transform: translateY(-1px);
}

.agdc-register .btn,
.agdc-login .btn,
.agdc-profile .btn {
  border-radius: 12px;
  padding: 10px 18px;
  font-weight: 600;
  transition: transform .25s ease, box-shadow .25s ease, background-color .25s ease, border-color .25s ease;
}

.agdc-register .btn-primary,
.agdc-login .btn-primary,
.agdc-profile .btn-primary {
  background: var(--agdc-primary);
  border-color: var(--agdc-primary);
  color: #fff;
  box-shadow: 0 10px 20px rgba(249, 138, 80, .28);
}

.agdc-register .btn-primary:hover,
.agdc-login .btn-primary:hover,
.agdc-profile .btn-primary:hover {
  background: var(--agdc-primary-dark);
  border-color: var(--agdc-primary-dark);
  transform: translateY(-2px);
}

.agdc-register .btn-outline-secondary,
.agdc-profile .btn-outline-secondary {
  border-color: var(--agdc-primary);
  color: var(--agdc-primary-dark);
  background: #fff;
}

.agdc-register .btn-outline-secondary:hover,
.agdc-profile .btn-outline-secondary:hover {
  background: var(--agdc-primary-soft);
  color: var(--agdc-primary-dark);
  transform: translateY(-1px);
}

#agdc-submit-btn[disabled] {
  opacity: .62;
  cursor: not-allowed;
  box-shadow: none;
}

#agdc-submit-btn.btn-loading {
  position: relative;
  overflow: hidden;
}

#agdc-submit-btn.btn-loading::after {
  content: '';
  position: absolute;
  top: 0;
  left: -120%;
  width: 120%;
  height: 100%;
  background: linear-gradient(90deg, rgba(255,255,255,0), rgba(255,255,255,.35), rgba(255,255,255,0));
  animation: agdcShimmer 1.1s linear infinite;
}

@keyframes agdcShimmer {
  from { left: -120%; }
  to { left: 120%; }
}

.agdc-register .form-check {
  background: #fff;
  border: 1px solid #f3ddcf;
  border-radius: 12px;
  padding: 10px 12px;
  margin-bottom: 10px;
}

.agdc-register .form-check-input:checked {
  background-color: var(--agdc-primary);
  border-color: var(--agdc-primary);
}

.agdc-child-row {
  display: flex;
  gap: 12px;
  align-items: flex-end;
  background: #fff;
  border: 1px solid #f2dfd4;
  border-radius: 14px;
  padding: 12px;
  margin-bottom: 14px;
  transition: box-shadow .22s ease, transform .22s ease;
}

.agdc-child-row:hover {
  box-shadow: 0 8px 18px rgba(249, 138, 80, .12);
  transform: translateY(-1px);
}

#agdc-adult-block .agdc-pref-col,
#agdc-children-wrap .agdc-pref-col {
  min-width: 190px;
}

#agdc-adult-block .agdc-pref-col .form-label,
#agdc-children-wrap .agdc-pref-col .form-label {
  white-space: nowrap;
}

.agdc-register #agdc-register-form > * {
  animation: agdcFadeUp .42s ease both;
}

.agdc-register #agdc-register-form > *:nth-child(2n) {
  animation-delay: .03s;
}

@keyframes agdcFadeUp {
  from {
    opacity: 0;
    transform: translateY(8px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.agdc-email-feedback {
  font-size: .9rem;
  margin-top: 7px;
  min-height: 1.2em;
  font-weight: 500;
}

.agdc-email-feedback.is-checking {
  color: #bf641f;
}

.agdc-email-feedback.is-valid {
  color: #2f8f57;
}

.agdc-email-feedback.is-error {
  color: #c43f36;
}

#agdc-register-result,
#agdc-login-result,
#agdc-profile-result {
  min-height: 1.4em;
}

.agdc-register .alert,
.agdc-login .alert,
.agdc-profile .alert {
  border-radius: 12px;
  border: 1px solid #f5d8c7;
}

@media (max-width: 992px) {
  .agdc-register,
  .agdc-login,
  .agdc-profile {
    padding: 18px;
    border-radius: 16px;
  }
}

@media (max-width: 768px) {
  .agdc-child-row {
    flex-direction: column;
    align-items: stretch;
  }

  .agdc-register h3,
  .agdc-login h3,
  .agdc-profile h3 {
    font-size: 1.35rem;
  }

  .agdc-register .btn,
  .agdc-login .btn,
  .agdc-profile .btn {
    width: 100%;
  }

  .agdc-register .form-check {
    margin-bottom: 8px;
  }

  #agdc-adult-block .agdc-pref-col,
  #agdc-children-wrap .agdc-pref-col {
    min-width: 100%;
  }

  #agdc-adult-block .agdc-pref-col .form-label,
  #agdc-children-wrap .agdc-pref-col .form-label {
    white-space: normal;
  }
}

.agdc-login form,
.agdc-profile .card {
  border: 1px solid #f1d9cc;
  border-radius: 16px;
  box-shadow: 0 8px 20px rgba(249, 138, 80, .1);
  background: #fff;
}

.agdc-login form {
  padding: 18px;
}

.agdc-profile .nav-tabs {
  border-bottom: 1px solid #f2d7ca;
  gap: 8px;
}

.agdc-profile .nav-tabs .nav-link {
  border: 1px solid #f2d7ca;
  border-bottom: 0;
  border-top-left-radius: 12px;
  border-top-right-radius: 12px;
  color: #6a5b52;
  font-weight: 600;
  background: #fffaf7;
  transition: all .22s ease;
}

.agdc-profile .nav-tabs .nav-link:hover {
  color: var(--agdc-primary-dark);
  background: #fff2eb;
}

.agdc-profile .nav-tabs .nav-link.active {
  color: var(--agdc-primary-dark);
  background: #fff;
  border-color: #f1cdb8;
  box-shadow: 0 -2px 0 var(--agdc-primary) inset;
}

.agdc-profile .tab-pane {
  animation: agdcFadeUp .32s ease;
}

.agdc-profile .table {
  --bs-table-striped-bg: #fff6f1;
  border-color: #f3ddcf;
}

.agdc-profile .table thead th {
  background: #fff0e7;
  color: #6d4b39;
  border-bottom: 1px solid #f1d9cd;
}

.agdc-profile .table td,
.agdc-profile .table th {
  vertical-align: middle;
}

.agdc-profile .btn-success {
  background: var(--agdc-primary);
  border-color: var(--agdc-primary);
}

.agdc-profile .btn-success:hover {
  background: var(--agdc-primary-dark);
  border-color: var(--agdc-primary-dark);
}

.agdc-profile .btn-danger {
  border-radius: 10px;
}

.agdc-profile .modal-content {
  border-radius: 16px;
  border: 1px solid #f1d8cb;
  box-shadow: 0 16px 42px rgba(249, 138, 80, .25);
}

.agdc-profile .modal-header {
  border-bottom: 1px solid #f4ded1;
  background: #fff8f4;
}

.agdc-profile .modal-footer {
  border-top: 1px solid #f4ded1;
}

@media (max-width: 768px) {
  .agdc-profile .nav-tabs {
    display: grid;
    grid-template-columns: 1fr;
    gap: 6px;
    border-bottom: 0;
  }

  .agdc-profile .nav-tabs .nav-link {
    border-radius: 10px;
    border-bottom: 1px solid #f2d7ca;
  }

  .agdc-profile .d-flex.justify-content-between.align-items-center {
    flex-direction: column;
    align-items: flex-start !important;
    gap: 10px;
  }

  .agdc-login form {
    padding: 12px;
  }
}
