/* ============================================
   All Time Draft — Responsive Breakpoints
   3-tier system: mobile / tablet / desktop
   ============================================ */

/* ---- MOBILE: max 767px ---- */
@media (max-width: 767px) {
    .btn {
        min-height: 44px;
        padding: 14px 20px;
    }

    .form-row input,
    .form-row select,
    .form-row textarea,
    .comment-form textarea,
    .flag-form textarea,
    .flag-form select {
        min-height: 44px;
        font-size: 16px; /* prevents iOS zoom on focus */
    }

    .action-grid {
        grid-template-columns: 1fr;
    }

    .stats-bar {
        grid-template-columns: 1fr 1fr;
    }

    .desktop-nav,
    .topbar-right {
        display: none;
    }

    .filters {
        grid-template-columns: 1fr;
    }

    .player-grid {
        grid-template-columns: 1fr 1fr;
    }

    .hero h1 { font-size: 1.6rem; }

    .profile-grid {
        grid-template-columns: 1fr;
    }
}

/* ---- TABLET: 768px – 1023px ---- */
@media (min-width: 768px) {
    .grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .grid-2 {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .grid-3 {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }

    .stats-bar {
        grid-template-columns: repeat(4, 1fr);
    }

    .stats-grid {
        grid-template-columns: repeat(4, minmax(0, 1fr));
    }

    .matchup-grid {
        grid-template-columns: 1fr 1fr;
    }

    .profile-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .badge-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .filters {
        grid-template-columns: 1.4fr 0.8fr 0.8fr auto;
    }

    .hero h1 { font-size: 2.5rem; }
}

@media (min-width: 768px) and (max-width: 1023px) {
    .desktop-nav,
    .topbar-right {
        display: none;
    }
}

/* ---- DESKTOP: 1024px+ ---- */
@media (min-width: 1024px) {
    .desktop-nav,
    .topbar-right {
        display: flex;
    }

    .mobile-nav {
        display: none;
    }

    .hamburger-btn {
        display: none !important;
    }

    .site-footer {
        padding-bottom: 18px;
    }

    .page-wrap {
        padding-bottom: 20px;
    }
}

/* ============================================
   Hamburger Menu  (visible on mobile + tablet)
   ============================================ */

.hamburger-btn {
    display: none;
    background: none;
    border: none;
    color: var(--text-primary);
    font-size: 1.4rem;
    cursor: pointer;
    padding: 4px 8px;
    line-height: 1;
    min-height: 44px;
    min-width: 44px;
    align-items: center;
    justify-content: center;
    border-radius: var(--radius-md);
    transition: background 0.15s;
}

.hamburger-btn:hover {
    background: rgba(255, 255, 255, 0.06);
}

@media (max-width: 1023px) {
    .hamburger-btn {
        display: flex;
    }
}

/* Overlay dimmer */
.hamburger-overlay {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.65);
    z-index: 200;
    backdrop-filter: blur(2px);
    -webkit-backdrop-filter: blur(2px);
}

.hamburger-overlay.is-open {
    display: block;
}

/* Slide-in panel */
.hamburger-panel {
    position: fixed;
    top: 0;
    right: 0;
    transform: translateX(100%);
    width: 280px;
    max-width: 90vw;
    height: 100%;
    background: var(--bg-topbar);
    border-left: 1px solid var(--border);
    z-index: 201;
    overflow-y: auto;
    transition: transform 0.25s cubic-bezier(0.4, 0, 0.2, 1);
    display: flex;
    flex-direction: column;
}

.hamburger-panel.is-open {
    transform: translateX(0);
}

/* Panel header */
.ham-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 16px 18px;
    border-bottom: 1px solid var(--border);
    flex-shrink: 0;
}

.ham-brand {
    font-weight: bold;
    font-size: 1rem;
    color: var(--text-primary);
    text-decoration: none;
}

.ham-close {
    background: none;
    border: none;
    color: var(--text-muted);
    font-size: 1.3rem;
    cursor: pointer;
    padding: 4px 8px;
    border-radius: var(--radius-sm);
    line-height: 1;
    min-height: 36px;
    min-width: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.1s, color 0.1s;
}

.ham-close:hover {
    background: rgba(255, 255, 255, 0.06);
    color: var(--text-primary);
}

/* Section groups */
.ham-section {
    border-bottom: 1px solid var(--border);
    padding: 6px 0;
}

.ham-section:last-child {
    border-bottom: none;
}

.ham-section-label {
    font-size: 0.7rem;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--text-muted);
    padding: 8px 18px 4px 18px;
}

/* Links inside panel */
.ham-link {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 13px 18px;
    color: var(--text-secondary);
    font-size: 0.96rem;
    text-decoration: none;
    transition: background 0.1s, color 0.1s;
    min-height: 44px;
}

.ham-link:hover {
    background: rgba(255, 255, 255, 0.05);
    color: var(--text-primary);
}

.ham-link.is-accent {
    color: var(--accent);
    font-weight: bold;
}

.ham-icon {
    font-size: 1rem;
    width: 22px;
    text-align: center;
    flex-shrink: 0;
}

/* Auth at bottom */
.ham-auth {
    margin-top: auto;
    border-top: 1px solid var(--border);
    padding: 6px 0;
    flex-shrink: 0;
}
