.cadastro-body {
    background: linear-gradient(135deg, var(--creme) 0%, var(--creme-escuro) 100%);
    color: var(--texto-escuro);
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

body:not(.mode-complete) .advanced-only {
    display: none !important;
}

.loja-header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    background: rgba(245, 234, 224, 0.85);
    backdrop-filter: blur(12px);
    box-shadow: 0 4px 20px rgba(92, 48, 32, 0.08);
    padding: 8px 16px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid rgba(92, 48, 32, 0.1);
    z-index: 1100;
    height: 65px;
    animation: slideDown 0.6s ease;
    gap: 12px;
}

@keyframes slideDown {
    from {
        transform: translateY(-50px);
        opacity: 0;
    }

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

.header-left,
.header-right {
    display: flex;
    align-items: center;
    flex-shrink: 0;
    width: 40px;
}

.header-center {
    flex-grow: 1;
    display: flex;
    justify-content: center;
    overflow: hidden;
}

.header-center h1 {
    margin: 0;
    color: var(--marrom);
    font-family: var(--fonte-titulo);
    font-weight: 600;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    font-size: clamp(18px, 4vw, 22px);
    text-align: center;
}

.icon-btn,
.hamburger-btn {
    background: var(--creme-escuro);
    border: 1px solid rgba(92, 48, 32, 0.05);
    color: var(--marrom);
    font-size: 16px;
    width: 40px;
    height: 40px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    cursor: pointer;
    text-decoration: none;
    transition: all 0.25s;
    box-shadow: 0 2px 6px rgba(92, 48, 32, 0.1);
}

.icon-btn:hover,
.hamburger-btn:hover {
    background: var(--marrom);
    color: var(--creme);
    transform: translateY(-2px);
}

.content-wrapper {
    min-height: calc(100vh - 65px);
    padding-top: 85px;
    padding-bottom: 40px;
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.8s cubic-bezier(0.25, 0.46, 0.45, 0.94), transform 0.8s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

body:not(.page-hidden) .content-wrapper {
    opacity: 1;
    transform: translateY(0);
}

.mode-toggle-container {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 15px;
    margin-bottom: 24px;
    background: var(--branco);
    padding: 10px 24px;
    border-radius: 999px;
    width: fit-content;
    margin-left: auto;
    margin-right: auto;
    border: 1px solid rgba(92, 48, 32, 0.08);
    box-shadow: 0 4px 10px rgba(92, 48, 32, 0.05);
}

.mode-label {
    font-weight: 600;
    font-size: 14px;
    color: var(--texto-suave);
    transition: color 0.3s;
}

.mode-label.active {
    color: var(--marrom);
}

.dashboard-container {
    display: flex;
    max-width: 1400px;
    width: 100%;
    margin: 0 auto;
    gap: 24px;
    padding: 0 24px;
    box-sizing: border-box;
}

.form-container {
    flex: 1;
    min-width: 0;
    background: var(--branco);
    border-radius: var(--radius-xl);
    box-shadow: var(--sombra-lg);
    padding: 30px;
    border: 1px solid rgba(92, 48, 32, 0.05);
}

.preview-container {
    width: 340px;
    position: sticky;
    top: 85px;
    height: fit-content;
    background: var(--branco);
    border-radius: var(--radius-xl);
    box-shadow: var(--sombra-lg);
    padding: 24px;
    border: 1px solid rgba(92, 48, 32, 0.05);
}

.form-section {
    margin-bottom: 24px;
    padding-bottom: 24px;
    border-bottom: 1px dashed rgba(92, 48, 32, 0.15);
}

.form-section h2 {
    font-size: 18px;
    margin-bottom: 16px;
    color: var(--marrom);
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 8px;
}

.campo {
    margin-bottom: 16px;
    width: 100%;
}

.produto-grid-2 {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 16px;
}

.produto-grid-3 {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 16px;
}

.produto-textarea {
    min-height: 100px;
    resize: vertical;
}

.custom-select-btn {
    width: 100%;
    padding: var(--space-3) var(--space-4);
    background: rgba(253, 248, 244, 0.92);
    border: 1px solid rgba(92, 48, 32, 0.12);
    border-radius: var(--radius-md);
    color: var(--texto-escuro);
    font-size: var(--texto-base);
    transition: all var(--transicao-rapida);
    outline: none;
    display: flex;
    align-items: center;
    justify-content: space-between;
    cursor: pointer;
}

.custom-select-btn .placeholder {
    color: var(--texto-suave);
}

.custom-select-btn::after {
    content: '\f078';
    font-family: 'Font Awesome 6 Free';
    font-weight: 900;
    color: var(--marrom);
    font-size: 12px;
}

.province-scroll-container {
    display: flex;
    gap: 8px;
    overflow-x: auto;
    padding-bottom: 8px;
    scrollbar-width: none;
    -webkit-overflow-scrolling: touch;
}

.province-scroll-container::-webkit-scrollbar {
    display: none;
}

.province-chip {
    padding: 6px 14px;
    border-radius: 20px;
    background: var(--creme-claro);
    border: 1px solid var(--marrom-palido);
    color: var(--marrom);
    font-size: 12px;
    font-weight: 500;
    cursor: pointer;
    white-space: nowrap;
    transition: all 0.2s ease;
    user-select: none;
    flex-shrink: 0;
}

.province-chip:hover {
    background: var(--creme);
}

.province-chip.active {
    background: var(--marrom);
    border-color: var(--marrom);
    color: var(--creme);
    font-weight: 700;
}

.btn-tiny-action {
    background: transparent;
    border: 1px solid var(--marrom-palido);
    color: var(--marrom);
    border-radius: 15px;
    padding: 4px 10px;
    font-size: 11px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
}

.btn-tiny-action:hover {
    background: var(--marrom);
    color: var(--creme);
}

.image-upload {
    border: 2px dashed var(--marrom-palido);
    border-radius: var(--radius-lg);
    padding: 24px;
    text-align: center;
    cursor: pointer;
    background: var(--creme-claro);
    transition: all 0.2s;
}

.image-upload:hover {
    border-color: var(--marrom);
    background: var(--creme);
}

.upload-icon {
    font-size: 32px;
    color: var(--marrom);
    margin-bottom: 8px;
}

.image-preview {
    display: flex;
    gap: 12px;
    margin-top: 16px;
    flex-wrap: wrap;
}

.image-preview-item {
    position: relative;
    width: 80px;
    height: 80px;
    border-radius: 8px;
    border: 1px solid rgba(92, 48, 32, 0.1);
}

.image-preview-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 8px;
}

.remove-image {
    position: absolute;
    top: -6px;
    right: -6px;
    background: var(--erro);
    color: white;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    font-size: 10px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

.upload-progress {
    margin-top: 16px;
}

.progress-track {
    width: 100%;
    background-color: var(--creme-escuro);
    border-radius: 5px;
    margin-top: 8px;
    height: 24px;
    overflow: hidden;
}

.progress-bar {
    width: 0%;
    background: var(--marrom);
    height: 100%;
    line-height: 24px;
    color: white;
    text-align: center;
    font-size: 12px;
    font-weight: bold;
    transition: width 0.3s;
}

.selection-modal {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(44, 24, 16, 0.45);
    z-index: 2000;
    justify-content: center;
    align-items: center;
    backdrop-filter: blur(6px);
}

.selection-modal-content {
    background: var(--creme-claro);
    width: 90%;
    max-width: 400px;
    border-radius: 24px;
    padding: 24px;
    box-shadow: 0 18px 50px rgba(92, 48, 32, 0.25);
    display: flex;
    flex-direction: column;
    max-height: 80vh;
}

.selection-modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid rgba(92, 48, 32, 0.1);
    padding-bottom: 12px;
    margin-bottom: 16px;
}

.selection-modal-header h3 {
    font-size: 18px;
    color: var(--marrom);
    font-weight: 700;
}

.close-btn {
    background: transparent;
    border: none;
    font-size: 28px;
    cursor: pointer;
    color: var(--marrom);
    opacity: 0.6;
}

.selection-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
    overflow-y: auto;
    padding-right: 5px;
}

.selection-list::-webkit-scrollbar {
    display: none;
}

.selection-option {
    background: var(--branco);
    padding: 12px;
    border-radius: 12px;
    cursor: pointer;
    text-align: center;
    font-weight: 600;
    color: var(--marrom);
    border: 1px solid rgba(92, 48, 32, 0.05);
    transition: all 0.2s;
}

.selection-option:hover {
    background: var(--creme);
}

.selection-option.active {
    background: var(--marrom);
    color: var(--creme);
    box-shadow: 0 4px 12px rgba(92, 48, 32, 0.15);
}

.dynamic-table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 8px;
}

.dynamic-table th {
    text-align: left;
    padding: 10px;
    background: var(--creme-escuro);
    color: var(--marrom);
    font-weight: 600;
    font-size: 12px;
    border-radius: 4px;
}

.dynamic-table td {
    padding: 6px;
}

.btn-remove-row {
    background: var(--erro);
    color: white;
    border: none;
    padding: 8px 12px;
    border-radius: 8px;
    cursor: pointer;
}

.produto-switch-line {
    display: flex;
    align-items: center;
    gap: 12px;
}

.switch {
    position: relative;
    display: inline-block;
    width: 50px;
    height: 28px;
}

.switch input {
    opacity: 0;
    width: 0;
    height: 0;
}

.slider {
    position: absolute;
    cursor: pointer;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: var(--marrom-palido);
    transition: .4s;
    border-radius: 34px;
}

.slider:before {
    position: absolute;
    content: "";
    height: 20px;
    width: 20px;
    left: 4px;
    bottom: 4px;
    background-color: white;
    transition: .4s;
    border-radius: 50%;
}

input:checked+.slider {
    background-color: var(--sucesso);
}

input:checked+.slider:before {
    transform: translateX(22px);
}

.color-picker-trigger {
    width: 44px;
    height: 44px;
    border-radius: 8px;
    border: 1px solid rgba(92, 48, 32, 0.2);
    cursor: pointer;
    background: #ffffff;
    display: flex;
    justify-content: center;
    align-items: center;
    color: var(--marrom);
}

.selected-colors-wrap {
    display: flex;
    gap: 8px;
    margin-top: 10px;
    flex-wrap: wrap;
}

.color-badge {
    display: flex;
    align-items: center;
    gap: 6px;
    background: var(--creme-claro);
    padding: 6px 12px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 600;
    border: 1px solid var(--marrom-palido);
}

.color-dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    border: 1px solid rgba(0, 0, 0, 0.1);
}

.color-remove {
    cursor: pointer;
    color: var(--erro);
    font-weight: bold;
    font-size: 14px;
    margin-left: 4px;
}

.badge-creme {
    background: var(--creme-escuro);
    color: var(--marrom);
    padding: 4px 8px;
    border-radius: 6px;
    font-size: 10px;
    font-weight: 600;
}

.dashed-btn {
    border: 2px dashed var(--marrom-palido) !important;
    background: transparent !important;
    color: var(--marrom) !important;
}

.dashed-btn:hover {
    background: var(--creme-claro) !important;
    border-color: var(--marrom) !important;
}

.preview-header {
    text-align: center;
    margin-bottom: 20px;
}

.preview-header h3 {
    color: var(--marrom);
    font-weight: 700;
    font-size: 18px;
}

.preview-header p {
    color: var(--texto-suave);
    font-size: 13px;
}

.product-card {
    background: var(--branco);
    border-radius: 20px;
    overflow: hidden;
    box-shadow: 0 6px 16px rgba(92, 48, 32, 0.06);
    border: 1px solid rgba(92, 48, 32, 0.05);
    display: flex;
    flex-direction: column;
}

.product-image-wrapper {
    position: relative;
    width: 100%;
    aspect-ratio: 1 / 1;
    background: var(--creme-escuro);
    overflow: hidden;
}

.preview-placeholder-img {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 40px;
    color: var(--marrom-palido);
}

.card-badge {
    position: absolute;
    top: 12px;
    left: 12px;
    padding: 4px 10px;
    border-radius: 999px;
    font-size: 10px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    z-index: 10;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.15);
    display: flex;
    align-items: center;
    gap: 4px;
}

.card-badge.destaque {
    background: linear-gradient(135deg, var(--marrom), #3a1e14);
    color: var(--creme);
}

.card-badge.promo {
    background: var(--erro);
    color: var(--branco);
}

.card-badge.erro {
    background: #666;
    color: #fff;
}

.product-info {
    padding: 16px;
    display: flex;
    flex-direction: column;
    flex-grow: 1;
}

.product-title-row {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 8px;
    margin-bottom: 8px;
}

.product-title {
    font-family: var(--fonte-titulo);
    font-size: 18px;
    font-weight: 600;
    color: var(--marrom);
    line-height: 1.25;
    margin-bottom: 0;
}

.stock-info {
    font-family: var(--fonte-corpo);
    font-size: 12px;
    font-weight: 700;
    color: var(--texto-suave);
    background: var(--creme-escuro);
    padding: 3px 8px;
    border-radius: 6px;
}

.product-meta {
    display: flex;
    gap: 6px;
    margin-bottom: 12px;
    flex-wrap: wrap;
}

.meta-item {
    background: rgba(92, 48, 32, 0.06);
    padding: 3px 8px;
    border-radius: 6px;
    font-size: 10px;
    font-weight: 600;
    color: var(--marrom-claro);
    text-transform: uppercase;
}

.product-description {
    font-size: 13px;
    color: var(--texto-medio);
    margin-bottom: 12px;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    line-height: 1.5;
}

.price-container {
    margin-top: auto;
    display: flex;
    flex-direction: column;
}

.product-price {
    font-size: 20px;
    font-weight: 700;
    color: var(--sucesso);
}

.old-price-line {
    display: flex;
    align-items: center;
    gap: 8px;
}

.old-price {
    color: var(--texto-suave);
    text-decoration: line-through;
    font-size: 12px;
    font-weight: 600;
}

.discount-badge {
    background: var(--erro);
    color: white;
    padding: 2px 6px;
    border-radius: 4px;
    font-size: 10px;
    font-weight: 700;
}

.card-footer {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 10px;
    border-top: 1px solid rgba(92, 48, 32, 0.05);
    margin-top: auto;
    width: 100%;
    background: var(--creme-claro);
}

.store-logo-sm {
    width: 24px !important;
    height: 24px !important;
    border-radius: 50%;
    object-fit: cover;
    border: 1px solid rgba(92, 48, 32, 0.1);
    background: #fff;
    flex-shrink: 0;
    display: block;
}

.store-text-anim {
    position: relative;
    height: 18px;
    flex: 1;
    min-width: 0;
    display: flex;
    align-items: center;
    overflow: hidden;
}

.store-name-text {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    font-size: 11px;
    font-weight: 600;
    white-space: nowrap;
    color: var(--texto-medio);
}

@media (max-width: 1024px) {
    .dashboard-container {
        flex-direction: column;
    }

    .preview-container {
        width: 100%;
        position: static;
        top: 0;
    }
}

@media (max-width: 768px) {

    .produto-grid-2,
    .produto-grid-3 {
        grid-template-columns: 1fr;
    }

    .form-container,
    .preview-container {
        padding: 20px;
    }
}

.section-hint {
  margin: -6px 0 16px;
  color: rgba(92, 48, 32, .72);
  font-size: .92rem;
  line-height: 1.45;
  background: rgba(255, 255, 255, .58);
  border: 1px solid rgba(92, 48, 32, .12);
  border-radius: 14px;
  padding: 10px 12px;
}

/* Cadastro direto no Armazém: sem desconto/promoção nesta etapa */
.produto-grid-1 {
    display: grid;
    grid-template-columns: 1fr;
    gap: 16px;
}

.field-hint {
    display: block;
    margin-top: 8px;
    color: var(--texto-medio);
    font-size: 12px;
    line-height: 1.45;
}
