/* Alma mascot — shared Twig / legacy styles */
.alma {
  display: inline-block;
  line-height: 0;
}

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

.alma--sm { width: 56px; }
.alma--md { width: 96px; }
.alma--lg { width: 160px; }
.alma--xl { width: 240px; }
.alma--icon { width: 40px; }

/* Concept icons in landing / steps */
.alma-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  line-height: 0;
}
.alma-icon img {
  display: block;
  width: 100%;
  height: auto;
  object-fit: contain;
}

/* Loader */
.alma-loader {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.85rem;
  padding: 2rem 1rem;
}
.alma-loader--page { min-height: 40vh; }
.alma-loader--section { min-height: 120px; padding: 1.5rem 1rem; }
.alma-loader__sr {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
}
.alma-loader__img {
  width: 140px;
  height: 140px;
  object-fit: contain;
  animation: alma-loader-bob 1.6s ease-in-out infinite;
}
.alma-loader--section .alma-loader__img {
  width: 96px;
  height: 96px;
}
.alma-loader__dots {
  display: flex;
  gap: 6px;
  align-items: center;
}
.alma-loader__dots span {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #d9080b;
  opacity: 0.35;
  animation: alma-loader-dot 1.2s ease-in-out infinite;
}
.alma-loader__dots span:nth-child(2) { animation-delay: 0.18s; }
.alma-loader__dots span:nth-child(3) { animation-delay: 0.36s; }

@keyframes alma-loader-bob {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-6px); }
}
@keyframes alma-loader-dot {
  0%, 100% { opacity: 0.3; transform: scale(0.9); }
  50% { opacity: 1; transform: scale(1.1); }
}

.alma-empty {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1rem;
  padding: 2.5rem 1rem;
  text-align: center;
}

.alma-empty__title {
  margin: 0;
  font-size: 1.125rem;
  font-weight: 700;
  color: #00131a;
}

.alma-empty__desc {
  margin: 0.35rem 0 0;
  color: #5c6b73;
  font-size: 0.95rem;
}

.alma-home-mascot {
  margin: 1.75rem auto 0;
  max-width: 180px;
}

.alma-home-mascot img,
.alma-intro__mascot img {
  filter: drop-shadow(0 8px 20px rgba(0, 19, 26, 0.1));
}

/* Home intro */
.alma-intro {
  background: linear-gradient(180deg, #fff8f1 0%, #f8f1e4 100%);
}

.alma-intro__mascot {
  margin: 0 auto 1rem;
  max-width: 220px;
}

.alma-intro__tagline {
  margin: 0.25rem 0 0.75rem;
  font-size: 1.15rem;
  font-weight: 600;
  color: #d9080b;
}

.alma-intro__lead {
  max-width: 32rem;
  margin-left: auto;
  margin-right: auto;
  font-size: 1rem;
  line-height: 1.5;
}

.alma-footer-micro {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  margin: 0.75rem 0 1rem;
  color: rgba(255, 255, 255, 0.85);
  font-size: 0.85rem;
}

.alma-footer-micro .alma--sm {
  width: 40px;
}

/* App message Alma face */
.togalma-app-message__alma {
  flex-shrink: 0;
  width: 36px;
  height: 36px;
  object-fit: contain;
  margin-top: 0.1rem;
}

.togalma-app-message__inner {
  text-align: left;
}

/* Welcome modal */
.alma-welcome-backdrop {
  position: fixed;
  inset: 0;
  z-index: 1100;
  background: rgba(0, 19, 26, 0.45);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1.25rem;
  opacity: 0;
  transition: opacity 0.25s ease;
}

.alma-welcome-backdrop.is-open {
  opacity: 1;
}

.alma-welcome-dialog {
  position: relative;
  width: min(100%, 22rem);
  background: #fff;
  border-radius: 1.25rem;
  padding: 1.75rem 1.5rem 1.5rem;
  text-align: center;
  box-shadow: 0 24px 48px rgba(0, 19, 26, 0.2);
  transform: scale(0.92) translateY(12px);
  transition: transform 0.35s cubic-bezier(0.34, 1.45, 0.64, 1);
}

.alma-welcome-backdrop.is-open .alma-welcome-dialog {
  transform: scale(1) translateY(0);
}

.alma-welcome-dialog__alma {
  margin: 0 auto 0.75rem;
  width: 140px;
  animation: alma-pop 0.45s cubic-bezier(0.34, 1.56, 0.64, 1) both;
}

.alma-welcome-dialog h2 {
  margin: 0 0 0.35rem;
  font-size: 1.35rem;
  font-weight: 700;
  color: #00131a;
}

.alma-welcome-dialog p {
  margin: 0 0 1.25rem;
  color: #5c6b73;
  font-size: 0.95rem;
  line-height: 1.45;
}

.alma-welcome-dialog__actions {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.alma-welcome-dialog__cta {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: none;
  border-radius: 999px;
  padding: 0.7rem 1.25rem;
  background: #d9080b;
  color: #fff;
  font-weight: 600;
  font-size: 0.95rem;
  text-decoration: none;
  cursor: pointer;
}

.alma-welcome-dialog__cta:hover {
  background: #b80709;
  color: #fff;
}

.alma-welcome-dialog__ghost {
  border: none;
  background: transparent;
  color: #5c6b73;
  font-size: 0.85rem;
  cursor: pointer;
  padding: 0.4rem;
  text-decoration: underline;
}

@keyframes alma-pop {
  0% { transform: scale(0.6); opacity: 0; }
  70% { transform: scale(1.08); }
  100% { transform: scale(1); opacity: 1; }
}

@media (prefers-reduced-motion: reduce) {
  .alma-welcome-backdrop,
  .alma-welcome-dialog,
  .alma-welcome-dialog__alma,
  .alma-loader__img,
  .alma-loader__dots span {
    animation: none !important;
    transition: none !important;
  }
  .alma-welcome-backdrop.is-open .alma-welcome-dialog {
    transform: none;
  }
}
