/*
 * Mobile “product” shell — app-like polish (loads only ≤768px via link media).
 * Desktop uses style.css; this file is the dedicated mobile UX layer.
 */

html {
    -webkit-text-size-adjust: 100%;
}

/* Match style.css: extra space above fixed tab bar (height:auto + FAB lift) */
:root {
    --mobile-bottom-nav-stack-h: calc(
        var(--mobile-bottom-nav-h, 52px) + max(env(safe-area-inset-bottom, 0px), 6px) + 22px
    );
}

body {
    font-family:
        -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto,
        "Helvetica Neue", Arial, "Noto Sans", sans-serif,
        "Apple Color Emoji", "Segoe UI Emoji";
    -webkit-tap-highlight-color: transparent;
    touch-action: manipulation;
    background-color: #f1f5f9 !important;
}

/* İçerik: alt tab bar + güvenli alan; üst dock sayfayla kaydığı için body padding düşülmüyor */
.main-container .content-area {
    min-height: calc(100dvh - var(--mobile-bottom-nav-stack-h, 70px) - 24px);
    /* ~3px ekstra yatay nefes (önceki 10px); kenarlara yapışmayı azaltır */
    padding-left: 13px;
    padding-right: 13px;
    padding-bottom: 8px;
}

/* Arama sayfası: köşelerden %4 daha fazla yatay boşluk */
body.page-search .main-container .content-area,
.page-search .content-area {
    padding-left: 20px !important;
    padding-right: 20px !important;
}

/* Softer “card” grid like native marketplaces */
.listing-grid {
    gap: 8px !important;
    padding: 8px 0 12px;
    background: transparent !important;
}

.listing-card {
    border-radius: 12px !important;
    overflow: hidden;
    box-shadow: 0 1px 3px rgba(15, 23, 42, 0.08);
    background: #fff !important;
    transition: transform 0.12s ease;
}

.listing-card:active {
    transform: scale(0.98);
}

/* Top dock: slight elevation */
.header-container {
    box-shadow: 0 2px 12px rgba(15, 23, 42, 0.06);
}

.sidebar {
    box-shadow: 0 2px 8px rgba(15, 23, 42, 0.04);
}

.search-wrapper {
    border-radius: 10px !important;
}

.secondhand-sidebar-toggle:active,
.cat-item:active {
    opacity: 0.85;
    transform: scale(0.96);
}

/* Tab bar: stronger app chrome */
.mobile-nav {
    height: auto !important;
    min-height: var(--mobile-bottom-nav-h, 52px);
    padding-top: 3px;
    padding-bottom: max(4px, env(safe-area-inset-bottom, 0px)) !important;
    background: rgba(255, 255, 255, 0.92) !important;
    border-top: 1px solid rgba(15, 23, 42, 0.08) !important;
    box-shadow: 0 -4px 24px rgba(15, 23, 42, 0.06);
}

.mobile-nav-item {
    min-height: 40px;
    border-radius: 10px;
    transition: color 0.15s ease, transform 0.12s ease;
}

.mobile-nav-item:active {
    transform: scale(0.94);
}

.mobile-nav-item.active {
    font-weight: 700;
}

.mobile-nav-item svg {
    opacity: 0.9;
}

.mobile-nav-item.active svg {
    opacity: 1;
}

/* Form / detail pages: card padding (content-area ile aynı yatay inset) */
.form-container,
.messages-container {
    margin-left: 13px;
    margin-right: 13px;
}
