/**
 * WhatsRay Marketing Site — Modern Redesign
 * Extends the existing "Digital Curator" design tokens (see apple-style.css)
 * so the marketing site and the app dashboard share one visual language.
 * Loaded last: intentionally overrides legacy template rules for the
 * homepage/marketing chrome only (scoped under .frontend / #header / .footer-area).
 */

:root {
  --mx-accent: #25d366;
  --mx-accent-dark: #128c53;
  --mx-ink: var(--on-surface, #191c1d);
  --mx-ink-soft: var(--on-surface-variant, #55625a);
  --mx-surface: var(--surface, #f8f9fa);
  --mx-card: var(--surface-container-lowest, #ffffff);
  --mx-border: var(--outline-variant, rgba(25, 28, 29, 0.1));
  --mx-radius: var(--radius-lg, 20px);
  --mx-radius-sm: var(--radius-md, 16px);
  --mx-radius-pill: var(--radius-pill, 980px);
  --mx-shadow: 0 10px 30px rgba(15, 35, 30, 0.08);
  --mx-shadow-lg: 0 30px 60px rgba(15, 35, 30, 0.14);
  --mx-gradient: linear-gradient(135deg, var(--primary, #006b5f) 0%, var(--mx-accent-dark) 60%, var(--mx-accent) 100%);
  --mx-ease: cubic-bezier(0.16, 1, 0.3, 1);
}

/* ==========================================================================
   Base type refinements for marketing pages
   ========================================================================== */
.frontend .mx-section,
.frontend .mx-hero {
  position: relative;
  overflow: hidden;
}

.frontend .section-heading.mx-heading {
  max-width: 640px;
}

.frontend .mx-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 7px 16px 7px 14px;
  margin-bottom: 18px;
  border-radius: var(--mx-radius-pill);
  background: hsl(var(--base, 173 100% 21%) / 0.09);
  color: var(--primary, #006b5f) !important;
  font-family: var(--font-body, 'Inter', sans-serif) !important;
  font-size: 13px;
  font-weight: 600 !important;
  letter-spacing: 0.02em;
  border: 1px solid hsl(var(--base, 173 100% 21%) / 0.16);
}

.frontend .mx-eyebrow i {
  font-size: 14px;
}

.frontend .mx-eyebrow--light {
  background: rgba(255, 255, 255, 0.14);
  border-color: rgba(255, 255, 255, 0.24);
  color: #fff !important;
}

.frontend .section-heading__title {
  font-weight: 800 !important;
  letter-spacing: -0.03em !important;
  line-height: 1.15 !important;
}

/* ==========================================================================
   Hero / Banner
   ========================================================================== */
.frontend .mx-hero {
  padding: 190px 0 120px;
  background: linear-gradient(180deg, #f4faf8 0%, var(--mx-surface) 55%, var(--mx-surface) 100%);
}

@media screen and (max-width: 991px) {
  .frontend .mx-hero {
    padding: 150px 0 80px;
  }
}

.mx-hero-bg {
  position: absolute;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  overflow: hidden;
}

.mx-blob {
  position: absolute;
  border-radius: 50%;
  filter: blur(70px);
  opacity: 0.55;
  animation: mxFloat 12s ease-in-out infinite;
}

.mx-blob--a {
  width: 480px;
  height: 480px;
  top: -160px;
  right: -120px;
  background: radial-gradient(circle, hsl(var(--base, 173 100% 21%) / 0.35), transparent 70%);
}

.mx-blob--b {
  width: 380px;
  height: 380px;
  bottom: -140px;
  left: -100px;
  background: radial-gradient(circle, rgba(37, 211, 102, 0.28), transparent 70%);
  animation-delay: -6s;
}

.mx-grid-fade {
  position: absolute;
  inset: 0;
  background-image: linear-gradient(hsl(var(--base, 173 100% 21%) / 0.05) 1px, transparent 1px),
    linear-gradient(90deg, hsl(var(--base, 173 100% 21%) / 0.05) 1px, transparent 1px);
  background-size: 44px 44px;
  mask-image: radial-gradient(ellipse 60% 50% at 50% 0%, #000 40%, transparent 80%);
}

@keyframes mxFloat {
  0%, 100% { transform: translate(0, 0) scale(1); }
  50% { transform: translate(-20px, 24px) scale(1.06); }
}

.mx-hero-content {
  position: relative;
  z-index: 1;
}

.frontend .mx-hero-title {
  font-size: 54px !important;
  font-weight: 800 !important;
  letter-spacing: -0.035em !important;
  line-height: 1.08 !important;
  background: var(--mx-gradient);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  margin-bottom: 22px;
}

@media screen and (max-width: 767px) {
  .frontend .mx-hero-title {
    font-size: 36px !important;
  }
}

.frontend .mx-hero-desc {
  font-size: 18px !important;
  line-height: 1.6 !important;
  color: var(--mx-ink-soft) !important;
  max-width: 520px;
  margin-bottom: 34px;
}

.mx-hero-actions {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 20px;
  margin-bottom: 36px;
}

.frontend .mx-hero-actions .btn-hero-glow {
  padding: 16px 34px !important;
  border-radius: var(--mx-radius-pill) !important;
  font-weight: 700 !important;
  transition: transform 0.35s var(--mx-ease) !important;
}

.frontend .mx-hero-actions .btn-hero-glow:hover {
  transform: translateY(-3px);
}

.mx-hero-note {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 14px;
  font-weight: 500;
  color: var(--mx-ink-soft);
}

.mx-hero-trust {
  display: flex;
  align-items: center;
  gap: 14px;
}

.mx-hero-trust p {
  font-size: 14px !important;
  color: var(--mx-ink-soft) !important;
  margin: 0;
}

.mx-hero-avatars {
  display: flex;
}

.mx-hero-avatars span {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  border: 2px solid var(--mx-surface);
  margin-left: -10px;
  background: var(--mx-gradient);
}

.mx-hero-avatars span:first-child {
  margin-left: 0;
}

.mx-hero-avatars span:nth-child(2) { filter: hue-rotate(20deg); }
.mx-hero-avatars span:nth-child(3) { filter: hue-rotate(-20deg); }
.mx-hero-avatars span:nth-child(4) { filter: hue-rotate(45deg); }

.mx-hero-visual {
  position: relative;
  z-index: 1;
  padding: 30px;
}

.mx-hero-visual__glow {
  position: absolute;
  inset: 20px;
  background: var(--mx-gradient);
  filter: blur(60px);
  opacity: 0.35;
  border-radius: 50%;
  z-index: 0;
}

.mx-hero-visual__frame {
  position: relative;
  z-index: 1;
  border-radius: 28px;
  overflow: hidden;
  box-shadow: var(--mx-shadow-lg);
  border: 1px solid rgba(255, 255, 255, 0.6);
  transform: perspective(1000px) rotateY(-6deg) rotateX(2deg);
  transition: transform 0.6s var(--mx-ease);
}

.mx-hero-visual:hover .mx-hero-visual__frame {
  transform: perspective(1000px) rotateY(0deg) rotateX(0deg);
}

.mx-hero-visual__frame img {
  display: block;
  width: 100%;
  height: auto;
}

.mx-float-card {
  position: absolute;
  z-index: 2;
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px 18px;
  background: var(--mx-card);
  border-radius: var(--mx-radius-sm);
  box-shadow: var(--mx-shadow-lg);
  border: 1px solid var(--mx-border);
  animation: mxBob 5s ease-in-out infinite;
}

.mx-float-card--top {
  top: -6%;
  left: -8%;
}

.mx-float-card--bottom {
  bottom: -6%;
  right: -8%;
  animation-delay: -2.5s;
}

@media screen and (max-width: 767px) {
  .mx-float-card {
    display: none;
  }
}

@keyframes mxBob {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-10px); }
}

.mx-float-card__icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 42px;
  height: 42px;
  border-radius: 50%;
  background: hsl(var(--base, 173 100% 21%) / 0.12);
  color: var(--primary, #006b5f);
  font-size: 18px;
  flex-shrink: 0;
}

.mx-float-card__icon--alt {
  background: rgba(37, 211, 102, 0.15);
  color: var(--mx-accent-dark);
}

.mx-float-card strong {
  display: block;
  font-size: 13px !important;
  color: var(--mx-ink) !important;
}

.mx-float-card small {
  font-size: 12px;
  color: var(--mx-ink-soft);
}

/* ==========================================================================
   Sticky glass header
   ========================================================================== */
.mx-header {
  transition: background-color 0.35s ease, box-shadow 0.35s ease, padding 0.35s ease, backdrop-filter 0.35s ease;
}

.mx-header.fixed-header {
  background: rgba(255, 255, 255, 0.72) !important;
  backdrop-filter: blur(16px) saturate(160%);
  -webkit-backdrop-filter: blur(16px) saturate(160%);
  box-shadow: 0 8px 30px rgba(15, 35, 30, 0.08) !important;
  padding: 12px 0 !important;
}

.mx-header .nav-link {
  font-weight: 600 !important;
  position: relative;
}

.mx-header .nav-link::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: -4px;
  width: 0;
  height: 2px;
  background: var(--mx-gradient);
  transition: width 0.3s var(--mx-ease);
}

.mx-header .nav-item.active .nav-link::after,
.mx-header .nav-link:hover::after {
  width: 100%;
}

.mx-header .mx-nav-cta {
  border-radius: var(--mx-radius-pill) !important;
  padding: 11px 24px !important;
  font-weight: 700 !important;
  background: var(--mx-gradient) !important;
  border: none !important;
  box-shadow: 0 10px 22px hsl(var(--base, 173 100% 21%) / 0.24);
}

/* ==========================================================================
   Cards, hover lift, generic section polish
   ========================================================================== */
.mx-card-hover {
  transition: transform 0.4s var(--mx-ease), box-shadow 0.4s var(--mx-ease);
}

.mx-card-hover:hover {
  transform: translateY(-8px);
  box-shadow: var(--mx-shadow-lg) !important;
}

.frontend .feature-item {
  background: var(--mx-card) !important;
  border: 1px solid var(--mx-border) !important;
  border-radius: var(--mx-radius) !important;
  box-shadow: var(--mx-shadow);
  padding: 36px 30px !important;
}

.frontend .feature-item__icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 56px;
  height: 56px;
  border-radius: 16px;
  background: hsl(var(--base, 173 100% 21%) / 0.1);
  color: var(--primary, #006b5f) !important;
  font-size: 22px;
  margin-bottom: 20px;
}

.frontend .feature-item__title {
  font-weight: 700 !important;
}

/* How it works — numbered timeline feel */
.frontend .how-work-item {
  position: relative;
  background: var(--mx-card) !important;
  border: 1px solid var(--mx-border) !important;
  border-radius: var(--mx-radius) !important;
  box-shadow: var(--mx-shadow);
  padding: 34px 26px 28px !important;
  text-align: left;
}

.mx-step-number {
  display: block;
  font-family: var(--font-display, 'Manrope', sans-serif);
  font-size: 34px;
  font-weight: 800;
  background: var(--mx-gradient);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  opacity: 0.45;
  margin-bottom: 6px;
}

.frontend .how-work-item__icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 46px;
  height: 46px;
  border-radius: 14px;
  background: hsl(var(--base, 173 100% 21%) / 0.1);
  color: var(--primary, #006b5f) !important;
  margin-bottom: 16px;
}

/* Mobile app section */
.frontend .customer-management-section .management-wrapper {
  background: var(--mx-card) !important;
  border: 1px solid var(--mx-border) !important;
  border-radius: 28px !important;
  box-shadow: var(--mx-shadow-lg);
  padding: 56px !important;
}

@media screen and (max-width: 767px) {
  .frontend .customer-management-section .management-wrapper {
    padding: 30px !important;
  }
}

.frontend .text-list__icon {
  background: hsl(var(--base, 173 100% 21%) / 0.12) !important;
  color: var(--mx-accent-dark) !important;
}

.frontend .management-wrapper__thumb {
  border-radius: var(--mx-radius) !important;
  overflow: hidden;
  box-shadow: var(--mx-shadow-lg);
}

/* Testimonials */
.frontend .feedback-item {
  background: var(--mx-card) !important;
  border: 1px solid var(--mx-border) !important;
  border-radius: var(--mx-radius) !important;
  box-shadow: var(--mx-shadow);
}

.mx-quote-mark {
  display: inline-flex;
  color: hsl(var(--base, 173 100% 21%) / 0.25);
  font-size: 30px;
  margin-bottom: 6px;
}

/* Pricing */
.frontend .pricing-card {
  border-radius: var(--mx-radius) !important;
  border: 1px solid var(--mx-border) !important;
  box-shadow: var(--mx-shadow);
  transition: transform 0.4s var(--mx-ease), box-shadow 0.4s var(--mx-ease) !important;
}

.frontend .pricing-card:hover {
  transform: translateY(-6px);
}

.frontend .pricing-card.popular {
  background: var(--mx-gradient) !important;
  box-shadow: var(--mx-shadow-lg) !important;
  border: none !important;
}

/* FAQ accordion */
.frontend .custom--accordion .accordion-item {
  border: 1px solid var(--mx-border) !important;
  border-radius: var(--mx-radius-sm) !important;
  overflow: hidden;
  margin-bottom: 14px;
  background: var(--mx-card) !important;
}

.frontend .custom--accordion .accordion-button {
  font-weight: 600 !important;
}

.frontend .custom--accordion .accordion-button:not(.collapsed) {
  color: var(--primary, #006b5f) !important;
  background: hsl(var(--base, 173 100% 21%) / 0.06) !important;
}

.frontend .faq-section__top .nav-link {
  border-radius: var(--mx-radius-pill) !important;
  font-weight: 600 !important;
}

.frontend .faq-section__top .nav-link.active {
  background: var(--mx-gradient) !important;
  border: none !important;
  color: #fff !important;
}

/* CTA banner */
.frontend .cta-section {
  border-radius: 32px;
  margin: 0 auto;
  max-width: 1290px;
  background: var(--mx-gradient);
  overflow: hidden;
}

.frontend .cta-wrapper {
  position: relative;
  z-index: 1;
}

.frontend .cta-section .section-heading__desc {
  color: rgba(255, 255, 255, 0.85) !important;
}

.frontend .cta-wrapper__btn .btn--base {
  background: #fff !important;
  color: var(--primary, #006b5f) !important;
  border-radius: var(--mx-radius-pill) !important;
  font-weight: 700 !important;
  padding: 15px 32px !important;
  transition: transform 0.35s var(--mx-ease) !important;
}

.frontend .cta-wrapper__btn .btn--base:hover {
  transform: translateY(-3px);
}

/* Blog cards */
.frontend .blog-item {
  background: var(--mx-card) !important;
  border: 1px solid var(--mx-border) !important;
  border-radius: var(--mx-radius) !important;
  box-shadow: var(--mx-shadow);
  overflow: hidden;
}

.frontend .blog-item__thumb {
  overflow: hidden;
}

.frontend .blog-item__thumb img {
  transition: transform 0.6s var(--mx-ease);
}

.frontend .blog-item:hover .blog-item__thumb img {
  transform: scale(1.08);
}

/* ==========================================================================
   Footer refinements
   ========================================================================== */
.footer-area {
  background: linear-gradient(180deg, #0c1f1a 0%, #071410 100%) !important;
  position: relative;
  overflow: hidden;
}

.footer-area .search-form.subscribe-form {
  border-radius: var(--mx-radius-pill);
  overflow: hidden;
  display: flex;
}

.footer-area .search-form.subscribe-form .form--control {
  border-radius: var(--mx-radius-pill) 0 0 var(--mx-radius-pill) !important;
}

.footer-area .search-form.subscribe-form .btn--base {
  border-radius: 0 var(--mx-radius-pill) var(--mx-radius-pill) 0 !important;
  background: var(--mx-gradient) !important;
}

.hp-footer__glow {
  position: absolute;
  top: -220px;
  left: 50%;
  transform: translateX(-50%);
  width: 900px;
  height: 420px;
  background: radial-gradient(circle, rgba(37, 211, 102, 0.16), transparent 65%);
  filter: blur(50px);
  pointer-events: none;
}

.hp-footer__top {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 50px;
  align-items: start;
  padding-bottom: 48px;
  margin-bottom: 48px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

@media screen and (max-width: 900px) {
  .hp-footer__top {
    grid-template-columns: 1fr;
    gap: 30px;
  }
}

.hp-footer__brand .footer-item__logo {
  margin-bottom: 18px !important;
}

.hp-footer__brand .footer-item__logo img {
  width: auto !important;
  max-width: 180px !important;
  max-height: 44px !important;
}

.hp-footer__brand .footer-item__desc {
  max-width: 420px;
  margin-bottom: 22px !important;
}

.hp-footer__subscribe {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: var(--mx-radius);
  padding: 28px 30px;
}

.hp-footer__subscribe .search-wrapper__title {
  color: #fff !important;
  font-size: 17px;
  margin-bottom: 6px !important;
}

.hp-footer__subscribe .search-wrapper__text {
  margin-bottom: 18px !important;
}

.hp-footer__grid {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 30px;
  margin-bottom: 44px;
}

@media screen and (max-width: 900px) {
  .hp-footer__grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media screen and (max-width: 560px) {
  .hp-footer__grid {
    grid-template-columns: 1fr;
  }
}

.hp-footer__referral {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: var(--mx-radius-sm);
  padding: 22px;
}

.hp-footer__referral .title {
  color: #fff !important;
  -webkit-text-fill-color: #fff !important;
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 15px;
  margin-bottom: 0 !important;
}

.hp-footer__referral-desc {
  color: rgba(255, 255, 255, 0.7) !important;
  font-size: 13px;
  line-height: 1.55;
  margin: 10px 0 16px !important;
}

.footer-area .bottom-footer {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 16px;
  padding-top: 26px;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
}

.hp-footer__lang .custom--dropdown__selected {
  background: rgba(255, 255, 255, 0.06);
  border-radius: var(--mx-radius-pill);
  padding: 6px 14px;
}

/* ==========================================================================
   Features page (key-feature-wrapper)
   ========================================================================== */
.frontend .key-feature-wrapper {
  background: var(--mx-card) !important;
  border: 1px solid var(--mx-border) !important;
  border-radius: var(--mx-radius) !important;
  box-shadow: var(--mx-shadow);
  overflow: hidden;
}

.frontend .key-feature-wrapper__top .icon {
  background: hsl(var(--base, 173 100% 21%) / 0.1) !important;
  color: var(--primary, #006b5f) !important;
}

.frontend .key-feature-wrapper__thumb img {
  border-radius: var(--mx-radius-sm);
}

/* Fix: --heading-color is a near-white mint tone meant for dark surfaces;
   custom.css forces it with !important on this light-background checklist,
   making the text nearly invisible. */
.frontend .key-feature-wrapper__content .why-choose-us li {
  color: var(--mx-ink) !important;
}

/* ==========================================================================
   Contact page
   ========================================================================== */
.frontend .contact-item {
  background: var(--mx-card) !important;
  border: 1px solid var(--mx-border) !important;
  border-radius: var(--mx-radius) !important;
  box-shadow: var(--mx-shadow);
}

.frontend .contact-item__icon {
  background: hsl(var(--base, 173 100% 21%) / 0.1) !important;
  color: var(--primary, #006b5f) !important;
}

.frontend .support-item {
  background: var(--mx-card) !important;
  border: 1px solid var(--mx-border) !important;
  border-radius: var(--mx-radius) !important;
  box-shadow: var(--mx-shadow);
}

.frontend .support-item__top {
  color: var(--primary, #006b5f) !important;
}

.frontend .contact-form .form--control,
.frontend .contact-form textarea {
  border-radius: var(--mx-radius-sm) !important;
  border-color: var(--mx-border) !important;
}

.frontend .contact-form button[type="submit"] {
  border-radius: var(--mx-radius-pill) !important;
}

/* ==========================================================================
   Motion — extra scroll-reveal keyframes (used via .wow class, same as
   the site's existing wow.js pipeline)
   ========================================================================== */
@media (prefers-reduced-motion: reduce) {
  .mx-blob,
  .mx-float-card,
  .mx-hero-visual__frame,
  .mx-card-hover {
    animation: none !important;
    transition: none !important;
  }
}
