/* =============================================
   Método Ancestral — Main Stylesheet
   Mobile-First · Responsive · Professional
   ============================================= */

/* ── Custom Properties ───────────────────────────────────────────────────── */
:root {
    --color-primary:      #16A34A;
    --color-primary-light:#22C55E;
    --color-primary-dark: #15803D;
    --color-text:         #334155;
    --color-bg:           #F8FAFC;
    --font-heading:       'Poppins', sans-serif;
    --font-body:          'Inter', sans-serif;
    --radius:             0.75rem;
    --shadow:             0 1px 3px 0 rgb(0 0 0 / 0.1), 0 1px 2px -1px rgb(0 0 0 / 0.1);
    --shadow-md:          0 4px 6px -1px rgb(0 0 0 / 0.1), 0 2px 4px -2px rgb(0 0 0 / 0.1);
    --shadow-lg:          0 10px 15px -3px rgb(0 0 0 / 0.1), 0 4px 6px -4px rgb(0 0 0 / 0.1);

    /* Fluid type scale */
    --text-xs:   clamp(0.6875rem, 0.65rem + 0.19vw, 0.75rem);
    --text-sm:   clamp(0.8125rem, 0.77rem + 0.22vw, 0.875rem);
    --text-base: clamp(0.9375rem, 0.88rem + 0.29vw, 1rem);
    --text-lg:   clamp(1rem, 0.92rem + 0.38vw, 1.125rem);
    --text-xl:   clamp(1.125rem, 1rem + 0.63vw, 1.25rem);
    --text-2xl:  clamp(1.25rem, 1.07rem + 0.88vw, 1.5rem);
    --text-3xl:  clamp(1.5rem, 1.2rem + 1.5vw, 1.875rem);
    --text-4xl:  clamp(1.75rem, 1.3rem + 2.25vw, 2.25rem);
    --text-5xl:  clamp(2rem, 1.4rem + 3vw, 3rem);
    --text-6xl:  clamp(2.25rem, 1.5rem + 3.75vw, 3.75rem);
}

/* ── Reset & Base ────────────────────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; }
html {
    scroll-behavior: smooth;
    /* prevent horizontal overflow globally */
    overflow-x: hidden;
}
body {
    font-family: var(--font-body);
    color: var(--color-text);
    background: var(--color-bg);
    font-size: var(--text-base);
    line-height: 1.6;
    overflow-x: hidden;
    -webkit-text-size-adjust: 100%;
    text-size-adjust: 100%;
}
/* Scroll lock when mobile menu is open */
body.menu-open { overflow: hidden; }

img, video, svg {
    max-width: 100%;
    height: auto;
    display: block;
}
a { color: inherit; text-decoration: none; }
button { cursor: pointer; }

/* Minimum touch target */
button, a, input, select, textarea, [role="button"] {
    touch-action: manipulation;
}

/* ── Scrollbar ───────────────────────────────────────────────────────────── */
::-webkit-scrollbar { width: 6px; height: 6px; }
::-webkit-scrollbar-track { background: #f1f5f9; }
::-webkit-scrollbar-thumb { background: #16A34A; border-radius: 9999px; }
::-webkit-scrollbar-thumb:hover { background: #15803D; }

/* ── Typography — Fluid ──────────────────────────────────────────────────── */
.font-heading { font-family: var(--font-heading); }
.font-body    { font-family: var(--font-body); }
.font-500 { font-weight: 500; }
.font-600 { font-weight: 600; }
.font-700 { font-weight: 700; }
.font-800 { font-weight: 800; }
.font-900 { font-weight: 900; }

/* ── Navigation ──────────────────────────────────────────────────────────── */
.nav-link {
    display: inline-flex;
    align-items: center;
    padding: 0.5rem 0.75rem;
    border-radius: 0.625rem;
    font-family: var(--font-heading);
    font-size: var(--text-sm);
    font-weight: 600;
    color: #374151;
    transition: all 0.15s ease;
    white-space: nowrap;
    background: none;
    border: none;
    min-height: 44px;
}
.nav-link:hover,
.nav-link.active {
    color: #16A34A;
    background-color: #F0FDF4;
}

/* Dropdown nav items */
.dropdown-item {
    display: flex;
    align-items: center;
    gap: 0.625rem;
    padding: 0.5rem 0.625rem;
    border-radius: 0.75rem;
    transition: background 0.15s;
    min-height: 44px;
}
.dropdown-item:hover { background: #F0FDF4; }

.dropdown-item-sm {
    display: block;
    padding: 0.375rem 0.625rem;
    border-radius: 0.625rem;
    font-size: var(--text-sm);
    font-weight: 500;
    color: #4B5563;
    transition: all 0.15s;
    min-height: 36px;
    line-height: 1.75;
}
.dropdown-item-sm:hover { background: #F0FDF4; color: #16A34A; }

/* Mega-menu responsive */
@media (max-width: 1280px) {
    .mega-menu-inner { width: min(560px, 90vw) !important; }
}

/* Mobile nav */
.mobile-nav-link {
    display: flex;
    align-items: center;
    padding: 0.75rem 1rem;
    border-radius: 0.75rem;
    font-family: var(--font-heading);
    font-weight: 600;
    color: #374151;
    transition: all 0.15s ease;
    font-size: var(--text-base);
    min-height: 48px;
    width: 100%;
    border: none;
    background: none;
    text-align: left;
}
.mobile-nav-link:hover { color: #16A34A; background-color: #F0FDF4; }

.mobile-nav-link-sub {
    display: flex;
    align-items: center;
    padding: 0.5rem 0.75rem;
    border-radius: 0.625rem;
    font-size: var(--text-sm);
    font-weight: 500;
    color: #6B7280;
    transition: all 0.15s ease;
    min-height: 44px;
}
.mobile-nav-link-sub:hover { color: #16A34A; background-color: #F0FDF4; }

/* Mobile menu overlay */
.mobile-menu-overlay {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.4);
    z-index: 40;
    backdrop-filter: blur(2px);
}
.mobile-menu-overlay.active { display: block; }

.footer-link {
    color: #9CA3AF;
    transition: color 0.15s ease;
    line-height: 1.6;
    font-size: var(--text-sm);
}
.footer-link:hover { color: #D1FAE5; }

.social-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 2.25rem;
    height: 2.25rem;
    border-radius: 0.5rem;
    background: #374151;
    color: #9CA3AF;
    transition: all 0.15s ease;
    flex-shrink: 0;
}
.social-icon:hover { background: #16A34A; color: white; }

/* ── Buttons — Touch-friendly (min 48px) ─────────────────────────────────── */
.btn-primary {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.75rem 1.375rem;
    min-height: 48px;
    background: #16A34A;
    color: white;
    border-radius: 0.75rem;
    font-family: var(--font-heading);
    font-weight: 600;
    font-size: var(--text-sm);
    transition: all 0.2s ease;
    box-shadow: 0 2px 8px rgba(22, 163, 74, 0.3);
    border: none;
    cursor: pointer;
    text-decoration: none;
    white-space: nowrap;
    -webkit-tap-highlight-color: transparent;
}
.btn-primary:hover {
    background: #15803D;
    transform: translateY(-1px);
    box-shadow: 0 4px 16px rgba(22, 163, 74, 0.4);
    color: white;
}
.btn-primary:active { transform: translateY(0); }

.btn-secondary {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.75rem 1.375rem;
    min-height: 48px;
    background: white;
    color: #16A34A;
    border: 2px solid #16A34A;
    border-radius: 0.75rem;
    font-family: var(--font-heading);
    font-weight: 600;
    font-size: var(--text-sm);
    transition: all 0.2s ease;
    cursor: pointer;
    text-decoration: none;
    white-space: nowrap;
    -webkit-tap-highlight-color: transparent;
}
.btn-secondary:hover {
    background: #F0FDF4;
    transform: translateY(-1px);
    color: #16A34A;
}

.btn-outline {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.625rem 1.125rem;
    min-height: 44px;
    background: transparent;
    color: #6B7280;
    border: 1.5px solid #E5E7EB;
    border-radius: 0.75rem;
    font-family: var(--font-heading);
    font-weight: 500;
    font-size: var(--text-sm);
    transition: all 0.15s ease;
    cursor: pointer;
    -webkit-tap-highlight-color: transparent;
}
.btn-outline:hover { border-color: #16A34A; color: #16A34A; background: #F0FDF4; }

.btn-danger {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.5rem 1rem;
    min-height: 40px;
    background: #FEF2F2;
    color: #DC2626;
    border: 1.5px solid #FECACA;
    border-radius: 0.5rem;
    font-size: var(--text-xs);
    font-weight: 600;
    cursor: pointer;
    transition: all 0.15s ease;
}
.btn-danger:hover { background: #DC2626; color: white; border-color: #DC2626; }

/* ── Section Patterns ────────────────────────────────────────────────────── */
.section-header {
    text-align: center;
    margin-bottom: clamp(1.5rem, 5vw, 3rem);
}
.section-badge {
    display: inline-block;
    background: #DCFCE7;
    color: #15803D;
    font-family: var(--font-heading);
    font-weight: 700;
    font-size: var(--text-xs);
    letter-spacing: 0.05em;
    text-transform: uppercase;
    padding: 0.3rem 0.875rem;
    border-radius: 9999px;
    margin-bottom: 0.75rem;
}
.section-title {
    font-family: var(--font-heading);
    font-weight: 800;
    font-size: var(--text-3xl);
    color: #111827;
    margin-bottom: 0.75rem;
    line-height: 1.2;
}
.section-desc {
    color: #6B7280;
    font-size: var(--text-base);
    max-width: min(36rem, 100%);
    margin: 0 auto;
    line-height: 1.7;
}

/* ── Cards ───────────────────────────────────────────────────────────────── */
.stat-card {
    position: relative;
    background: white;
    border-radius: 1rem;
    padding: clamp(1rem, 3vw, 1.5rem);
    text-align: center;
    box-shadow: var(--shadow);
    border: 1px solid #F0FDF4;
    transition: all 0.2s ease;
}
.stat-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-lg);
    border-color: #BBF7D0;
}

.category-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: clamp(0.875rem, 2.5vw, 1.25rem) 0.75rem;
    background: white;
    border-radius: 1rem;
    border: 1.5px solid #F3F4F6;
    transition: all 0.2s ease;
    cursor: pointer;
}
.category-card:hover {
    border-color: #86EFAC;
    background: #F0FDF4;
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
}

.tool-card {
    position: relative;
    display: flex;
    flex-direction: column;
    padding: clamp(1rem, 2.5vw, 1.25rem);
    background: white;
    border-radius: 1rem;
    border: 1.5px solid #F3F4F6;
    transition: all 0.2s ease;
    cursor: pointer;
}
.tool-card:hover {
    border-color: #86EFAC;
    box-shadow: var(--shadow-md);
    transform: translateY(-2px);
}

.food-card {
    cursor: pointer;
    transition: all 0.2s ease;
}
.food-card:hover { transform: translateY(-2px); }

.recipe-card {
    background: white;
    border-radius: 1rem;
    padding: clamp(0.75rem, 2.5vw, 1rem);
    border: 1.5px solid #F3F4F6;
    transition: all 0.2s ease;
}
.recipe-card:hover { box-shadow: var(--shadow-md); border-color: #BBF7D0; }

.blog-card {
    background: white;
    border-radius: 1rem;
    padding: clamp(1rem, 2.5vw, 1.25rem);
    border: 1.5px solid #F3F4F6;
    transition: all 0.2s ease;
}
.blog-card:hover { box-shadow: var(--shadow-md); }

/* ── Form Elements ───────────────────────────────────────────────────────── */
.form-group { margin-bottom: 1.125rem; }

.form-label {
    display: block;
    font-family: var(--font-heading);
    font-weight: 600;
    font-size: var(--text-sm);
    color: #374151;
    margin-bottom: 0.375rem;
}

.form-input,
.form-select,
.form-textarea {
    width: 100%;
    padding: 0.75rem 1rem;
    min-height: 48px;
    border: 1.5px solid #E5E7EB;
    border-radius: 0.75rem;
    font-family: var(--font-body);
    font-size: var(--text-base); /* prevents iOS zoom (>= 16px effective) */
    color: #374151;
    background: white;
    transition: all 0.15s ease;
    outline: none;
    appearance: none;
    -webkit-appearance: none;
}
.form-input:focus,
.form-select:focus,
.form-textarea:focus {
    border-color: #16A34A;
    box-shadow: 0 0 0 3px rgba(22, 163, 74, 0.1);
}
.form-input::placeholder { color: #9CA3AF; }

.form-select {
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 20 20'%3e%3cpath stroke='%236b7280' stroke-linecap='round' stroke-linejoin='round' stroke-width='1.5' d='M6 8l4 4 4-4'/%3e%3c/svg%3e");
    background-repeat: no-repeat;
    background-position: right 0.75rem center;
    background-size: 1.25em;
    padding-right: 2.5rem;
    cursor: pointer;
}

/* ── Tables — Responsive Scroll Wrapper ──────────────────────────────────── */
.table-responsive {
    width: 100%;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    border-radius: 0.75rem;
}
.table-responsive table {
    min-width: 480px;
}

/* Nutritional Table */
.nutrient-table {
    width: 100%;
    border-collapse: collapse;
}
.nutrient-table th {
    background: #F0FDF4;
    font-family: var(--font-heading);
    font-weight: 700;
    font-size: var(--text-xs);
    color: #15803D;
    padding: 0.625rem 0.875rem;
    text-align: left;
    border-bottom: 2px solid #BBF7D0;
    white-space: nowrap;
}
.nutrient-table td {
    padding: 0.625rem 0.875rem;
    font-size: var(--text-sm);
    border-bottom: 1px solid #F3F4F6;
    color: #374151;
}
.nutrient-table tr:last-child td { border-bottom: none; }
.nutrient-table tr:hover td { background: #F9FAFB; }
.nutrient-table td:last-child { font-weight: 600; text-align: right; }

/* ── Calculator ──────────────────────────────────────────────────────────── */
.calc-card {
    background: white;
    border-radius: 1.25rem;
    padding: clamp(1.25rem, 4vw, 2rem);
    box-shadow: var(--shadow-md);
    border: 1px solid #F3F4F6;
}

.calc-result {
    background: linear-gradient(135deg, #F0FDF4 0%, #DCFCE7 100%);
    border: 2px solid #86EFAC;
    border-radius: 1rem;
    padding: clamp(1rem, 3vw, 1.5rem);
    margin-top: 1.25rem;
    animation: fadeInUp 0.4s ease-out;
}

.range-bar {
    height: 12px;
    border-radius: 9999px;
    background: linear-gradient(to right, #3B82F6, #22C55E, #F59E0B, #EF4444);
    position: relative;
    margin: 0.5rem 0 1rem;
}
.range-indicator {
    position: absolute;
    top: -4px;
    width: 20px;
    height: 20px;
    background: white;
    border: 3px solid #374151;
    border-radius: 50%;
    transform: translateX(-50%);
    transition: left 0.5s ease;
}

/* ── Comparator ──────────────────────────────────────────────────────────── */
.compare-col {
    background: white;
    border-radius: 1rem;
    border: 1.5px solid #E5E7EB;
    overflow: hidden;
    transition: all 0.2s ease;
}
.compare-col.highlight { border-color: #16A34A; box-shadow: 0 0 0 3px rgba(22, 163, 74, 0.1); }
.compare-header {
    padding: 1rem;
    background: #F0FDF4;
    border-bottom: 1.5px solid #E5E7EB;
    text-align: center;
}
.compare-row {
    display: flex;
    border-bottom: 1px solid #F3F4F6;
    min-width: 0;
}
.compare-row:last-child { border-bottom: none; }
.compare-row > div {
    flex: 1;
    padding: 0.5rem 0.75rem;
    font-size: var(--text-sm);
    text-align: center;
    min-width: 0;
    word-break: break-word;
}
.compare-row > div.label { background: #F9FAFB; font-weight: 600; text-align: left; flex: 1.5; }
.compare-row > div.best { background: #F0FDF4; color: #15803D; font-weight: 700; }

/* ── Meal Planner ────────────────────────────────────────────────────────── */
.meal-item {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.75rem;
    background: white;
    border-radius: 0.75rem;
    border: 1.5px solid #E5E7EB;
    margin-bottom: 0.5rem;
    animation: fadeInUp 0.3s ease-out;
    min-width: 0;
}
.meal-item > * { min-width: 0; }
.meal-totals {
    background: linear-gradient(135deg, #16A34A 0%, #22C55E 100%);
    border-radius: 1rem;
    padding: clamp(1rem, 3vw, 1.5rem);
    color: white;
    margin-top: 1rem;
}
.macro-bar {
    height: 8px;
    border-radius: 9999px;
    background: rgba(255,255,255,0.2);
    overflow: hidden;
    margin-top: 0.25rem;
}
.macro-bar-fill {
    height: 100%;
    border-radius: 9999px;
    background: white;
    transition: width 0.5s ease;
}

/* ── Pagination ──────────────────────────────────────────────────────────── */
.pagination {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.25rem;
    margin-top: 2rem;
    flex-wrap: wrap;
    padding: 0 0.5rem;
}
.pagination a,
.pagination span {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 2.25rem;
    min-height: 2.25rem;
    padding: 0 0.5rem;
    border-radius: 0.5rem;
    font-size: var(--text-sm);
    font-weight: 500;
    border: 1.5px solid #E5E7EB;
    color: #374151;
    transition: all 0.15s ease;
}
.pagination a:hover { border-color: #16A34A; color: #16A34A; background: #F0FDF4; }
.pagination span.current { background: #16A34A; color: white; border-color: #16A34A; font-weight: 700; }
.pagination span.ellipsis { border: none; color: #9CA3AF; }

/* ── Admin Panel ─────────────────────────────────────────────────────────── */
.admin-sidebar {
    position: fixed;
    top: 0;
    left: 0;
    width: 16rem;
    height: 100vh;
    background: #111827;
    display: flex;
    flex-direction: column;
    z-index: 50;
    overflow-y: auto;
    transition: transform 0.3s ease;
}
.admin-content {
    margin-left: 16rem;
    min-height: 100vh;
    background: #F9FAFB;
    transition: margin 0.3s ease;
}
.admin-nav-link {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.75rem 1.25rem;
    color: #9CA3AF;
    font-size: var(--text-sm);
    font-weight: 500;
    border-radius: 0.625rem;
    margin: 0.125rem 0.75rem;
    transition: all 0.15s ease;
    min-height: 44px;
}
.admin-nav-link:hover,
.admin-nav-link.active { color: white; background: rgba(22, 163, 74, 0.2); }
.admin-nav-link.active { color: #4ADE80; }

.admin-card {
    background: white;
    border-radius: 0.875rem;
    padding: clamp(1rem, 3vw, 1.5rem);
    box-shadow: 0 1px 3px rgba(0,0,0,0.06);
    border: 1px solid #F3F4F6;
}

/* Admin table — always scrollable */
.admin-table-wrap {
    width: 100%;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
}
.admin-table {
    width: 100%;
    min-width: 600px;
    border-collapse: collapse;
    font-size: var(--text-sm);
}
.admin-table th {
    background: #F9FAFB;
    font-family: var(--font-heading);
    font-weight: 700;
    font-size: var(--text-xs);
    color: #374151;
    letter-spacing: 0.025em;
    text-transform: uppercase;
    padding: 0.75rem 1rem;
    text-align: left;
    border-bottom: 2px solid #E5E7EB;
    white-space: nowrap;
}
.admin-table td {
    padding: 0.875rem 1rem;
    color: #374151;
    border-bottom: 1px solid #F3F4F6;
    vertical-align: middle;
}
.admin-table tr:last-child td { border-bottom: none; }
.admin-table tr:hover td { background: #FAFAFA; }

/* Admin responsive: sidebar collapses to overlay on small screens */
@media (max-width: 1024px) {
    .admin-sidebar {
        transform: translateX(-100%);
    }
    .admin-sidebar.open {
        transform: translateX(0);
        box-shadow: var(--shadow-lg);
    }
    .admin-content {
        margin-left: 0;
    }
    .admin-overlay {
        display: none;
        position: fixed;
        inset: 0;
        background: rgba(0,0,0,0.5);
        z-index: 40;
    }
    .admin-overlay.active { display: block; }
}

/* ── Badges ──────────────────────────────────────────────────────────────── */
.badge {
    display: inline-flex;
    align-items: center;
    padding: 0.2rem 0.625rem;
    border-radius: 9999px;
    font-size: var(--text-xs);
    font-weight: 600;
    white-space: nowrap;
}
.badge-green  { background: #DCFCE7; color: #15803D; }
.badge-blue   { background: #DBEAFE; color: #1D4ED8; }
.badge-orange { background: #FEF3C7; color: #D97706; }
.badge-red    { background: #FEE2E2; color: #DC2626; }
.badge-gray   { background: #F3F4F6; color: #6B7280; }

/* ── Swiper ──────────────────────────────────────────────────────────────── */
.swiper-button-next,
.swiper-button-prev {
    color: #16A34A !important;
    background: white;
    width: 2.25rem !important;
    height: 2.25rem !important;
    border-radius: 50%;
    box-shadow: var(--shadow-md);
}
.swiper-button-next::after,
.swiper-button-prev::after { font-size: 0.8125rem !important; font-weight: 700 !important; }
.swiper-pagination-bullet-active { background: #16A34A !important; }

/* ── Keyframes ───────────────────────────────────────────────────────────── */
@keyframes fadeInUp {
    from { opacity: 0; transform: translateY(40px); }
    to   { opacity: 1; transform: translateY(0); }
}
@keyframes fadeInDown {
    from { opacity: 0; transform: translateY(-40px); }
    to   { opacity: 1; transform: translateY(0); }
}
@keyframes fadeInLeft {
    from { opacity: 0; transform: translateX(-48px); }
    to   { opacity: 1; transform: translateX(0); }
}
@keyframes fadeInRight {
    from { opacity: 0; transform: translateX(48px); }
    to   { opacity: 1; transform: translateX(0); }
}
@keyframes fadeIn {
    from { opacity: 0; }
    to   { opacity: 1; }
}
@keyframes zoomIn {
    from { opacity: 0; transform: scale(0.88); }
    to   { opacity: 1; transform: scale(1); }
}
@keyframes shimmer {
    0%   { background-position: -200% 0; }
    100% { background-position:  200% 0; }
}

/* ── Instant animation classes (for hero, above-fold) ───────────────────── */
.animate-fade-in-up    { animation: fadeInUp    0.7s cubic-bezier(.22,.68,0,1.2) both; }
.animate-fade-in-down  { animation: fadeInDown  0.7s cubic-bezier(.22,.68,0,1.2) both; }
.animate-fade-in-left  { animation: fadeInLeft  0.7s cubic-bezier(.22,.68,0,1.2) both; }
.animate-fade-in-right { animation: fadeInRight 0.7s cubic-bezier(.22,.68,0,1.2) both; }
.animate-fade-in       { animation: fadeIn      0.6s ease-out both; }
.animate-zoom-in       { animation: zoomIn      0.6s cubic-bezier(.22,.68,0,1.2) both; }

/* Delay utilities */
.delay-100 { animation-delay: 100ms; }
.delay-150 { animation-delay: 150ms; }
.delay-200 { animation-delay: 200ms; }
.delay-300 { animation-delay: 300ms; }
.delay-400 { animation-delay: 400ms; }
.delay-500 { animation-delay: 500ms; }
.delay-600 { animation-delay: 600ms; }
.delay-700 { animation-delay: 700ms; }
.delay-800 { animation-delay: 800ms; }

/* ── Scroll-triggered animations (Intersection Observer) ────────────────── */
/* Initial hidden state — applied to elements waiting to enter viewport */
[data-anim] {
    opacity: 0;
    will-change: opacity, transform;
    transition: opacity 0.65s cubic-bezier(.22,.68,0,1.1),
                transform 0.65s cubic-bezier(.22,.68,0,1.1);
}
[data-anim="up"]    { transform: translateY(48px); }
[data-anim="down"]  { transform: translateY(-48px); }
[data-anim="left"]  { transform: translateX(-56px); }
[data-anim="right"] { transform: translateX(56px); }
[data-anim="fade"]  { transform: none; }
[data-anim="zoom"]  { transform: scale(0.88); }
[data-anim="flip"]  { transform: rotateX(15deg) translateY(32px); transform-origin: bottom; }

/* Visible state */
[data-anim].anim-visible {
    opacity: 1;
    transform: none !important;
}

/* Stagger children — parent triggers, children animate in sequence */
[data-anim-group] > * {
    opacity: 0;
    transform: translateY(32px);
    transition: opacity 0.55s cubic-bezier(.22,.68,0,1.1),
                transform 0.55s cubic-bezier(.22,.68,0,1.1);
}
[data-anim-group="left"] > * {
    transform: translateX(-40px);
}
[data-anim-group="right"] > * {
    transform: translateX(40px);
}
[data-anim-group].anim-visible > * {
    opacity: 1;
    transform: none;
}
/* Auto stagger delay for up to 12 children */
[data-anim-group].anim-visible > *:nth-child(1)  { transition-delay: 0ms; }
[data-anim-group].anim-visible > *:nth-child(2)  { transition-delay: 80ms; }
[data-anim-group].anim-visible > *:nth-child(3)  { transition-delay: 160ms; }
[data-anim-group].anim-visible > *:nth-child(4)  { transition-delay: 240ms; }
[data-anim-group].anim-visible > *:nth-child(5)  { transition-delay: 320ms; }
[data-anim-group].anim-visible > *:nth-child(6)  { transition-delay: 400ms; }
[data-anim-group].anim-visible > *:nth-child(7)  { transition-delay: 480ms; }
[data-anim-group].anim-visible > *:nth-child(8)  { transition-delay: 560ms; }
[data-anim-group].anim-visible > *:nth-child(9)  { transition-delay: 640ms; }
[data-anim-group].anim-visible > *:nth-child(10) { transition-delay: 720ms; }
[data-anim-group].anim-visible > *:nth-child(11) { transition-delay: 800ms; }
[data-anim-group].anim-visible > *:nth-child(12) { transition-delay: 880ms; }

/* Custom delay via data-delay attribute */
[data-delay="100"]  { transition-delay: 100ms !important; }
[data-delay="200"]  { transition-delay: 200ms !important; }
[data-delay="300"]  { transition-delay: 300ms !important; }
[data-delay="400"]  { transition-delay: 400ms !important; }
[data-delay="500"]  { transition-delay: 500ms !important; }

/* ── Legacy .reveal support ──────────────────────────────────────────────── */
.reveal {
    opacity: 0;
    transform: translateY(24px);
    transition: opacity 0.55s ease, transform 0.55s ease;
}
.reveal.revealed {
    opacity: 1;
    transform: translateY(0);
}

/* ── Skeleton ────────────────────────────────────────────────────────────── */
.skeleton {
    background: linear-gradient(90deg, #f0f0f0 25%, #e8e8e8 50%, #f0f0f0 75%);
    background-size: 200% 100%;
    animation: shimmer 1.5s infinite;
    border-radius: 0.5rem;
}

/* ── Reduce motion ───────────────────────────────────────────────────────── */
@media (prefers-reduced-motion: reduce) {
    [data-anim], [data-anim-group] > *, .reveal,
    .animate-fade-in-up, .animate-fade-in-down,
    .animate-fade-in-left, .animate-fade-in-right,
    .animate-fade-in, .animate-zoom-in {
        animation: none !important;
        transition: none !important;
        opacity: 1 !important;
        transform: none !important;
    }
}

/* ── Utilities ───────────────────────────────────────────────────────────── */
.sr-only {
    position: absolute; width: 1px; height: 1px; padding: 0;
    margin: -1px; overflow: hidden; clip: rect(0,0,0,0);
    white-space: nowrap; border-width: 0;
}
.not-sr-only { position: static; width: auto; height: auto; padding: 0; margin: 0; overflow: visible; clip: auto; }
.aspect-square { aspect-ratio: 1 / 1; }

.line-clamp-1 { overflow: hidden; display: -webkit-box; -webkit-line-clamp: 1; -webkit-box-orient: vertical; }
.line-clamp-2 { overflow: hidden; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; }
.line-clamp-3 { overflow: hidden; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; }

/* Prevent long words from breaking layout */
.break-words { word-break: break-word; overflow-wrap: break-word; }

/* Container utility */
.container-fluid {
    width: 100%;
    max-width: 1400px;
    margin-inline: auto;
    padding-inline: clamp(1rem, 4vw, 2rem);
}

/* ── Mobile-specific fixes ───────────────────────────────────────────────── */
@media (max-width: 639px) {
    /* Prevent hero text overflow */
    h1, h2, h3 { word-break: break-word; }

    /* Stack flex rows on tiny screens */
    .flex-stack-xs {
        flex-direction: column;
        align-items: stretch;
    }
    .flex-stack-xs > * { width: 100%; }

    /* Narrower padding on calc cards */
    .calc-card { padding: 1.25rem; }

    /* Full-width buttons on mobile */
    .btn-full-mobile { width: 100%; justify-content: center; }

    /* Ensure food grid doesn't go below 2 cols */
    .food-grid {
        grid-template-columns: repeat(2, 1fr) !important;
    }
}

/* ── Tablet tweaks ───────────────────────────────────────────────────────── */
@media (min-width: 640px) and (max-width: 1023px) {
    .admin-sidebar { transform: translateX(-100%); }
    .admin-content { margin-left: 0; }
}

/* ── Large screen max-width ─────────────────────────────────────────────── */
@media (min-width: 1921px) {
    /* Scale up font sizes slightly for very large screens */
    :root {
        --text-base: 1.0625rem;
        --text-lg:   1.1875rem;
    }
}

/* ── Mobile Bottom Navbar — apenas mobile/tablet (< 1024px) ─────────────── */
@media (min-width: 1024px) {
    .mobile-bottom-nav,
    .mbn-drawer,
    .mbn-overlay { display: none !important; }
}

.mobile-bottom-nav {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    z-index: 60;
    display: flex;
    align-items: stretch;
    background: rgba(255, 255, 255, 0.97);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-top: 1px solid rgba(0,0,0,0.06);
    box-shadow: 0 -4px 24px rgba(0,0,0,0.08);
    padding-bottom: env(safe-area-inset-bottom, 0);
    height: calc(60px + env(safe-area-inset-bottom, 0px));
}

.mbn-item {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 3px;
    padding: 8px 4px;
    color: #9CA3AF;
    font-size: 0.625rem;
    font-weight: 600;
    font-family: var(--font-heading);
    letter-spacing: 0.02em;
    text-decoration: none;
    background: none;
    border: none;
    cursor: pointer;
    transition: color 0.15s ease;
    -webkit-tap-highlight-color: transparent;
    position: relative;
    min-height: 60px;
}
.mbn-item svg {
    width: 22px;
    height: 22px;
    transition: transform 0.2s cubic-bezier(.22,.68,0,1.6);
    flex-shrink: 0;
}
.mbn-item:hover { color: #16A34A; }
.mbn-item:hover svg { transform: translateY(-2px) scale(1.1); }
.mbn-item:active svg { transform: scale(0.9); }

/* Active state — green indicator dot */
.mbn-item.active {
    color: #16A34A;
}
.mbn-item.active::before {
    content: '';
    position: absolute;
    top: 5px;
    left: 50%;
    transform: translateX(-50%);
    width: 28px;
    height: 3px;
    background: #16A34A;
    border-radius: 0 0 3px 3px;
}

/* Center FAB button */
.mbn-center {
    position: relative;
    padding-top: 0;
}
.mbn-fab {
    width: 48px;
    height: 48px;
    background: linear-gradient(135deg, #16A34A, #15803D);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 16px rgba(22, 163, 74, 0.45);
    transition: transform 0.25s cubic-bezier(.22,.68,0,1.4), box-shadow 0.2s;
    margin-bottom: 1px;
}
.mbn-fab svg {
    width: 22px;
    height: 22px;
    color: white;
    transition: transform 0.3s cubic-bezier(.22,.68,0,1.6);
}
.mbn-center:hover .mbn-fab {
    transform: translateY(-4px) scale(1.08);
    box-shadow: 0 8px 24px rgba(22, 163, 74, 0.55);
}
.mbn-center.open .mbn-fab {
    background: linear-gradient(135deg, #15803D, #166534);
    transform: translateY(-4px) scale(1.08);
}
.mbn-center.open .mbn-fab svg {
    transform: rotate(135deg);
}
.mbn-center { color: #16A34A; }

/* ── Tools Drawer ────────────────────────────────────────────────────────── */
.mbn-overlay {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.45);
    z-index: 58;
    backdrop-filter: blur(3px);
    -webkit-backdrop-filter: blur(3px);
    opacity: 0;
    transition: opacity 0.3s ease;
}
.mbn-overlay.active {
    display: block;
    opacity: 1;
}

.mbn-drawer {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    z-index: 59;
    background: #fff;
    border-radius: 1.5rem 1.5rem 0 0;
    padding: 0 1.25rem calc(80px + env(safe-area-inset-bottom, 0px));
    box-shadow: 0 -8px 40px rgba(0,0,0,0.15);
    transform: translateY(100%);
    transition: transform 0.35s cubic-bezier(.22,.68,0,1.1);
    max-height: 80vh;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
}
.mbn-drawer.open {
    transform: translateY(0);
}

.mbn-drawer-handle {
    width: 40px;
    height: 4px;
    background: #E5E7EB;
    border-radius: 9999px;
    margin: 0.75rem auto 1.25rem;
}

.mbn-drawer-title {
    font-family: var(--font-heading);
    font-weight: 700;
    font-size: 1rem;
    color: #111827;
    margin-bottom: 1.25rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}
.mbn-drawer-title::before {
    content: '⚡';
    font-size: 1.125rem;
}

.mbn-drawer-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 0.75rem;
    margin-bottom: 1.25rem;
}

.mbn-tool-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.375rem;
    text-decoration: none;
    -webkit-tap-highlight-color: transparent;
    transition: transform 0.2s cubic-bezier(.22,.68,0,1.4);
}
.mbn-tool-item:active {
    transform: scale(0.9);
}

.mbn-tool-icon {
    width: 56px;
    height: 56px;
    border-radius: 1rem;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    transition: transform 0.2s cubic-bezier(.22,.68,0,1.6), box-shadow 0.2s;
    box-shadow: 0 2px 8px rgba(0,0,0,0.06);
}
.mbn-tool-item:hover .mbn-tool-icon {
    transform: translateY(-3px) scale(1.06);
    box-shadow: 0 6px 16px rgba(0,0,0,0.1);
}

.mbn-tool-label {
    font-family: var(--font-heading);
    font-size: 0.6875rem;
    font-weight: 600;
    text-align: center;
    line-height: 1.2;
}

.mbn-all-link {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    padding: 0.875rem;
    background: #F0FDF4;
    border: 1.5px solid #BBF7D0;
    border-radius: 0.875rem;
    color: #15803D;
    font-family: var(--font-heading);
    font-weight: 600;
    font-size: 0.875rem;
    text-decoration: none;
    transition: all 0.15s;
}
.mbn-all-link:hover {
    background: #DCFCE7;
    border-color: #86EFAC;
}

/* Push page content up so bottom nav doesn't cover it */
@media (max-width: 1023px) {
    main#main-content {
        padding-bottom: calc(60px + env(safe-area-inset-bottom, 0px));
    }
    /* Adjust scroll-top button so it stays above the bottom nav */
    .scroll-top-btn {
        bottom: calc(72px + env(safe-area-inset-bottom, 0px));
    }
}

/* ── Scroll to Top Button ────────────────────────────────────────────────── */
.scroll-top-btn {
    position: fixed;
    bottom: clamp(1.25rem, 4vw, 2rem);
    right: clamp(1rem, 3vw, 1.75rem);
    z-index: 999;

    width: 48px;
    height: 48px;
    border-radius: 50%;
    border: none;
    cursor: pointer;

    background: #16A34A;
    color: white;
    box-shadow: 0 4px 16px rgba(22, 163, 74, 0.45), 0 2px 6px rgba(0,0,0,0.12);

    display: flex;
    align-items: center;
    justify-content: center;

    /* Hidden by default */
    opacity: 0;
    transform: translateY(16px) scale(0.85);
    pointer-events: none;
    transition:
        opacity  0.3s cubic-bezier(.22,.68,0,1.2),
        transform 0.3s cubic-bezier(.22,.68,0,1.4),
        background 0.2s ease,
        box-shadow 0.2s ease;
}

.scroll-top-btn svg {
    width: 20px;
    height: 20px;
    transition: transform 0.25s cubic-bezier(.22,.68,0,1.6);
}

/* Visible state */
.scroll-top-btn.visible {
    opacity: 1;
    transform: translateY(0) scale(1);
    pointer-events: auto;
}

/* Hover */
.scroll-top-btn:hover {
    background: #15803D;
    box-shadow: 0 6px 24px rgba(22, 163, 74, 0.55), 0 3px 8px rgba(0,0,0,0.15);
    transform: translateY(-3px) scale(1.08);
}
.scroll-top-btn:hover svg {
    transform: translateY(-2px);
}

/* Active / press */
.scroll-top-btn:active {
    transform: scale(0.95) !important;
    box-shadow: 0 2px 8px rgba(22, 163, 74, 0.3) !important;
}

/* Progress ring (optional visual indicator) */
.scroll-top-btn::before {
    content: '';
    position: absolute;
    inset: -3px;
    border-radius: 50%;
    border: 2px solid rgba(22, 163, 74, 0.25);
    opacity: 0;
    transform: scale(0.8);
    transition: opacity 0.3s, transform 0.3s;
}
.scroll-top-btn.visible:hover::before {
    opacity: 1;
    transform: scale(1);
}

/* Pulse animation when first appearing */
@keyframes scrollBtnAppear {
    0%   { box-shadow: 0 0 0 0 rgba(22, 163, 74, 0.5); }
    70%  { box-shadow: 0 0 0 12px rgba(22, 163, 74, 0); }
    100% { box-shadow: 0 4px 16px rgba(22, 163, 74, 0.45); }
}
.scroll-top-btn.visible {
    animation: scrollBtnAppear 0.6s ease-out;
}

/* Keep above mobile navigation bars on phones */
@media (max-width: 639px) {
    .scroll-top-btn {
        bottom: 1.25rem;
        right: 1rem;
        width: 44px;
        height: 44px;
    }
    .scroll-top-btn svg { width: 18px; height: 18px; }
}

/* ── Hover micro-animations ──────────────────────────────────────────────── */

/* Lift effect on interactive cards */
.stat-card,
.category-card,
.tool-card,
.food-card,
.recipe-card,
.blog-card {
    transition: transform 0.25s cubic-bezier(.22,.68,0,1.4),
                box-shadow 0.25s ease,
                border-color 0.2s ease;
}
.stat-card:hover    { transform: translateY(-6px) scale(1.02); }
.category-card:hover{ transform: translateY(-4px) scale(1.04); }
.tool-card:hover    { transform: translateY(-4px) scale(1.02); }
.food-card:hover    { transform: translateY(-4px); }
.recipe-card:hover  { transform: translateY(-3px); }
.blog-card:hover    { transform: translateY(-3px); }

/* Button press effect */
.btn-primary:active,
.btn-secondary:active,
.btn-outline:active {
    transform: scale(0.97) translateY(1px) !important;
}

/* Icon bounce on hover */
.group:hover .group-icon-bounce {
    animation: iconBounce 0.4s cubic-bezier(.22,.68,0,1.6) both;
}
@keyframes iconBounce {
    0%   { transform: scale(1); }
    50%  { transform: scale(1.25) rotate(-5deg); }
    100% { transform: scale(1); }
}

/* Shimmer on badge hover */
.section-badge {
    position: relative;
    overflow: hidden;
}
.section-badge::after {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(90deg, transparent 0%, rgba(255,255,255,0.5) 50%, transparent 100%);
    transform: translateX(-100%);
    transition: transform 0s;
}
.section-badge:hover::after {
    transform: translateX(100%);
    transition: transform 0.5s ease;
}

/* Link underline slide */
.footer-link {
    position: relative;
}
.footer-link::after {
    content: '';
    position: absolute;
    bottom: -1px;
    left: 0;
    width: 0;
    height: 1px;
    background: #D1FAE5;
    transition: width 0.2s ease;
}
.footer-link:hover::after { width: 100%; }

/* Nav link underline */
.nav-link {
    position: relative;
}
.nav-link::after {
    content: '';
    position: absolute;
    bottom: 4px;
    left: 50%;
    transform: translateX(-50%);
    width: 0;
    height: 2px;
    background: #16A34A;
    border-radius: 9999px;
    transition: width 0.2s ease;
}
.nav-link:hover::after,
.nav-link.active::after { width: 60%; }

/* ── Print ───────────────────────────────────────────────────────────────── */
@media print {
    header, footer, .no-print, nav,
    .mobile-bottom-nav, .mbn-drawer, .mbn-overlay,
    .scroll-top-btn, #pwa-install-banner { display: none !important; }
    body { color: black; background: white; font-size: 12pt; }
    .calc-result { border: 1px solid #ccc; }
    main#main-content { padding-bottom: 0 !important; }
}

/* ── Responsividade complementar ────────────────────────────────────────── */

/* Garantir que imagens nunca transbordem */
img { max-width: 100%; height: auto; }

/* Inputs em mobile: previne zoom automático no iOS (font-size >= 16px) */
@media (max-width: 767px) {
    .form-input,
    .form-select,
    .form-textarea,
    input[type="text"],
    input[type="number"],
    input[type="email"],
    input[type="search"],
    select,
    textarea {
        font-size: 16px !important;
    }
}

/* Tabelas admin: scroll horizontal em mobile */
@media (max-width: 1023px) {
    .admin-table-wrap {
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
        border-radius: 0.75rem;
    }
}

/* Blog sidebar: em mobile vai abaixo do conteúdo */
@media (max-width: 1023px) {
    .blog-sidebar-sticky { position: static !important; }
}

/* Comparador: chips de alimentos selecionados não transbordam */
#selected-foods {
    max-width: 100%;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
}

/* Calculadora: resultado sempre legível em mobile */
@media (max-width: 639px) {
    .calc-result .text-5xl { font-size: 2.5rem; }
    .range-bar { margin: 0.75rem 0; }
}

/* Hero: título em telas muito pequenas */
@media (max-width: 375px) {
    #hero-title { font-size: 1.5rem !important; }
    .btn-primary, .btn-secondary { padding: 0.625rem 1rem; font-size: 0.8125rem; }
}

/* Section badge: nunca quebra linha */
.section-badge { white-space: nowrap; }

/* Pagination: scrollável em mobile */
.pagination { overflow-x: auto; flex-wrap: nowrap; padding-bottom: 0.25rem; }
@media (max-width: 480px) {
    .pagination a, .pagination span { min-width: 2rem; min-height: 2rem; font-size: 0.75rem; }
}

/* Meal planner: input de quantidade menor em mobile */
@media (max-width: 480px) {
    .meal-item input[type="number"] { width: 4rem; }
}

/* Alimentos: card grid mínimo 2 colunas mesmo em telas < 375px */
@media (max-width: 374px) {
    .food-grid {
        grid-template-columns: repeat(2, 1fr) !important;
    }
}

/* PWA: bottom navbar não sobrepõe dropdown de resultados */
#search-results,
#hero-search-results,
#food-search-results,
#mp-search-results,
.comp-search-results {
    z-index: 55;
}

/* Safe area para iPhones com notch (bottom) */
@supports (padding-bottom: env(safe-area-inset-bottom)) {
    .mobile-bottom-nav {
        padding-bottom: env(safe-area-inset-bottom);
    }
    @media (max-width: 1023px) {
        main#main-content {
            padding-bottom: calc(60px + env(safe-area-inset-bottom));
        }
    }
}

/* PWA standalone: esconder elementos desnecessários */
@media (display-mode: standalone) {
    .pwa-hide-standalone { display: none !important; }
}

/* ── Focus visible (acessibilidade) ─────────────────────────────────────── */
:focus-visible {
    outline: 2px solid #16A34A;
    outline-offset: 2px;
}
button:focus-visible,
a:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible {
    outline: 2px solid #16A34A;
    outline-offset: 2px;
    border-radius: 0.375rem;
}

/* ── Scrollbar fina em mobile (WebKit) ───────────────────────────────────── */
@media (max-width: 1023px) {
    ::-webkit-scrollbar { width: 3px; height: 3px; }
}

/* ══════════════════════════════════════════════════════════════════════════
   GOOGLE ADSENSE — Slots de Anúncio
   Placeholder visual enquanto aguarda aprovação
   ══════════════════════════════════════════════════════════════════════════ */

.ad-slot {
    display: block;
    width: 100%;
    margin: 0 auto;
    clear: both;
}

/* Wrapper de seção de anúncio com label "Publicidade" */
.ad-wrapper {
    text-align: center;
    padding: 0.5rem 1rem;
    position: relative;
}
.ad-wrapper::before {
    content: 'Publicidade';
    display: block;
    font-size: 0.625rem;
    font-weight: 600;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: #9CA3AF;
    margin-bottom: 0.375rem;
}

/* Placeholder visual (antes da aprovação) */
.ad-slot--placeholder {
    margin: 0 auto;
}
.ad-slot--placeholder .ad-slot__inner {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.75rem;
    width: 100%;
    background: #F9FAFB;
    border: 1.5px dashed #D1FAE5;
    border-radius: 0.75rem;
    padding: 0.75rem 1rem;
    transition: background 0.2s;
}
.ad-slot--placeholder .ad-slot__icon {
    width: 22px;
    height: 22px;
    color: #86EFAC;
    flex-shrink: 0;
}
.ad-slot--placeholder .ad-slot__info {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 0.125rem;
    min-width: 0;
}
.ad-slot--placeholder .ad-slot__tag {
    font-size: 0.625rem;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: #9CA3AF;
}
.ad-slot--placeholder .ad-slot__label {
    font-size: 0.75rem;
    font-weight: 600;
    color: #6B7280;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 220px;
}
.ad-slot--placeholder .ad-slot__size {
    font-size: 0.625rem;
    color: #BBF7D0;
    font-family: monospace;
}

/* Tipos específicos */
.ad-slot--leaderboard .ad-slot__inner  { min-height: 70px; }
.ad-slot--rectangle   .ad-slot__inner  { min-height: 180px; flex-direction: column; text-align: center; }
.ad-slot--rectangle   .ad-slot__info   { align-items: center; }
.ad-slot--sidebar     .ad-slot__inner  { min-height: 400px; flex-direction: column; text-align: center; }
.ad-slot--sidebar     .ad-slot__info   { align-items: center; }
.ad-slot--banner      .ad-slot__inner  { min-height: 50px; }
.ad-slot--in-article  .ad-slot__inner  { min-height: 150px; flex-direction: column; text-align: center; }
.ad-slot--in-article  .ad-slot__info   { align-items: center; }
.ad-slot--in-feed     .ad-slot__inner  { min-height: 120px; }

/* Separadores de seção com anúncio */
.ad-section {
    background: #FAFAFA;
    border-top: 1px solid #F3F4F6;
    border-bottom: 1px solid #F3F4F6;
    padding: 1rem 0;
    text-align: center;
}
.ad-section-inline {
    padding: 1.5rem 0;
    text-align: center;
}

/* Em mobile: leaderboard vira banner menor */
@media (max-width: 767px) {
    .ad-slot--leaderboard .ad-slot__inner { min-height: 50px; }
    .ad-slot--sidebar     .ad-slot__inner { min-height: 200px; }
    .ad-slot--rectangle   .ad-slot__inner { min-height: 130px; }
}

/* Não mostrar placeholder em modo print */
@media print {
    .ad-slot, .ad-wrapper, .ad-section { display: none !important; }
}
