:root {
  --ink: #1a221e;
  --muted: #4a5a52;
  --teal: #2f8f7f;
  --teal-soft: #7ebfb2;
  --foam: #e8f3ef;
  --mist: #f3f7f4;
  --sand: #eef2ea;
  --glow: rgba(47, 143, 127, 0.28);
  --radius: 999px;
  --font-display: "Bricolage Grotesque", system-ui, sans-serif;
  --font-body: "Figtree", system-ui, sans-serif;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  min-height: 100%;
}

body {
  color: var(--ink);
  font-family: var(--font-body);
  background:
    radial-gradient(1200px 700px at 12% -10%, #d7ece6 0%, transparent 55%),
    radial-gradient(900px 600px at 92% 8%, #cfe4dd 0%, transparent 50%),
    linear-gradient(165deg, var(--mist) 0%, var(--sand) 48%, #d9ebe4 100%);
  overflow-x: hidden;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

[hidden] {
  display: none !important;
}

.atmosphere {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  overflow: hidden;
}

.blob {
  position: absolute;
  border-radius: 50%;
  filter: blur(40px);
  opacity: 0.55;
  animation: drift 18s ease-in-out infinite alternate;
}

.blob-a {
  width: min(52vw, 520px);
  height: min(52vw, 520px);
  background: var(--glow);
  top: -8%;
  right: -6%;
}

.blob-b {
  width: min(42vw, 420px);
  height: min(42vw, 420px);
  background: rgba(126, 191, 178, 0.35);
  bottom: -12%;
  left: -8%;
  animation-duration: 22s;
  animation-direction: alternate-reverse;
}

.waves {
  position: absolute;
  inset: auto 0 18% 0;
  height: 180px;
  background:
    radial-gradient(ellipse 70% 90% at 50% 100%, transparent 42%, rgba(47, 143, 127, 0.07) 43%, transparent 46%),
    radial-gradient(ellipse 85% 100% at 50% 100%, transparent 48%, rgba(47, 143, 127, 0.06) 49%, transparent 52%),
    radial-gradient(ellipse 100% 110% at 50% 100%, transparent 54%, rgba(47, 143, 127, 0.05) 55%, transparent 58%);
  opacity: 0.9;
  animation: pulse-waves 4.5s ease-in-out infinite;
}

.hero {
  position: relative;
  z-index: 1;
  min-height: 100dvh;
  display: flex;
  justify-content: center;
  align-items: center;
  padding: clamp(1.5rem, 4vw, 3rem);
  width: 100%;
  animation: rise 0.9s ease-out both;
}

.hero-inner {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 1.15rem;
  width: max-content;
  max-width: 100%;
  transform: translateY(-30px);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 0.95rem;
  text-decoration: none;
  color: inherit;
  margin-bottom: 0.35rem;
}

.brand-mark {
  width: clamp(4.25rem, 12vw, 5.5rem);
  height: auto;
  border-radius: 22%;
  box-shadow: 0 18px 40px rgba(26, 34, 30, 0.12);
}

.brand-name {
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 0.02em;
  font-family: var(--font-display);
  line-height: 0.92;
}

.brand-panda {
  font-weight: 800;
  font-size: clamp(2.15rem, 7.2vw, 3.35rem);
  letter-spacing: -0.055em;
  color: var(--ink);
}

.brand-esim {
  font-weight: 700;
  font-size: clamp(1.35rem, 4.4vw, 1.95rem);
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--teal);
  margin-left: 5px;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  margin: 0;
  font-size: 0.95rem;
  font-weight: 600;
  letter-spacing: -0.01em;
  text-transform: none;
  color: var(--teal);
}

.pulse {
  width: 0.55rem;
  height: 0.55rem;
  border-radius: 50%;
  background: var(--teal);
}

h1 {
  margin: 0;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: clamp(1.05rem, 4.2vw, 1.7rem);
  line-height: 1.15;
  letter-spacing: -0.03em;
  color: var(--ink);
  white-space: nowrap;
}

.offer {
  display: flex;
  flex-direction: column;
  align-items: stretch;
  gap: 1.15rem;
  width: max-content;
  max-width: 100%;
}

.offer .lede,
.offer .price-check,
.offer .store-row {
  width: 0;
  min-width: 100%;
}

.store-row {
  display: flex;
  flex-wrap: nowrap;
  align-items: center;
  justify-content: center;
  gap: 0.70rem;
  margin-top: 0.35rem;
  width: 100%;
}

.store-badge {
  display: block;
  flex: 1 1 0;
  min-width: 0;
  line-height: 0;
  border-radius: 0.5rem;
  cursor: default;
  user-select: none;
}

.store-badge-img {
  display: block;
  width: 100%;
  height: auto;
  object-fit: contain;
}

.lede {
  margin: 0;
  font-size: clamp(1.02rem, 2.2vw, 1.15rem);
  line-height: 1.55;
  color: var(--muted);
  font-weight: 500;
}

.price-check {
  position: relative;
  margin-top: 0;
  display: flex;
  align-items: flex-start;
  gap: 0.65rem;
  flex-wrap: nowrap;
}

.price-label {
  flex: 0 0 auto;
  margin: 0;
  padding-top: 0.65rem;
  font-family: var(--font-display);
  font-size: 0.95rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--ink);
  white-space: nowrap;
}

.price-check-col {
  flex: 1 1 auto;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 0.55rem;
}

.price-check-row {
  display: flex;
  position: relative;
  width: 100%;
  flex-wrap: nowrap;
  align-items: stretch;
}

.price-check input {
  flex: 1 1 auto;
  width: 100%;
  min-width: 0;
  min-height: 2.55rem;
  padding: 0.55rem 0.9rem;
  border: 1px solid rgba(26, 34, 30, 0.12);
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.72);
  backdrop-filter: blur(8px);
  color: var(--ink);
  font: inherit;
  font-size: 0.92rem;
  outline: none;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.price-check input::placeholder {
  color: #7a8a82;
}

.price-check input:focus {
  border-color: var(--teal);
  box-shadow: 0 0 0 3px rgba(47, 143, 127, 0.18);
}

.suggestions {
  list-style: none;
  margin: 0.4rem 0 0;
  padding: 0.35rem;
  position: absolute;
  left: 0;
  right: 0;
  z-index: 5;
  border-radius: 1rem;
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: blur(10px);
  border: 1px solid rgba(26, 34, 30, 0.08);
  box-shadow: 0 12px 28px rgba(26, 34, 30, 0.1);
  max-height: 14rem;
  overflow: auto;
}

.suggestion {
  width: 100%;
  display: flex;
  align-items: center;
  gap: 0.55rem;
  padding: 0.55rem 0.7rem;
  border: 0;
  border-radius: 0.75rem;
  background: transparent;
  color: var(--ink);
  font: inherit;
  font-size: 0.92rem;
  text-align: left;
  cursor: pointer;
}

.suggestion:hover,
.suggestion:focus {
  background: rgba(47, 143, 127, 0.1);
  outline: none;
}

.suggestion-flag {
  font-size: 1.15rem;
  line-height: 1;
}

.price-result {
  display: flex;
  align-items: center;
  gap: 0.7rem;
  margin: 0;
  animation: rise 0.35s ease-out both;
}

.price-flag {
  font-size: 1.85rem;
  line-height: 1;
}

.price-meta {
  display: flex;
  flex-direction: column;
  gap: 0.1rem;
  min-width: 0;
}

.price-country {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1rem;
  letter-spacing: -0.02em;
  color: var(--ink);
}

.price-amount {
  font-weight: 700;
  font-size: 0.98rem;
  color: var(--teal);
}

.form-error {
  margin: 0;
  color: #a33b3b;
  font-weight: 600;
  font-size: 0.92rem;
}

@keyframes rise {
  from {
    opacity: 0;
    transform: translateY(18px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes drift {
  from {
    transform: translate3d(0, 0, 0) scale(1);
  }
  to {
    transform: translate3d(-24px, 18px, 0) scale(1.06);
  }
}

@keyframes pulse-waves {
  0%,
  100% {
    opacity: 0.55;
    transform: translateY(0) scaleX(1);
  }
  50% {
    opacity: 0.95;
    transform: translateY(-6px) scaleX(1.02);
  }
}

@media (max-width: 520px) {
  .offer {
    width: 100%;
  }

  h1 {
    white-space: normal;
  }

  .store-row {
    gap: 0.35rem;
  }

  .price-check {
    flex-direction: column;
    align-items: stretch;
    gap: 0.55rem;
  }

  .price-label {
    padding-top: 0;
  }

  .price-check-col {
    width: 100%;
  }
}

.legal-page {
  overflow-x: hidden;
}

.legal {
  position: relative;
  z-index: 1;
  padding: clamp(1.5rem, 4vw, 3rem);
  padding-bottom: 4rem;
  animation: rise 0.7s ease-out both;
}

.legal-inner {
  width: min(720px, 100%);
  margin: 0 auto;
}

.brand-compact {
  margin-bottom: 1.5rem;
}

.brand-compact .brand-mark {
  width: 3.5rem;
}

.brand-compact .brand-panda {
  font-size: 1.85rem;
}

.brand-compact .brand-esim {
  font-size: 1.05rem;
}

.legal-title {
  white-space: normal;
  font-size: clamp(1.6rem, 5vw, 2.2rem);
  margin-bottom: 0.35rem;
}

.legal-updated {
  margin: 0 0 1.75rem;
  color: var(--muted);
  font-size: 0.95rem;
}

.legal-body {
  color: var(--ink);
  line-height: 1.6;
  font-size: 1rem;
}

.legal-body h2 {
  margin: 1.75rem 0 0.55rem;
  font-family: var(--font-display);
  font-size: 1.15rem;
  font-weight: 800;
  letter-spacing: -0.02em;
}

.legal-body p,
.legal-body ul {
  margin: 0 0 0.85rem;
  color: var(--muted);
}

.legal-body ul {
  padding-left: 1.2rem;
}

.legal-body li {
  margin-bottom: 0.4rem;
}

.legal-body a {
  color: var(--teal);
  font-weight: 600;
  text-decoration: none;
}

.legal-body a:hover {
  text-decoration: underline;
}

.legal-body strong {
  color: var(--ink);
  font-weight: 700;
}

.legal-back {
  margin: 2.5rem 0 0;
}

.legal-back a {
  color: var(--teal);
  font-weight: 700;
  text-decoration: none;
}

.legal-back a:hover {
  text-decoration: underline;
}

.site-footer {
  position: relative;
  z-index: 1;
  padding: 0 1.5rem 1.5rem;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.65rem;
}

.site-footer-links {
  display: flex;
  gap: 0.85rem;
  justify-content: center;
  align-items: center;
  flex-wrap: wrap;
}

.site-footer a {
  color: var(--muted);
  font-size: 0.9rem;
  font-weight: 600;
  text-decoration: none;
}

.site-footer-links a + a::before {
  content: "";
  display: inline-block;
  width: 1px;
  height: 0.95em;
  margin-right: 0.85rem;
  background: rgba(26, 34, 30, 0.22);
  vertical-align: -0.1em;
}

.site-footer a:hover {
  color: var(--teal);
}

.site-footer-copy {
  margin: 0;
  color: var(--muted);
  font-size: 0.78rem;
  font-weight: 500;
  opacity: 0.85;
}

.account-hero {
  align-items: flex-start;
  padding-top: clamp(2rem, 6vw, 3.5rem);
}

.account-shell {
  width: min(440px, 100%);
  transform: none;
}

.account-card {
  width: 100%;
  margin-top: 0.5rem;
}

.account-card h1 {
  margin: 0 0 0.4rem;
  font-family: var(--font-display);
  font-size: clamp(1.55rem, 4vw, 1.9rem);
  letter-spacing: -0.03em;
}

.account-card h2,
.account-section-title {
  margin: 1.5rem 0 0.4rem;
  font-family: var(--font-display);
  font-size: 1.05rem;
  font-weight: 800;
}

.account-form {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  margin-top: 1.15rem;
}

.account-label {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--muted);
}

.account-label input {
  border: 1px solid rgba(26, 34, 30, 0.14);
  border-radius: 16px;
  padding: 0.8rem 0.95rem;
  font: inherit;
  color: var(--ink);
  background: rgba(255, 255, 255, 0.72);
}

.account-label input:focus {
  outline: 2px solid rgba(47, 143, 127, 0.35);
  border-color: var(--teal);
}

.account-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin-top: 0.35rem;
  border: 0;
  border-radius: 16px;
  padding: 0.85rem 1.1rem;
  background: var(--ink);
  color: #f5faf7;
  font-family: var(--font-display);
  font-size: 1rem;
  font-weight: 700;
  text-decoration: none;
  cursor: pointer;
}

.account-btn.secondary {
  background: transparent;
  color: var(--ink);
  border: 1px solid rgba(26, 34, 30, 0.2);
}

.account-btn:disabled {
  opacity: 0.55;
  cursor: default;
}

.account-link-btn {
  margin-top: 0.85rem;
  border: 0;
  background: transparent;
  color: var(--teal);
  font: inherit;
  font-weight: 600;
  cursor: pointer;
  padding: 0;
}

#auth-toggle {
  display: block;
  width: 100%;
  text-align: center;
}

.account-dash-head {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  align-items: flex-start;
}

.account-balance-label {
  margin: 1.35rem 0 0;
  color: var(--muted);
  font-weight: 600;
}

.account-balance {
  margin: 0.15rem 0 0;
  font-family: var(--font-display);
  font-size: clamp(2.2rem, 8vw, 2.8rem);
  font-weight: 800;
  color: var(--teal);
  letter-spacing: -0.04em;
}

.account-meta,
.account-status {
  margin: 0.35rem 0 0;
  color: var(--muted);
  line-height: 1.45;
}

.account-amounts {
  display: flex;
  flex-wrap: wrap;
  gap: 0.65rem;
  margin-top: 0.85rem;
}

.account-amount-btn {
  border: 1px solid rgba(26, 34, 30, 0.18);
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.7);
  color: var(--ink);
  font-family: var(--font-display);
  font-weight: 700;
  padding: 0.7rem 1rem;
  cursor: pointer;
}

.account-amount-btn:disabled {
  opacity: 0.55;
  cursor: default;
}

.account-esim-actions {
  display: flex;
  flex-direction: column;
  gap: 0.55rem;
  margin-top: 0.85rem;
}

.account-qr {
  display: block;
  width: 220px;
  max-width: 100%;
  height: auto;
  margin: 1rem auto 0;
  background: #fff;
  border-radius: 16px;
  padding: 0.75rem;
}

.account-delete-wrap {
  margin: 2.25rem 0 0;
  text-align: center;
}

.account-delete-link {
  border: 0;
  background: transparent;
  color: #8a6a6a;
  font: inherit;
  font-size: 0.78rem;
  font-weight: 500;
  text-decoration: underline;
  cursor: pointer;
  padding: 0;
}

.account-delete-link:hover {
  color: #a33b3b;
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation: none !important;
    transition: none !important;
  }
}
