/* Reset e base */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
  background: linear-gradient(135deg, #f5f3ff 0%, #ede9fe 100%);
  color: #1f2937;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  min-height: 100vh;
}

.hidden {
  display: none !important;
}

/* Loading state */
.loading {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-height: 100vh;
  padding: 20px;
}

.spinner {
  width: 50px;
  height: 50px;
  border: 4px solid #e9d5ff;
  border-top: 4px solid #7c3aed;
  border-radius: 50%;
  animation: spin 1s linear infinite;
  box-shadow: 0 4px 16px rgba(124, 58, 237, 0.15);
}

@keyframes spin {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

.loading p {
  margin-top: 16px;
  color: #7c3aed;
  font-size: 16px;
  font-weight: 600;
}

/* Error state */
.error {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-height: 100vh;
  padding: 20px;
  text-align: center;
}

.error-icon {
  font-size: 64px;
  margin-bottom: 16px;
}

.error h2 {
  font-size: 24px;
  margin-bottom: 8px;
  color: #e11d48;
}

.error p {
  color: #666;
  font-size: 16px;
}

/* Content */
.content {
  max-width: 600px;
  margin: 0 auto;
  padding: 20px;
  min-height: 100vh;
}

/* Banner SMARRITO */
.lost-banner {
  background: linear-gradient(135deg, #dc2626, #ef4444);
  color: white;
  padding: 24px;
  border-radius: 16px;
  box-shadow: 0 8px 24px rgba(220, 38, 38, 0.3);
  margin-bottom: 20px;
  animation: slideInDown 0.5s ease-out;
}

@keyframes slideInDown {
  from {
    opacity: 0;
    transform: translateY(-20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.lost-banner-content {
  display: flex;
  align-items: center;
  gap: 16px;
  margin-bottom: 16px;
}

.lost-icon {
  font-size: 48px;
  animation: pulse 2s infinite;
}

@keyframes pulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.7; }
}

.lost-banner h2 {
  font-size: 28px;
  font-weight: bold;
  margin: 0;
  text-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

.lost-banner p {
  margin: 4px 0 0 0;
  font-size: 14px;
  opacity: 0.95;
}

.view-post-btn {
  width: 100%;
  padding: 14px;
  background-color: white;
  color: #dc2626;
  border: none;
  border-radius: 8px;
  font-size: 16px;
  font-weight: bold;
  cursor: pointer;
  transition: all 0.2s;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.view-post-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
}

.view-post-btn:active {
  transform: translateY(0);
}

/* Hero photo */
.hero-photo {
  width: 100%;
  height: 300px;
  overflow: hidden;
  background-color: #e5e7eb;
  border-radius: 20px;
  box-shadow: 0 8px 32px rgba(147, 51, 234, 0.15);
  margin-bottom: 24px;
  animation: fadeIn 0.6s ease-out;
}

@keyframes fadeIn {
  from {
    opacity: 0;
    transform: scale(0.95);
  }
  to {
    opacity: 1;
    transform: scale(1);
  }
}

.hero-photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* Pet info */
.pet-info {
  background: white;
  border-radius: 20px;
  padding: 28px;
  box-shadow: 0 4px 24px rgba(147, 51, 234, 0.08);
  animation: fadeIn 0.7s ease-out 0.1s both;
}

.pet-name {
  font-size: 32px;
  font-weight: 800;
  color: #7c3aed;
  margin-bottom: 8px;
  letter-spacing: -0.5px;
}

.pet-type-info {
  font-size: 18px;
  color: #6b7280;
  margin-bottom: 28px;
  font-weight: 500;
}

/* Sections */
.section {
  margin-bottom: 24px;
  padding-bottom: 24px;
  border-bottom: 2px solid #f3f4f6;
}

.section:last-of-type {
  border-bottom: none;
  margin-bottom: 0;
  padding-bottom: 0;
}

.section h3 {
  font-size: 18px;
  font-weight: 700;
  margin-bottom: 12px;
  color: #374151;
  display: flex;
  align-items: center;
  gap: 8px;
}

.section .icon {
  font-size: 22px;
}

.section p {
  color: #6b7280;
  font-size: 15px;
  line-height: 1.7;
}

/* Contact section */
.contact-section {
  background: linear-gradient(135deg, #faf5ff 0%, #f3e8ff 100%);
  padding: 24px;
  border-radius: 16px;
  border: 2px solid #e9d5ff;
  box-shadow: 0 4px 16px rgba(147, 51, 234, 0.1);
}

.phone-link {
  display: inline-block;
  font-size: 24px;
  font-weight: 700;
  color: white;
  text-decoration: none;
  margin-bottom: 12px;
  padding: 16px 28px;
  background: linear-gradient(135deg, #7c3aed, #9333ea);
  border-radius: 12px;
  border: none;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  box-shadow: 0 4px 16px rgba(147, 51, 234, 0.25);
}

.phone-link:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(147, 51, 234, 0.35);
}

.phone-link:active {
  transform: translateY(0);
}

.contact-info {
  font-size: 14px;
  color: #6b7280;
  margin-top: 8px;
  line-height: 1.5;
}

/* QR Info */
.qr-info {
  border: none;
}

.info-box {
  display: flex;
  gap: 12px;
  padding: 18px;
  background: linear-gradient(135deg, #eff6ff 0%, #dbeafe 100%);
  border-radius: 12px;
  border-left: 4px solid #7c3aed;
  box-shadow: 0 2px 8px rgba(124, 58, 237, 0.08);
}

.info-box .icon {
  font-size: 20px;
  flex-shrink: 0;
}

.info-box p {
  font-size: 14px;
  color: #4b5563;
  margin: 0;
  line-height: 1.6;
}

/* App download */
.app-download {
  text-align: center;
  padding: 36px 24px;
  background: linear-gradient(135deg, #7c3aed, #9333ea);
  margin: 32px -28px -28px -28px;
  border-radius: 0 0 20px 20px;
  color: white;
  box-shadow: 0 -4px 24px rgba(124, 58, 237, 0.15);
}

.app-download h3 {
  font-size: 26px;
  font-weight: 800;
  margin-bottom: 8px;
  text-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.app-download p {
  font-size: 15px;
  opacity: 0.95;
  margin-bottom: 24px;
  font-weight: 500;
}

.download-buttons {
  display: flex;
  gap: 12px;
  justify-content: center;
  flex-wrap: wrap;
}

.download-btn {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 14px 28px;
  background-color: white;
  color: #7c3aed;
  text-decoration: none;
  border-radius: 12px;
  font-weight: 700;
  font-size: 16px;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.15);
}

.download-btn:hover {
  transform: translateY(-3px);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.25);
  background-color: #fafafa;
}

.download-btn:active {
  transform: translateY(-1px);
}

.download-btn span {
  font-size: 22px;
}

/* Footer */
.footer {
  text-align: center;
  padding: 32px 20px 24px 20px;
  margin-top: 32px;
}

.footer p {
  font-size: 14px;
  color: #6b7280;
  margin-bottom: 6px;
  font-weight: 500;
}

.footer strong {
  color: #7c3aed;
  font-weight: 700;
}

.footer-tagline {
  font-size: 13px;
  color: #9ca3af;
  font-style: italic;
}

/* Responsive */
@media (max-width: 600px) {
  .content {
    padding: 12px;
  }

  .hero-photo {
    height: 250px;
    border-radius: 16px;
  }

  .pet-info {
    padding: 24px 20px;
  }

  .pet-name {
    font-size: 28px;
  }

  .pet-type-info {
    font-size: 16px;
  }

  .section h3 {
    font-size: 17px;
  }

  .phone-link {
    font-size: 20px;
    padding: 14px 24px;
  }

  .lost-banner {
    padding: 20px;
    border-radius: 12px;
  }

  .lost-banner h2 {
    font-size: 24px;
  }

  .lost-icon {
    font-size: 40px;
  }

  .app-download {
    margin: 28px -20px -24px -20px;
    padding: 32px 20px;
  }

  .app-download h3 {
    font-size: 22px;
  }

  .download-btn {
    padding: 12px 24px;
    font-size: 15px;
  }
}
