:root {
  --bg: #fbfaff;
  --surface: #fff;
  --surface-2: #f6f2ff;
  --text: #211c2e;
  --muted: #6e687a;
  --primary: #7c3aed;
  --primary-dark: #5b21b6;
  --primary-soft: #ede9fe;
  --accent: #f59e0b;
  --success: #16834b;
  --success-soft: #eaf8f0;
  --danger: #c0392b;
  --danger-soft: #fff1ef;
  --border: #e8e2f0;
  --shadow: 0 16px 45px rgba(54, 34, 89, .09);
  --radius: 20px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  color: var(--text);
  background: var(--bg);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  line-height: 1.55;
}

button,
input,
select,
textarea {
  font: inherit;
}

button,
a,
input,
select,
textarea {
  -webkit-tap-highlight-color: transparent;
}

a {
  color: inherit;
}

button {
  cursor: pointer;
}

[hidden] {
  display: none !important;
}

.container {
  width: min(1180px, calc(100% - 32px));
  margin-inline: auto;
}

.skip-link {
  position: fixed;
  left: 16px;
  top: -100px;
  z-index: 100;
  padding: 10px 14px;
  background: #111;
  color: #fff;
  border-radius: 8px;
}

.skip-link:focus {
  top: 16px;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 30;
  background: rgba(251, 250, 255, .88);
  border-bottom: 1px solid rgba(232, 226, 240, .85);
  backdrop-filter: blur(16px);
}

.header-inner {
  min-height: 68px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  font-weight: 850;
  letter-spacing: -.03em;
}

.brand-mark {
  display: grid;
  place-items: center;
  width: 38px;
  height: 38px;
  border-radius: 12px;
  background: var(--primary-soft);
}

.main-nav {
  display: flex;
  gap: 8px;
  align-items: center;
}

.main-nav a {
  padding: 9px 12px;
  text-decoration: none;
  border-radius: 10px;
  font-weight: 700;
  color: #5b5368;
}

.main-nav a:hover,
.main-nav a:focus-visible {
  background: var(--primary-soft);
  color: var(--primary-dark);
}

.nav-count {
  display: inline-grid;
  place-items: center;
  min-width: 20px;
  height: 20px;
  padding: 0 5px;
  margin-left: 3px;
  border-radius: 999px;
  background: var(--primary);
  color: #fff;
  font-size: .72rem;
}

.hero {
  position: relative;
  overflow: hidden;
  padding: 74px 0 92px;
  background: linear-gradient(145deg, #f4efff 0%, #fff9f5 52%, #f7f1ff 100%);
}

.hero-content {
  position: relative;
  z-index: 1;
  max-width: 880px;
  text-align: center;
}

.hero-glow {
  position: absolute;
  width: 330px;
  height: 330px;
  border-radius: 50%;
  filter: blur(5px);
  opacity: .35;
}

.hero-glow-one {
  right: -120px;
  top: -150px;
  background: #d8b4fe;
}

.hero-glow-two {
  left: -150px;
  bottom: -200px;
  background: #fed7aa;
}

.eyebrow,
.section-kicker {
  color: var(--primary-dark);
  text-transform: uppercase;
  letter-spacing: .12em;
  font-size: .76rem;
  font-weight: 850;
}

.hero h1 {
  margin: 14px 0 16px;
  font-size: clamp(2.35rem, 6vw, 4.8rem);
  line-height: .98;
  letter-spacing: -.055em;
}

.hero p {
  max-width: 720px;
  margin: 0 auto;
  font-size: clamp(1rem, 2vw, 1.2rem);
  color: var(--muted);
}

.hero-points {
  margin-top: 26px;
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 9px;
}

.hero-points span {
  padding: 8px 12px;
  background: rgba(255, 255, 255, .78);
  border: 1px solid rgba(255, 255, 255, .8);
  border-radius: 999px;
  font-size: .88rem;
  font-weight: 750;
  box-shadow: 0 8px 20px rgba(70, 45, 90, .06);
}

.page-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 310px;
  gap: 22px;
  margin-top: -42px;
  position: relative;
  z-index: 2;
}

.panel,
.results-section,
.favorites-section {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}

.form-panel {
  padding: clamp(20px, 4vw, 36px);
}

.section-heading {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 20px;
  margin-bottom: 25px;
}

h2,
h3 {
  letter-spacing: -.03em;
  line-height: 1.15;
}

h2 {
  margin: 5px 0 0;
  font-size: clamp(1.55rem, 3vw, 2.05rem);
}

h3 {
  margin: 0;
  font-size: 1.1rem;
}

.form-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 22px;
}

.field {
  min-width: 0;
  position: relative;
}

.field.full {
  grid-column: 1 / -1;
}

.field>label,
.field>legend {
  display: block;
  margin-bottom: 8px;
  font-weight: 800;
}

.field small {
  display: block;
  margin-top: 6px;
  color: var(--muted);
  font-size: .8rem;
}

select,
textarea,
input[type="text"] {
  width: 100%;
  border: 1px solid #dcd4e8;
  background: #fff;
  color: var(--text);
  border-radius: 12px;
  padding: 12px 13px;
  outline: none;
}

select {
  min-height: 48px;
}

textarea {
  resize: vertical;
  min-height: 132px;
}

select:focus,
textarea:focus,
input[type="text"]:focus,
input[type="range"]:focus-visible {
  border-color: var(--primary);
  box-shadow: 0 0 0 4px rgba(124, 58, 237, .12);
}

.conditional {
  display: none;
  margin-top: 9px;
}

.conditional.visible {
  display: block;
}

.category-field {
  border: 0;
  padding: 0;
  margin: 0;
}

.chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.chip input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.chip span {
  display: block;
  padding: 9px 12px;
  border: 1px solid var(--border);
  background: #fff;
  border-radius: 999px;
  font-size: .88rem;
  font-weight: 700;
  cursor: pointer;
  transition: .16s ease;
}

.chip input:checked+span {
  background: var(--primary-soft);
  border-color: #c4b5fd;
  color: var(--primary-dark);
  box-shadow: 0 4px 10px rgba(124, 58, 237, .08);
}

.chip input:focus-visible+span {
  outline: 3px solid rgba(124, 58, 237, .25);
  outline-offset: 2px;
}

.category-other {
  margin-top: 10px;
}

.budget-display {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 1.08rem;
  margin-bottom: 12px;
}

.range-wrap {
  position: relative;
  height: 32px;
  display: grid;
  align-items: center;
}

.range-track {
  position: absolute;
  left: 0;
  right: 0;
  height: 6px;
  border-radius: 999px;
  background: #e9e3f2;
  pointer-events: none;
}

.range-track span {
  position: absolute;
  height: 100%;
  border-radius: inherit;
  background: var(--primary);
}

input[type="range"] {
  position: absolute;
  inset: 0;
  width: 100%;
  margin: 0;
  appearance: none;
  background: transparent;
  pointer-events: none;
}

input[type="range"]::-webkit-slider-thumb {
  appearance: none;
  width: 23px;
  height: 23px;
  border: 3px solid #fff;
  border-radius: 50%;
  background: var(--primary);
  box-shadow: 0 3px 10px rgba(52, 34, 89, .2);
  pointer-events: auto;
}

input[type="range"]::-moz-range-thumb {
  width: 18px;
  height: 18px;
  border: 3px solid #fff;
  border-radius: 50%;
  background: var(--primary);
  box-shadow: 0 3px 10px rgba(52, 34, 89, .2);
  pointer-events: auto;
}

.range-hints {
  display: flex;
  justify-content: space-between;
  color: var(--muted);
  font-size: .75rem;
}

.char-counter {
  text-align: right;
  color: var(--muted);
  font-size: .75rem;
  margin-top: 4px;
}

.privacy-note {
  display: flex;
  gap: 9px;
  margin: 24px 0 16px;
  padding: 12px 14px;
  border-radius: 12px;
  background: #faf8fd;
  color: var(--muted);
  font-size: .8rem;
}

.form-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.btn {
  border: 1px solid transparent;
  min-height: 44px;
  padding: 10px 15px;
  border-radius: 12px;
  font-weight: 800;
  transition: transform .15s ease, box-shadow .15s ease, background .15s ease;
}

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

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

.btn:focus-visible,
.filter-action:focus-visible,
.icon-button:focus-visible {
  outline: 3px solid rgba(124, 58, 237, .3);
  outline-offset: 2px;
}

.btn-primary {
  color: #fff;
  background: var(--primary);
  box-shadow: 0 9px 22px rgba(124, 58, 237, .22);
}

.btn-primary:hover {
  background: var(--primary-dark);
}

.btn-large {
  padding-inline: 20px;
  min-height: 50px;
}

.btn-ghost {
  background: #fff;
  border-color: var(--border);
  color: #544c60;
}

.btn-small {
  min-height: 38px;
  padding: 7px 11px;
  font-size: .86rem;
  /*background: #fff;*/
  border-color: var(--border);
}

.btn-surprise {
  background: #fff7ed;
  color: #9a4c00;
  border-color: #fed7aa;
}

.sidebar {
  display: grid;
  align-content: start;
  gap: 16px;
}

.status-card,
.tip-card {
  padding: 20px;
}

.status-top {
  display: flex;
  align-items: center;
  gap: 9px;
}

.status-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: #a3a3a3;
  box-shadow: 0 0 0 5px #eee;
}

.status-dot.ok {
  background: #20a55b;
  box-shadow: 0 0 0 5px #dcfce7;
}

.status-dot.error {
  background: #d63d30;
  box-shadow: 0 0 0 5px #fee2e2;
}

.status-dot.pending {
  background: #e9a11b;
  box-shadow: 0 0 0 5px #fef3c7;
}

.status-card p,
.tip-card p {
  color: var(--muted);
  font-size: .9rem;
  margin: 9px 0 15px;
}

.tip-icon {
  font-size: 1.5rem;
}

.results-section,
.favorites-section {
  margin-top: 24px;
  padding: clamp(20px, 4vw, 30px);
}

.results-summary {
  max-width: 800px;
  margin: 8px 0 0;
  color: var(--muted);
}

.result-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  justify-content: flex-end;
}

.filters {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 9px;
  padding: 12px;
  margin-bottom: 18px;
  border: 1px solid var(--border);
  border-radius: 14px;
  background: #fcfbfe;
}

.filters label {
  display: flex;
  align-items: center;
  gap: 7px;
  color: var(--muted);
  font-size: .82rem;
  font-weight: 750;
}

.filters select {
  width: auto;
  min-height: 38px;
  padding: 7px 10px;
}

.focus-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
  margin-left: auto;
}

.filter-action {
  border: 1px solid #ddd6fe;
  color: var(--primary-dark);
  background: #f5f3ff;
  border-radius: 999px;
  padding: 7px 10px;
  font-size: .78rem;
  font-weight: 800;
}

.results-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 15px;
}

.gift-card {
  position: relative;
  display: flex;
  flex-direction: column;
  min-width: 0;
  border: 1px solid var(--border);
  border-radius: 17px;
  padding: 18px;
  background: #fff;
  box-shadow: 0 7px 20px rgba(44, 27, 66, .055);
}

.gift-number {
  color: #9b93a7;
  font-size: .72rem;
  font-weight: 850;
}

.gift-card h3 {
  margin: 5px 42px 7px 0;
}

.gift-description {
  margin: 0 0 11px;
  color: #554e60;
  font-size: .9rem;
}

.gift-why {
  padding: 10px 11px;
  border-radius: 11px;
  background: #faf8ff;
  font-size: .83rem;
  color: #4e465a;
  margin-bottom: 11px;
}

.gift-why strong {
  color: var(--primary-dark);
}

.badges {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-bottom: 13px;
}

.badge {
  padding: 5px 8px;
  border-radius: 999px;
  background: #f5f3f7;
  color: #5e5668;
  font-size: .72rem;
  font-weight: 800;
}

.price {
  font-size: 1.05rem;
  font-weight: 900;
  margin-bottom: 9px;
}

.gift-notes {
  color: var(--muted);
  font-size: .78rem;
  margin-top: 10px;
}

.gift-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
  margin-top: auto;
  padding-top: 15px;
}

.gift-actions .btn {
  flex: 1;
  min-width: 105px;
  font-size: .8rem;
}

.favorite-btn {
  position: absolute;
  right: 13px;
  top: 13px;
  width: 38px;
  height: 38px;
  display: grid;
  place-items: center;
  border: 1px solid var(--border);
  border-radius: 50%;
  background: #fff;
  font-size: 1.2rem;
  color: #766c80;
}

.favorite-btn.active {
  color: #e5484d;
  background: #fff1f2;
  border-color: #fecdd3;
}

.loading-panel {
  margin-top: 24px;
  padding: 42px 20px;
  text-align: center;
  border: 1px solid var(--border);
  border-radius: var(--radius);  
  box-shadow: var(--shadow);
  background: linear-gradient(90deg, #f4efff, #fff, #f4efff);
  background-size: 200% 100%;
  animation: shimmer 1.4s infinite;
}

.loading-icon {
  font-size: 2.4rem;
  animation: float 1.4s ease-in-out infinite;
}

.loading-panel p {
  color: var(--muted);
}

.skeleton-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
  margin-top: 25px;
}

.skeleton-grid span {
  height: 150px;
  border-radius: 15px;
  background: linear-gradient(90deg, #f3eff7, #faf8fd, #f3eff7);
  background-size: 200% 100%;
  animation: shimmer 1.4s infinite;
}

.error-panel {
  margin-top: 24px;
  display: grid;
  grid-template-columns: auto 1fr auto;
  gap: 15px;
  align-items: center;
  padding: 22px;
  border: 1px solid #fecaca;
  border-radius: var(--radius);
  background: var(--danger-soft);
}

.error-icon {
  display: grid;
  place-items: center;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: #fee2e2;
  color: var(--danger);
  font-weight: 900;
}

.error-panel h2 {
  font-size: 1.15rem;
}

.error-panel p {
  color: #74413d;
  margin: 5px 0 0;
}

.error-panel pre {
  max-width: 100%;
  overflow: auto;
  font-size: .72rem;
}

.empty-state {
  padding: 40px 20px;
  text-align: center;
  border: 1px dashed #dcd4e8;
  border-radius: 16px;
  color: var(--muted);
}

.empty-state>span {
  font-size: 2rem;
  color: #a79cad;
}

.empty-state h3 {
  margin: 7px 0 4px;
  color: var(--text);
}

.favorites-list {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 13px;
}

.favorite-item {
  border: 1px solid var(--border);
  border-radius: 15px;
  padding: 15px;
  background: #fff;
}

.favorite-item h3 {
  margin: 5px 0;
}

.favorite-meta {
  color: var(--muted);
  font-size: .78rem;
}

.favorite-actions {
  display: flex;
  gap: 7px;
  flex-wrap: wrap;
  margin-top: 12px;
}

.muted-label {
  color: var(--muted);
  font-size: .85rem;
}

.site-footer {
  margin-top: 55px;
  padding: 35px 0 55px;
  background: #201a2a;
  color: #fff;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 30px;
}

.footer-grid p {
  margin: 6px 0;
  color: #c9c2d1;
  font-size: .82rem;
}

.context-dialog {
  width: min(600px, calc(100% - 28px));
  border: 0;
  border-radius: 18px;
  padding: 0;
  box-shadow: 0 30px 80px rgba(0, 0, 0, .25);
  color: var(--text);
}

.context-dialog::backdrop {
  background: rgba(26, 18, 36, .55);
  backdrop-filter: blur(3px);
}

.dialog-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 20px 22px;
  border-bottom: 1px solid var(--border);
}

.dialog-header h2 {
  font-size: 1.3rem;
  margin: 0;
}

.icon-button {
  border: 0;
  background: transparent;
  font-size: 1.7rem;
  line-height: 1;
}

#context-content {
  padding: 20px 22px;
}

.context-row {
  display: grid;
  grid-template-columns: 140px 1fr;
  gap: 12px;
  padding: 8px 0;
  border-bottom: 1px solid #f0ebf4;
}

.context-row strong {
  font-size: .82rem;
}

.context-row span {
  color: var(--muted);
  font-size: .88rem;
  white-space: pre-wrap;
}

.dialog-actions {
  padding: 0 22px 22px;
  text-align: right;
}

@keyframes float {
  50% {
    transform: translateY(-7px) rotate(-3deg);
  }
}

@keyframes shimmer {
  to {
    background-position: -200% 0;
  }
}

@media (max-width: 1000px) {

  .results-grid,
  .favorites-list {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .page-grid {
    grid-template-columns: 1fr;
  }

  .sidebar {
    grid-template-columns: 1fr 1fr;
  }
}

@media (max-width: 720px) {
  .main-nav a:first-child {
    display: none;
  }

  .hero {
    padding: 55px 0 75px;
  }

  .page-grid {
    margin-top: -30px;
  }

  .form-grid {
    grid-template-columns: 1fr;
  }

  .field.full {
    grid-column: auto;
  }

  .results-grid,
  .favorites-list {
    grid-template-columns: 1fr;
  }

  .sidebar {
    grid-template-columns: 1fr;
  }

  .results-heading {
    flex-direction: column;
  }

  .result-actions {
    justify-content: flex-start;
  }

  .focus-actions {
    margin-left: 0;
    width: 100%;
  }

  .footer-grid {
    grid-template-columns: 1fr;
  }

  .error-panel {
    grid-template-columns: auto 1fr;
  }

  .error-panel .btn {
    grid-column: 1 / -1;
  }
}

@media (max-width: 480px) {
  .container {
    width: min(100% - 22px, 1180px);
  }

  .hero h1 {
    font-size: 2.55rem;
  }

  .header-inner {
    min-height: 60px;
  }

  .brand {
    font-size: .92rem;
  }

  .brand-mark {
    width: 34px;
    height: 34px;
  }

  .form-panel {
    padding: 17px;
  }

  .section-heading {
    flex-direction: column;
  }

  .section-heading>.btn {
    align-self: flex-start;
  }

  .form-actions .btn {
    width: 100%;
  }

  .filters {
    align-items: stretch;
  }

  .filters label {
    width: 100%;
    justify-content: space-between;
  }

  .filters select {
    flex: 1;
  }

  .gift-actions .btn {
    flex-basis: 100%;
    
  }
}

@media print {

  .site-header,
  .hero,
  .form-panel,
  .sidebar,
  .favorites-section,
  .site-footer,
  .filters,
  .result-actions,
  .favorite-btn,
  .gift-actions {
    display: none !important;
  }

  body {
    background: #fff;
  }

  .page-grid,
  .results-section {
    display: block;
    margin: 0;
    width: 100%;
    border: 0;
    box-shadow: none;
  }

  .results-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .gift-card {
    break-inside: avoid;
    box-shadow: none;
  }
}

@media (prefers-reduced-motion: reduce) {

  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    animation-duration: .001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: .001ms !important;
  }
}

.btn {
  text-decoration: none;
    text-align: center;
}

/* =========================================================
   PWA INSTALL BANNER
   ========================================================= */

   .pwa-install-banner {
    position: relative;
    width: 100%;
    padding: 12px 16px;
    background:
        linear-gradient(
            135deg,
            #6d28d9 0%,
            #c026d3 42%,
            #ec4899 68%,
            #f97316 100%
        );
    color: #ffffff;
    box-shadow:
        0 4px 18px rgba(76, 29, 149, 0.18);
    z-index: 100;
}

.pwa-install-banner[hidden] {
    display: none;
}

.pwa-install-banner__inner {
    width: min(1180px, 100%);
    margin: 0 auto;

    display: flex;
    align-items: center;
    gap: 14px;
}

.pwa-install-banner__icon {
    flex: 0 0 48px;

    width: 48px;
    height: 48px;

    display: flex;
    align-items: center;
    justify-content: center;

    background: rgba(255, 255, 255, 0.16);
    border: 1px solid rgba(255, 255, 255, 0.24);
    border-radius: 14px;

    font-size: 27px;

    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.16);
}

.pwa-install-banner__content {
    flex: 1;
    min-width: 0;
}

.pwa-install-banner__title {
    display: block;

    margin-bottom: 3px;

    font-size: 0.98rem;
    font-weight: 800;
    line-height: 1.25;
}

.pwa-install-banner__text {
    margin: 0;

    font-size: 0.84rem;
    line-height: 1.4;

    color: rgba(255, 255, 255, 0.9);
}

.pwa-install-banner__actions {
    flex: 0 0 auto;

    display: flex;
    align-items: center;
    gap: 8px;
}

.pwa-install-banner__install {
    appearance: none;
    border: 0;

    min-height: 40px;
    padding: 0 17px;

    border-radius: 999px;

    background: #ffffff;
    color: #7e22ce;

    font-family: inherit;
    font-size: 0.86rem;
    font-weight: 800;

    cursor: pointer;

    box-shadow:
        0 4px 12px rgba(0, 0, 0, 0.15);

    transition:
        transform 160ms ease,
        box-shadow 160ms ease,
        background-color 160ms ease;
}

.pwa-install-banner__install:hover {
    transform: translateY(-1px);

    box-shadow:
        0 6px 16px rgba(0, 0, 0, 0.2);
}

.pwa-install-banner__install:active {
    transform: translateY(0);
}

.pwa-install-banner__install:focus-visible {
    outline: 3px solid rgba(255, 255, 255, 0.9);
    outline-offset: 3px;
}

.pwa-install-banner__dismiss {
    appearance: none;
    border: 0;

    min-height: 40px;
    padding: 0 11px;

    background: transparent;
    color: rgba(255, 255, 255, 0.9);

    font-family: inherit;
    font-size: 0.8rem;
    font-weight: 700;

    cursor: pointer;
    border-radius: 8px;

    transition:
        background-color 160ms ease,
        color 160ms ease;
}

.pwa-install-banner__dismiss:hover {
    background: rgba(255, 255, 255, 0.12);
    color: #ffffff;
}

.pwa-install-banner__dismiss:focus-visible {
    outline: 2px solid #ffffff;
    outline-offset: 2px;
}


/* =========================================================
   AYUDA DE INSTALACIÓN PARA iOS
   ========================================================= */

.pwa-ios-help {
    position: fixed;
    inset: 0;

    display: flex;
    align-items: flex-end;
    justify-content: center;

    padding: 16px;

    background: rgba(15, 23, 42, 0.52);

    z-index: 1000;
}

.pwa-ios-help[hidden] {
    display: none;
}

.pwa-ios-help__card {
    position: relative;

    width: min(460px, 100%);

    padding: 28px 24px 24px;

    background: #ffffff;
    color: #1f2937;

    border-radius: 24px;

    box-shadow:
        0 20px 60px rgba(15, 23, 42, 0.28);

    animation: pwa-install-card-in 220ms ease-out;
}

.pwa-ios-help__icon {
    width: 58px;
    height: 58px;

    display: flex;
    align-items: center;
    justify-content: center;

    margin-bottom: 14px;

    border-radius: 17px;

    background:
        linear-gradient(
            135deg,
            #7c3aed,
            #ec4899,
            #f97316
        );

    font-size: 31px;

    box-shadow:
        0 8px 22px rgba(124, 58, 237, 0.22);
}

.pwa-ios-help__card h2 {
    margin: 0 38px 10px 0;

    font-size: 1.25rem;
    line-height: 1.25;
}

.pwa-ios-help__card p {
    margin: 0 0 12px;

    color: #4b5563;
    line-height: 1.55;
}

.pwa-ios-help__card ol {
    margin: 0 0 20px;
    padding-left: 22px;

    color: #374151;
    line-height: 1.65;
}

.pwa-ios-help__card li + li {
    margin-top: 5px;
}

.pwa-ios-help__close {
    position: absolute;
    top: 14px;
    right: 14px;

    width: 36px;
    height: 36px;

    display: flex;
    align-items: center;
    justify-content: center;

    border: 0;
    border-radius: 50%;

    background: #f3f4f6;
    color: #4b5563;

    font-family: inherit;
    font-size: 1.5rem;
    line-height: 1;

    cursor: pointer;
}

.pwa-ios-help__close:hover {
    background: #e5e7eb;
}

.pwa-ios-help__close:focus-visible {
    outline: 2px solid #7c3aed;
    outline-offset: 2px;
}

.pwa-ios-help__button {
    width: 100%;
    min-height: 46px;

    border: 0;
    border-radius: 12px;

    background:
        linear-gradient(
            135deg,
            #7c3aed,
            #ec4899
        );

    color: #ffffff;

    font-family: inherit;
    font-size: 0.92rem;
    font-weight: 800;

    cursor: pointer;
}

.pwa-ios-help__button:hover {
    filter: brightness(1.05);
}

.pwa-ios-help__button:focus-visible {
    outline: 3px solid rgba(124, 58, 237, 0.3);
    outline-offset: 3px;
}


/* =========================================================
   ANIMACIÓN
   ========================================================= */

@keyframes pwa-install-card-in {
    from {
        opacity: 0;
        transform: translateY(18px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}


/* =========================================================
   RESPONSIVE
   ========================================================= */

@media (max-width: 700px) {

    .pwa-install-banner {
        padding: 11px 13px;
    }

    .pwa-install-banner__inner {
        align-items: flex-start;
        gap: 10px;
    }

    .pwa-install-banner__icon {
        flex-basis: 42px;
        width: 42px;
        height: 42px;

        border-radius: 12px;
        font-size: 23px;
    }

    .pwa-install-banner__title {
        font-size: 0.9rem;
    }

    .pwa-install-banner__text {
        font-size: 0.77rem;
    }

    .pwa-install-banner__actions {
        flex-direction: column;
        align-items: stretch;
        gap: 3px;
    }

    .pwa-install-banner__install {
        min-height: 37px;
        padding: 0 13px;
        font-size: 0.8rem;
    }

    .pwa-install-banner__dismiss {
        min-height: 28px;
        font-size: 0.72rem;
    }
}

@media (max-width: 430px) {

    .pwa-install-banner__text {
        display: none;
    }

    .pwa-install-banner__content {
        align-self: center;
    }

    .pwa-install-banner__actions {
        margin-left: auto;
    }
}


/* =========================================================
   REDUCED MOTION
   ========================================================= */

@media (prefers-reduced-motion: reduce) {

    .pwa-install-banner__install,
    .pwa-install-banner__dismiss {
        transition: none;
    }

    .pwa-ios-help__card {
        animation: none;
    }
}