/* Tablet: 768-1024px */
@media (max-width: 1024px) {
    .card-grid { grid-template-columns: repeat(2, 1fr); }
    .with-sidebar { grid-template-columns: 1fr; }
    .tool-detail-header { grid-template-columns: 1fr; gap: 24px; }
    .stats-grid { grid-template-columns: repeat(2, 1fr); }
    .nav-search input { width: 140px; }
}

/* Mobile: < 768px */
@media (max-width: 768px) {
    body { font-size: 15px; }
    .container { padding: 0 16px; }

    /* Hamburger nav */
    .hamburger { display: flex; }
    .nav-menu {
        display: none;
        position: absolute;
        top: 64px;
        left: 0;
        right: 0;
        background: var(--bg);
        border-bottom: 1px solid var(--border);
        flex-direction: column;
        padding: 8px 16px;
        box-shadow: var(--shadow);
    }
    .nav-menu.show { display: flex; }
    .nav-menu a { padding: 12px 16px; font-size: 16px; }
    .nav-search { display: none; }

    /* Hero */
    .hero { padding: 32px 0; }
    .hero h1 { font-size: 24px; }
    .hero p { font-size: 16px; }

    /* Cards */
    .card-grid { grid-template-columns: 1fr; gap: 14px; }
    .card { padding: 16px; }

    /* Post list */
    .post-item { flex-direction: column; gap: 8px; padding: 14px; }

    /* Tool detail */
    .tool-detail-header { padding: 20px 0; }
    .tool-info h1 { font-size: 22px; }
    .download-btn { width: 100%; justify-content: center; padding: 14px 24px; font-size: 16px; min-height: 48px; }
    .tool-meta { flex-wrap: wrap; gap: 12px; }

    /* Section */
    .section { padding: 24px 0; }
    .section-title { font-size: 18px; }

    /* Social proof */
    .social-proof .number { font-size: 28px; }

    /* Admin */
    .admin-sidebar { width: 56px; overflow: hidden; }
    .admin-sidebar .brand { font-size: 0; padding: 0; height: 0; overflow: hidden; }
    .admin-sidebar .nav a span { display: none; }
    .admin-sidebar .nav a { justify-content: center; padding: 12px; }
    .admin-main { padding: 16px; }
    .stats-grid { grid-template-columns: repeat(2, 1fr); gap: 10px; }
    .stat-card { padding: 14px; }
    .stat-card .value { font-size: 22px; }
    .table-wrap { overflow-x: auto; }

    /* Category tabs */
    .category-tabs { gap: 6px; }
    .category-tabs a { padding: 6px 14px; font-size: 13px; }

    /* Benefit bar */
    .benefit-bar .links { gap: 6px 14px; }

    /* Buttons */
    .btn { min-height: 44px; justify-content: center; }
    .btn-lg { width: 100%; justify-content: center; }

    /* Content */
    .tool-content h2 { font-size: 18px; }
    .tool-content h3 { font-size: 16px; }

    /* About */
    .about-section { padding: 24px 0; }

    /* Prevent horizontal scroll */
    html, body { overflow-x: hidden; }
    img, pre, code, table { max-width: 100%; word-break: break-word; }
}

/* Small phone: < 480px */
@media (max-width: 480px) {
    .stats-grid { grid-template-columns: 1fr; }
    .post-item .post-meta { gap: 8px; }
    .tool-features { gap: 6px; }
    .tool-features span { font-size: 12px; padding: 3px 10px; }
}
