/* Butterfly Essentials — shared base for desktop and mobile designs. */

:root {
  --be-font-display: "Playfair Display", Georgia, serif;
  --be-font-ui: "Poppins", system-ui, -apple-system, "Segoe UI", sans-serif;
  --be-maroon: #7a1f3d;
  --be-ink: #5a2333;
  --be-ink-60: rgba(90, 35, 51, 0.6);
  --be-ink-soft: #5c4742;
  --be-muted: #9e8b82;
  --be-coral: #ff6f61;
  --be-coral-soft: #ff8b7a;
  --be-blush: #ffe9e5;
  --be-blush-line: #ffd0c8;
  --be-line: #f5e7dd;
  --be-canvas: #fff9f4;
  --be-white: #ffffff;
  --be-container: 1280px;
  --be-gutter: 80px;
  --be-shadow-soft: 0 12px 32px rgba(90, 35, 51, 0.06);
}

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

html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  background: var(--be-canvas);
  color: var(--be-ink);
  font-family: var(--be-font-ui);
  font-size: 14px;
  line-height: 22px;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
}

h1, h2, h3, h4, h5, h6, p, ul, ol, figure, blockquote {
  margin: 0;
}

ul, ol {
  padding: 0;
  list-style: none;
}

img, svg, video {
  display: block;
  max-width: 100%;
}

img {
  height: auto;
}

a {
  color: inherit;
  text-decoration: none;
}

button, input, select, textarea {
  font: inherit;
  color: inherit;
}

button {
  cursor: pointer;
}

:focus-visible {
  outline: 2px solid var(--be-coral-soft);
  outline-offset: 2px;
}

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

.be-container {
  width: 100%;
  max-width: calc(var(--be-container) + 2 * var(--be-gutter));
  margin: 0 auto;
  padding: 0 var(--be-gutter);
}

/* Typography */
.be-display {
  font-family: var(--be-font-display);
  font-weight: 700;
  font-size: 36px;
  line-height: 44px;
  color: var(--be-ink);
}

.be-display--coral {
  color: var(--be-coral);
}

.be-h2 {
  font-family: var(--be-font-ui);
  font-weight: 700;
  font-size: 22px;
  line-height: 30px;
  color: var(--be-ink);
}

.be-h3 {
  font-weight: 700;
  font-size: 16px;
  line-height: 26px;
  color: var(--be-ink);
}

.be-text-muted {
  color: var(--be-ink-60);
}

.be-eyebrow {
  font-size: 10px;
  font-weight: 600;
  line-height: 16px;
  letter-spacing: 1px;
  text-transform: uppercase;
  color: var(--be-color-text-accent-rose, #d98c9a);
}

/* Watermark heading — large gradient word behind a section title */
.be-watermark {
  position: relative;
  display: grid;
  justify-items: center;
  text-align: center;
}

.be-watermark__word {
  font-family: var(--be-font-display);
  font-weight: 700;
  font-size: 80px;
  line-height: 64px;
  letter-spacing: -6px;
  background: linear-gradient(180deg, var(--be-coral-soft) 0%, rgba(255, 139, 122, 0) 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  opacity: 0.24;
  white-space: nowrap;
}

.be-watermark__title {
  margin-top: -40px;
  font-size: 22px;
  font-weight: 700;
  line-height: 30px;
  color: var(--be-ink);
  position: relative;
}

/* Buttons */
.be-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  height: 52px;
  padding: 0 28px;
  border: none;
  border-radius: 999px;
  background: var(--be-coral-soft);
  color: var(--be-ink);
  font-size: 14px;
  font-weight: 600;
  line-height: 20px;
  white-space: nowrap;
  box-shadow: 0 8px 20px rgba(255, 139, 122, 0.28);
  transition: background 0.15s ease, transform 0.12s ease;
}

.be-btn:hover {
  background: var(--be-coral);
}

.be-btn:active:not(:disabled) {
  transform: scale(0.98);
}

.be-btn:disabled {
  background: var(--be-color-button-inactive, #e7ddd7);
  color: var(--be-muted);
  box-shadow: none;
  cursor: not-allowed;
}

.be-btn--solid {
  background: var(--be-coral);
  color: #fff;
  border-radius: 16px;
  box-shadow: 0 8px 20px rgba(255, 111, 97, 0.32);
}

.be-btn--solid:hover {
  background: #e85d50;
}

.be-btn--dark {
  background: var(--be-ink);
  color: #fff;
  box-shadow: none;
}

.be-btn--dark:hover {
  background: var(--be-maroon);
}

.be-btn--ghost {
  background: var(--be-white);
  color: var(--be-ink);
  border: 1.5px solid var(--be-blush-line);
  box-shadow: none;
}

.be-btn--ghost:hover {
  background: var(--be-blush);
  border-color: var(--be-coral-soft);
}

.be-btn--sm {
  height: 40px;
  padding: 0 18px;
}

.be-btn--block {
  width: 100%;
}

.be-link {
  color: var(--be-coral);
  font-weight: 600;
}

.be-link:hover {
  text-decoration: underline;
}

/* Fields */
.be-field {
  width: 100%;
  min-height: 56px;
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 0 16px;
  background: var(--be-white);
  border: 1.5px solid var(--be-line);
  border-radius: 16px;
  box-shadow: 0 1px 2px rgba(90, 35, 51, 0.04);
  transition: border-color 0.2s, box-shadow 0.2s;
}

.be-field:focus-within {
  border-color: var(--be-coral-soft);
  box-shadow: 0 0 0 3px rgba(255, 139, 122, 0.18);
}

.be-field.is-error {
  border-color: var(--be-color-text-error, #b81e40);
}

.be-field input,
.be-field select,
.be-field textarea {
  flex: 1;
  min-width: 0;
  border: none;
  background: none;
  outline: none;
  font-size: 14px;
  font-weight: 500;
  line-height: 22px;
  color: var(--be-ink);
  caret-color: var(--be-coral);
}

.be-field input::placeholder,
.be-field textarea::placeholder {
  color: var(--be-muted);
  font-weight: 400;
}

.be-error-text {
  margin-top: 6px;
  font-size: 12px;
  font-weight: 500;
  line-height: 18px;
  color: var(--be-color-text-error, #b81e40);
}

/* Chips */
.be-chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  height: 36px;
  padding: 0 14px;
  border-radius: 999px;
  border: 1px solid var(--be-line);
  background: var(--be-white);
  font-size: 12px;
  font-weight: 500;
  color: var(--be-ink);
  white-space: nowrap;
}

.be-chip.is-active,
.be-chip[aria-pressed="true"] {
  background: var(--be-blush);
  border-color: var(--be-coral-soft);
  color: var(--be-coral);
}

/* Cards */
.be-card {
  background: var(--be-white);
  border: 1px solid var(--be-line);
  border-radius: 24px;
}

/* Badges (cart / notifications count) */
.be-badge {
  position: absolute;
  top: -4px;
  right: -4px;
  min-width: 18px;
  height: 18px;
  padding: 0 5px;
  border-radius: 999px;
  background: var(--be-coral);
  color: #fff;
  font-size: 10px;
  font-weight: 700;
  line-height: 18px;
  text-align: center;
  box-shadow: 0 0 0 2px var(--be-canvas);
}

.be-badge[hidden] {
  display: none;
}

/* Flash messages */
.be-flash {
  margin: 16px auto;
  padding: 12px 16px;
  border-radius: 16px;
  font-size: 14px;
  font-weight: 500;
  background: var(--be-color-status-success, #dce8cf);
  color: #2b5a1f;
}

.be-flash--error {
  background: var(--be-color-status-error, #f6cad4);
  color: #7a1530;
}

.be-flash--info {
  background: var(--be-blush);
  color: var(--be-ink);
}

/* Toast */
.be-toast {
  position: fixed;
  left: 50%;
  bottom: 32px;
  z-index: 2000;
  transform: translate(-50%, 24px);
  padding: 12px 20px;
  border-radius: 999px;
  background: var(--be-ink);
  color: #fff;
  font-size: 14px;
  font-weight: 500;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s ease, transform 0.2s ease;
}

.be-toast.is-on {
  opacity: 1;
  transform: translate(-50%, 0);
}

/* Dotted heart separator */
.be-heart-sep {
  display: flex;
  align-items: center;
  gap: 16px;
  color: var(--be-coral-soft);
}

.be-heart-sep::before,
.be-heart-sep::after {
  content: "";
  flex: 1 1 0;
  border-top: 2px dotted var(--be-blush-line);
}

.be-heart-sep svg {
  width: 24px;
  height: 24px;
}

/* Search suggestions panel (shared by both shells) */
.be-suggest {
  position: absolute;
  left: 0;
  right: 0;
  top: calc(100% + 8px);
  z-index: 60;
  max-height: min(70vh, 520px);
  overflow-y: auto;
  padding: 8px;
  background: var(--be-white);
  border: 1px solid var(--be-line);
  border-radius: 20px;
  box-shadow: var(--be-shadow-soft);
}

.be-suggest[hidden] {
  display: none;
}

.be-suggest__group + .be-suggest__group {
  margin-top: 4px;
  padding-top: 4px;
  border-top: 1px dashed var(--be-line);
}

.be-suggest__label {
  padding: 8px 12px 4px;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.6px;
  text-transform: uppercase;
  color: var(--be-muted);
}

.be-suggest__item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 8px 12px;
  border-radius: 12px;
}

.be-suggest__item:hover,
.be-suggest__item.is-active {
  background: var(--be-blush);
}

.be-suggest__item img {
  width: 40px;
  height: 40px;
  border-radius: 10px;
  object-fit: cover;
  background: var(--be-canvas);
  flex-shrink: 0;
}

.be-suggest__title {
  font-size: 13px;
  font-weight: 500;
  line-height: 18px;
  color: var(--be-ink);
}

.be-suggest__sub {
  font-size: 11px;
  line-height: 16px;
  color: var(--be-muted);
}

.be-suggest__all {
  display: block;
  padding: 10px 12px;
  font-size: 13px;
  font-weight: 600;
  color: var(--be-coral);
}

.be-suggest__empty {
  padding: 16px 12px;
  font-size: 13px;
  color: var(--be-muted);
}
