:root {
  --brand-navy: #003b5c;
  --brand-navy-deep: #002a45;
  --brand-teal: #009ba3;
  --brand-teal-soft: #63d4d9;
  --brand-teal-dark: #007a82;
  --ink: #1f2a37;
  --muted: #5c6773;
  --surface: #ffffff;
  --surface-soft: #f7fbfd;
  --line: #d9e4ea;
  --success: #157347;
}

body {
  margin: 0;
  font-family: "DM Sans", "Segoe UI", sans-serif;
  background:
    radial-gradient(circle at 90% 10%, rgba(99, 212, 217, 0.22), transparent 35%),
    linear-gradient(180deg, #eef6fa 0%, #f7fbfd 50%, #f2f7fa 100%);
  color: var(--ink);
}

.container {
  width: 90%;
  max-width: 960px;
  margin: 0 auto;
}

.container-wide {
  width: 95%;
  max-width: 1400px;
  margin: 0 auto;
}

.site-header {
  background: linear-gradient(118deg, var(--brand-navy-deep) 0%, var(--brand-navy) 58%, #0a4f75 100%);
  color: #fff;
  padding: 26px 0 30px;
  box-shadow: 0 14px 30px rgba(0, 33, 54, 0.2);
}

.header-brand {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 26px;
}

.brand-link {
  display: inline-flex;
  align-items: center;
}

.brand-logo {
  width: min(360px, 46vw);
  min-width: 180px;
  height: auto;
}

.brand-copy {
  text-align: right;
}

.site-header h1 {
  margin: 0;
  font-size: clamp(1.5rem, 3.2vw, 2.1rem);
  font-weight: 800;
  letter-spacing: 0.01em;
}

.site-header p {
  margin: 6px 0 0;
  font-size: 1rem;
  opacity: 0.92;
  color: #d7ebf6;
}

.header-admin-link {
  margin-top: 10px;
  display: inline-flex;
  color: #ffffff;
  text-decoration: none;
  font-weight: 700;
  border: 1px solid rgba(255, 255, 255, 0.5);
  border-radius: 999px;
  padding: 6px 12px;
  transition: background 0.2s ease, border-color 0.2s ease;
}

.header-admin-link:hover {
  background: rgba(255, 255, 255, 0.16);
  border-color: rgba(255, 255, 255, 0.85);
}

.card {
  background: linear-gradient(180deg, var(--surface) 0%, var(--surface-soft) 100%);
  margin-top: 30px;
  margin-bottom: 34px;
  padding: 24px 28px;
  border-radius: 14px;
  border: 1px solid rgba(0, 59, 92, 0.08);
  box-shadow: 0 16px 40px rgba(0, 45, 68, 0.12);
}

h2 {
  margin-top: 0;
  margin-bottom: 20px;
  font-size: 1.35rem;
  color: var(--brand-navy);
}

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

label {
  display: block;
  font-weight: 700;
  color: #27475c;
  margin-bottom: 6px;
}

input[type="text"],
input[type="password"],
input[type="tel"],
input[type="email"],
select,
input[type="file"] {
  width: 100%;
  padding: 10px 12px;
  border-radius: 8px;
  border: 1px solid var(--line);
  box-sizing: border-box;
  background: #fff;
  color: var(--ink);
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

input[type="text"]:focus,
input[type="password"]:focus,
input[type="tel"]:focus,
input[type="email"]:focus,
select:focus,
input[type="file"]:focus {
  outline: none;
  border-color: var(--brand-teal);
  box-shadow: 0 0 0 3px rgba(0, 155, 163, 0.18);
}

.btn-primary,
.btn-secondary {
  padding: 10px 18px;
  border-radius: 8px;
  border: none;
  cursor: pointer;
  font-weight: 700;
  transition: transform 0.15s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.btn-primary {
  background: linear-gradient(90deg, #007aa2 0%, var(--brand-teal) 100%);
  color: #fff;
  box-shadow: 0 8px 18px rgba(0, 113, 142, 0.22);
}

.btn-primary-with-icon {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
}

.btn-primary-with-icon .btn-confirmar-icon {
  flex-shrink: 0;
  display: block;
}

.btn-primary:hover {
  background: linear-gradient(90deg, #006f94 0%, #008f96 100%);
  transform: translateY(-1px);
}

.btn-secondary {
  background: #e8edf0;
  color: #2d4658;
}

.btn-secondary:hover {
  background: #d9e2e8;
}

.hidden {
  display: none !important;
}

/* Legacy modal used by index.html confirmation */
div.modal {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.4);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1000;
}

div.modal .modal-content {
  background: #fff;
  padding: 20px 25px;
  border-radius: 12px;
  max-width: 400px;
  width: 90%;
  border: 1px solid rgba(0, 59, 92, 0.08);
  box-shadow: 0 14px 30px rgba(0, 0, 0, 0.16);
}

div.modal .modal-actions {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
  margin-top: 15px;
}

/* Toast */
.toast {
  position: fixed;
  bottom: 20px;
  right: 20px;
  background: var(--success);
  color: #fff;
  padding: 11px 16px;
  border-radius: 8px;
  box-shadow: 0 2px 6px rgba(0,0,0,0.2);
  z-index: 1100;
}

@media (max-width: 760px) {
  .site-header {
    padding: 18px 0 22px;
  }

  .header-brand {
    flex-direction: column;
    align-items: flex-start;
    gap: 14px;
  }

  .brand-logo {
    width: min(320px, 78vw);
    min-width: 140px;
  }

  .brand-copy {
    text-align: left;
  }

  .card {
    margin-top: 20px;
    padding: 18px;
  }
}