/* ============================================================
   FORMS — Campos, inputs, divider, spinner
============================================================ */

.field {
  margin-bottom: 14px;
}

.field-label {
  display: block;
  font-size: 10px;
  font-weight: 700;
  color: var(--slate);
  letter-spacing: 0.09em;
  text-transform: uppercase;
  margin-bottom: 6px;
}

.field-input {
  width: 100%;
  background: rgba(255,255,255,0.60);
  border: 1.5px solid rgba(22,64,176,0.15);
  border-radius: 14px;
  padding: 14px 16px;
  font-family: var(--sans);
  font-size: 16px;
  font-weight: 500;
  color: var(--ink);
  outline: none;
  transition: all 0.2s ease;
  -webkit-appearance: none;
}

.field-input::placeholder {
  color: var(--silver);
  font-weight: 400;
}

.field-input:focus {
  background: white;
  border-color: var(--royal);
  box-shadow: 0 0 0 4px rgba(22,64,176,0.10), 0 2px 8px rgba(22,64,176,0.08);
}

.field-input.ok    { border-color: var(--vivid-teal); }
.field-input.error { border-color: #EF4444; background: #FFF5F5; }

.field-msg {
  font-size: 12px;
  margin-top: 5px;
  display: none;
}

.field-msg.show-error {
  display: block;
  color: #EF4444;
}

.field-msg.show-hint {
  display: block;
  color: var(--silver);
}

/* ── Input con ícono ── */
.field-input-wrap {
  position: relative;
}

.field-icon {
  position: absolute;
  left: 14px;
  top: 50%;
  transform: translateY(-50%);
  pointer-events: none;
  stroke: #A8C4C6;
  flex-shrink: 0;
}

.field-input-icon {
  padding-left: 42px !important;
}

/* ── Divider ── */
.divider {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 16px 0;
}

.divider-line {
  flex: 1;
  height: 1px;
  background: rgba(22,64,176,0.10);
}

.divider-text {
  font-size: 11px;
  color: var(--slate);
  font-weight: 500;
}

/* ── Spinner ── */
.spin {
  width: 17px;
  height: 17px;
  border: 2px solid rgba(255,255,255,0.30);
  border-top-color: white;
  border-radius: 50%;
  animation: rotate 0.65s linear infinite;
  flex-shrink: 0;
}

/* ── Campo celular con prefijo +569 ── */
.cel-input-wrap {
  display: flex;
  align-items: center;
  background: rgba(255,255,255,0.60);
  border: 1.5px solid rgba(22,64,176,0.15);
  border-radius: 14px;
  overflow: hidden;
  transition: all 0.2s ease;
}

.cel-input-wrap:focus-within {
  background: white;
  border-color: var(--royal, #3B7FC2);
  box-shadow: 0 0 0 4px rgba(22,64,176,0.09), 0 2px 8px rgba(22,64,176,0.08);
}

.cel-input-wrap.error {
  border-color: var(--danger, #EF4444);
  background: #FFF5F5;
}

.cel-prefix {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 14px 12px 14px 16px;
  flex-shrink: 0;
  background: rgba(45,204,211,0.07);
}

.cel-flag {
  font-size: 16px;
  line-height: 1;
}

.cel-code {
  font-family: var(--sans);
  font-size: 15px;
  font-weight: 600;
  color: #005479;
  letter-spacing: 0.02em;
  white-space: nowrap;
}

.cel-divider {
  width: 1px;
  height: 24px;
  background: rgba(45,204,211,0.30);
  flex-shrink: 0;
}

.cel-input {
  border: none !important;
  border-radius: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
  padding: 14px 16px !important;
  flex: 1;
  min-width: 0;
  font-size: 18px !important;
  font-weight: 500;
  letter-spacing: 0.08em;
  color: #005479;
}

.cel-input:focus {
  outline: none;
  box-shadow: none !important;
}

.cel-input::placeholder {
  color: var(--silver, #A8C4C6);
  font-weight: 400;
  letter-spacing: 0;
  font-size: 14px;
}

/* Contador de dígitos */
.cel-counter {
  padding-right: 14px;
  font-size: 11px;
  font-weight: 600;
  color: var(--silver, #A8C4C6);
  flex-shrink: 0;
  transition: color 0.2s;
}

.cel-counter.complete { color: #2DCCD3; }
