/* ==========================================================================
   SOS meditation — sticky button + modal
   ========================================================================== */

.sos-fixed {
  position: fixed;
  bottom: 1.25rem;
  left: 1.25rem;
  z-index: 60;
}

.sos-circle {
  width: 70px;
  height: 70px;
  background: #D64545;
  border: none;
  border-radius: 50%;
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  animation: sosPulse 2.5s infinite;
  box-shadow: 0 0 20px rgba(214, 69, 69, 0.35);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.sos-circle:hover {
  transform: scale(1.1);
  box-shadow: 0 0 30px rgba(214, 69, 69, 0.5);
}

@keyframes sosPulse {
  0%, 100% { transform: scale(1); }
  50%      { transform: scale(1.05); }
}

.sos-text-circle {
  position: absolute;
  top: -22px;
  left: -22px;
  width: 114px;
  height: 114px;
  fill: #666666;
  font-size: 13px;
  font-weight: 400;
  letter-spacing: 1.8px;
  pointer-events: none;
}

.sos-text-circle text {
  dominant-baseline: middle;
}

.sos-content {
  display: flex;
  align-items: center;
  gap: 6px;
  position: relative;
}

.sos-label {
  color: var(--color-white);
  font-family: var(--font-body);
  font-weight: 700;
  font-size: 20px;
  letter-spacing: 2px;
  z-index: 2;
}

.sos-icon-touch {
  position: absolute;
  right: -22px;
  top: 2px;
  z-index: 3;
  width: 30px;
  height: 30px;
  fill: var(--color-white);
  animation: tapPulse 1.5s infinite;
}

@keyframes tapPulse {
  0%, 100% { transform: scale(1); }
  50%      { transform: scale(1.2); }
}

@media (prefers-reduced-motion: reduce) {
  .sos-circle,
  .sos-icon-touch {
    animation: none;
  }
}

@media (max-width: 640px) {
  .sos-fixed {
    bottom: 0.75rem;
    left: 0.75rem;
  }
  .sos-circle {
    width: 58px;
    height: 58px;
  }
  .sos-label {
    font-size: 16px;
  }
  .sos-text-circle {
    width: 98px;
    height: 98px;
    top: -20px;
    left: -20px;
    font-size: 6px;
  }
  .sos-icon-touch {
    width: 24px;
    height: 24px;
    right: -18px;
  }
}

/* ---------- Modal ---------- */

.sos-modal {
  position: fixed;
  inset: 0;
  z-index: 120;
  align-items: center;
  justify-content: center;
  padding: var(--space-md);
}

.sos-modal:not([hidden]) {
  display: flex;
}

.sos-modal[hidden] {
  display: none;
}

.sos-modal__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(20, 15, 12, 0.6);
  backdrop-filter: blur(3px);
}

.sos-modal__panel {
  position: relative;
  z-index: 1;
  width: 100%;
  max-width: 620px;
  max-height: 85vh;
  display: flex;
  flex-direction: column;
  background: var(--color-mist);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lift);
  overflow: hidden;
}

.sos-modal__scroll {
  overflow-y: auto;
  padding: var(--space-lg);
}

.sos-modal__close {
  position: absolute;
  top: var(--space-md);
  right: var(--space-md);
  z-index: 2;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  border: none;
  background: var(--color-sand);
  color: var(--color-ember);
  font-size: 18px;
  line-height: 1;
  cursor: pointer;
}

.sos-modal__title {
  font-family: var(--font-display);
  font-size: 1.3rem;
  line-height: var(--lh-snug);
  text-align: center;
  max-width: 40ch;
  margin-inline: auto;
  margin-bottom: var(--space-lg);
  padding-right: var(--space-lg);
}

.sos-accordion {
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
}

.sos-item {
  background: var(--color-white);
  border: 1px solid var(--color-ember-12);
  border-radius: var(--radius-md);
  overflow: hidden;
}

.sos-item.is-open {
  border-color: var(--color-marigold);
}

.sos-item__q {
  width: 100%;
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.85rem 1rem;
  background: none;
  border: none;
  text-align: left;
  cursor: pointer;
}

.sos-item__icon {
  font-size: 1.5rem;
  flex-shrink: 0;
}

.sos-item__text {
  flex-grow: 1;
  display: flex;
  flex-direction: column;
}

.sos-item__name {
  font-weight: 700;
  font-size: var(--fs-body-sm);
  color: var(--color-ember);
}

.sos-item__subtitle {
  font-size: var(--fs-caption);
  color: var(--color-ember-60);
}

.sos-item__chevron {
  flex-shrink: 0;
  color: var(--color-marigold);
  transition: transform 0.3s var(--ease-breath);
}

.sos-item__q[aria-expanded="true"] .sos-item__chevron {
  transform: rotate(180deg);
}

.sos-item__a {
  overflow: hidden;
  max-height: 0;
  transition: max-height 0.4s var(--ease-breath);
}

.sos-item__a-inner {
  padding: 0 1rem 1rem;
}

.sos-item__a-inner p {
  font-size: var(--fs-body-sm);
  color: var(--color-ember-60);
  line-height: var(--lh-normal);
  margin-bottom: 0.75rem;
}

.sos-item__a-inner audio {
  width: 100%;
}
