:root {
    --primary: #1e293b;
    --primary-hover: #334155;
    --accent: #3b5998;
    --bg: #f8f8f7;
    --surface: #ffffff;
    --text-main: #18181b;
    --text-muted: #71717a;
    --border: #e4e4e7;
    --success: #15803d;
    --danger: #dc2626;
    --shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.04);
    --shadow-md: 0 8px 24px -6px rgba(0, 0, 0, 0.06);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
}

html {
    scroll-behavior: smooth;
    -webkit-tap-highlight-color: transparent;
    overflow-x: hidden;
}

body {
    background-color: var(--bg);
    color: var(--text-main);
    line-height: 1.55;
    padding-bottom: 4.5rem;
    -webkit-font-smoothing: antialiased;
    overflow-x: hidden;
    width: 100%;
}

/* Minimal Header */
.header {
    background: rgba(255, 255, 255, 0.92);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    padding: 0.85rem 5%;
    border-bottom: 1px solid var(--border);
    display: flex;
    justify-content: space-between;
    align-items: center;
    position: sticky;
    top: 0;
    z-index: 900;
    width: 100%;
}

.logo {
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 0.65rem;
    min-width: 0;
}

.koreve-emblem {
    flex-shrink: 0;
}

.brand-name {
    font-size: 1.3rem;
    font-weight: 700;
    color: var(--text-main);
    letter-spacing: -0.03em;
}

.header-actions {
    display: flex;
    align-items: center;
    gap: 0.65rem;
    flex-shrink: 0;
}

.currency-select {
    padding: 0.48rem 0.75rem;
    border-radius: 10px;
    border: 1px solid var(--border);
    background: var(--surface);
    font-weight: 600;
    font-size: 0.84rem;
    color: var(--text-main);
    cursor: pointer;
    outline: none;
}

.trip-drawer-btn {
    background: var(--primary);
    color: white;
    border: none;
    padding: 0.5rem 0.95rem;
    border-radius: 10px;
    font-weight: 600;
    font-size: 0.85rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    transition: background 0.2s;
}

.trip-drawer-btn:hover {
    background: var(--primary-hover);
}

.trip-badge {
    background: rgba(255, 255, 255, 0.2);
    color: white;
    font-size: 0.72rem;
    padding: 0.08rem 0.45rem;
    border-radius: 99px;
}

/* Container */
.container {
    max-width: 1240px;
    width: 100%;
    margin: 0 auto;
    padding: 1.75rem 1.5rem 0;
    overflow-x: hidden;
}

/* Quiet Planner Section */
.planner-section {
    background: var(--surface);
    border-radius: 18px;
    padding: 1.65rem 1.85rem;
    margin-bottom: 2.5rem;
    box-shadow: var(--shadow-sm);
    border: 1px solid var(--border);
    width: 100%;
    overflow: hidden;
}

.planner-header {
    margin-bottom: 1.25rem;
}

.planner-title {
    font-size: 1.22rem;
    font-weight: 700;
    letter-spacing: -0.02em;
    color: var(--text-main);
}

.planner-sub {
    color: var(--text-muted);
    font-size: 0.88rem;
    margin-top: 0.2rem;
}

.planner-form {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 0.85rem;
    align-items: end;
    width: 100%;
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 0.35rem;
    min-width: 0;
    width: 100%;
}

.form-group label {
    font-size: 0.78rem;
    font-weight: 600;
    color: var(--text-muted);
}

.form-group select,
.form-group input {
    width: 100%;
    max-width: 100%;
    min-width: 0;
    padding: 0.68rem 0.75rem;
    border: 1px solid var(--border);
    border-radius: 10px;
    font-size: 0.9rem;
    font-weight: 500;
    outline: none;
    background: var(--bg);
    color: var(--text-main);
    transition: border-color 0.2s, background 0.2s;
}

.form-group select:focus,
.form-group input:focus {
    border-color: var(--primary);
    background: var(--surface);
}

.plan-btn {
    background: var(--primary);
    color: white;
    border: none;
    padding: 0.7rem 1.25rem;
    border-radius: 10px;
    font-size: 0.9rem;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.2s;
    height: 41px;
    width: 100%;
    min-width: 0;
}

.plan-btn:hover {
    background: var(--primary-hover);
}

/* Generated Itinerary Result */
.plan-result {
    margin-top: 1.5rem;
    background: var(--bg);
    border: 1px solid var(--border);
    border-radius: 14px;
    padding: 1.35rem;
    display: none;
    width: 100%;
}

.plan-result.show {
    display: block;
    animation: fadeIn 0.25s ease;
}

.plan-result-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 0.75rem;
    margin-bottom: 1.1rem;
}

.plan-result-header h4 {
    color: var(--text-main);
    font-size: 1.05rem;
    font-weight: 700;
}

.save-all-plan-btn {
    background: var(--surface);
    color: var(--text-main);
    border: 1px solid var(--border);
    padding: 0.45rem 0.85rem;
    border-radius: 8px;
    font-weight: 600;
    font-size: 0.82rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 0.4rem;
    transition: all 0.2s;
}

.save-all-plan-btn:hover {
    border-color: var(--primary);
}

.day-blocks {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 0.85rem;
    margin-bottom: 1.1rem;
}

.day-card {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 12px;
    padding: 1rem;
    min-width: 0;
}

.day-badge {
    display: inline-block;
    background: var(--bg);
    color: var(--text-muted);
    font-weight: 600;
    font-size: 0.74rem;
    padding: 0.18rem 0.6rem;
    border-radius: 6px;
    margin-bottom: 0.45rem;
}

.day-spot-title {
    font-weight: 700;
    font-size: 0.98rem;
    margin-bottom: 0.25rem;
}

.day-spot-meta {
    font-size: 0.82rem;
    color: var(--text-muted);
    margin-bottom: 0.55rem;
}

.day-food-tip {
    font-size: 0.8rem;
    background: var(--bg);
    color: var(--text-main);
    padding: 0.45rem 0.65rem;
    border-radius: 8px;
}

.plan-breakdown {
    background: var(--surface);
    border-radius: 12px;
    padding: 1rem 1.2rem;
    border: 1px solid var(--border);
}

.plan-list {
    list-style: none;
    margin-bottom: 0.75rem;
}

.plan-list li {
    padding: 0.38rem 0;
    border-bottom: 1px solid var(--border);
    display: flex;
    justify-content: space-between;
    gap: 0.5rem;
    font-size: 0.88rem;
}

.plan-list li:last-child {
    border-bottom: none;
}

.plan-total {
    font-weight: 700;
    font-size: 1.02rem;
    color: var(--text-main);
    display: flex;
    justify-content: space-between;
    padding-top: 0.65rem;
    border-top: 1px solid var(--border);
}

.plan-status {
    margin-top: 0.85rem;
    padding: 0.7rem 0.9rem;
    border-radius: 10px;
    font-size: 0.85rem;
    font-weight: 500;
}

.plan-status.success {
    background: #f0fdf4;
    color: #166534;
    border: 1px solid #bbf7d0;
}

.plan-status.warning {
    background: #fffbeb;
    color: #92400e;
    border: 1px solid #fde68a;
}

/* Search & Filter Toolbar */
.discover-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 1rem;
    margin-bottom: 1.15rem;
    width: 100%;
}

.section-title {
    font-size: 1.45rem;
    font-weight: 700;
    letter-spacing: -0.02em;
    color: var(--text-main);
}

.search-sort-bar {
    display: flex;
    gap: 0.65rem;
    flex-wrap: wrap;
    flex: 1 1 280px;
    max-width: 480px;
    min-width: 0;
}

.search-box {
    position: relative;
    flex: 1 1 160px;
    min-width: 0;
}

.search-box i {
    position: absolute;
    left: 0.85rem;
    top: 50%;
    transform: translateY(-50%);
    color: var(--text-muted);
    font-size: 0.85rem;
    pointer-events: none;
}

.search-box input {
    width: 100%;
    min-width: 0;
    padding: 0.62rem 0.85rem 0.62rem 2.25rem;
    border: 1px solid var(--border);
    border-radius: 10px;
    background: var(--surface);
    color: var(--text-main);
    font-size: 0.88rem;
    outline: none;
}

.search-box input:focus {
    border-color: var(--primary);
}

.sort-select {
    padding: 0.62rem 0.75rem;
    border: 1px solid var(--border);
    border-radius: 10px;
    background: var(--surface);
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--text-main);
    cursor: pointer;
    outline: none;
    flex-shrink: 0;
}

/* Filter Pills */
.filters-wrapper {
    display: flex;
    flex-direction: column;
    gap: 0.6rem;
    margin-bottom: 1.75rem;
    width: 100%;
    min-width: 0;
}

.filter-row {
    display: flex;
    align-items: center;
    gap: 0.45rem;
    flex-wrap: wrap;
    width: 100%;
    min-width: 0;
}

.pill-btn {
    background: var(--surface);
    border: 1px solid var(--border);
    padding: 0.42rem 0.9rem;
    border-radius: 99px;
    font-size: 0.82rem;
    font-weight: 600;
    color: var(--text-muted);
    cursor: pointer;
    transition: all 0.15s;
    white-space: nowrap;
}

.pill-btn:hover {
    border-color: var(--primary);
    color: var(--text-main);
}

.pill-btn.active {
    background: var(--primary);
    color: white;
    border-color: var(--primary);
}

.free-toggle {
    margin-left: auto;
    display: flex;
    align-items: center;
    gap: 0.4rem;
    font-size: 0.82rem;
    font-weight: 600;
    color: var(--text-main);
    cursor: pointer;
    background: var(--surface);
    padding: 0.4rem 0.85rem;
    border-radius: 99px;
    border: 1px solid var(--border);
    white-space: nowrap;
}

.free-toggle input {
    accent-color: var(--primary);
    width: 15px;
    height: 15px;
    cursor: pointer;
}

/* Grid & Minimal Cards */
.grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(290px, 1fr));
    gap: 1.5rem;
    width: 100%;
}

.card {
    background: var(--surface);
    border-radius: 16px;
    overflow: hidden;
    box-shadow: var(--shadow-sm);
    border: 1px solid var(--border);
    transition: transform 0.25s ease, box-shadow 0.25s ease;
    cursor: pointer;
    display: flex;
    flex-direction: column;
    min-width: 0;
}

.card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-md);
}

.card-img-wrap {
    position: relative;
    width: 100%;
    height: 225px;
    overflow: hidden;
    background: #f1f5f9;
}

.card-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.4s ease;
}

.card:hover .card-image {
    transform: scale(1.03);
}

.card-city-badge {
    position: absolute;
    top: 12px;
    left: 12px;
    background: rgba(255, 255, 255, 0.92);
    backdrop-filter: blur(6px);
    color: var(--text-main);
    font-size: 0.74rem;
    font-weight: 600;
    padding: 0.26rem 0.68rem;
    border-radius: 8px;
}

.card-save-btn {
    position: absolute;
    top: 12px;
    right: 12px;
    width: 34px;
    height: 34px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.92);
    border: none;
    color: var(--text-muted);
    font-size: 0.92rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s;
}

.card-save-btn:hover {
    transform: scale(1.08);
}

.card-save-btn.saved {
    color: var(--danger);
}

.card-content {
    padding: 1.2rem;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
}

.card-top-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.76rem;
    font-weight: 500;
    color: var(--text-muted);
    margin-bottom: 0.35rem;
}

.card-rating {
    color: var(--text-main);
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 0.25rem;
}

.card-rating i {
    color: #eab308;
    font-size: 0.72rem;
}

.card-title {
    font-size: 1.12rem;
    font-weight: 700;
    margin-bottom: 0.4rem;
    color: var(--text-main);
    letter-spacing: -0.01em;
}

.card-desc {
    color: var(--text-muted);
    font-size: 0.87rem;
    margin-bottom: 1.1rem;
    flex-grow: 1;
}

.card-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-top: 0.8rem;
    border-top: 1px solid var(--border);
}

.price-tag {
    font-weight: 700;
    font-size: 0.98rem;
    color: var(--text-main);
}

.price-tag.free {
    color: var(--success);
}

.loc-btn {
    background: var(--bg);
    color: var(--text-main);
    border: 1px solid var(--border);
    padding: 0.38rem 0.75rem;
    border-radius: 8px;
    font-size: 0.8rem;
    font-weight: 600;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 0.35rem;
    transition: all 0.2s;
}

.loc-btn:hover {
    background: var(--primary);
    color: white;
    border-color: var(--primary);
}

.empty-state {
    grid-column: 1 / -1;
    text-align: center;
    padding: 3.5rem 1rem;
    background: var(--surface);
    border-radius: 16px;
    border: 1px dashed var(--border);
}

.empty-state i {
    font-size: 2rem;
    color: var(--text-muted);
    margin-bottom: 0.65rem;
}

/* Modal */
.modal-overlay {
    position: fixed;
    inset: 0;
    background: rgba(24, 24, 27, 0.55);
    backdrop-filter: blur(4px);
    display: none;
    justify-content: center;
    align-items: center;
    z-index: 1000;
    padding: 1rem;
}

.modal-overlay.active {
    display: flex;
}

.modal {
    background: var(--surface);
    border-radius: 20px;
    max-width: 680px;
    width: 100%;
    max-height: 90vh;
    overflow-y: auto;
    position: relative;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.2);
}

.modal-close {
    position: absolute;
    top: 1rem;
    right: 1rem;
    background: rgba(255, 255, 255, 0.92);
    border: none;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    font-size: 1rem;
    cursor: pointer;
    z-index: 10;
    display: flex;
    align-items: center;
    justify-content: center;
}

.modal-hero-img {
    width: 100%;
    height: 330px;
    object-fit: cover;
    display: block;
}

.modal-thumbs {
    display: flex;
    gap: 0.5rem;
    padding: 0.85rem 1.5rem 0;
    overflow-x: auto;
}

.modal-thumbs img {
    width: 68px;
    height: 50px;
    object-fit: cover;
    border-radius: 8px;
    cursor: pointer;
    opacity: 0.55;
    border: 2px solid transparent;
    transition: all 0.2s;
}

.modal-thumbs img.active,
.modal-thumbs img:hover {
    opacity: 1;
    border-color: var(--primary);
}

.modal-info {
    padding: 1.5rem;
}

.modal-info h2 {
    font-size: 1.5rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
}

.modal-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-bottom: 1.1rem;
}

.modal-meta span {
    background: var(--bg);
    border: 1px solid var(--border);
    padding: 0.3rem 0.7rem;
    border-radius: 8px;
    font-size: 0.8rem;
    font-weight: 600;
    color: var(--text-main);
    display: flex;
    align-items: center;
    gap: 0.35rem;
}

.modal-info p {
    color: var(--text-main);
    margin-bottom: 1rem;
    font-size: 0.92rem;
}

.insider-tip {
    background: var(--bg);
    border-left: 3px solid var(--primary);
    padding: 0.85rem 1rem;
    border-radius: 0 10px 10px 0;
    margin-bottom: 1.1rem;
    font-size: 0.86rem;
}

/* Nearby Hotels inside Modal */
.nearby-hotels-section {
    margin: 1.25rem 0;
    padding-top: 1.15rem;
    border-top: 1px solid var(--border);
}

.nearby-hotels-title {
    font-size: 0.92rem;
    font-weight: 700;
    color: var(--text-main);
    margin-bottom: 0.75rem;
    display: flex;
    align-items: center;
    gap: 0.45rem;
}

.nearby-hotels-list {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 0.65rem;
}

.hotel-card {
    background: var(--bg);
    border: 1px solid var(--border);
    border-radius: 12px;
    padding: 0.85rem 0.95rem;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    gap: 0.55rem;
}

.hotel-top {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 0.5rem;
}

.hotel-name {
    font-weight: 700;
    font-size: 0.9rem;
    color: var(--text-main);
    line-height: 1.3;
}

.hotel-rating {
    font-size: 0.76rem;
    font-weight: 600;
    color: var(--text-main);
    white-space: nowrap;
}

.hotel-rating i {
    color: #eab308;
    font-size: 0.7rem;
}

.hotel-meta {
    font-size: 0.78rem;
    color: var(--text-muted);
}

.hotel-bottom {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-top: 0.45rem;
    border-top: 1px solid var(--border);
}

.hotel-price {
    font-size: 0.85rem;
    font-weight: 700;
    color: var(--text-main);
}

.hotel-price span {
    font-weight: 500;
    font-size: 0.74rem;
    color: var(--text-muted);
}

.hotel-map-btn {
    background: var(--surface);
    color: var(--text-main);
    border: 1px solid var(--border);
    padding: 0.3rem 0.65rem;
    border-radius: 7px;
    font-size: 0.76rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.15s;
}

.hotel-map-btn:hover {
    background: var(--primary);
    color: white;
    border-color: var(--primary);
}

.modal-cta-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0.65rem;
    margin-top: 0.85rem;
}

.btn-primary {
    background: var(--primary);
    color: white;
    border: none;
    padding: 0.8rem 1.1rem;
    border-radius: 10px;
    font-weight: 600;
    font-size: 0.88rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.45rem;
}

.btn-primary:hover {
    background: var(--primary-hover);
}

.btn-secondary {
    background: var(--bg);
    color: var(--text-main);
    border: 1px solid var(--border);
    padding: 0.8rem 1.1rem;
    border-radius: 10px;
    font-weight: 600;
    font-size: 0.88rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.45rem;
}

.btn-secondary:hover {
    border-color: var(--primary);
}

/* Saved Trip Drawer */
.drawer-backdrop {
    position: fixed;
    inset: 0;
    background: rgba(24, 24, 27, 0.45);
    display: none;
    z-index: 1100;
}

.drawer-backdrop.active {
    display: block;
}

.drawer {
    position: fixed;
    top: 0;
    right: -400px;
    width: 100%;
    max-width: 380px;
    height: 100vh;
    background: var(--surface);
    box-shadow: -8px 0 24px rgba(0, 0, 0, 0.1);
    z-index: 1101;
    display: flex;
    flex-direction: column;
    transition: right 0.25s ease;
}

.drawer.open {
    right: 0;
}

.drawer-header {
    padding: 1.2rem 1.4rem;
    border-bottom: 1px solid var(--border);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.drawer-header h3 {
    font-size: 1.12rem;
    font-weight: 700;
}

.drawer-body {
    flex: 1;
    overflow-y: auto;
    padding: 1.2rem 1.4rem;
}

.drawer-people-bar {
    background: var(--bg);
    padding: 0.65rem 0.9rem;
    border-radius: 10px;
    border: 1px solid var(--border);
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.1rem;
    font-size: 0.86rem;
    font-weight: 600;
}

.drawer-people-bar input {
    width: 60px;
    padding: 0.3rem 0.45rem;
    border-radius: 6px;
    border: 1px solid var(--border);
    text-align: center;
    font-weight: 600;
}

.saved-item {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.7rem;
    border: 1px solid var(--border);
    border-radius: 12px;
    margin-bottom: 0.65rem;
}

.saved-item-thumb {
    width: 50px;
    height: 50px;
    border-radius: 8px;
    overflow: hidden;
    flex-shrink: 0;
}

.saved-item-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.saved-item-info {
    flex: 1;
}

.saved-item-title {
    font-weight: 600;
    font-size: 0.9rem;
}

.saved-item-sub {
    font-size: 0.78rem;
    color: var(--text-muted);
}

.remove-saved-btn {
    background: none;
    border: none;
    color: var(--text-muted);
    cursor: pointer;
    padding: 0.35rem;
}

.remove-saved-btn:hover {
    color: var(--danger);
}

.drawer-footer {
    padding: 1.15rem 1.4rem;
    border-top: 1px solid var(--border);
    background: var(--bg);
}

.drawer-total-row {
    display: flex;
    justify-content: space-between;
    font-weight: 700;
    font-size: 1rem;
    margin-bottom: 0.85rem;
}

.drawer-actions {
    display: flex;
    gap: 0.55rem;
}

.drawer-actions button {
    flex: 1;
}

/* Toast Notification */
.toast {
    position: fixed;
    bottom: 1.5rem;
    left: 50%;
    transform: translateX(-50%) translateY(100px);
    background: var(--primary);
    color: white;
    padding: 0.7rem 1.25rem;
    border-radius: 99px;
    font-size: 0.85rem;
    font-weight: 500;
    z-index: 1200;
    opacity: 0;
    transition: all 0.25s ease;
    display: flex;
    align-items: center;
    gap: 0.45rem;
}

.toast.show {
    transform: translateX(-50%) translateY(0);
    opacity: 1;
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

/* Мобильный режим (Android & iOS) */
.mobile-tab-bar {
    display: none;
}

@media (max-width: 768px) {
    body {
        padding-bottom: calc(5rem + env(safe-area-inset-bottom));
    }

    .desktop-only {
        display: none !important;
    }

    .header {
        padding: calc(0.7rem + env(safe-area-inset-top)) 1rem 0.7rem;
    }

    .container {
        padding: 0.9rem 0.9rem 0;
    }

    .planner-section {
        padding: 1.1rem;
        margin-bottom: 1.5rem;
        border-radius: 16px;
    }

    .planner-form {
        grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
        gap: 0.65rem;
    }

    .form-group select,
    .form-group input,
    .search-box input,
    .sort-select {
        font-size: 15px;
        padding: 0.6rem 0.65rem;
    }

    .search-box input {
        padding-left: 2.15rem;
    }

    .plan-btn {
        grid-column: 1 / -1;
        height: 44px;
    }

    .discover-header {
        gap: 0.7rem;
    }

    .search-sort-bar {
        max-width: 100%;
        width: 100%;
        flex-wrap: nowrap;
        gap: 0.45rem;
    }

    .search-box {
        flex: 1 1 auto;
        min-width: 0;
    }

    .sort-select {
        max-width: 112px;
        font-size: 0.8rem;
        padding: 0.6rem 0.55rem;
    }

    .filter-row {
        flex-wrap: nowrap;
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
        scrollbar-width: none;
        padding-bottom: 2px;
    }

    .filter-row::-webkit-scrollbar {
        display: none;
    }

    .pill-btn,
    .free-toggle {
        flex-shrink: 0;
    }

    .free-toggle {
        margin-left: 0;
    }

    .grid {
        grid-template-columns: minmax(0, 1fr);
        gap: 1.15rem;
    }

    .modal-overlay {
        padding: 0;
        align-items: flex-end;
    }

    .modal {
        border-radius: 22px 22px 0 0;
        max-height: 90vh;
    }

    .modal-cta-row {
        grid-template-columns: minmax(0, 1fr);
    }

    .drawer {
        max-width: 100%;
        right: -100%;
    }

    .mobile-tab-bar {
        display: flex;
        position: fixed;
        bottom: 0;
        left: 0;
        right: 0;
        background: rgba(255, 255, 255, 0.96);
        backdrop-filter: blur(12px);
        border-top: 1px solid var(--border);
        padding: 0.45rem 0.5rem calc(0.45rem + env(safe-area-inset-bottom));
        z-index: 950;
        justify-content: space-around;
    }

    .tab-item {
        background: none;
        border: none;
        display: flex;
        flex-direction: column;
        align-items: center;
        gap: 0.2rem;
        color: var(--text-muted);
        font-size: 0.7rem;
        font-weight: 600;
        cursor: pointer;
        flex: 1;
    }

    .tab-item i {
        font-size: 1.15rem;
    }

    .tab-item.active {
        color: var(--primary);
    }

    .tab-icon-wrap {
        position: relative;
        display: inline-flex;
    }

    .mobile-tab-badge {
        position: absolute;
        top: -4px;
        right: -10px;
        background: var(--primary);
        color: white;
        font-size: 0.62rem;
        font-weight: 700;
        padding: 0.04rem 0.35rem;
        border-radius: 99px;
    }

    .toast {
        bottom: calc(4.75rem + env(safe-area-inset-bottom));
    }
}