/* ============================================================
   MyStash Pricing Section — Shared CSS
   Add to: Admin → System → Site Templates → mystash → user.css
   ============================================================ */

:root {
  --ms-teal:        #1a7a6e;
  --ms-teal-dark:   #0e4a42;
  --ms-teal-light:  #e8f4f2;
  --ms-teal-mid:    #2a9d8f;
  --ms-terra:       #c0784a;
  --ms-terra-light: #f5ece5;
  --ms-cream:       #faf7f2;
  --ms-cream-dark:  #f0ebe2;
  --ms-ink:         #1c2b28;
  --ms-ink-mid:     #3d5450;
  --ms-ink-light:   #6b8a84;
  --ms-yes:         #1a7a6e;
  --ms-no:          #c8c0b8;
  --ms-shadow-sm:   0 2px 8px rgba(26,122,110,0.10);
  --ms-shadow-md:   0 8px 32px rgba(26,122,110,0.14);
  --ms-shadow-lg:   0 20px 60px rgba(26,122,110,0.18);
  --ms-radius:      16px;
  --ms-radius-sm:   10px;
}

.ms-pricing-section {
  padding: 96px 24px 80px;
  background: var(--ms-cream);
  position: relative;
  overflow: hidden;
}

.ms-pricing-section::before {
  content: '';
  position: absolute;
  top: -120px; left: -120px;
  width: 500px; height: 500px;
  background: radial-gradient(circle, rgba(26,122,110,0.06) 0%, transparent 70%);
  pointer-events: none;
}

.ms-pricing-section::after {
  content: '';
  position: absolute;
  bottom: -80px; right: -80px;
  width: 400px; height: 400px;
  background: radial-gradient(circle, rgba(192,120,74,0.05) 0%, transparent 70%);
  pointer-events: none;
}

.ms-pricing-inner {
  max-width: 1100px;
  margin: 0 auto;
  position: relative;
  z-index: 1;
}

.ms-pricing-header {
  text-align: center;
  margin-bottom: 48px;
}

.ms-pricing-header h2 {
  font-family: 'Nunito', sans-serif;
  font-size: clamp(2rem, 4vw, 2.75rem);
  font-weight: 900;
  color: var(--ms-teal-dark);
  letter-spacing: -0.02em;
  line-height: 1.15;
  margin-bottom: 12px;
}

.ms-pricing-header p {
  font-size: 1.125rem;
  color: var(--ms-ink-mid);
  font-weight: 600;
}

.ms-billing-toggle {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  margin-bottom: 48px;
}

.ms-toggle-label {
  font-family: 'Nunito', sans-serif;
  font-weight: 700;
  font-size: 0.95rem;
  color: var(--ms-ink-mid);
  cursor: pointer;
  transition: color 0.2s;
}

.ms-toggle-label.active { color: var(--ms-teal-dark); }

.ms-toggle-switch {
  position: relative;
  width: 52px; height: 28px;
  cursor: pointer;
}

.ms-toggle-switch input {
  opacity: 0; width: 0; height: 0; position: absolute;
}

.ms-toggle-track {
  position: absolute; inset: 0;
  background: var(--ms-teal);
  border-radius: 100px;
  transition: background 0.25s;
}

.ms-toggle-thumb {
  position: absolute;
  top: 4px; left: 4px;
  width: 20px; height: 20px;
  background: white;
  border-radius: 50%;
  transition: transform 0.25s cubic-bezier(.34,1.56,.64,1);
  box-shadow: 0 2px 4px rgba(0,0,0,0.15);
}

.ms-toggle-switch input:checked ~ .ms-toggle-track { background: var(--ms-terra); }
.ms-toggle-switch input:checked ~ .ms-toggle-thumb { transform: translateX(24px); }

.ms-savings-badge {
  background: var(--ms-terra);
  color: white;
  font-family: 'Nunito', sans-serif;
  font-weight: 800;
  font-size: 0.75rem;
  padding: 3px 10px;
  border-radius: 100px;
  letter-spacing: 0.02em;
}

.ms-pricing-cards {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
  align-items: start;
  margin-bottom: 32px;
}

@media (max-width: 768px) {
  .ms-pricing-cards { grid-template-columns: 1fr; gap: 16px; }
}

.ms-pricing-card {
  background: #ffffff;
  border-radius: var(--ms-radius);
  border: 2px solid transparent;
  padding: 32px 28px 28px;
  box-shadow: var(--ms-shadow-sm);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
  position: relative;
  overflow: hidden;
  animation: msFadeUp 0.5s ease both;
}

.ms-pricing-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--ms-shadow-md);
}

.ms-pricing-card.ms-featured {
  border-color: var(--ms-teal);
  box-shadow: var(--ms-shadow-lg);
  transform: translateY(-8px);
}

.ms-pricing-card.ms-featured:hover { transform: translateY(-12px); }

.ms-pricing-card.ms-trial {
  background: var(--ms-teal-light);
  border-color: var(--ms-teal-mid);
}

.ms-pricing-card:nth-child(1) { animation-delay: 0.05s; }
.ms-pricing-card:nth-child(2) { animation-delay: 0.15s; }
.ms-pricing-card:nth-child(3) { animation-delay: 0.25s; }

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

.ms-featured-ribbon {
  position: absolute;
  top: 16px; right: -28px;
  background: var(--ms-terra);
  color: white;
  font-family: 'Nunito', sans-serif;
  font-weight: 800;
  font-size: 0.7rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  padding: 5px 36px;
  transform: rotate(35deg);
  transform-origin: top right;
}

.ms-card-tier {
  font-family: 'Nunito', sans-serif;
  font-weight: 900;
  font-size: 0.8rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--ms-teal);
  margin-bottom: 8px;
}

.ms-trial .ms-card-tier { color: var(--ms-teal-dark); }

.ms-card-price {
  display: flex;
  align-items: baseline;
  gap: 2px;
  margin-bottom: 4px;
}

.ms-price-amount {
  font-family: 'Nunito', sans-serif;
  font-weight: 900;
  font-size: clamp(2rem, 3.5vw, 2.5rem);
  color: var(--ms-teal-dark);
  line-height: 1;
}

.ms-price-period {
  font-weight: 700;
  font-size: 0.9rem;
  color: var(--ms-ink-light);
  margin-left: 2px;
}

.ms-price-alt {
  font-size: 0.85rem;
  color: var(--ms-ink-light);
  font-weight: 600;
  margin-bottom: 4px;
  min-height: 1.2em;
}

.ms-card-note {
  font-size: 0.8rem;
  color: var(--ms-ink-mid);
  margin-bottom: 24px;
  min-height: 2.4em;
  line-height: 1.5;
}

.ms-feature-list {
  list-style: none;
  margin-bottom: 28px;
  padding: 0;
}

.ms-feature-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 9px 0;
  border-bottom: 1px solid var(--ms-cream-dark);
  gap: 8px;
}

.ms-feature-row:last-child { border-bottom: none; }

.ms-feature-name {
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--ms-ink-mid);
  flex: 1;
}

.ms-feature-val {
  font-family: 'Nunito', sans-serif;
  font-weight: 800;
  font-size: 0.9rem;
  text-align: right;
  min-width: 32px;
}

.ms-feature-val.ms-yes { color: var(--ms-yes); font-size: 1rem; }
.ms-feature-val.ms-no  { color: var(--ms-no);  font-size: 1rem; }
.ms-feature-val.ms-num { color: var(--ms-teal-dark); }

.ms-cta-btn {
  display: block;
  width: 100%;
  padding: 14px 20px;
  border-radius: var(--ms-radius-sm);
  font-family: 'Nunito', sans-serif;
  font-weight: 800;
  font-size: 0.95rem;
  text-align: center;
  cursor: pointer;
  border: none;
  text-decoration: none;
  transition: transform 0.18s ease, box-shadow 0.18s ease, background 0.18s ease;
  letter-spacing: 0.01em;
}

.ms-cta-btn:hover { transform: translateY(-2px); text-decoration: none; }

.ms-cta-btn.ms-primary {
  background: var(--ms-teal);
  color: white !important;
  box-shadow: 0 4px 16px rgba(26,122,110,0.3);
}

.ms-cta-btn.ms-primary:hover {
  background: var(--ms-teal-dark);
  box-shadow: 0 6px 24px rgba(26,122,110,0.4);
}

.ms-cta-btn.ms-secondary {
  background: transparent;
  color: var(--ms-teal) !important;
  border: 2px solid var(--ms-teal);
}

.ms-cta-btn.ms-secondary:hover { background: var(--ms-teal-light); }

.ms-cta-btn.ms-terra {
  background: var(--ms-terra);
  color: white !important;
  box-shadow: 0 4px 16px rgba(192,120,74,0.3);
}

.ms-cta-btn.ms-terra:hover {
  background: #a5633a;
  box-shadow: 0 6px 24px rgba(192,120,74,0.4);
}

.ms-pricing-footnotes {
  text-align: center;
  padding-top: 16px;
}

.ms-pricing-footnotes p {
  font-size: 0.8rem;
  color: var(--ms-ink-light);
  line-height: 1.7;
  margin: 0;
}

.ms-pricing-loading {
  text-align: center;
  padding: 60px;
  color: var(--ms-ink-light);
  font-weight: 600;
}

/* ── Home note (shown instead of buttons on home page) ── */
.ms-home-note {
  text-align: center;
  font-family: 'Nunito', sans-serif;
  font-weight: 900;
  font-size: 1.25rem;
  color: var(--ms-teal-dark);
  padding: 24px 16px 8px;
  letter-spacing: -0.01em;
}

/* ── Store badges (app pages only) ── */
.ms-store-badges {
  text-align: center;
  padding: 28px 16px 8px;
}

.ms-store-note {
  font-size: 0.875rem;
  color: var(--ms-ink-mid);
  font-weight: 600;
  margin-bottom: 20px;
}

.ms-store-buttons {
  display: flex;
  justify-content: center;
  gap: 16px;
  flex-wrap: wrap;
}

.ms-store-btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 12px 22px;
  border-radius: var(--ms-radius-sm);
  text-decoration: none !important;
  font-family: 'Nunito', sans-serif;
  font-weight: 700;
  font-size: 0.95rem;
  transition: transform 0.18s ease, box-shadow 0.18s ease;
  min-width: 180px;
}

.ms-store-btn:hover {
  transform: translateY(-2px);
  text-decoration: none !important;
}

.ms-store-btn svg {
  width: 24px;
  height: 24px;
  flex-shrink: 0;
}

.ms-store-btn span {
  display: flex;
  flex-direction: column;
  text-align: left;
  line-height: 1.2;
}

.ms-store-btn small {
  font-size: 0.7rem;
  font-weight: 600;
  opacity: 0.85;
}

.ms-store-apple {
  background: var(--ms-ink);
  color: white !important;
  box-shadow: 0 4px 16px rgba(28,43,40,0.25);
}

.ms-store-apple:hover {
  background: #000;
  box-shadow: 0 6px 24px rgba(28,43,40,0.35);
}

.ms-store-google {
  background: var(--ms-teal);
  color: white !important;
  box-shadow: 0 4px 16px rgba(26,122,110,0.3);
}

.ms-store-google:hover {
  background: var(--ms-teal-dark);
  box-shadow: 0 6px 24px rgba(26,122,110,0.4);
}

@media (max-width: 480px) {
  .ms-store-buttons { flex-direction: column; align-items: center; }
  .ms-store-btn { width: 100%; max-width: 260px; justify-content: center; }
}

/* ── Language Switcher ── */
#ms-lang-switcher {
  position: fixed;
  top: 16px;
  right: 16px;
  z-index: 1000;
}

#ms-lang-switcher .ms-ls-inner {
  display: flex;
  gap: 2px;
  align-items: center;
  background: rgba(14, 74, 66, 0.88);
  backdrop-filter: blur(8px);
  border-radius: 24px;
  padding: 5px 8px;
  box-shadow: 0 2px 12px rgba(0,0,0,0.25);
}

.ms-ls-btn {
  font-family: 'Open Sans', sans-serif;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  padding: 4px 9px;
  border-radius: 16px;
  border: none;
  background: transparent;
  color: rgba(255,255,255,0.55);
  cursor: pointer;
  transition: background 0.2s ease, color 0.2s ease;
  line-height: 1;
}

.ms-ls-btn:hover {
  background: rgba(255,255,255,0.12);
  color: white;
}

.ms-ls-btn.ms-ls-active {
  background: rgba(255,255,255,0.22);
  color: white;
}

/* Separator dots */
.ms-ls-btn + .ms-ls-btn {
  position: relative;
}

.ms-ls-btn + .ms-ls-btn::before {
  content: '·';
  position: absolute;
  left: -4px;
  color: rgba(255,255,255,0.25);
  font-weight: 400;
  pointer-events: none;
}

@media (max-width: 480px) {
  #ms-lang-switcher {
    top: 10px;
    right: 10px;
  }
  .ms-ls-btn {
    font-size: 0.68rem;
    padding: 3px 7px;
  }
}

/* ── Language-overridden app page title ── */
.ap-title-override {
  font-family: 'Open Sans', sans-serif;
  font-size: clamp(1.5rem, 3vw, 2.25rem);
  font-weight: 800;
  color: var(--ms-ink, #1c2b28);
  line-height: 1.2;
  margin-bottom: 0.5rem;
}

/* ── Footer ── */
#ms-footer {
  background: var(--ms-teal-dark, #0e4a42);
  color: rgba(255,255,255,0.85);
  padding: 0;
}

.ms-footer-inner {
  max-width: 1100px;
  margin: 0 auto;
  padding: 40px 32px 28px;
}

.ms-footer-brand {
  display: flex;
  align-items: center;
  gap: 16px;
  margin-bottom: 24px;
}

.ms-footer-logo {
  width: 48px;
  height: 48px;
  border-radius: 10px;
  object-fit: cover;
}

.ms-footer-tagline {
  font-family: 'Open Sans', sans-serif;
  font-weight: 700;
  font-size: 1rem;
  color: rgba(255,255,255,0.75);
  letter-spacing: 0.01em;
}

.ms-footer-divider {
  border: none;
  border-top: 1px solid rgba(255,255,255,0.12);
  margin: 0 0 20px 0;
}

.ms-footer-bottom {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
}

.ms-footer-copy {
  font-size: 0.825rem;
  color: rgba(255,255,255,0.5);
  font-family: 'Open Sans', sans-serif;
}

.ms-footer-links {
  display: flex;
  align-items: center;
  gap: 12px;
}

.ms-footer-links a {
  font-size: 0.825rem;
  color: rgba(255,255,255,0.65);
  text-decoration: none;
  font-family: 'Open Sans', sans-serif;
  transition: color 0.2s ease;
}

.ms-footer-links a:hover {
  color: white;
  text-decoration: underline;
}

.ms-footer-sep {
  color: rgba(255,255,255,0.25);
  font-size: 0.75rem;
}

@media (max-width: 600px) {
  .ms-footer-bottom {
    flex-direction: column;
    align-items: flex-start;
  }
  .ms-footer-inner {
    padding: 32px 20px 24px;
  }
}
