:root {
  font-family: "Space Grotesk", sans-serif;
  --ink: #141414;
  --sand-25: #ebe2d4;
  --sand-50: #f3e7d3;
  --stroke: #e2e8f0;
  --accent-yellow: #fbbd23;
  --gray-button: #808080;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  background: var(--sand-50);
  color: var(--ink);
}

.background {
  position: fixed;
  inset: 0;
  background: radial-gradient(circle at 18% 15%, rgba(255, 214, 126, 0.4), transparent 50%),
    radial-gradient(circle at 75% -5%, rgba(214, 122, 10, 0.15), transparent 45%),
    linear-gradient(180deg, #fff9ef, #f5ebdc);
  pointer-events: none;
  z-index: -1;
}

/* Nav styles in nav.css */

/* MAIN CONTAINER */
.upload-shell {
  max-width: 1100px;
  margin: 24px auto;
  padding: 0 20px;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

/* HERO SECTION - Like Profile */
.upload-hero {
  display: flex;
  align-items: flex-start;
  gap: 20px;
  background: linear-gradient(135deg, rgba(251, 189, 35, 0.08) 0%, rgba(255, 255, 255, 0.5) 100%);
  padding: 32px;
  border-radius: 20px;
  border: 1px solid rgba(251, 189, 35, 0.2);
}

.hero-avatar {
  width: 80px;
  height: 80px;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, var(--accent-yellow) 0%, #f3ba3a 100%);
  border-radius: 16px;
  font-size: 2.5rem;
  color: #fff;
  box-shadow: 0 8px 24px rgba(251, 189, 35, 0.25);
}

.hero-info {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.hero-name {
  font-size: 1.8rem;
  font-weight: 800;
  margin: 0;
  color: var(--ink);
}

.hero-subtitle {
  font-size: 0.95rem;
  color: #666;
  margin: 0;
  line-height: 1.5;
}

/* DROPZONE HERO - BIG & PROMINENT */
.dropzone-card {
  padding: 20px !important;
  background: #fff !important;
  border: 1px solid #e8e3d8 !important;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.06) !important;
  display: flex !important;
  flex-direction: column !important;
  gap: 16px !important;
}

.dropzone-area {
  border: 3px dashed var(--accent-yellow) !important;
  border-radius: 24px;
  padding: 40px 40px;
  text-align: center;
  background: linear-gradient(135deg, rgba(251, 189, 35, 0.1), rgba(251, 189, 35, 0.02));
  transition: all 0.3s ease;
  cursor: pointer;
  min-height: 240px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 12px;
}
.dropzone-area:not(.has-files):hover {
  border-color: #f3ba3a;
  background: linear-gradient(135deg, rgba(251, 189, 35, 0.15), rgba(251, 189, 35, 0.05));
  box-shadow: 0 16px 48px rgba(251, 189, 35, 0.2);
  transform: translateY(-4px);
}

.dropzone-area.has-files:hover {
  border-color: #f3ba3a;
}

.dropzone-area.drop-error {
  border-color: #e53935;
  background: rgba(229, 57, 53, 0.04);
}

/* DROPZONE 2-COLUMN LAYOUT */
.dropzone-columns {
  display: flex;
  width: 100%;
  gap: 32px;
  align-items: stretch;
  transition: all 0.3s ease;
}

.dropzone-left-col {
  flex: 1;
  width: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 12px;
}

.dropzone-right-col {
  display: none; /* oculto por defecto */
  flex: 1;
  flex-direction: column;
  justify-content: center;
  align-items: stretch;
  text-align: left;
  border-left: 1px solid rgba(251, 189, 35, 0.25);
  padding-left: 32px;
}

.dropzone-area.has-files .dropzone-right-col {
  display: flex;
}

.dropzone-area.has-files {
  cursor: default;
}


@media (max-width: 768px) {
  .dropzone-columns {
    flex-direction: column;
    gap: 24px;
  }
  .dropzone-right-col {
    border-left: none;
    border-top: 1px solid rgba(251, 189, 35, 0.25);
    padding-left: 0;
    padding-top: 24px;
  }
}

.cloud-icon-yellow {
  color: var(--accent-yellow);
  font-size: 3.5rem;
  animation: floatIcon 3s ease-in-out infinite;
  margin-bottom: 4px;
}

@keyframes floatIcon {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-12px); }
}

.dz-title {
  font-weight: 800;
  font-size: 1.3rem;
  margin: 0;
  color: var(--ink);
}

.dz-subtitle {
  font-size: 0.9rem;
  color: #666;
  margin: 0;
}

.dz-or {
  display: none;
}

.dz-btn-select {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 14px 32px;
  border: 2px solid #000;
  background: transparent;
  color: #000;
  border-radius: 8px;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.3s ease;
  font-size: 0.95rem;
}

.dz-btn-select:hover {
  background: #000;
  color: #fff;
  transform: scale(1.05);
}

.dz-btn-large {
  padding: 16px 48px;
  font-size: 1.05rem;
  margin-top: 12px;
}

/* Información compacta de tipos de archivos dentro del dropzone */
.file-info-compact {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-top: 20px;
  padding-top: 16px;
  border-top: 1px solid rgba(251, 189, 35, 0.3);
  font-size: 0.85rem;
}

.file-info-item {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  flex-wrap: wrap;
}

.file-info-label {
  font-weight: 700;
  color: var(--ink);
  min-width: 80px;
}

.file-types-tags-inline {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  align-items: center;
}

.file-type-tag-small {
  display: inline-block;
  background: linear-gradient(135deg, var(--accent-yellow) 0%, #f3ba3a 100%);
  color: #fff;
  padding: 4px 10px;
  border-radius: 16px;
  font-weight: 600;
  font-size: 0.75rem;
  box-shadow: 0 2px 4px rgba(251, 189, 35, 0.25);
}

.file-info-text {
  color: #666;
  font-weight: 500;
}

/* UPLOAD GRID - 2 columns for details (Archivos Añadidos and Opciones Avanzadas) */
.upload-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 12px;
  margin-top: 8px;
}

@media (max-width: 1024px) {
  .upload-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 768px) {
  .upload-shell {
    gap: 20px;
  }

  .upload-hero {
    flex-direction: column;
    align-items: center;
    text-align: center;
    gap: 16px;
    padding: 24px;
  }

  .dropzone-area {
    padding: 40px 24px;
    min-height: 250px;
  }

  .cloud-icon-yellow {
    font-size: 3rem;
  }

  .dz-title {
    font-size: 1.2rem;
  }

  .dz-subtitle {
    font-size: 0.9rem;
  }

  .upload-grid {
    grid-template-columns: 1fr;
  }
}

/* FILE TYPES INFORMATION CARD */
.file-types-card {
  background: linear-gradient(135deg, #fff 0%, rgba(251, 189, 35, 0.02) 100%);
  border-radius: 16px;
  padding: 20px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.06);
  border: 1px solid #e8e3d8;
}

.file-types-card .card-title {
  margin-bottom: 16px;
}

.file-types-info {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}

.file-types-section {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.file-types-section .section-title {
  display: flex;
  align-items: center;
  gap: 8px;
  font-weight: 700;
  font-size: 0.95rem;
  color: var(--ink);
  margin: 0;
}

.file-types-section .section-title i {
  font-size: 1rem;
  color: #2e7d32;
}

#restrictions-title i {
  color: #d32f2f;
}

.file-types-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.file-type-tag {
  display: inline-block;
  background: linear-gradient(135deg, var(--accent-yellow) 0%, #f3ba3a 100%);
  color: #fff;
  padding: 8px 14px;
  border-radius: 20px;
  font-weight: 600;
  font-size: 0.85rem;
  box-shadow: 0 2px 6px rgba(251, 189, 35, 0.3);
}

.restrictions-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.restrictions-list li {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  font-size: 0.9rem;
  color: #555;
}

.restrictions-list li::before {
  content: '⚠';
  color: #f57c00;
  font-weight: bold;
  flex-shrink: 0;
}

.restrictions-list li.centered-item {
  justify-content: flex-start;
  align-items: flex-start;
}

.item-content {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
  text-align: center;
}

@media (max-width: 768px) {
  .file-types-info {
    grid-template-columns: 1fr;
  }
}

/* INDIVIDUAL CARDS */
.upload-card {
  background: #fff;
  border-radius: 16px;
  padding: 20px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.06);
  border: 1px solid #e8e3d8;
  display: flex;
  flex-direction: column;
  gap: 0;
}

/* CARD SECTIONS */
.card-title {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 700;
  font-size: 0.95rem;
  color: var(--ink);
  cursor: default;
  list-style: none;
  margin: 0;
  padding: 0;
}

.card-title i {
  font-size: 1.1rem;
  color: var(--accent-yellow);
}

.card-content {
  padding-top: 16px;
  margin-top: 12px;
  border-top: 1px solid #f0f0f0;
}

.files-card .files-added-container {
  border: none;
  background: transparent;
  padding: 0;
  margin: 0;
}

.files-card .files-added-container summary {
  padding: 0;
  background: transparent;
  border: none;
  margin-bottom: 12px;
}

.action-card {
  text-align: center;
}

/* DROPZONE AREA */
.dropzone-area {
  border: 2px dashed #ddd;
  border-radius: 16px;
  padding: 32px;
  text-align: center;
  background: linear-gradient(135deg, rgba(251, 189, 35, 0.03), #fff);
  transition: all 0.3s ease;
}

.dropzone-area.drop-error {
  border-color: #e53935;
  background: rgba(229, 57, 53, 0.04);
}

.dropzone-area:hover {
  border-color: var(--accent-yellow);
  background-color: rgba(251, 189, 35, 0.05);
}

.cloud-icon-yellow {
  color: var(--accent-yellow);
  font-size: 2.2rem;
  margin-bottom: 8px;
}

.dz-title { font-weight: 700; font-size: 1rem; margin: 0; }
.dz-or { margin: 6px 0; color: #888; font-weight: 600; font-size: 0.9rem; }

.dz-btn-select {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 24px;
  border: 1px solid #000;
  border-radius: 8px;
  font-weight: 700;
  cursor: pointer;
  background: #fff;
}

/* ARCHIVOS AÑADIDOS */
.files-added-container {
  border: none;
  border-radius: 0;
  background: transparent;
  overflow: visible;
  margin: 0;
  padding: 0;
}

.files-added-container summary {
  padding: 0;
  font-weight: 700;
  font-size: 0.95rem;
  cursor: pointer;
  list-style: none;
  color: var(--ink);
  outline: none;
  margin: 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 0;
}

.files-added-container summary::before {
  content: '📁';
  font-size: 1.1rem;
}

.files-added-container summary::-webkit-details-marker { display: none; }

#file-list-content {
  padding: 16px 0;
  background: transparent;
  border-top: 1px solid #f0f0f0;
  margin-top: 12px;
  min-height: 30px;
  max-height: 200px;
  overflow-y: auto;
}
.placeholder-text { color: #a0aec0; font-size: 0.9rem; }

/* ═══════════════════════════════════════════════════════════
   ADVANCED OPTIONS ACCORDION
   ═══════════════════════════════════════════════════════════ */
.advanced-options {
  border: none;
  border-radius: 0;
  background: transparent;
  overflow: visible;
  margin: 0;
  padding: 0;
}

.advanced-options[open] {
  box-shadow: none;
}

.advanced-options-summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0;
  font-weight: 700;
  font-size: 0.95rem;
  cursor: pointer;
  list-style: none;
  color: var(--ink);
  outline: none;
  user-select: none;
  background: transparent;
  transition: all 0.2s ease;
  margin: 0;
  border: none;
}

.advanced-options-summary:hover {
  background: transparent;
}

.advanced-options-summary::-webkit-details-marker { display: none; }

.advanced-options-summary.card-title {
  margin: 0;
  padding: 0;
}

.summary-text {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 700;
  font-size: 0.95rem;
}

.summary-text i {
  font-size: 1.1rem;
  color: var(--accent-yellow);
}

.summary-icon {
  display: flex;
  align-items: center;
  font-size: 1.2rem;
  transition: transform 0.3s ease;
  color: #a0aec0;
  margin-left: auto;
}

.summary-icon.rotated { transform: rotate(180deg); }

.advanced-options[open] .summary-icon {
  transform: rotate(180deg);
}

.advanced-options-content {
  padding: 16px;
  border-top: 1px solid #e2e8f0;
  display: flex;
  flex-direction: column;
  gap: 14px;
  animation: slideDown 0.3s ease;
}

@keyframes slideDown {
  from {
    opacity: 0;
    max-height: 0;
  }
  to {
    opacity: 1;
    max-height: 500px;
  }
}

.optional-label {
  font-size: 0.75rem;
  font-weight: 500;
  color: #a0aec0;
  font-style: italic;
}

/* SEND METHOD SELECTOR (pre-upload, above COMPARTIR button) */
.send-method-label {
  font-size: 0.9rem;
  font-weight: 600;
  color: #555;
  margin: 0 0 10px 0;
  display: flex;
  align-items: center;
  gap: 6px;
}

.send-method-toggle {
  display: flex;
  gap: 8px;
}

.send-method-btn {
  flex: 1;
  padding: 10px 16px;
  border: 1.5px solid #e2e8f0;
  border-radius: 10px;
  background: #fff;
  color: #666;
  font-family: inherit;
  font-size: 0.9rem;
  font-weight: 600;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  transition: border-color 0.2s, background 0.2s, color 0.2s;
}

.send-method-btn.active {
  border-color: var(--accent-yellow);
  background: rgba(251, 189, 35, 0.1);
  color: #a67c00;
}

.send-method-btn:hover:not(.active) {
  border-color: #cbd5e0;
  background: #f9fafb;
}

/* INPUT FIELDS - Con efecto de foco amarillo (Mensaje y Límite) */
textarea, 
.custom-select,
.password-input {
  width: 100%;
  padding: 12px;
  border: 1px solid #e2e8f0;
  border-radius: 10px;
  font-family: inherit;
  font-size: 0.95rem;
  box-sizing: border-box;
  display: block;
  max-width: 100%;
  outline: none;
  background-color: #fff;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

/* EFECTO FOCO AMARILLO: Se aplica a ambos al hacer clic */
textarea:focus, 
.custom-select:focus,
.password-input:focus {
  border-color: var(--accent-yellow);
  box-shadow: 0 0 0 4px rgba(251, 189, 35, 0.2); /* Brillo amarillo de la imagen */
}

.message-textarea {
  resize: vertical;
  min-height: 48px; /* un poco más pequeño */
  max-height: 100px;
  margin-bottom: 12px; /* separar del botón enviar */
}

.input-field { width: 100%; }

.label-with-icon {
  display: block;
  font-weight: 700;
  margin-bottom: 6px;
  font-size: 0.85rem;
}

.share-label {
  font-size: 0.8rem;
  font-weight: 800;
  color: var(--accent-yellow);
  letter-spacing: 0.1em;
  margin: 0 0 20px 0;
  text-align: center;
}

/* BOTÓN SUBIR ARCHIVOS - DESTACADO */
.btn-submit-upload {
  background: linear-gradient(135deg, #fbbd23 0%, #f3ba3a 100%);
  color: #1a1a1a;
  border: none;
  padding: 20px 48px;
  border-radius: 16px;
  font-weight: 800;
  font-size: 1.1rem;
  cursor: pointer;
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 12px;
  transition: all 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
  max-height: none;
  overflow: visible;
  margin: 0;
  box-shadow: 0 12px 40px rgba(251, 189, 35, 0.4);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  width: 100%;
  min-height: 64px;
}

.btn-submit-upload i {
  font-size: 1.3rem;
}

.btn-submit-upload:hover:not(:disabled) {
  background: linear-gradient(135deg, #fcc044 0%, #fbb833 100%);
  box-shadow: 0 16px 48px rgba(251, 189, 35, 0.5);
  transform: translateY(-4px) scale(1.02);
}

.btn-submit-upload:active:not(:disabled) {
  transform: translateY(-1px) scale(0.98);
}

.btn-submit-upload:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.btn-highlight {
  animation: pulseHighlight 0.8s ease-out, slideDown 0.6s cubic-bezier(0.34, 1.56, 0.64, 1);
}

@keyframes slideDown {
  0% {
    opacity: 0;
    transform: translateY(-20px);
  }
  100% {
    opacity: 1;
    transform: translateY(0);
  }
}

/* BOTÓN IR A DESCARGAS */
.btn-go-downloads {
  background: linear-gradient(135deg, #d08a07, #a86a05);
  color: #fff;
  border: none;
  padding: 16px 32px;
  border-radius: 12px;
  font-weight: 800;
  font-size: 1rem;
  cursor: pointer;
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 10px;
  transition: all 0.3s ease;
  text-decoration: none;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  box-shadow: 0 6px 20px rgba(208, 138, 7, 0.25);
  margin-top: 12px;
}

.btn-go-downloads:hover {
  background: linear-gradient(135deg, #e09607, #b8750a);
  box-shadow: 0 8px 28px rgba(208, 138, 7, 0.35);
  transform: translateY(-2px);
}

.btn-go-downloads:active {
  transform: translateY(0);
}

/* ─── Panel de compartir ───────────────────────────────────── */
.share-panel {
  flex-direction: column;
  gap: 14px;
  width: 100%;
}

.share-panel__title {
  margin: 0 0 12px 0;
  font-size: 0.95rem;
  font-weight: 700;
  color: #5c6168;
  display: flex;
  align-items: center;
  gap: 8px;
}

.link-display-row {
  display: flex;
  gap: 10px;
  align-items: center;
}

.link-display-row .email-input {
  flex: 1;
  background: #f7f5f0;
  color: #444;
  font-size: 0.85rem;
}

.share-panel__actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

.share-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 14px 20px;
  border-radius: 12px;
  font-weight: 700;
  font-size: 0.95rem;
  cursor: pointer;
  border: none;
  transition: transform 0.2s ease, box-shadow 0.2s ease, filter 0.2s ease;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.share-btn--copy {
  background: linear-gradient(135deg, #d08a07, #a86a05);
  color: #fff;
  box-shadow: 0 6px 20px rgba(208, 138, 7, 0.25);
}

.share-btn--copy:hover {
  filter: brightness(1.08);
  transform: translateY(-2px);
  box-shadow: 0 8px 28px rgba(208, 138, 7, 0.35);
}

.share-btn--email {
  background: #fff;
  color: #1f2327;
  border: 2px solid #e5ded1;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.06);
}

.share-btn--email:hover {
  border-color: #d08a07;
  color: #d08a07;
  transform: translateY(-2px);
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.1);
}

.share-btn:active { transform: translateY(0); }

/* ─── Botón nueva transferencia ───────────────────────────── */
.nuevo-envio-wrap {
  display: flex;
  justify-content: center;
  padding: 20px 0 2px;
  margin-top: 12px;
  border-top: 2px solid rgba(208, 138, 7, 0.18);
}

.btn-nuevo-envio {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 14px;
  width: 100%;
  padding: 17px 28px;
  border-radius: 14px;
  font-family: inherit;
  cursor: pointer;
  background: linear-gradient(135deg, #f0a010 0%, #c07806 100%);
  color: #fff;
  border: none;
  box-shadow: 0 6px 24px rgba(208, 138, 7, 0.38), 0 0 0 0 rgba(240, 160, 16, 0.45);
  animation: nuevo-envio-pulse 2.4s ease-in-out infinite;
  transition: filter 0.2s ease, transform 0.2s ease;
}

.btn-nuevo-envio__icon {
  font-size: 1.7rem;
  flex-shrink: 0;
  line-height: 1;
}

.btn-nuevo-envio__content {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 3px;
}

.btn-nuevo-envio__label {
  font-size: 1rem;
  font-weight: 800;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  line-height: 1.1;
}

.btn-nuevo-envio__sub {
  font-size: 0.78rem;
  font-weight: 400;
  opacity: 0.88;
  letter-spacing: 0.01em;
  line-height: 1.2;
}

.btn-nuevo-envio:hover {
  filter: brightness(1.1);
  transform: translateY(-2px);
  box-shadow: 0 14px 36px rgba(208, 138, 7, 0.52);
  animation-play-state: paused;
}

.btn-nuevo-envio:active {
  transform: translateY(0);
  filter: brightness(0.95);
}

@keyframes nuevo-envio-pulse {
  0%, 100% {
    box-shadow: 0 6px 24px rgba(208, 138, 7, 0.38), 0 0 0 0 rgba(240, 160, 16, 0.45);
  }
  55% {
    box-shadow: 0 6px 24px rgba(208, 138, 7, 0.38), 0 0 0 12px rgba(240, 160, 16, 0);
  }
}

@media (prefers-reduced-motion: reduce) {
  .btn-nuevo-envio { animation: none; }
}

.email-form {
  animation: slideDown 0.25s ease;
  display: flex;
  flex-direction: column;
  gap: 24px; /* más espacio vertical entre campos */
}

@keyframes slideDown {
  from { opacity: 0; transform: translateY(-8px); }
  to   { opacity: 1; transform: translateY(0); }
}

.email-form__field {
  display: flex;
  flex-direction: column; /* apilar elementos para separación clara */
  gap: 10px; /* espacio entre elementos dentro del campo */
}

.sender-name-wrap {
  position: relative;
  display: flex;
  align-items: center;
}

.sender-name-wrap .sender-name-input {
  padding-right: 44px;
  background: #faf9f7;
  cursor: default;
}

.sender-name-wrap .sender-name-input.sender-name-editing {
  background: #fff;
  cursor: text;
}

.sender-name-edit-btn {
  position: absolute;
  right: 12px;
  background: transparent;
  border: none;
  cursor: pointer;
  padding: 4px;
  color: #a0906a;
  display: flex;
  align-items: center;
  transition: color 0.15s;
}

.sender-name-edit-btn:hover,
.sender-name-edit-btn.active {
  color: #d08a07;
}

.email-input {
  flex: 1;
  padding: 12px 16px;
  border: 1px solid #e5ded1;
  border-radius: 10px;
  font-family: inherit;
  font-size: 0.95rem;
  color: #1f2327;
  outline: none;
  transition: border-color 0.2s;
}

.email-input:focus { border-color: #d08a07; }

.share-btn--send {
  background: linear-gradient(135deg, #d08a07, #a86a05);
  color: #fff;
  box-shadow: 0 4px 14px rgba(208, 138, 7, 0.25);
  white-space: nowrap;
  padding: 12px 20px;
}

.share-btn--send:hover {
  filter: brightness(1.08);
  transform: translateY(-2px);
}

/* Recipients chip input */
.recipients-container {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  padding: 12px 16px;
  border: 1px solid #e5ded1;
  border-radius: 10px;
  background: #fff;
  width: 100%;
  min-height: 64px; /* aún más alto para mayor claridad */
  margin-bottom: 6px;
}

.recipients-list {
  display: flex;
  gap: 8px;
  align-items: center;
  flex-wrap: wrap;
}

.recipient-chip {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 10px;
  background: #fff7e6;
  border: 1px solid rgba(208,138,7,0.18);
  color: #5a3f00;
  border-radius: 999px;
  font-weight: 700;
  font-size: 0.88rem;
}

.recipient-chip .remove-recipient {
  background: transparent;
  border: none;
  color: inherit;
  font-weight: 900;
  font-size: 0.95rem;
  cursor: pointer;
  padding: 0 6px 0 0;
}

.recipient-input {
  border: none;
  outline: none;
  min-width: 220px;
  flex: 1 1 320px;
  font-family: inherit;
  font-size: 0.95rem;
  padding: 8px;
}

.recipient-input::placeholder { color: #b09a7a; }

/* Small helper for screen readers */
.sr-only { position: absolute !important; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0; }

.card-footer {
  display: flex;
  justify-content: center;
  gap: 15px;
  font-size: 0.8rem;
  font-weight: 700;
  border-top: 1px solid #f0f0f0;
  padding-top: 12px;
  margin-top: 0;
}

.card-footer a { color: var(--ink); text-decoration: underline; }

/* Lista de archivos añadidos */
.file-item {
  background: #fff;
  border: 1px solid #ddd;
  border-radius: 6px;
  padding: 10px 14px;
  margin-bottom: 8px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.9rem;
  box-shadow: 0 1px 3px rgb(0 0 0 / 0.1);
}

.file-info {
  display: flex;
  flex-direction: column;
  gap: 3px;
  max-width: 85%;
  overflow-wrap: break-word;
}

.file-name {
  font-weight: 600;
  color: #333;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.file-meta {
  font-size: 0.75rem;
  color: #666;
}

.file-remove-btn {
  background: #dc3545;
  border: none;
  color: white;
  font-weight: 700;
  font-size: 1rem;
  padding: 4px 10px;
  border-radius: 4px;
  cursor: pointer;
  transition: background-color 0.2s ease;
  flex-shrink: 0;
}

.file-remove-btn:hover {
  background: #bb2d3b;
}

/* Alerta personalizada */
.app-alert {
  position: fixed;
  top: 100px;
  left: 50%;
  right: auto;
  transform: translateX(-50%) translateY(-8px) scale(0.98);
  z-index: 1200;
  pointer-events: none;
  transition: transform 0.25s ease, opacity 0.25s ease;
  opacity: 0;
}
.app-alert.visible {
  pointer-events: auto;
  transform: translateX(-50%) translateY(0) scale(1);
  opacity: 1;
}
.app-alert__inner {
  display: flex;
  align-items: flex-start;
  gap: 16px;
  background: #fff;
  border-radius: 12px;
  padding: 16px 18px;
  box-shadow: 0 10px 30px rgba(0,0,0,0.12);
  border: 1px solid rgba(0,0,0,0.06);
  min-width: 360px;
  max-width: calc(100% - 40px);
  box-sizing: border-box;
  position: relative;
  overflow: hidden;
  border-left: 6px solid #c62828; /* strong red bar on the left */
}

.app-alert__content {
  flex: 1;
  display: flex;
  flex-direction: column;
}

.app-alert__badge {
  font-weight: 800;
  font-size: 1.05rem;
  margin-bottom: 6px;
  color: #c62828;
}

.app-alert__message {
  margin: 0;
  color: #c62828;
  font-size: 0.95rem;
  line-height: 1.5;
}

.app-alert__close {
  position: absolute;
  top: 8px;
  right: 10px;
  background: transparent;
  border: none;
  color: #9a9a9a;
  font-weight: 700;
  font-size: 1.05rem;
  line-height: 1;
  cursor: pointer;
}
.app-alert__close:hover { color: #666; }

/* ═══════════════════════════════════════════════════════════
   TOAST NOTIFICATIONS (Bottom-Right, Professional Stack)
   ═══════════════════════════════════════════════════════════ */
.toast-container {
  position: fixed;
  bottom: 24px;
  right: 24px;
  z-index: 9999;
  display: flex;
  flex-direction: column;
  gap: 12px;
  pointer-events: none;
  max-width: 500px;
  max-height: calc(100vh - 100px);
  overflow-y: auto;
  scrollbar-width: none;
}

.toast-container::-webkit-scrollbar {
  display: none;
}

.toast {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 14px 18px;
  border-radius: 12px;
  font-size: 0.9rem;
  font-weight: 500;
  min-width: 320px;
  max-width: 440px;
  color: #ffffff;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.15);
  pointer-events: auto;
  animation: toastIn 0.3s cubic-bezier(0.34, 1.56, 0.64, 1) forwards;
  word-wrap: break-word;
  overflow-wrap: break-word;
  line-height: 1.4;
}

.toast::before {
  content: '';
  display: block;
  width: 4px;
  height: 4px;
  border-radius: 50%;
  flex-shrink: 0;
  margin-top: 6px;
}

.toast.toast-out {
  animation: toastOut 0.25s ease forwards;
}

.toast-success { 
  background: linear-gradient(135deg, #2e7d32 0%, #1b5e20 100%);
}
.toast-success::before { background: #4caf50; }

.toast-error { 
  background: linear-gradient(135deg, #d32f2f 0%, #b71c1c 100%);
}
.toast-error::before { background: #ef5350; }

.toast-warning {
  background: linear-gradient(135deg, #f9a825 0%, #f57f17 100%);
  color: #fffdf5;
}
.toast-warning::before { background: #ffd54f; }

.toast-info { 
  background: linear-gradient(135deg, #1976d2 0%, #0d47a1 100%);
}
.toast-info::before { background: #42a5f5; }

@keyframes toastIn {
  from { 
    opacity: 0; 
    transform: translateX(400px) scale(0.95);
  }
  to { 
    opacity: 1; 
    transform: translateX(0) scale(1);
  }
}

@keyframes toastOut {
  from { 
    opacity: 1; 
    transform: translateX(0) scale(1);
  }
  to { 
    opacity: 0; 
    transform: translateX(400px) scale(0.95);
  }
}

/* PULSE ANIMATION FOR BUTTON HIGHLIGHT */
@keyframes pulseHighlight {
  0% {
    box-shadow: 0 8px 24px rgba(251, 189, 35, 0.3), 0 0 0 0 rgba(251, 189, 35, 0.7);
  }
  50% {
    box-shadow: 0 12px 36px rgba(251, 189, 35, 0.45), 0 0 0 12px rgba(251, 189, 35, 0);
  }
  100% {
    box-shadow: 0 8px 24px rgba(251, 189, 35, 0.3), 0 0 0 0 rgba(251, 189, 35, 0);
  }
}

/* ═══════════════════════════════════════════════════════════
   MODAL styles (Policy & Terms)
   ═══════════════════════════════════════════════════════════ */
body.modal-open {
  overflow: hidden;
}

.modal {
  position: fixed;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(16, 25, 40, 0.4);
  padding: 24px;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s ease;
  z-index: 10;
}

.modal.is-visible {
  opacity: 1;
  pointer-events: auto;
}

.modal__overlay {
  position: absolute;
  inset: 0;
}

.modal__content {
  position: relative;
  background: #fff;
  color: var(--ink);
  border-radius: 24px;
  box-shadow: var(--shadow-soft);
  max-width: 560px;
  width: min(560px, 100%);
  padding: 32px;
  z-index: 1;
}

.modal__content h2 {
  margin-top: 0;
}

.modal__content p + p {
  margin-top: 12px;
}

.modal__close {
  position: absolute;
  top: 16px;
  right: 16px;
  border: none;
  background: transparent;
  font-size: 1.5rem;
  color: #5c606b;
  cursor: pointer;
}



/* Rotate arrow for files-added when open, reuse summary-icon styles */
.files-added-container[open] .summary-icon {
  transform: rotate(180deg);
}