* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Poppins', sans-serif;
    background-size: cover;
    background-position: center;
    background-attachment: fixed;
    height: 100vh;
    overflow: hidden;
    position: relative;
    transition: background-image 1s ease-in-out;
}

body::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, rgba(0,0,0,0.85) 0%, rgba(0,0,0,0.7) 100%);
    z-index: 0;
}

.display-container {
    position: relative;
    z-index: 1;
    height: 100vh;
    width: 100%;
}

.screen {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0;
    transition: opacity 0.8s cubic-bezier(0.4, 0, 0.2, 1);
    display: none;
}

.screen.active {
    opacity: 1;
    display: flex;
    animation: slideIn 0.8s ease-out;
}

@keyframes slideIn {
    from {
        transform: translateY(30px);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

/* Tela Principal */
.main-screen {
    padding: 15px;
    display: flex;
    flex-direction: column;
    background: rgba(0, 0, 0, 0.3);
    height: 100vh;
}

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

.logo-container {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    margin-bottom: 2px;
}

.store-title {
    color: #ff4444;
    font-size: 28px;
    font-weight: 800;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.8);
    letter-spacing: 2px;
    text-transform: uppercase;
}

.store-subtitle {
    color: #ffd700;
    font-size: 14px;
    margin-top: 1px;
    text-shadow: 1px 1px 3px rgba(0,0,0,0.8);
    font-weight: 300;
    letter-spacing: 1px;
}

.header-line {
    width: 100px;
    height: 2px;
    background: linear-gradient(90deg, transparent, #ff4444, transparent);
    margin: 6px auto 0;
    border-radius: 2px;
}

/* Grid de produtos - 3 colunas x 6 linhas = 18 produtos */
.products-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    grid-template-rows: repeat(6, 1fr);
    gap: 10px;
    flex: 1;
    align-content: stretch;
    padding: 0 15px;
    overflow: hidden;
}

.product-card {
    background: linear-gradient(135deg, rgba(255,255,255,0.15) 0%, rgba(255,255,255,0.05) 100%);
    border: 2px solid rgba(255, 255, 255, 0.2);
    border-radius: 12px;
    padding: 12px 15px;
    backdrop-filter: blur(20px);
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
    min-height: 75px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
}

.product-card:hover {
    transform: translateY(-2px);
    border-color: #ff4444;
    background: linear-gradient(135deg, rgba(255,68,68,0.2) 0%, rgba(255,68,68,0.1) 100%);
    box-shadow: 0 5px 15px rgba(255,68,68,0.3);
}

.product-image {
    flex-shrink: 0;
    width: 60px;
    height: 60px;
    border-radius: 10px;
    overflow: hidden;
    border: 2px solid #ff4444;
    background: rgba(255,255,255,0.1);
}

.product-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.product-name {
    flex: 1;
    min-width: 0;
}

.product-name h3 {
    color: #ffffff;
    font-size: 18px;
    text-shadow: 1px 1px 3px rgba(0,0,0,0.8);
    font-weight: 700;
    letter-spacing: 0.5px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.product-price {
    flex-shrink: 0;
    display: flex;
    align-items: baseline;
    gap: 4px;
}

.currency {
    color: #ffd700;
    font-size: 18px;
    font-weight: 600;
}

.price {
    color: #ff4444;
    font-size: 36px;
    font-weight: 900;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.8);
    letter-spacing: 0.5px;
    line-height: 1;
}

.per-kg {
    color: #ffd700;
    font-size: 14px;
    font-weight: 300;
}

/* Tela de Destaque - Centralizada */
.highlight-screen {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0;
    position: relative;
    width: 100%;
    height: 100vh;
}

.highlight-background {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: radial-gradient(circle, rgba(255,68,68,0.15) 0%, rgba(0,0,0,0.9) 100%);
    z-index: 0;
}

.highlight-content {
    background: linear-gradient(135deg, rgba(20,20,20,0.98) 0%, rgba(30,30,30,0.98) 100%);
    border-radius: 25px;
    padding: 40px;
    text-align: center;
    width: 85%;
    height: 80vh;
    border: 3px solid #ff4444;
    box-shadow: 0 20px 60px rgba(0,0,0,0.6);
    animation: highlightAppear 0.8s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1;
    margin: 0 auto;
}

@keyframes highlightAppear {
    from {
        opacity: 0;
        transform: scale(0.9);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}

.highlight-content::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(255,68,68,0.08) 0%, transparent 70%);
    animation: rotateBg 10s linear infinite;
}

@keyframes rotateBg {
    from {
        transform: rotate(0deg);
    }
    to {
        transform: rotate(360deg);
    }
}

.highlight-layout {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 40px;
    width: 100%;
    height: 100%;
    position: relative;
    z-index: 2;
}

.highlight-image-section {
    flex: 1;
    display: flex;
    justify-content: center;
    align-items: center;
    min-width: 0;
    height: 100%;
}

.highlight-image-section img {
    max-width: 100%;
    max-height: 100%;
    width: auto;
    height: auto;
    object-fit: contain;
    border-radius: 20px;
    border: 4px solid #ff4444;
    box-shadow: 0 15px 40px rgba(255,68,68,0.5);
    animation: imagePulse 3s ease-in-out infinite;
}

@keyframes imagePulse {
    0%, 100% {
        box-shadow: 0 15px 40px rgba(255,68,68,0.5);
    }
    50% {
        box-shadow: 0 20px 60px rgba(255,68,68,0.7);
    }
}

.highlight-info-section {
    flex: 1;
    text-align: center;
    padding: 20px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    min-width: 0;
    height: 100%;
}

.highlight-badge {
    display: inline-block;
    background: linear-gradient(135deg, #ff4444 0%, #cc0000 100%);
    color: white;
    padding: 12px 30px;
    border-radius: 30px;
    font-size: 18px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 3px;
    margin-bottom: 25px;
    animation: badgePulse 2s ease-in-out infinite;
    box-shadow: 0 5px 20px rgba(255,68,68,0.5);
}

@keyframes badgePulse {
    0%, 100% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.05);
    }
}

.highlight-info-section h2 {
    color: #ffffff;
    font-size: 48px;
    margin-bottom: 25px;
    text-shadow: 3px 3px 6px rgba(0,0,0,0.8);
    font-weight: 800;
    letter-spacing: 2px;
    text-transform: uppercase;
}

.highlight-price-box {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 15px;
    background: rgba(255,68,68,0.1);
    border: 3px solid #ff4444;
    border-radius: 20px;
    padding: 25px;
    margin-bottom: 25px;
    box-shadow: 0 10px 30px rgba(255,68,68,0.3);
    width: 100%;
    max-width: 500px;
}

.highlight-currency {
    color: #ffd700;
    font-size: 40px;
    font-weight: 700;
}

.highlight-price {
    color: #ff4444;
    font-size: 80px;
    font-weight: 900;
    text-shadow: 4px 4px 8px rgba(0,0,0,0.8);
    animation: priceBounce 2s ease-in-out infinite;
    line-height: 1;
}

@keyframes priceBounce {
    0%, 100% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.08);
    }
}

.highlight-kg {
    color: #ffd700;
    font-size: 32px;
    font-weight: 300;
}

.highlight-info-section p {
    color: #cccccc;
    font-size: 22px;
    font-weight: 300;
    letter-spacing: 0.5px;
    line-height: 1.4;
    max-width: 500px;
}

/* Ajustes para TV 32" (1366x768) */
@media (max-height: 768px) {
    .main-screen {
        padding: 10px;
    }
    
    .store-title {
        font-size: 24px;
    }
    
    .store-subtitle {
        font-size: 12px;
    }
    
    .products-grid {
        gap: 8px;
        padding: 0 10px;
    }
    
    .product-card {
        min-height: 65px;
        padding: 10px 12px;
        gap: 10px;
    }
    
    .product-image {
        width: 50px;
        height: 50px;
    }
    
    .product-name h3 {
        font-size: 16px;
    }
    
    .price {
        font-size: 30px;
    }
    
    .currency {
        font-size: 15px;
    }
    
    .per-kg {
        font-size: 12px;
    }
    
    .highlight-content {
        padding: 30px;
        height: 75vh;
    }
    
    .highlight-layout {
        gap: 30px;
    }
    
    .highlight-image-section img {
        max-height: 350px;
    }
    
    .highlight-info-section h2 {
        font-size: 36px;
    }
    
    .highlight-price {
        font-size: 60px;
    }
    
    .highlight-currency {
        font-size: 30px;
    }
    
    .highlight-kg {
        font-size: 24px;
    }
}

/* ==========================================
   VERSÃO MOBILE E TABLET
   ========================================== */

/* Tablet (768px - 1024px) */
@media (min-width: 768px) and (max-width: 1024px) {
    .main-screen {
        padding: 10px;
    }
    
    .store-title {
        font-size: 22px;
        letter-spacing: 1px;
    }
    
    .store-subtitle {
        font-size: 11px;
    }
    
    .header-line {
        width: 70px;
        margin: 4px auto 0;
    }
    
    /* Grid adaptado para tablet */
    .products-grid {
        grid-template-columns: repeat(2, 1fr);
        grid-template-rows: repeat(9, 1fr);
        gap: 8px;
        padding: 0 5px;
    }
    
    .product-card {
        min-height: 60px;
        padding: 8px 10px;
        gap: 8px;
        border-radius: 10px;
        border-width: 1.5px;
    }
    
    .product-image {
        width: 45px;
        height: 45px;
        border-width: 1.5px;
        border-radius: 8px;
    }
    
    .product-name h3 {
        font-size: 14px;
        letter-spacing: 0.3px;
    }
    
    .product-price {
        gap: 3px;
    }
    
    .currency {
        font-size: 13px;
    }
    
    .price {
        font-size: 24px;
    }
    
    .per-kg {
        font-size: 10px;
    }
    
    /* Tela de destaque para tablet */
    .highlight-content {
        padding: 25px;
        width: 90%;
        height: 70vh;
        border-radius: 20px;
        border-width: 2px;
    }
    
    .highlight-layout {
        gap: 25px;
    }
    
    .highlight-badge {
        padding: 10px 20px;
        font-size: 14px;
        letter-spacing: 2px;
        margin-bottom: 20px;
    }
    
    .highlight-info-section h2 {
        font-size: 32px;
        margin-bottom: 20px;
        letter-spacing: 1px;
    }
    
    .highlight-price-box {
        padding: 20px;
        margin-bottom: 20px;
        border-width: 2px;
        border-radius: 15px;
        max-width: 400px;
    }
    
    .highlight-currency {
        font-size: 28px;
    }
    
    .highlight-price {
        font-size: 56px;
    }
    
    .highlight-kg {
        font-size: 24px;
    }
    
    .highlight-info-section p {
        font-size: 18px;
        max-width: 350px;
    }
    
    .highlight-image-section img {
        max-height: 250px;
        border-width: 3px;
    }
}

/* Smartphones em modo paisagem (600px - 767px) */
@media (min-width: 600px) and (max-width: 767px) {
    .main-screen {
        padding: 8px;
    }
    
    .store-title {
        font-size: 18px;
        letter-spacing: 1px;
    }
    
    .store-subtitle {
        font-size: 10px;
    }
    
    .header-line {
        width: 50px;
        margin: 3px auto 0;
        height: 1.5px;
    }
    
    .products-grid {
        grid-template-columns: repeat(2, 1fr);
        grid-template-rows: repeat(9, 1fr);
        gap: 6px;
        padding: 0 3px;
    }
    
    .product-card {
        min-height: 50px;
        padding: 6px 8px;
        gap: 6px;
        border-radius: 8px;
        border-width: 1px;
    }
    
    .product-image {
        width: 35px;
        height: 35px;
        border-width: 1px;
        border-radius: 6px;
    }
    
    .product-name h3 {
        font-size: 12px;
    }
    
    .currency {
        font-size: 11px;
    }
    
    .price {
        font-size: 20px;
    }
    
    .per-kg {
        font-size: 9px;
    }
    
    /* Tela de destaque */
    .highlight-content {
        padding: 20px;
        width: 95%;
        height: 85vh;
        border-radius: 15px;
        border-width: 2px;
    }
    
    .highlight-layout {
        gap: 20px;
    }
    
    .highlight-badge {
        padding: 8px 15px;
        font-size: 12px;
        letter-spacing: 1.5px;
        margin-bottom: 15px;
    }
    
    .highlight-info-section h2 {
        font-size: 28px;
        margin-bottom: 15px;
    }
    
    .highlight-price-box {
        padding: 15px;
        margin-bottom: 15px;
        border-width: 1.5px;
        border-radius: 12px;
    }
    
    .highlight-currency {
        font-size: 24px;
    }
    
    .highlight-price {
        font-size: 48px;
    }
    
    .highlight-kg {
        font-size: 20px;
    }
    
    .highlight-info-section p {
        font-size: 16px;
    }
    
    .highlight-image-section img {
        max-height: 200px;
        border-width: 2px;
    }
}

/* Smartphones em modo retrato (320px - 599px) */
@media (max-width: 599px) {
    .main-screen {
        padding: 5px;
    }
    
    .header {
        margin-bottom: 8px;
    }
    
    .store-title {
        font-size: 16px;
        letter-spacing: 0.5px;
    }
    
    .store-subtitle {
        font-size: 9px;
        letter-spacing: 0.5px;
    }
    
    .header-line {
        width: 40px;
        height: 1.5px;
        margin: 3px auto 0;
    }
    
    /* Grid para mobile retrato */
    .products-grid {
        grid-template-columns: repeat(2, 1fr);
        grid-template-rows: repeat(9, 1fr);
        gap: 5px;
        padding: 0 2px;
    }
    
    .product-card {
        min-height: 45px;
        padding: 5px 6px;
        gap: 5px;
        border-radius: 6px;
        border-width: 1px;
        flex-direction: row;
    }
    
    .product-image {
        width: 30px;
        height: 30px;
        border-width: 1px;
        border-radius: 5px;
    }
    
    .product-name h3 {
        font-size: 10px;
        letter-spacing: 0;
    }
    
    .product-price {
        gap: 2px;
        flex-direction: column;
        align-items: flex-end;
    }
    
    .currency {
        font-size: 9px;
    }
    
    .price {
        font-size: 16px;
    }
    
    .per-kg {
        font-size: 8px;
    }
    
    /* Tela de destaque mobile */
    .highlight-screen {
        padding: 10px;
    }
    
    .highlight-content {
        padding: 15px;
        width: 98%;
        height: 90vh;
        border-radius: 12px;
        border-width: 1.5px;
        margin: 0;
    }
    
    .highlight-layout {
        flex-direction: column;
        gap: 15px;
    }
    
    .highlight-image-section {
        height: 40%;
        min-height: auto;
    }
    
    .highlight-info-section {
        height: 60%;
        padding: 10px;
    }
    
    .highlight-badge {
        padding: 6px 12px;
        font-size: 10px;
        letter-spacing: 1px;
        margin-bottom: 10px;
        border-radius: 20px;
    }
    
    .highlight-info-section h2 {
        font-size: 22px;
        margin-bottom: 10px;
        letter-spacing: 0.5px;
    }
    
    .highlight-price-box {
        padding: 12px;
        margin-bottom: 10px;
        border-width: 1.5px;
        border-radius: 10px;
        gap: 8px;
        max-width: 280px;
    }
    
    .highlight-currency {
        font-size: 20px;
    }
    
    .highlight-price {
        font-size: 40px;
    }
    
    .highlight-kg {
        font-size: 18px;
    }
    
    .highlight-info-section p {
        font-size: 14px;
        max-width: 250px;
    }
    
    .highlight-image-section img {
        max-height: 150px;
        border-width: 2px;
        border-radius: 10px;
    }
}

/* Smartphones muito pequenos (até 380px) */
@media (max-width: 380px) {
    .store-title {
        font-size: 14px;
    }
    
    .store-subtitle {
        font-size: 8px;
    }
    
    .products-grid {
        grid-template-columns: 1fr;
        grid-template-rows: repeat(18, 1fr);
        gap: 4px;
    }
    
    .product-card {
        min-height: 40px;
        padding: 4px 5px;
    }
    
    .product-image {
        width: 25px;
        height: 25px;
    }
    
    .product-name h3 {
        font-size: 9px;
    }
    
    .price {
        font-size: 14px;
    }
    
    .currency, .per-kg {
        font-size: 7px;
    }
    
    .highlight-content {
        padding: 10px;
    }
    
    .highlight-info-section h2 {
        font-size: 18px;
    }
    
    .highlight-price {
        font-size: 32px;
    }
    
    .highlight-currency {
        font-size: 16px;
    }
    
    .highlight-kg {
        font-size: 14px;
    }
}