/* ============================================================
   E-WARRANTY WIZARD — CSS Variables + Responsive
   Prefix : .ew-*
   Ref    : Figma Website-Customer node-id=2-820..2-868
   ============================================================ */

@import url('https://fonts.googleapis.com/css2?family=Geist:wght@400;500;600&family=Inter:wght@400;500;600&display=swap');

:root {
  --ew-primary: #0088FF;
  --ew-primary-hover: #0077E6;
  --ew-primary-light: #EFF6FF;
  --ew-primary-light-hover: #E0EFFF;
  --ew-white: #FFFFFF;
  --ew-bg: #F8FAFC;
  --ew-bg-step1: #F2F4F8;
  --ew-bg-list: #F2F4F8;
  --ew-bg-subtle: #F1F5F9;
  --ew-bg-table-header: #F1F5F9;
  --ew-border: #E2E8F0;
  --ew-border-strong: #D0D5DD;
  --ew-border-light: #EBEBEB;
  --ew-border-subtle: #E5E5E5;
  --ew-text-primary: #020618;
  --ew-text-heading: #0A0A0A;
  --ew-text-secondary: #62748E;
  --ew-text-muted: #737373;
  --ew-text-disabled: rgba(2, 6, 24, 0.4);
  --ew-text-disabled-num: rgba(2, 6, 24, 0.5);
  --ew-text-terms: rgba(2, 6, 24, 0.8);
  --ew-success: #009966;
  --ew-success-light: #ECFDF5;
  --ew-success-border: #5EE9B5;
  --ew-success-connected: #00BC7D;
  --ew-success-connected-bg: #ECFDF5;
  --ew-success-connected-border: #A4F4CF;
  --ew-warning: #FF8904;
  --ew-error: #DC2626;
  --ew-error-light: rgba(220, 38, 38, 0.1);
  --ew-slider-dot: #CBD5E1;
  --ew-slider-dot-active: #0088FF;
  --ew-shadow-xs: 0px 1px 2px rgba(0, 0, 0, 0.1);
  --ew-shadow-sm: 0px 1px 3px rgba(0, 0, 0, 0.1);
  --ew-shadow-md: 0 2px 8px rgba(0, 0, 0, 0.08);
  --ew-shadow-md-hover: 0 4px 12px rgba(0, 0, 0, 0.12);
  --ew-shadow-dropdown: 0 4px 16px rgba(0, 0, 0, 0.08);
  --ew-overlay-bg: rgba(2, 6, 24, 0.4);
  --ew-radius-sm: 6px;
  --ew-radius-md: 8px;
  --ew-radius-lg: 10px;
  --ew-radius-xl: 12px;
  --ew-radius-full: 999px;
  --ew-radius-pill: 4444px;
  --ew-space-xs: 4px;
  --ew-space-sm: 8px;
  --ew-space-md: 12px;
  --ew-space-lg: 16px;
  --ew-space-xl: 20px;
  --ew-space-2xl: 24px;
  --ew-space-3xl: 40px;
  --ew-container-max: 1440px;
  --ew-container-padding: 180px;
  --ew-container-padding-mobile: 5%;
  --ew-font-geist: 'Geist', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  --ew-font-inter: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  --ew-fs-xs: 12px;
  --ew-fs-sm: 14px;
  --ew-fs-base: 16px;
  --ew-fs-lg: 18px;
  --ew-fs-xl: 20px;
  --ew-fs-2xl: 24px;
  --ew-fw-normal: 400;
  --ew-fw-medium: 500;
  --ew-fw-semibold: 600;
  --ew-lh-xs: 16px;
  --ew-lh-sm: 20px;
  --ew-lh-base: 24px;
  --ew-lh-lg: 28px;
  --ew-lh-xl: 32px;
}

body {
  margin: 0;
}

/* ── Reset ── */
.ew-wizard-wrapper,
.ew-wizard-wrapper *,
.ew-wizard-wrapper *::before,
.ew-wizard-wrapper *::after {
  box-sizing: border-box
}

.ew-wizard-wrapper *:focus {
  outline: none
}

.ew-wizard-wrapper {
  font-family: var(--ew-font-geist);
  margin: 0;
  padding: 0;
  width: 100%;
  min-width: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.ew-wizard-wrapper.ew-panel-mode,
.ew-wizard-wrapper.ew-panel-mode *,
.ew-wizard-wrapper.ew-panel-mode *::before,
.ew-wizard-wrapper.ew-panel-mode *::after {
  box-sizing: border-box;
}

/* ============================================================
   MAIN CONTAINER
   ============================================================ */
.ew-main-container {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  padding: 48px var(--ew-container-padding);
  gap: var(--ew-space-2xl);
  width: 100%;
  min-width: 0;
  max-width: var(--ew-container-max);
  min-height: 945px;
  margin: 0 auto;
}

/* Apply grid to kill max-content propagation ONLY in panel mode */
.ew-wizard-wrapper.ew-panel-mode {
  display: grid;
  grid-template-columns: minmax(0, 100%);
  align-items: start;
}

/* Base padding for panel mode (large screens) */
.ew-wizard-wrapper.ew-panel-mode .ew-main-container {
  padding: 48px var(--ew-container-padding);
  overflow: hidden;
}

@media (max-width: 1440px) {
  /* Reduced padding for laptop screens and below to prevent squishing */
  .ew-wizard-wrapper.ew-panel-mode .ew-main-container {
    padding: 32px 40px;
  }
}

/* Strict boundary to kill max-content propagation from slider */
.ew-wizard-wrapper.ew-panel-mode .ew-main-container,
.ew-wizard-wrapper.ew-panel-mode .ew-step-panel,
.ew-wizard-wrapper.ew-panel-mode .ew-card,
.ew-wizard-wrapper.ew-panel-mode .ew-slider-section,
.ew-wizard-wrapper.ew-panel-mode .ew-slider-wrapper,
.ew-wizard-wrapper.ew-panel-mode .ew-slider-container {
  max-width: 100% !important;
}

/* ============================================================
   STEPPER
   ============================================================ */
.ew-stepper {
  display: flex;
  flex-direction: row;
  align-items: flex-start;
  padding: 0;
  gap: var(--ew-space-lg);
  width: 100%;
}

.ew-step {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  padding: 0;
  gap: var(--ew-space-md);
  flex: 1;
}

.ew-step-num {
  display: flex;
  justify-content: center;
  align-items: center;
  padding: 2px var(--ew-space-sm);
  width: 22px;
  height: 22px;
  background: var(--ew-border);
  border: 1px solid var(--ew-text-disabled-num);
  border-radius: var(--ew-radius-full);
  font-family: var(--ew-font-inter);
  font-weight: var(--ew-fw-medium);
  font-size: var(--ew-fs-xs);
  line-height: var(--ew-lh-xs);
  color: var(--ew-text-disabled-num);
  flex-shrink: 0;
}

.ew-step.active .ew-step-num,
.ew-step.done .ew-step-num {
  background: var(--ew-primary);
  border-color: var(--ew-primary);
  color: var(--ew-white);
}

.ew-step-bar-container {
  width: 100%;
  height: 6px;
  background: var(--ew-border);
  border-radius: var(--ew-radius-pill);
}

.ew-step.active .ew-step-bar-container,
.ew-step.done .ew-step-bar-container {
  background: var(--ew-primary);
}

.ew-step-label {
  font-family: var(--ew-font-geist);
  font-weight: var(--ew-fw-medium);
  font-size: var(--ew-fs-sm);
  line-height: var(--ew-lh-sm);
  color: var(--ew-text-disabled);
  white-space: normal;
  word-break: break-word;
}

.ew-step.active .ew-step-label,
.ew-step.done .ew-step-label {
  color: var(--ew-primary);
}

.ew-step-panel {
  display: none;
  width: 100%;
  min-width: 0;
}

.ew-step-panel.active {
  display: flex;
  flex-direction: column;
  gap: var(--ew-space-2xl);
}

/* ============================================================
   CARD
   ============================================================ */
.ew-card {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  padding: var(--ew-space-2xl);
  gap: var(--ew-space-xl);
  width: 100%;
  min-width: 0;
  background: var(--ew-white);
  border: 1px solid var(--ew-border);
  border-radius: var(--ew-radius-xl);
  overflow: hidden;
}

.ew-card-header {
  display: flex;
  flex-direction: row;
  align-items: center;
  padding: 0;
  gap: var(--ew-space-lg);
  width: 100%;
}

.ew-card-header-icon {
  width: 80px;
  height: 80px;
  flex-shrink: 0;
}

.ew-card-header-icon img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.ew-card-header-text {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  padding: 0;
  gap: var(--ew-space-sm);
  flex: 1;
}

.ew-card-title {
  font-family: var(--ew-font-geist);
  font-weight: var(--ew-fw-semibold);
  font-size: var(--ew-fs-xl);
  line-height: var(--ew-lh-lg);
  display: flex;
  align-items: center;
  color: var(--ew-text-primary);
}

.ew-card-subtitle {
  font-family: var(--ew-font-geist);
  font-weight: var(--ew-fw-normal);
  font-size: var(--ew-fs-base);
  line-height: var(--ew-lh-base);
  display: flex;
  align-items: center;
  color: var(--ew-text-secondary);
}

.ew-divider {
  width: 100%;
  height: 0;
  border-top: .5px solid var(--ew-border);
  flex-shrink: 0;
}

/* ============================================================
   STEP 1 — Input SN + Terms
   ============================================================ */
.ew-step1-content {
  display: flex;
  flex-direction: row;
  flex-wrap: wrap;
  align-items: flex-start;
  padding: 0;
  gap: var(--ew-space-3xl);
  width: 100%;
}

.ew-sn-container {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  padding: 0;
  gap: var(--ew-space-lg);
  flex: 1 1 350px;
}

.ew-input-group {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  padding: 0;
  gap: var(--ew-space-xs);
  width: 100%;
}

.ew-input-label {
  font-family: var(--ew-font-geist);
  font-weight: var(--ew-fw-medium);
  font-size: var(--ew-fs-sm);
  line-height: var(--ew-lh-sm);
  color: var(--ew-text-primary);
}

.ew-input-field {
  box-sizing: border-box;
  display: flex;
  align-items: center;
  padding: var(--ew-space-sm) var(--ew-space-md);
  gap: var(--ew-space-sm);
  width: 100%;
  height: 40px;
  background: var(--ew-white);
  border: 1px solid var(--ew-border);
  border-radius: var(--ew-radius-md);
  font-family: var(--ew-font-geist);
  font-weight: var(--ew-fw-normal);
  font-size: var(--ew-fs-sm);
  line-height: var(--ew-lh-sm);
  letter-spacing: -0.4px;
  color: var(--ew-text-primary);
  outline: none;
}

.ew-input-field::placeholder {
  color: var(--ew-text-secondary);
}

.ew-input-field:focus {
  border-color: var(--ew-primary);
}

.ew-input-hint {
  font-family: var(--ew-font-geist);
  font-weight: var(--ew-fw-normal);
  font-size: var(--ew-fs-xs);
  line-height: var(--ew-lh-xs);
  color: var(--ew-text-secondary);
  opacity: .8;
}

.ew-terms-container {
  box-sizing: border-box;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  padding: var(--ew-space-md);
  gap: var(--ew-space-sm);
  width: 100%;
  background: var(--ew-bg-subtle);
  border: 1px solid var(--ew-border);
  border-radius: var(--ew-radius-md);
}

.ew-terms-title {
  font-family: var(--ew-font-geist);
  font-weight: var(--ew-fw-semibold);
  font-size: var(--ew-fs-xs);
  line-height: var(--ew-lh-xs);
  font-feature-settings: 'ss02' on, 'ss03' on;
  color: var(--ew-text-terms);
}

.ew-terms-list {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  padding: 0;
  gap: var(--ew-space-sm);
  width: 100%;
}

.ew-term-item {
  display: flex;
  flex-direction: row;
  align-items: flex-start;
  padding: 0;
  gap: var(--ew-space-sm);
  width: 100%;
}

.ew-term-check {
  width: 16px;
  height: 16px;
  flex-shrink: 0;
}

.ew-term-text {
  font-family: var(--ew-font-geist);
  font-weight: var(--ew-fw-normal);
  font-size: var(--ew-fs-xs);
  line-height: var(--ew-lh-xs);
  font-feature-settings: 'ss02' on, 'ss03' on;
  color: var(--ew-text-terms);
  flex: 1;
}

/* Image container */
.ew-image-container {
  display: flex;
  position: relative;
  justify-content: center;
  align-items: center;
  padding: 0;
  gap: 10px;
  isolation: isolate;
  width: 350px;
  height: 350px;
  border-radius: var(--ew-radius-md);
  flex-shrink: 0;
}

.ew-image-container img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  z-index: 1;
}

.ew-image-glow {
  position: absolute;
  width: 187.65px;
  height: 28.34px;
  background: var(--ew-primary);
  filter: blur(38.2979px);
  z-index: 0;
  bottom: 91px;
}

/* ============================================================
   ACTION BUTTONS
   ============================================================ */
.ew-action-container {
  display: flex;
  justify-content: flex-end;
  align-items: center;
  padding: 0;
  width: 100%;
}

.ew-action-container.between {
  justify-content: space-between;
}

.ew-action-group {
  display: flex;
  align-items: center;
  gap: var(--ew-space-lg);
}

.ew-btn {
  display: inline-flex;
  justify-content: center;
  align-items: center;
  padding: 0 var(--ew-space-md);
  height: 36px;
  border-radius: var(--ew-radius-md);
  font-family: var(--ew-font-inter);
  font-weight: var(--ew-fw-medium);
  font-size: var(--ew-fs-sm);
  line-height: var(--ew-lh-sm);
  cursor: pointer;
  transition: all 0.2s ease;
  border: none;
  white-space: nowrap;
}

.ew-btn.full-width {
  flex: 1;
}

.ew-btn-primary {
  background: var(--ew-primary);
  color: var(--ew-white);
}

.ew-btn-primary:hover {
  background: var(--ew-primary-hover);
}

.ew-btn-secondary {
  background: var(--ew-white);
  border: 1px solid var(--ew-border);
  color: var(--ew-text-primary);
}

.ew-btn-secondary:hover {
  background: var(--ew-bg-subtle);
}

.ew-btn-outline {
  background: var(--ew-primary-light);
  border: 1px solid transparent;
  color: var(--ew-primary);
}

.ew-btn-outline:hover {
  background: var(--ew-primary-light-hover);
}

.ew-btn-ghost {
  background: transparent;
  border: 1px solid var(--ew-border);
  color: var(--ew-text-primary);
}

.ew-btn-ghost:hover {
  background: var(--ew-bg-subtle);
}

.ew-btn-ghost-blue {
  background: transparent;
  color: var(--ew-primary);
}

.ew-btn .fa.fa-spin {
  margin-right: .25rem;
}

/* ============================================================
   HELP / SUPPORT BOX
   ============================================================ */
.ew-help-box {
  display: flex;
  flex-direction: row;
  align-items: center;
  padding: var(--ew-space-lg);
  gap: var(--ew-space-sm);
  width: 100%;
  min-height: 105px;
  background: var(--ew-white);
  border: 1px solid var(--ew-border);
  border-radius: var(--ew-radius-xl);
}

.ew-help-icon-wrap {
  width: 72px;
  height: 72px;
  background: var(--ew-primary-light);
  border-radius: var(--ew-radius-md);
  display: flex;
  justify-content: center;
  align-items: center;
  flex-shrink: 0;
}

.ew-help-icon-wrap img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.ew-help-text {
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: flex-start;
  gap: var(--ew-space-sm);
  width: 100%;
}

.ew-help-title {
  font-family: var(--ew-font-geist);
  font-weight: var(--ew-fw-semibold);
  font-size: var(--ew-fs-sm);
  line-height: 140%;
  letter-spacing: .01em;
  color: #263238;
}

.ew-help-desc {
  font-family: var(--ew-font-geist);
  font-weight: var(--ew-fw-normal);
  font-size: var(--ew-fs-sm);
  line-height: 140%;
  letter-spacing: .01em;
  color: var(--ew-text-secondary);
}

/* ============================================================
   STEP 2 & 3 CONTENT
   ============================================================ */
.ew-step2-content {
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  align-items: flex-start;
  padding: 0;
  gap: var(--ew-space-3xl);
  width: 100%;
}

.ew-step2-left {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  padding: 0;
  gap: var(--ew-space-sm);
  flex: 1 1 350px;
  max-width: 100%;
}

.ew-step3-left {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  padding: 0;
  gap: var(--ew-space-sm);
  flex: 1 1 350px;
  max-width: 100%;
}

.ew-step2-app-name {
  font-family: var(--ew-font-geist);
  font-weight: var(--ew-fw-medium);
  font-size: var(--ew-fs-base);
  line-height: var(--ew-lh-lg);
  color: var(--ew-text-primary);
}

.ew-step2-app-desc {
  font-family: var(--ew-font-geist);
  font-weight: var(--ew-fw-normal);
  font-size: var(--ew-fs-base);
  line-height: var(--ew-lh-base);
  color: var(--ew-text-secondary);
  margin-bottom: 8px;
}

.ew-step2-features {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  padding: 0;
  gap: var(--ew-space-md);
  width: 100%;
}

.ew-feature-item {
  display: flex;
  flex-direction: row;
  align-items: center;
  padding: var(--ew-space-md);
  gap: var(--ew-space-sm);
  background: var(--ew-white);
  border: 1px solid var(--ew-border);
  border-radius: var(--ew-radius-md);
}

.ew-feature-icon {
  display: flex;
  justify-content: center;
  align-items: center;
  width: 22px;
  height: 22px;
  flex-shrink: 0;
}

.ew-feature-text {
  font-family: var(--ew-font-geist);
  font-weight: var(--ew-fw-normal);
  font-size: var(--ew-fs-sm);
  line-height: var(--ew-lh-sm);
  color: var(--ew-text-primary);
  opacity: 0.7;
}

.ew-feature-item.bordered .ew-feature-text {
  opacity: 1;
}

.ew-step2-right {
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  padding: 0;
  gap: var(--ew-space-sm);
  width: 200px;
  flex-shrink: 0;
}

.ew-step2-right.row {
  flex-direction: row;
  gap: var(--ew-space-2xl);
  width: auto;
}

.ew-qr-column {
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  padding: 0;
  gap: var(--ew-space-sm);
  width: 200px;
}

.ew-qr-box {
  width: 200px;
  height: 200px;
}

.ew-qr-box img,
.ew-qr-box svg {
  width: 100%;
  height: 100%;
  display: block;
}

.ew-store-badge {
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  width: 200px;
  height: auto;
}

.ew-store-badge img {
  width: auto;
  height: 29px;
  border: 1px solid var(--ew-border);
  border-radius: 4px;
  cursor: pointer;
}

/* ============================================================
   SLIDER / CAROUSEL
   ============================================================ */
.ew-slider-section {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  padding: 0;
  gap: var(--ew-space-lg);
  width: 100%;
  min-width: 0;
  overflow: hidden;
}

.ew-slider-title {
  font-family: var(--ew-font-inter);
  font-weight: var(--ew-fw-medium);
  font-size: var(--ew-fs-base);
  line-height: var(--ew-lh-sm);
  color: var(--ew-text-primary);
}

.ew-slider-wrapper {
  position: relative;
  width: 100%;
  display: flex;
  align-items: center;
  min-width: 0;
}

.ew-slider-container {
  width: 100%;
  overflow: hidden;
  padding: 0 var(--ew-space-xs);
  min-width: 0;
}

.ew-slider-track {
  display: flex;
  flex-direction: row;
  align-items: flex-start;
  padding: 0;
  gap: var(--ew-space-xl);
  transition: transform 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.ew-slider-arrow {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: var(--ew-white);
  border: 1px solid var(--ew-border);
  box-shadow: var(--ew-shadow-md);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  z-index: 10;
  transition: all 0.2s ease;
  flex-shrink: 0;
}

.ew-slider-arrow:hover {
  background: var(--ew-bg);
  border-color: var(--ew-slider-dot);
  box-shadow: var(--ew-shadow-md-hover);
}

.ew-slider-arrow:active {
  background: var(--ew-primary-light);
  border-color: var(--ew-primary);
}

.ew-slider-arrow.prev {
  left: -20px;
}

.ew-slider-arrow.next {
  right: -20px;
}

.ew-slider-arrow svg {
  width: 20px;
  height: 20px;
  flex-shrink: 0;
}

.ew-slider-arrow.disabled {
  opacity: 0.35;
  pointer-events: none;
  cursor: default;
}

/* Hide arrows — slider fully drag/swipe based */
.ew-slider-arrow {
  display: none
}

.ew-slider-dots {
  /* display: flex; */
  display: none;
  /* Hide dots — slider fully drag/swipe based */
  justify-content: center;
  align-items: center;
  gap: var(--ew-space-sm);
  width: 100%;
  margin-top: var(--ew-space-md);
}

.ew-slider-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--ew-slider-dot);
  cursor: pointer;
  transition: all 0.2s ease;
}

.ew-slider-dot.active {
  background: var(--ew-slider-dot-active);
  width: 24px;
  border-radius: 4px;
}

.ew-feature-card {
  box-sizing: border-box;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  padding: var(--ew-space-lg);
  gap: var(--ew-space-md);
  width: 300px;
  height: 332px;
  background: linear-gradient(180deg, var(--ew-white) 21.77%, var(--ew-primary-light) 100%);
  border: 1px solid var(--ew-border);
  border-radius: var(--ew-radius-xl);
  flex-shrink: 0;
}

.ew-feature-card-img-container {
  display: flex;
  justify-content: center;
  align-items: center;
  padding: 0;
  gap: 10px;
  width: 268px;
  height: 268px;
  border-radius: var(--ew-radius-md);
}

.ew-feature-card-img {
  width: 248px;
  height: 248px;
  object-fit: contain;
}

.ew-feature-card-title {
  width: 268px;
  height: 20px;
  font-family: var(--ew-font-geist);
  font-weight: var(--ew-fw-semibold);
  font-size: var(--ew-fs-base);
  line-height: var(--ew-lh-sm);
  display: flex;
  align-items: center;
  color: var(--ew-text-primary);
}

/* ============================================================
   MODAL OVERLAY + POPUPS
   ============================================================ */
.ew-modal-overlay {
  position: fixed;
  inset: 0;
  background: var(--ew-overlay-bg);
  backdrop-filter: blur(4px);
  display: flex;
  justify-content: center;
  align-items: center;
  z-index: 99999;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s ease;
  padding: var(--ew-space-lg);
}

.ew-modal-overlay.show {
  opacity: 1;
  pointer-events: auto;
}

.ew-modal-card {
  box-sizing: border-box;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  padding: var(--ew-space-3xl);
  gap: var(--ew-space-xl);
  width: 650px;
  max-width: 92vw;
  max-height: 90vh;
  overflow-y: auto;
  background: var(--ew-white);
  border: 1px solid var(--ew-border);
  border-radius: var(--ew-radius-xl);
  animation: ewFadeUp 0.25s ease;
}

@keyframes ewFadeUp {
  from {
    opacity: 0;
    transform: translateY(16px) scale(0.97);
  }

  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

.ew-modal-image {
  width: 280px;
  height: 280px;
  flex-shrink: 0;
  max-width: 100%;
}

.ew-modal-image img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.ew-modal-text-container {
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  padding: 0;
  gap: var(--ew-space-sm);
  width: 100%;
  max-width: 570px;
}

.ew-modal-title {
  font-family: var(--ew-font-geist);
  font-weight: var(--ew-fw-semibold);
  font-size: var(--ew-fs-xl);
  line-height: var(--ew-lh-lg);
  text-align: center;
  color: var(--ew-text-primary);
}

.ew-modal-desc {
  font-family: var(--ew-font-geist);
  font-weight: var(--ew-fw-normal);
  font-size: var(--ew-fs-base);
  line-height: var(--ew-lh-base);
  text-align: center;
  color: var(--ew-text-secondary);
}

.ew-modal-actions {
  display: flex;
  justify-content: center;
  align-items: center;
  padding: 0;
  gap: var(--ew-space-sm);
  width: 100%;
  max-width: 570px;
}

.ew-warranty-box {
  box-sizing: border-box;
  display: flex;
  justify-content: center;
  align-items: center;
  padding: var(--ew-space-md);
  gap: var(--ew-space-lg);
  background: var(--ew-success-light);
  border: 1px solid var(--ew-success-border);
  border-radius: var(--ew-radius-md);
}

.ew-warranty-box-text {
  font-family: var(--ew-font-geist);
  font-weight: var(--ew-fw-normal);
  font-size: var(--ew-fs-sm);
  line-height: var(--ew-lh-base);
  color: var(--ew-success);
}

.ew-warranty-box-icon {
  font-size: var(--ew-fs-sm);
  color: var(--ew-success);
  margin-right: var(--ew-space-xs);
}

.ew-warranty-note-box {
  box-sizing: border-box;
  display: flex;
  align-items: flex-start;
  padding: var(--ew-space-md);
  gap: var(--ew-space-lg);
  width: 100%;
  background: var(--ew-bg-subtle);
  opacity: 0.7;
  border-radius: var(--ew-radius-md);
}

.ew-warranty-note-inner {
  display: flex;
  align-items: flex-start;
  gap: var(--ew-space-sm);
  width: 100%;
}

.ew-warranty-note-text {
  font-family: var(--ew-font-geist);
  font-weight: var(--ew-fw-normal);
  font-size: var(--ew-fs-sm);
  line-height: var(--ew-lh-sm);
  color: var(--ew-text-primary);
  flex: 1;
}

.ew-warranty-note-icon i {
  font-size: var(--ew-fs-sm);
  color: var(--ew-text-primary);
  line-height: var(--ew-lh-sm);
}

.ew-error-box {
  box-sizing: border-box;
  display: flex;
  justify-content: center;
  align-items: center;
  padding: var(--ew-space-sm) var(--ew-space-lg);
  gap: var(--ew-space-sm);
  background: var(--ew-error-light);
  border: 1px solid var(--ew-error);
  border-radius: var(--ew-radius-md);
}

.ew-error-box-text {
  font-family: var(--ew-font-geist);
  font-weight: var(--ew-fw-medium);
  font-size: var(--ew-fs-base);
  line-height: var(--ew-lh-base);
  color: var(--ew-error);
}


/* ============================================================
   WARRANTY LIST STYLES
   ============================================================ */
.ew-list-page {
  font-family: var(--ew-font-inter);
  background: var(--ew-bg-list);
  padding: var(--ew-space-xl);
  min-height: calc(100vh - 60px);
}

.ew-list-container {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  padding: 28px var(--ew-space-2xl) 32px;
  gap: var(--ew-space-2xl);
  width: 100%;
  max-width: 1591px;
  margin: 0 auto;
  background: transparent;
}

.ew-list-header {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  padding: 0;
  gap: var(--ew-space-sm);
  width: 100%;
}

.ew-list-title {
  font-weight: var(--ew-fw-medium);
  font-size: var(--ew-fs-2xl);
  line-height: var(--ew-lh-xl);
  color: var(--ew-text-heading);
  margin: 0;
}

.ew-list-desc {
  font-family: var(--ew-font-inter);
  font-weight: var(--ew-fw-normal);
  font-size: var(--ew-fs-base);
  line-height: var(--ew-lh-base);
  color: var(--ew-text-muted);
  margin: 0;
}

.ew-list-desc b {
  font-weight: var(--ew-fw-semibold);
}

.ew-list-divider {
  width: 100%;
  border: 1px solid var(--ew-border);
  margin: 0;
}

.ew-list-controls {
  display: flex;
  justify-content: space-between;
  align-items: center;
  width: 100%;
  min-height: 40px;
  flex-wrap: wrap;
  gap: var(--ew-space-sm);
}

.ew-list-left-filters {
  display: flex;
  gap: var(--ew-space-sm);
  flex-wrap: wrap;
}

.ew-list-right-actions {
  display: flex;
  gap: var(--ew-space-sm);
  align-items: center;
}

.ew-list-btn-group {
  display: flex;
  gap: var(--ew-space-sm);
}

.ew-list-btn-filter {
  box-sizing: border-box;
  display: flex;
  align-items: center;
  padding: var(--ew-space-sm) var(--ew-space-md);
  gap: var(--ew-space-sm);
  height: 40px;
  background: var(--ew-white);
  border: 1px solid var(--ew-border-strong);
  border-radius: var(--ew-radius-md);
  font-weight: var(--ew-fw-medium);
  font-size: var(--ew-fs-sm);
  color: var(--ew-text-heading);
  cursor: pointer;
}

.ew-list-btn-primary {
  display: flex;
  align-items: center;
  padding: var(--ew-space-sm) var(--ew-space-md);
  gap: var(--ew-space-sm);
  height: 40px;
  background: var(--ew-primary);
  border-radius: var(--ew-radius-md);
  border: none;
  font-weight: var(--ew-fw-medium);
  font-size: var(--ew-fs-sm);
  color: var(--ew-white);
  cursor: pointer;
  text-decoration: none;
}

.ew-table-wrapper {
  box-sizing: border-box;
  display: flex;
  flex-direction: column;
  width: 100%;
  background: var(--ew-white);
  border: 1px solid var(--ew-border);
  border-radius: var(--ew-radius-md);
  overflow: hidden;
}

.ew-table-header-row {
  display: flex;
  align-items: center;
  width: 100%;
  height: 40px;
  background: var(--ew-bg-table-header);
  border-bottom: 1px solid var(--ew-border);
}

.ew-table-body-row {
  display: flex;
  align-items: center;
  width: 100%;
  min-height: 53px;
  border-bottom: 1px solid var(--ew-border);
  transition: background 0.15s ease;
  cursor: pointer;
}

.ew-table-body-row:last-child {
  border-bottom: none;
}

.ew-table-body-row:hover {
  background: var(--ew-bg);
}

.ew-th {
  padding: 0 var(--ew-space-md);
  font-family: var(--ew-font-inter);
  font-weight: var(--ew-fw-medium);
  font-size: var(--ew-fs-sm);
  line-height: var(--ew-lh-sm);
  color: var(--ew-text-primary);
  flex-shrink: 0;
  display: flex;
  align-items: center;
}

.ew-td {
  padding: var(--ew-space-md);
  font-family: var(--ew-font-inter);
  font-weight: var(--ew-fw-normal);
  font-size: var(--ew-fs-sm);
  line-height: var(--ew-lh-sm);
  color: var(--ew-text-primary);
  flex-shrink: 0;
  display: flex;
  align-items: center;
}

.ew-td-right {
  justify-content: flex-end;
}

.ew-th-right {
  justify-content: flex-end;
}

.ew-table {
  width: 100%;
  border-collapse: collapse;
}

.ew-table thead {
  background: var(--ew-bg-table-header);
  border-bottom: 1px solid var(--ew-border);
}

.ew-table th,
.ew-table td {
  padding: 10px 16px;
  font-family: var(--ew-font-inter);
  font-size: var(--ew-fs-sm);
  text-align: left;
}

.ew-table th {
  font-weight: var(--ew-fw-medium);
  color: var(--ew-text-primary);
}

.ew-table td {
  font-weight: var(--ew-fw-normal);
}

.ew-table tbody tr {
  border-bottom: 1px solid var(--ew-border);
}

.ew-table tbody tr:last-child {
  border-bottom: none;
}

.ew-badge-status {
  display: inline-flex;
  align-items: center;
  padding: 2px var(--ew-space-sm);
  gap: 6px;
  border-radius: 16px;
  font-family: var(--ew-font-inter);
  font-weight: var(--ew-fw-medium);
  font-size: var(--ew-fs-xs);
  line-height: 18px;
}

.ew-badge-status.active {
  background: #ECFDF3;
  color: #027A48;
}

.ew-badge-status.inactive {
  background: #F2F4F7;
  color: #344054;
}

.ew-badge-status.expired {
  background: #FEF3F2;
  color: #B42318;
}

.ew-badge-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  flex-shrink: 0;
}

.ew-badge-status.active .ew-badge-dot {
  background: #12B76A;
}

.ew-badge-status.inactive .ew-badge-dot {
  background: #667085;
}

.ew-badge-status.expired .ew-badge-dot {
  background: #F04438;
}

.ew-action-link {
  font-family: var(--ew-font-inter);
  font-weight: var(--ew-fw-medium);
  font-size: var(--ew-fs-sm);
  text-decoration: none;
  cursor: pointer;
}

.ew-action-link.blue {
  color: var(--ew-primary);
}

.ew-action-link.blue:hover {
  text-decoration: underline;
}

.ew-action-link.grey {
  color: #667085;
}

.ew-empty-state {
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  padding: 48px 48px 0 48px;
  gap: var(--ew-space-lg);
  width: 100%;
  font-family: var(--ew-font-inter);
  font-size: var(--ew-fs-sm);
  color: var(--ew-text-secondary);
}

.ew-empty-icon {
  width: 48px;
  height: 48px;
  opacity: 0.5;
}

.ew-filter-dropdown {
  background: var(--ew-white);
  border: 1px solid var(--ew-border);
  border-radius: var(--ew-radius-md);
  box-shadow: var(--ew-shadow-dropdown);
  z-index: 1000;
  padding: var(--ew-space-xs);
  min-width: 180px;
}

.ew-filter-option {
  padding: var(--ew-space-sm) var(--ew-space-md);
  font-family: var(--ew-font-inter);
  font-size: var(--ew-fs-sm);
  line-height: var(--ew-lh-sm);
  color: var(--ew-text-primary);
  cursor: pointer;
  border-radius: var(--ew-radius-sm);
  transition: background 0.15s ease;
}

.ew-filter-option:hover {
  background: var(--ew-bg-subtle);
}

.ew-filter-option.selected {
  background: var(--ew-primary-light);
  color: var(--ew-primary);
  font-weight: var(--ew-fw-medium)
}

/* ============================================================
   LIST TABLE — SN link, checkbox, device badge
   ============================================================ */
.ew-sn-link {
  text-decoration: underline;
  cursor: pointer;
  color: var(--ew-text-primary);
  font-weight: var(--ew-fw-medium);
  font-size: var(--ew-fs-sm);
  line-height: var(--ew-lh-sm);
}

.ew-checkbox-box {
  width: 16px;
  height: 16px;
  background: var(--ew-white);
  border: 1px solid var(--ew-border-subtle);
  border-radius: 4px;
  box-shadow: var(--ew-shadow-xs);
  flex-shrink: 0;
}

.ew-device-badge {
  box-sizing: border-box;
  display: inline-flex;
  justify-content: center;
  align-items: center;
  padding: 2px 6px;
  gap: var(--ew-space-xs);
  height: 22px;
  border-radius: var(--ew-radius-md);
  font-family: var(--ew-font-inter);
  font-weight: var(--ew-fw-medium);
  font-size: var(--ew-fs-xs);
  line-height: var(--ew-lh-xs);
  flex-shrink: 0;
}

.ew-device-badge.connected {
  background: var(--ew-success-connected-bg);
  border: 1px solid var(--ew-success-connected-border);
  color: var(--ew-success-connected);
}

.ew-device-badge.disconnected {
  background: var(--ew-bg-subtle);
  border: 1px solid var(--ew-border);
  color: var(--ew-text-secondary);
}

.ew-device-btn-connect,
.ew-device-btn-activate {
  box-sizing: border-box;
  display: inline-flex;
  justify-content: center;
  align-items: center;
  padding: var(--ew-space-sm) var(--ew-space-md);
  gap: var(--ew-space-sm);
  height: 32px;
  background: var(--ew-white);
  border: 1px solid var(--ew-border-strong);
  border-radius: var(--ew-radius-md);
  font-family: var(--ew-font-inter);
  font-weight: var(--ew-fw-medium);
  font-size: var(--ew-fs-sm);
  line-height: var(--ew-lh-sm);
  color: var(--ew-text-heading);
  cursor: pointer;
  transition: background 0.15s ease;
  text-decoration: none;
}

.ew-device-btn-connect:hover,
.ew-device-btn-activate:hover {
  background: var(--ew-bg-subtle);
}

/* ============================================================
   DETAIL MODAL
   ============================================================ */
.ew-detail-overlay {
  position: fixed;
  inset: 0;
  background: var(--ew-overlay-bg);
  backdrop-filter: blur(4px);
  display: flex;
  justify-content: center;
  align-items: center;
  z-index: 99999;
  padding: var(--ew-space-lg);
}

.ew-detail-card {
  box-sizing: border-box;
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  padding: var(--ew-space-2xl);
  gap: var(--ew-space-2xl);
  width: 751px;
  max-width: 92vw;
  max-height: 90vh;
  overflow-y: auto;
  background: var(--ew-white);
  border: 1px solid var(--ew-border-subtle);
  box-shadow: var(--ew-shadow-sm);
  border-radius: var(--ew-radius-lg);
  animation: ewFadeUp 0.25s ease;
}

.ew-detail-header {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  padding: 0;
  gap: 10px;
  width: 100%;
}

.ew-detail-title {
  font-family: var(--ew-font-inter);
  font-weight: var(--ew-fw-semibold);
  font-size: var(--ew-fs-xl);
  line-height: var(--ew-lh-lg);
  display: flex;
  align-items: center;
  color: var(--ew-text-heading);
  flex: 1;
}

.ew-detail-close {
  width: 24px;
  height: 24px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.ew-detail-device-info {
  box-sizing: border-box;
  display: flex;
  align-items: center;
  padding: var(--ew-space-sm);
  gap: var(--ew-space-lg);
  width: 100%;
  border: 1px solid var(--ew-border-light);
  border-radius: var(--ew-radius-md);
}

.ew-detail-device-img {
  width: 64px;
  height: 64px;
  flex-shrink: 0;
  border-radius: 4px;
  overflow: hidden;
}

.ew-detail-device-img img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.ew-detail-device-meta {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  padding: 0;
  gap: var(--ew-space-xs);
  flex: 1;
}

.ew-detail-device-name {
  font-family: var(--ew-font-inter);
  font-weight: var(--ew-fw-semibold);
  font-size: var(--ew-fs-base);
  line-height: var(--ew-lh-base);
  color: var(--ew-text-heading);
  width: 100%;
}

.ew-detail-sn-row {
  display: flex;
  align-items: center;
  padding: 0;
  gap: var(--ew-space-xs);
}

.ew-detail-sn-badge {
  box-sizing: border-box;
  display: flex;
  justify-content: center;
  align-items: center;
  padding: var(--ew-space-xs);
  width: 25px;
  height: 22px;
  background: var(--ew-white);
  border: 1px solid var(--ew-border-subtle);
  border-radius: 4px;
  font-family: var(--ew-font-inter);
  font-weight: var(--ew-fw-medium);
  font-size: var(--ew-fs-xs);
  line-height: var(--ew-lh-xs);
  color: var(--ew-text-muted);
}

.ew-detail-sn-value {
  font-family: var(--ew-font-inter);
  font-weight: var(--ew-fw-normal);
  font-size: var(--ew-fs-sm);
  line-height: var(--ew-lh-sm);
  color: var(--ew-text-muted);
}

.ew-detail-fields {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  padding: 0;
  gap: var(--ew-space-xl);
  width: 100%;
}

.ew-detail-field-row {
  display: flex;
  align-items: flex-end;
  padding: 0;
  gap: var(--ew-space-sm);
  width: 100%;
}

.ew-detail-field {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  padding: 0;
  gap: var(--ew-space-xs);
  flex: 1;
}

.ew-detail-label {
  font-family: var(--ew-font-inter);
  font-weight: var(--ew-fw-medium);
  font-size: var(--ew-fs-sm);
  line-height: var(--ew-lh-sm);
  display: flex;
  align-items: center;
  color: var(--ew-text-primary);
}

.ew-detail-input {
  box-sizing: border-box;
  display: flex;
  align-items: center;
  padding: var(--ew-space-sm) var(--ew-space-md);
  gap: var(--ew-space-sm);
  width: 100%;
  height: 40px;
  background: var(--ew-white);
  border: 1px solid var(--ew-border);
  border-radius: var(--ew-radius-sm);
  font-family: var(--ew-font-inter);
  font-weight: var(--ew-fw-normal);
  font-size: var(--ew-fs-sm);
  line-height: var(--ew-lh-sm);
  color: var(--ew-text-secondary);
  outline: none;
}

.ew-detail-btn-action,
.ew-detail-btn-upload {
  box-sizing: border-box;
  display: flex;
  justify-content: center;
  align-items: center;
  padding: var(--ew-space-sm) var(--ew-space-md);
  gap: var(--ew-space-sm);
  height: 40px;
  background: var(--ew-white);
  border: 1px solid var(--ew-border-strong);
  border-radius: var(--ew-radius-md);
  font-family: var(--ew-font-inter);
  font-weight: var(--ew-fw-medium);
  font-size: var(--ew-fs-sm);
  line-height: var(--ew-lh-sm);
  color: var(--ew-text-heading);
  cursor: pointer;
  white-space: nowrap;
  flex-shrink: 0;
  transition: background 0.15s ease;
}

.ew-detail-btn-action:hover,
.ew-detail-btn-upload:hover {
  background: var(--ew-bg-subtle);
}

/* ── Pagination & Per-page ── */
.ew-table-footer {
  display: flex;
  flex-direction: row;
  justify-content: space-between;
  align-items: center;
  padding: var(--ew-space-md) var(--ew-space-lg);
  width: 100%;
  min-height: 40px;
  gap: var(--ew-space-sm);
  flex-wrap: wrap;
}

.ew-info-text {
  font-family: var(--ew-font-inter);
  font-size: var(--ew-fs-sm);
  color: var(--ew-text-secondary);
  flex-shrink: 0;
}

.ew-pagination {
  display: flex;
  flex-direction: row;
  align-items: center;
  gap: 4px;
  flex-shrink: 0;
}

.ew-page-btn {
  display: inline-flex;
  justify-content: center;
  align-items: center;
  min-width: 32px;
  height: 32px;
  padding: 0 8px;
  background: var(--ew-white);
  border: 1px solid var(--ew-border);
  border-radius: var(--ew-radius-sm);
  font-family: var(--ew-font-inter);
  font-size: var(--ew-fs-sm);
  color: var(--ew-text-primary);
  cursor: pointer;
  transition: all 0.15s ease;
}

.ew-page-btn:hover {
  background: var(--ew-bg-subtle);
  border-color: var(--ew-primary);
}

.ew-page-btn.active {
  background: var(--ew-primary);
  border-color: var(--ew-primary);
  color: var(--ew-white);
}

.ew-page-dots {
  display: inline-flex;
  justify-content: center;
  align-items: center;
  min-width: 24px;
  height: 32px;
  font-family: var(--ew-font-inter);
  font-size: var(--ew-fs-sm);
  color: var(--ew-text-secondary);
}

.ew-per-page {
  display: flex;
  flex-direction: row;
  align-items: center;
  gap: var(--ew-space-sm);
}

.ew-per-page-label {
  font-family: var(--ew-font-inter);
  font-size: var(--ew-fs-sm);
  color: var(--ew-text-primary);
}

.ew-per-page-select {
  padding: 4px 8px;
  height: 32px;
  border: 1px solid var(--ew-border);
  border-radius: var(--ew-radius-sm);
  font-family: var(--ew-font-inter);
  font-size: var(--ew-fs-sm);
  color: var(--ew-text-primary);
  background: var(--ew-white);
  cursor: pointer;
  outline: none;
}

.ew-per-page-select:focus {
  border-color: var(--ew-primary);
}

.ew-loading {
  display: flex;
  justify-content: center;
  align-items: center;
  padding: var(--ew-space-3xl);
  padding-bottom: 0;
  font-family: var(--ew-font-inter);
  font-size: var(--ew-fs-sm);
  color: var(--ew-text-secondary);
  width: 100%;
}

/* ── Toast / Sonner Loading ── */
.ew-toast-overlay {
  position: fixed;
  inset: 0;
  background: var(--ew-overlay-bg);
  backdrop-filter: blur(1px);
  display: flex;
  justify-content: center;
  align-items: center;
  z-index: 999999;
}

.ew-toast-card {
  box-sizing: border-box;
  display: flex;
  flex-direction: row;
  justify-content: center;
  align-items: center;
  padding: var(--ew-space-lg);
  gap: 6px;
  width: auto;
  min-width: 200px;
  max-width: 92vw;
  min-height: 52px;
  background: var(--ew-white);
  border: 1px solid var(--ew-border-subtle);
  box-shadow: 0px 10px 15px -3px rgba(0, 0, 0, 0.1), 0px 4px 6px -4px rgba(0, 0, 0, 0.1);
  border-radius: var(--ew-radius-lg);
  animation: ewToastIn 0.3s ease;
}

@keyframes ewToastIn {
  from {
    opacity: 0;
    transform: translateY(-12px) scale(0.95);
  }

  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

.ew-toast-spinner {
  width: 16px;
  height: 16px;
  flex-shrink: 0;
  animation: ewSpin 0.8s linear infinite;
}

@keyframes ewSpin {
  from {
    transform: rotate(0deg);
  }

  to {
    transform: rotate(360deg);
  }
}

.ew-toast-text {
  font-family: var(--ew-font-inter);
  font-weight: var(--ew-fw-normal);
  font-size: var(--ew-fs-sm);
  line-height: var(--ew-lh-sm);
  color: var(--ew-text-heading);
  flex: 1;
}

/* ── Public Header (Sticky) ──
   Figma: Before Login — Language divider Daftar/Masuk
   Figma: After Login  — Language divider Avatar+Nama
   ====================================================== */
.ew-pub-header {
  position: sticky;
  top: 0;
  z-index: 10000;
  height: 72px;
  background: var(--ew-white);
  box-shadow: var(--ew-shadow-md), 0px 2px 4px -1px rgba(0, 0, 0, 0.06);
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
}

.ew-pub-header-inner {
  display: flex;
  flex-direction: row;
  align-items: center;
  justify-content: space-between;
  padding: 16px;
  gap: 40px;
  width: 100%;
  max-width: 1280px;
  height: 72px;
}

.ew-pub-right {
  display: flex;
  flex-direction: row;
  align-items: center;
}

.ew-pub-logo {
  display: flex;
  align-items: center;
  height: auto;
  max-height: 18px;
  flex-shrink: 0;
  text-decoration: none;
}

.ew-pub-logo img {
  height: 20px;
  width: auto;
  display: block;
}

.ew-pub-spacer {
  flex: 1;
}

.ew-pub-actions {
  display: flex;
  flex-direction: row;
  align-items: center;
  gap: 24px;
  flex-shrink: 0;
}

/* ── Language Selector ── */
.ew-pub-lang {
  position: relative;
  flex-shrink: 0;
  cursor: pointer;
}

.ew-pub-lang__btn {
  display: flex;
  flex-direction: row;
  align-items: center;
  gap: 8px;
  background: var(--ew-white);
  border-radius: 2px;
  border: none;
  cursor: pointer;
  outline: none;
  font-family: var(--ew-font-inter);
}

.ew-pub-lang__flag {
  width: 20px;
  height: 20px;
  flex-shrink: 0;
  border: 1px solid var(--ew-border);
  border-radius: 9999px;
}

.ew-pub-lang__text {
  flex: 1;
  text-align: left;
  font-size: var(--ew-fs-sm);
  font-weight: var(--ew-fw-medium);
  line-height: 20px;
  color: var(--ew-text-primary);
}

.ew-pub-lang__chev {
  width: 16px;
  height: 16px;
  flex-shrink: 0;
  transition: transform .2s;
}

.ew-pub-lang.open .ew-pub-lang__chev {
  transform: rotate(180deg);
}

.ew-pub-lang__menu {
  position: absolute;
  top: calc(100% + 4px);
  right: 0;
  z-index: 200;
  min-width: 194px;
  background: var(--ew-white);
  border: 1px solid var(--ew-border);
  border-radius: var(--ew-radius-md);
  box-shadow: var(--ew-shadow-dropdown);
  padding: 4px;
  display: none;
}

.ew-pub-lang__menu.open {
  display: block;
}

.ew-pub-lang__item {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 12px;
  border-radius: var(--ew-radius-sm);
  font-family: var(--ew-font-inter);
  font-size: var(--ew-fs-sm);
  font-weight: var(--ew-fw-medium);
  color: var(--ew-text-primary);
  cursor: pointer;
}

.ew-pub-lang__item .ew-pub-lang__flag {
  flex-shrink: 0;
}

.ew-pub-lang__item:hover {
  background: var(--ew-bg-subtle);
}

/* ── Divider ── */
.ew-pub-divider {
  width: 0;
  height: 24px;
  border-left: 2px solid #E5E5E5;
  flex-shrink: 0;
}

/* ── Daftar ── */
.ew-pub-btn-daftar {
  display: flex;
  flex-direction: row;
  justify-content: center;
  align-items: center;
  padding: 8px 12px;
  gap: 6px;
  width: 66px;
  height: 40px;
  background: var(--ew-white);
  border: 1px solid var(--ew-border);
  border-radius: var(--ew-radius-md);
  font-family: var(--ew-font-inter);
  font-size: var(--ew-fs-sm);
  font-weight: var(--ew-fw-medium);
  line-height: 20px;
  color: #0F172B;
  cursor: pointer;
  white-space: nowrap;
  text-decoration: none;
  transition: background .15s;
}

.ew-pub-btn-daftar:hover {
  background: var(--ew-bg);
}

/* ── Masuk ── */
.ew-pub-btn-masuk {
  display: flex;
  flex-direction: row;
  justify-content: center;
  align-items: center;
  padding: 8px 12px;
  gap: 6px;
  width: 69px;
  height: 40px;
  background: #3F87B9;
  border: none;
  border-radius: var(--ew-radius-md);
  font-family: var(--ew-font-inter);
  font-size: var(--ew-fs-sm);
  font-weight: var(--ew-fw-medium);
  line-height: 20px;
  color: var(--ew-white);
  cursor: pointer;
  white-space: nowrap;
  text-decoration: none;
  transition: opacity .15s;
}

.ew-pub-btn-masuk:hover {
  opacity: .9;
}

/* ── User (Logged In) ── */
.ew-pub-user {
  display: flex;
  flex-direction: row;
  align-items: center;
  gap: 8px;
  flex-shrink: 0;
}

.ew-pub-avatar {
  display: flex;
  justify-content: center;
  align-items: center;
  width: 28px;
  height: 28px;
  background: var(--ew-white);
  border: 1px solid var(--ew-border);
  border-radius: 9999px;
  overflow: hidden;
  flex-shrink: 0;
}

.ew-pub-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 9999px;
}

.ew-pub-name {
  font-family: var(--ew-font-inter);
  font-size: var(--ew-fs-sm);
  font-weight: var(--ew-fw-medium);
  line-height: 20px;
  color: var(--ew-text-primary);
}

/* ── Wizard area ── */
.ew-pub-wiz-wrap {
  min-height: calc(100vh - 72px);
}

/* ── Mobile Toggle (hamburger) — default hidden on all screens */
.ew-pub-mobile-toggle {
  display: none;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  width: 40px;
  height: 40px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 8px;
  gap: 5px;
  flex-shrink: 0;
  position: relative;
  z-index: 10001;
}

.ew-pub-mobile-toggle span {
  display: block;
  width: 24px;
  height: 2px;
  background: var(--ew-text-primary);
  border-radius: 2px;
  transition: transform .2s, opacity .2s;
}

.ew-pub-mobile-toggle.open span:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}

.ew-pub-mobile-toggle.open span:nth-child(2) {
  opacity: 0;
}

.ew-pub-mobile-toggle.open span:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

.ew-pub-mobile-menu {
  display: none;
  position: fixed;
  top: 72px;
  right: 0;
  width: 280px;
  background: var(--ew-white);
  border: 1px solid var(--ew-border);
  border-radius: 0 0 0 var(--ew-radius-xl);
  box-shadow: var(--ew-shadow-dropdown);
  padding: var(--ew-space-lg);
  z-index: 10000;
  flex-direction: column;
  gap: var(--ew-space-md);
}

.ew-pub-mobile-menu.open {
  display: flex;
}

.ew-pub-mobile-menu .ew-pub-btn-daftar,
.ew-pub-mobile-menu .ew-pub-btn-masuk {
  width: 100%;
  justify-content: center;
}

.ew-pub-mobile-menu .ew-pub-mobile-user {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 8px 0;
}

/* ============================================================
   RESPONSIVE BREAKPOINTS
   ============================================================ */

/* ── Small Desktop (≤1280px) ── */
@media (max-width: 1280px) {
  .ew-main-container {
    padding: 48px 40px;
  }
}

/* ── Tablet (≤1024px) ── */
@media (max-width: 1024px) {
  .ew-main-container {
    padding: 32px var(--ew-container-padding-mobile);
  }

  .ew-step1-content {
    flex-direction: column;
    gap: var(--ew-space-2xl);
  }

  .ew-image-container {
    width: 100%;
    height: auto;
    max-height: 300px;
  }

  .ew-image-container img {
    max-height: 300px;
  }

  .ew-step2-content {
    flex-direction: column;
    gap: var(--ew-space-2xl);
  }

  .ew-step2-left,
  .ew-step3-left {
    width: 100%;
  }

  .ew-step2-right,
  .ew-step2-right.row {
    width: 100%;
    flex-direction: row;
    justify-content: center;
    gap: var(--ew-space-2xl);
  }

  .ew-card-header {
    flex-direction: column;
    align-items: flex-start;
  }

  .ew-help-box {
    flex-direction: column;
    align-items: flex-start;
    min-height: auto;
  }

  .ew-modal-card {
    padding: var(--ew-space-2xl);
    width: 100%;
  }

  .ew-modal-image {
    width: 200px;
    height: 200px;
  }

  /* ── Responsive Header ── */
  .ew-pub-header {
    padding: 0 var(--ew-space-xl);
  }

  .ew-pub-header-inner {
    gap: 24px;
  }

  .ew-pub-logo img {
    height: 20px;
  }

  .ew-pub-lang__btn {
    width: auto;
  }
}

@media (max-width: 1024px) and (min-width: 641px) {
  .ew-pub-header {
    padding: 0 var(--ew-space-lg);
    height: auto;
    min-height: 64px;
  }

  .ew-pub-header-inner {
    gap: 16px;
    height: auto;
    min-height: 64px;
    padding: 8px 16px;
  }

  .ew-pub-logo img {
    height: 20px;
  }

  .ew-pub-actions {
    gap: 16px;
  }

  .ew-pub-lang__btn {
    width: auto;
    padding: 4px 10px;
  }

  .ew-pub-lang__text {
    font-size: 13px;
  }

  .ew-pub-btn-daftar,
  .ew-pub-btn-masuk {
    height: 36px;
    width: auto;
    padding: 8px 10px;
    font-size: 13px;
  }

  .ew-pub-divider {
    height: 20px;
  }

  .ew-pub-wiz-wrap {
    min-height: calc(100vh - 64px);
  }
}

/* ── Mobile (≤640px) ── */
@media (max-width: 640px) {

  /* Sembunyikan nama company di mobile */
  .ew-pub-name {
    display: none;
  }

  .ew-main-container {
    padding: 20px var(--ew-space-lg);
    gap: var(--ew-space-lg);
  }

  .ew-stepper {
    gap: var(--ew-space-sm);
  }

  .ew-step-label {
    font-size: var(--ew-fs-xs);
  }

  .ew-card {
    padding: var(--ew-space-lg);
  }

  .ew-card-title {
    font-size: var(--ew-fs-lg);
    line-height: var(--ew-lh-base);
  }

  .ew-card-subtitle {
    font-size: var(--ew-fs-sm);
    line-height: var(--ew-lh-sm);
  }

  .ew-card-header-icon {
    width: 56px;
    height: 56px;
  }

  .ew-step2-right,
  .ew-step2-right.row {
    flex-direction: column;
    align-items: center;
  }

  .ew-qr-box {
    width: 160px;
    height: 160px;
  }

  .ew-slider-arrow.prev {
    left: -12px;
  }

  .ew-slider-arrow.next {
    right: -12px;
  }

  .ew-slider-arrow {
    width: 32px;
    height: 32px;
  }

  .ew-slider-arrow svg {
    width: 16px;
    height: 16px;
  }

  .ew-feature-card {
    width: 260px;
    height: auto;
  }

  .ew-feature-card-img-container {
    width: 100%;
    height: auto;
  }

  .ew-feature-card-img {
    width: 100%;
    height: auto;
    max-height: 200px;
  }

  .ew-feature-card-title {
    width: 100%;
  }

  .ew-modal-card {
    padding: var(--ew-space-xl);
    gap: var(--ew-space-lg);
  }

  .ew-modal-image {
    width: 160px;
    height: 160px;
  }

  .ew-modal-title {
    font-size: var(--ew-fs-lg);
    line-height: var(--ew-lh-base);
  }

  .ew-modal-desc {
    font-size: var(--ew-fs-sm);
    line-height: var(--ew-lh-sm);
  }

  .ew-modal-actions {
    flex-direction: column;
  }

  .ew-modal-actions .ew-btn {
    width: 100%;
  }

  .ew-btn.full-width {
    flex: inherit;
  }

  .ew-action-container {
    flex-wrap: wrap;
    gap: var(--ew-space-sm);
  }

  .ew-action-group {
    flex-wrap: wrap;
    gap: var(--ew-space-sm);
  }

  /* ── Responsive Header ── */
  .ew-pub-header {
    height: auto;
    min-height: 56px;
  }

  .ew-pub-header-inner {
    height: auto;
    min-height: 56px;
    padding: 8px 16px;
    gap: 8px;
  }

  .ew-pub-logo img {
    height: 20px;
  }

  .ew-pub-actions {
    gap: 8px;
  }

  /* Sembunyikan desktop items — pakai mobile toggle */
  .ew-pub-lang__btn {
    width: auto;
    padding: 4px 6px;
    gap: 4px;
    height: 28px;
  }

  .ew-pub-lang__text {
    font-size: 12px;
  }

  .ew-pub-divider {
    display: none;
  }

  .ew-pub-btn-daftar,
  .ew-pub-btn-masuk {
    display: none;
  }

  /* Hamburger tampil hanya jika guest di mobile */
  .ew-pub-mobile-toggle.is-guest {
    display: flex;
  }

  .ew-pub-wiz-wrap {
    min-height: calc(100vh - 56px);
  }
}

@media (max-width: 480px) {
  .ew-pub-lang__text {
    display: none;
  }

  .ew-pub-mobile-menu {
    width: -moz-available;
    width: -webkit-fill-available;
    width: fill-available;
    top: 56px;
    border-radius: 0;
  }

  .ew-pub-lang__btn {
    padding: 4px 6px;
  }
}