body[data-layout="admin"] [data-admin-mobile-menu-toggle] {
  display: none;
}

@media (prefers-reduced-motion: no-preference) {
  body[data-layout="showcase"] [data-mobile-navigation] a.is-tapping {
    animation: kaiocell-menu-option-tap 160ms cubic-bezier(0.2, 0.75, 0.25, 1);
    border-radius: 0.75rem;
  }

  @keyframes kaiocell-menu-option-tap {
    0% { background-color: transparent; color: inherit; transform: translateX(0) scale(1); }
    45% { background-color: rgb(0 103 106 / 14%); color: rgb(0 103 106); transform: translateX(5px) scale(0.985); }
    100% { background-color: rgb(0 103 106 / 8%); color: rgb(0 103 106); transform: translateX(0) scale(1); }
  }
}

@media (hover: hover) and (pointer: fine) {
  body[data-layout="showcase"] [data-mobile-navigation] a:hover {
    background-color: rgb(0 103 106 / 8%);
    color: #00676a;
  }
}

body[data-layout="admin"] [data-mobile-menu-logout],
body[data-layout="admin"] [data-mobile-menu-divider] {
  display: none;
}

@media (max-width: 767px) {
  body[data-layout="showcase"] header > .max-w-7xl,
  body[data-layout="detail"] header > .max-w-7xl {
    position: relative;
  }

  body[data-layout="showcase"] [data-showcase-brand],
  body[data-layout="detail"] [data-showcase-brand] {
    position: absolute;
    top: 50%;
    left: 50%;
    z-index: 1;
    transform: translate(-50%, -50%);
  }

  body[data-layout="showcase"] [data-showcase-brand] > a,
  body[data-layout="detail"] [data-showcase-brand] > a {
    position: relative;
    display: block;
    width: 8rem;
    height: 3.5rem;
    overflow: hidden;
  }

  body[data-layout="showcase"] [data-showcase-brand] img,
  body[data-layout="detail"] [data-showcase-brand] img {
    position: absolute;
    top: 50%;
    left: 50%;
    width: auto;
    height: 8rem;
    max-width: none;
    object-fit: contain;
    transform: translate(-50%, -50%);
  }
  body[data-layout="showcase"] [data-mobile-menu-toggle],
  body[data-layout="detail"] [data-mobile-menu-toggle] {
    position: relative;
    z-index: 2;
  }

  body[data-layout="showcase"] [data-mobile-navigation] a,
  body[data-layout="detail"] [data-mobile-navigation] a {
    min-height: 44px;
  }
}
@media (max-width: 767px) {
  body[data-layout="admin"] {
    min-width: 320px;
    overflow-x: hidden;
  }

  body[data-layout="admin"] [data-admin-sidebar] {
    position: sticky !important;
    top: 0;
    z-index: 50;
    inset: auto !important;
    width: 100% !important;
    height: auto !important;
    box-shadow: none !important;
    background: #fff;
    border-bottom: 1px solid #e7eded;
  }

  body[data-layout="admin"] [data-admin-sidebar] > div:first-child {
    display: block;
  }

  body[data-layout="admin"] [data-admin-brand] {
    position: relative;
    display: flex !important;
    align-items: center;
    justify-content: center !important;
    height: 4.5rem !important;
    padding: 0 1rem !important;
  }

  body[data-layout="admin"] [data-admin-brand] img {
    position: absolute;
    top: 50%;
    left: 50%;
    width: 10rem !important;
    height: 3.5rem !important;
    max-width: none;
    object-fit: cover;
    object-position: center;
    transform: translate(-50%, -50%);
  }

  body[data-layout="admin"] [data-admin-mobile-menu-toggle] {
    position: absolute;
    top: 50%;
    left: 0.75rem;
    z-index: 2;
    display: inline-flex;
    width: 2.75rem;
    height: 2.75rem;
    align-items: center;
    justify-content: center;
    border: 1px solid #e1e9e9;
    border-radius: 0.875rem;
    background: #f7f9f9;
    color: #007d80;
    cursor: pointer;
    transform: translateY(-50%);
  }

  body[data-layout="admin"] [data-admin-mobile-menu-toggle]:focus-visible {
    outline: 2px solid #007d80;
    outline-offset: 2px;
  }

  body[data-layout="admin"] [data-admin-sidebar] > div:first-child > div:nth-child(2) {
    display: none;
  }

  body[data-layout="admin"] [data-admin-sidebar] nav {
    position: fixed;
    top: 4.5rem;
    right: 0.75rem;
    left: 0.75rem;
    z-index: 60;
    display: none !important;
    flex-direction: column !important;
    gap: 0.25rem;
    max-height: calc(100dvh - 5.25rem);
    overflow-y: auto;
    padding: 0.75rem;
    border: 1px solid #e7eded;
    border-radius: 1rem;
    background: #fff;
    box-shadow: 0 12px 28px rgba(20, 43, 43, 0.16);
    white-space: normal;
  }

  body[data-layout="admin"] [data-admin-sidebar] nav[data-mobile-open="true"] {
    display: flex !important;
  }

  body[data-layout="admin"] [data-admin-sidebar] nav a {
    display: flex;
    min-height: 2.75rem;
    width: 100%;
    align-items: center;
    flex: 0 0 auto;
  }

  body[data-layout="admin"] [data-admin-sidebar] nav [data-mobile-menu-logout] {
    display: flex !important;
  }

  body[data-layout="admin"] [data-mobile-menu-divider] {
    display: block;
    height: 1px;
    margin: 0.375rem 0;
    background: #e7eded;
  }

  body[data-layout="admin"] [data-admin-sidebar] > div:last-child {
    display: none;
  }

  body[data-layout="admin"] [data-settings-content] {
    padding-bottom: calc(6rem + env(safe-area-inset-bottom)) !important;
  }

  body[data-layout="admin"] [data-settings-actions] {
    position: fixed;
    right: 0;
    bottom: 0;
    left: 0;
    z-index: 45;
    display: grid !important;
    grid-template-columns: minmax(0, 0.85fr) minmax(0, 1.15fr);
    align-items: stretch;
    gap: 0.5rem;
    padding: 0.75rem;
    padding-bottom: calc(0.75rem + env(safe-area-inset-bottom));
    border-top: 1px solid #e7eded;
    background: rgba(255, 255, 255, 0.96);
    box-shadow: 0 -8px 24px rgba(20, 43, 43, 0.08);
    backdrop-filter: blur(12px);
  }

  body[data-layout="admin"] [data-settings-actions] button {
    min-width: 0;
    min-height: 3rem;
    justify-content: center;
    gap: 0.375rem;
    padding: 0.5rem 0.625rem !important;
    text-align: center;
    font-size: 0.75rem;
    line-height: 1.15;
  }

  body[data-layout="admin"] [data-admin-frame] {
    padding-left: 0 !important;
  }

  body[data-layout="admin"] [data-edit-footer] {
    left: 0 !important;
    right: 0 !important;
    width: auto;
    height: auto !important;
    min-height: 0;
    display: grid !important;
    grid-template-columns: minmax(0, 0.85fr) minmax(0, 1.15fr);
    align-items: stretch;
    gap: 8px;
    padding: 10px 12px calc(10px + env(safe-area-inset-bottom));
  }

  body[data-layout="admin"] [data-edit-footer] > div:first-child {
    display: none;
  }

  body[data-layout="admin"] [data-edit-footer] > div:last-child {
    display: contents;
  }

  body[data-layout="admin"] [data-edit-footer] button {
    min-width: 0;
    min-height: 48px;
    justify-content: center;
    gap: 5px;
    padding: 8px 10px !important;
    text-align: center;
    font-size: 12px;
    line-height: 1.2;
  }

  body[data-layout="admin"] main {
    min-width: 0;
    padding-left: 12px;
    padding-right: 12px;
    overflow-x: auto;
  }
}

.checkbox-hit-area {
  position: relative;
  display: inline-flex;
  width: 1rem;
  height: 1rem;
  vertical-align: middle;
}

.checkbox-hit-area::after {
  position: absolute;
  inset: -4px;
  content: "";
}

.checkbox-hit-area > input {
  position: relative;
  z-index: 1;
}

@media (max-width: 639px) {
  body[data-layout="showcase"] {
    padding-bottom: calc(64px + env(safe-area-inset-bottom));
  }

  body[data-layout="showcase"] main {
    padding-left: 16px;
    padding-right: 16px;
  }

  body[data-layout="showcase"] h1 {
    font-size: 30px;
    line-height: 38px;
    letter-spacing: -0.02em;
  }

  body[data-layout="showcase"] .showcase-hero h1 {
    font-size: clamp(2.25rem, 10vw, 2.75rem);
    line-height: 1.08;
    letter-spacing: -0.035em;
  }

  body[data-layout="showcase"] .showcase-hero .font-body-lg {
    font-size: 17px;
    line-height: 1.55;
  }

  body[data-layout="showcase"] .showcase-hero__grid {
    row-gap: 0.75rem;
  }

  body[data-layout="showcase"] .showcase-hero__copy {
    display: contents;
  }

  body[data-layout="showcase"] .showcase-hero__title {
    order: 1;
  }

  body[data-layout="showcase"] .showcase-hero__lead {
    order: 2;
  }

  body[data-layout="showcase"] .showcase-hero__visual {
    order: 3;
    margin-top: 0;
  }

  body[data-layout="showcase"] .showcase-hero__benefits {
    order: 4;
  }

  body[data-layout="showcase"] .showcase-hero__actions {
    order: 5;
  }

  body[data-layout="showcase"] [data-product-grid] {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
  }

  body[data-layout="showcase"] > .fixed.bottom-0 {
    padding-bottom: calc(0.5rem + env(safe-area-inset-bottom));
  }

  body[data-layout="showcase"] [data-product-category-tabs] {
    align-self: stretch;
    box-sizing: border-box;
    display: flex;
    flex-wrap: nowrap;
    justify-content: flex-start;
    width: 100%;
    min-width: 0;
    max-width: 100%;
    overflow-x: auto;
    overscroll-behavior-inline: contain;
    scrollbar-width: none;
    -webkit-overflow-scrolling: touch;
  }

  body[data-layout="showcase"] [data-product-category-tabs]::-webkit-scrollbar {
    display: none;
  }

  body[data-layout="showcase"] [data-product-category-tabs] > .tab-btn {
    flex: 0 0 auto;
    white-space: nowrap;
    padding-left: 1rem;
    padding-right: 1rem;
  }

  body[data-layout="showcase"] [data-hero-whatsapp-cta] {
    display: none;
  }
}

@media (max-width: 359px) {
  body[data-layout="showcase"] [data-product-grid] {
    grid-template-columns: minmax(0, 1fr);
  }

  body[data-layout="detail"] .detail-product-specs {
    grid-template-columns: minmax(0, 1fr);
  }
}

@media (max-width: 639px) {
  body[data-layout="page"] header > div:first-child {
    display: none;
  }

  html:has(body[data-layout="auth"]) {
    overflow-x: clip;
  }

  body[data-layout="auth"] header .max-w-7xl {
    position: relative;
    padding-left: 12px;
    padding-right: 12px;
    justify-content: center;
  }

  body[data-layout="auth"] [data-auth-brand] {
    position: absolute;
    left: 50%;
    max-width: calc(100% - 5rem);
    justify-content: center;
    transform: translateX(-50%);
  }

  body[data-layout="auth"] [data-auth-brand] > div:last-child {
    align-items: center;
    text-align: center;
  }

  body[data-layout="auth"] [data-auth-back] {
    position: absolute;
    left: 0.75rem;
    display: inline-flex;
    width: 2.75rem;
    height: 2.75rem;
    align-items: center;
    justify-content: center;
    gap: 0;
    overflow: hidden;
    padding: 0 !important;
    border-radius: 50%;
  }

  body[data-layout="auth"] [data-auth-back] span {
    display: none;
  }

  body[data-layout="auth"] [data-auth-back] svg {
    width: 1.25rem;
    height: 1.25rem;
  }

  body[data-layout="auth"] {
    justify-content: flex-start;
  }

  body[data-layout="auth"] main {
    align-items: flex-start;
    justify-content: flex-start;
    padding-top: 1rem;
    padding-bottom: 1.5rem;
  }

  body[data-layout="auth"] main > div {
    align-items: flex-start;
    gap: 0;
  }

  body[data-layout="auth"] main > div > div:first-child {
    display: none;
  }

  body[data-layout="auth"] main > div > div:last-child {
    justify-content: center;
  }

  body[data-layout="auth"] footer .max-w-7xl > div:first-child,
  body[data-layout="auth"] footer .max-w-7xl > div:last-child {
    flex-wrap: wrap;
    justify-content: center;
  }

  body[data-layout="detail"] .detail-purchase-card {
    padding: 1rem;
  }

  body[data-layout="detail"] .detail-condition-pill {
    position: static !important;
    margin: 0 0 0.5rem;
  }

  body[data-layout="detail"] [data-product-kicker-row] {
    align-items: flex-start;
    flex-direction: column;
  }
}

@media (min-width: 1024px) {
  body[data-layout="auth"] main > div > div:first-child > div:last-child {
    flex-wrap: nowrap;
    gap: 12px;
  }
}
