/* ===============================
   FONTE E BASE
=============================== */
@import url('https://fonts.googleapis.com/css2?family=Poppins:wght@400;500;600&display=swap');

* { box-sizing: border-box; }

html, body {
    height: 100%;
}

body {
    font-family: 'Poppins', sans-serif;
    background: #fafafa;
    margin: 0;
    color: #222;
}

/* ===============================
   WRAPPER
=============================== */
#feed-wrapper {
    max-width: 720px;
    margin: 0 auto;
    padding: 20px;
}

/* ===============================
   CABEÇALHO
=============================== */
.header {
    background: #fff;
    border-bottom: 1px solid #eee;
    position: sticky;
    top: 0;
    z-index: 100;
}

.header-inner {
    max-width: 720px;
    margin: 0 auto;
    padding: 16px 20px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.header-title {
    font-weight: 600;
    font-size: 20px;
}

.header-actions {
    display: flex;
    gap: 12px;
}

/* ===============================
   MENU HAMBÚRGUER
=============================== */
.nav-toggle {
    display: none;
}

.hamburger {
    display: none;
    width: 32px;
    height: 32px;
    align-items: center;
    justify-content: center;
    border: 1px solid #ddd;
    border-radius: 8px;
    background: #fff;
    cursor: pointer;
}

.hamburger span {
    display: block;
    width: 18px;
    height: 2px;
    background: #222;
    position: relative;
}

.hamburger span::before,
.hamburger span::after {
    content: "";
    position: absolute;
    left: 0;
    width: 18px;
    height: 2px;
    background: #222;
}

.hamburger span::before { top: -6px; }
.hamburger span::after  { top:  6px; }

.nav {
    display: flex;
    gap: 16px;
}

.nav a {
    text-decoration: none;
    color: #333;
    font-weight: 500;
}

/* ===============================
   FILTROS
=============================== */
.ng-filtros {
    background: #fff;
    padding: 18px;
    border-radius: 14px;
    box-shadow: 0 2px 10px rgba(0,0,0,.08);
    margin-bottom: 20px;
}

.ng-filtros h3 {
    font-weight: 600;
    margin-bottom: 12px;
}

.filtros-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
}

.ng-input {
    width: 100%;
    padding: 12px;
    border: 1px solid #bbb;
    border-radius: 10px;
    margin-bottom: 12px;
    font-size: 15px;
}

/* ===============================
   CARD
=============================== */
.ng-ig-card {
    width: 100%;
    background: #fff;
    border-radius: 14px;
    box-shadow: 0 4px 14px rgba(0,0,0,.10);
    overflow: hidden;
    margin-bottom: 26px;
}

/* ===============================
   FOTO
=============================== */
.ng-ig-media img {
    width: 100%;
    display: block;
    object-fit: cover;
}

/* ===============================
   INFO
=============================== */
.ng-ig-info {
    padding: 16px;
}

.ng-ig-info h3 {
    font-size: 20px;
    margin-bottom: 6px;
}

.ng-price-city {
    font-weight: 600;
    margin-bottom: 10px;
}

.ng-desc {
    margin-bottom: 12px;
}

/* ===============================
   AÇÕES (LIKE / DISLIKE)
=============================== */
.ng-ig-actions {
    padding: 14px;
    display: flex;
    gap: 14px;
}

.ng-ig-actions button {
    padding: 12px 16px;
    background: #f2f2f2;
    border: 1px solid #ccc;
    border-radius: 12px;
    cursor: pointer;
    font-size: 16px;
    min-height: 44px;
    flex: 1;
    transition: background .15s ease, color .15s ease, transform .1s ease;
}

/* DESKTOP - ATIVO */
.btn-like.ativo {
    background: #007FBF
;
    color: #fff;
    border-color: #f2f2f2;
}

.btn-dislike.ativo {
    background: #007FBF;
    color: #fff;
    border-color: #f2f2f2;
}

/* ===============================
   WHATSAPP
=============================== */
.ng-wa-btn {
    display: block;
    background: #25D366;
    color: #fff;
    padding: 14px 20px;
    border-radius: 14px;
    text-decoration: none;
    font-weight: 600;
    text-align: center;
    font-size: 16px;
    min-height: 48px;
}

/* ===============================
   LOADING
=============================== */
#feed-loading {
    padding: 12px;
    color: #777;
    text-align: center;
}

/* ===============================
   MOBILE (até 900px)
=============================== */
@media (max-width: 900px) {

    #feed-wrapper {
        max-width: 100%;
        width: 100%;
        padding: 0;
        margin: 0;
    }

    .header-inner {
        max-width: 100%;
        padding: 12px;
    }

    .ng-ig-card {
        border-radius: 0;
        margin-bottom: 16px;
        box-shadow: none;
    }

    .ng-ig-info {
        padding: 12px;
    }

    .ng-ig-info h3 {
        font-size: 18px;
        font-weight: 600;
    }

    .ng-desc,
    .ng-price-city {
        font-size: 16px;
        line-height: 1.45;
    }

    .ng-ig-actions {
        justify-content: space-between;
        padding: 10px 12px;
        border-top: 1px solid #eee;
        gap: 10px;
    }

    .ng-ig-actions button {
        background: #fff;
        border: 1px solid #ddd;
        font-size: 17px;
        min-height: 48px;
        flex: 1;
    }

    /* MOBILE - ATIVO (CORRIGIDO) */
    .ng-ig-actions button.btn-like.ativo {
        background: #28a745;
        color: #fff;
        border-color: #28a745;
        transform: scale(1.05);
    }

    .ng-ig-actions button.btn-dislike.ativo {
        background: #dc3545;
        color: #fff;
        border-color: #dc3545;
        transform: scale(1.05);
    }

    .ng-wa-btn {
        width: 100%;
        border-radius: 0;
        font-size: 18px;
        padding: 14px;
        min-height: 50px;
    }

    .ng-filtros {
        padding: 12px;
        border-radius: 0;
        box-shadow: none;
        margin: 0;
        border-top: 1px solid #eee;
        border-bottom: 1px solid #eee;
    }

    .filtros-grid {
        grid-template-columns: 1fr;
        gap: 10px;
    }

    .ng-input {
        font-size: 16px;
        padding: 12px;
        min-height: 44px;
    }

    .header-title { font-size: 22px; }

    .nav {
        position: fixed;
        top: 56px;
        left: 0;
        right: 0;
        background: #fff;
        border-top: 1px solid #eee;
        display: none;
        flex-direction: column;
        padding: 12px;
        gap: 8px;
    }

    .hamburger {
        display: inline-flex;
    }

    .nav-toggle:checked ~ .nav {
        display: flex;
    }

    html, body {
        overflow-x: hidden;
    }
}

/* ===============================
   MOBILE PEQUENO (até 480px)
=============================== */
@media (max-width: 480px) {

    .header-inner { padding: 10px; }

    .header-title { font-size: 20px; }

    .ng-ig-info h3 { font-size: 17px; }

    .ng-price-city { font-size: 15px; }

    .ng-ig-actions button {
        font-size: 16px;
        min-height: 50px;
    }
}
