/* Mobil — kompakt, VIP, dokunmaya uygun, dolgun tipografi */

@media (max-width: 768px) {
    html {
        -webkit-text-size-adjust: 100%;
    }

    html:not(.ios-app-shell):not(.ios-auth-shell) body:not(.msg-thread-page) {
        min-height: 100vh;
        min-height: -webkit-fill-available;
        min-height: 100dvh;
        overscroll-behavior-y: none;
        background-color: #08090c;
    }

    body {
        -webkit-font-smoothing: antialiased;
        letter-spacing: 0.01em;
    }

    .btn {
        min-height: 44px;
        font-weight: 700;
        letter-spacing: 0.02em;
    }

    .btn-primary {
        box-shadow:
            0 4px 18px rgba(212, 168, 83, 0.32),
            0 0 24px rgba(234, 179, 8, 0.14);
    }

    .page-actions .btn-primary,
    .browse-create-bar .btn-primary {
        box-shadow:
            0 6px 22px rgba(212, 168, 83, 0.38),
            0 0 32px rgba(234, 179, 8, 0.2),
            0 0 52px rgba(212, 168, 83, 0.1);
    }

    .btn-sm {
        min-height: 38px;
        font-weight: 600;
    }

    .alert {
        padding: 0.75rem 0.9rem;
        font-size: 0.88rem;
        font-weight: 500;
        border-radius: 12px;
        margin-bottom: 1rem;
    }

    /* İlan kartları — tek sütun, VIP dolgunluk */
    .job-list,
    .jobs-grid {
        grid-template-columns: 1fr;
        gap: 0.9rem;
    }

    .job-id-card {
        padding: 1rem 1.05rem;
        border-radius: 16px;
        border-color: rgba(255, 255, 255, 0.05);
        background: rgba(255, 255, 255, 0.02) !important;
        box-shadow: 0 12px 40px rgba(0, 0, 0, 0.5);
        backdrop-filter: blur(12px);
        -webkit-backdrop-filter: blur(12px);
    }

    .job-id-card::before {
        background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.07), transparent);
    }

    .job-id-card:active {
        transform: scale(0.985);
        border-color: rgba(255, 255, 255, 0.09);
    }

    .job-id-avatar {
        width: 44px;
        height: 44px;
    }

    .job-id-venue {
        font-size: 1.02rem;
        font-weight: 800;
        letter-spacing: -0.02em;
    }

    .job-id-city {
        font-size: 0.8rem;
        font-weight: 600;
    }

    .job-id-listing {
        margin-top: 0.5rem;
        padding-top: 0.45rem;
    }

    .job-id-listing-label {
        font-size: 0.56rem;
    }

    .job-id-title {
        font-size: 0.92rem;
        font-weight: 700;
        color: var(--text);
    }

    .job-id-excerpt {
        font-size: 0.8rem;
        font-weight: 500;
    }

    .job-id-tags span {
        font-size: 0.72rem;
        font-weight: 600;
        padding: 0.3rem 0.58rem;
        background: rgba(255, 255, 255, 0.03);
        border-color: rgba(255, 255, 255, 0.06);
        color: rgba(255, 255, 255, 0.65);
    }

    .job-id-card-footer {
        margin-top: 0.75rem;
        padding-top: 0.75rem;
        gap: 0.45rem;
    }

    .job-id-card-footer .btn {
        flex: 1;
        min-width: 0;
        font-weight: 700;
    }

    .badge {
        font-weight: 700;
        font-size: 0.72rem;
    }

    .empty-state {
        padding: 2.25rem 1.25rem;
    }

    .empty-state-icon {
        font-size: 2.25rem;
        filter: drop-shadow(0 4px 12px rgba(212, 168, 83, 0.2));
    }

    .empty-state p {
        font-weight: 500;
        font-size: 0.9rem;
    }
}

/* Panel header & sayfa iskeleti */
@media (max-width: 768px) {
    .app-logo {
        flex: 1;
        min-width: 0;
    }

    .menu-toggle {
        display: none !important;
    }

    .app-nav {
        display: none !important;
    }

    .app-header {
        display: flex;
        flex-wrap: nowrap;
        align-items: center;
        padding: calc(0.55rem + env(safe-area-inset-top, 0px)) 0.85rem 0.55rem;
        gap: 0.5rem;
        background: rgba(12, 12, 16, 0.97);
        backdrop-filter: blur(16px);
        -webkit-backdrop-filter: blur(16px);
        border-bottom: 1px solid rgba(212, 168, 83, 0.14);
        box-shadow:
            0 4px 24px rgba(0, 0, 0, 0.3),
            inset 0 -1px 0 rgba(212, 168, 83, 0.08);
    }

    .app-logo a {
        font-size: 1.22rem;
        font-weight: 800;
        letter-spacing: -0.03em;
    }

    .app-header-tools {
        display: flex;
        align-items: center;
        gap: 0.4rem;
        order: 2;
    }

    .nav-profile-btn {
        padding: 0.2rem;
        border: 1px solid rgba(212, 168, 83, 0.28);
        background: rgba(212, 168, 83, 0.07);
        box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
    }

    .nav-profile-avatar {
        width: 38px;
        height: 38px;
        border: 2px solid rgba(212, 168, 83, 0.4);
    }

    .nav-profile-name,
    .nav-profile-chevron {
        display: none;
    }

    .nav-profile-menu a {
        font-weight: 600;
        font-size: 0.85rem;
        min-height: 40px;
        display: flex;
        align-items: center;
    }

    .app-main {
        padding: 0;
        overflow: hidden;
    }

    .app-main-inner,
    .dashboard-content,
    .page-content {
        padding: 0.9rem 0.85rem 1.75rem;
        padding-bottom: calc(1.75rem + env(safe-area-inset-bottom, 0px));
    }

    html.ios-app-shell .app-main-inner,
    html.ios-app-shell .dashboard-content,
    html.ios-app-shell .page-content {
        padding-bottom: calc(0.85rem + env(safe-area-inset-bottom, 0px));
    }

    .page-header {
        margin-bottom: 0.85rem;
    }

    .page-header h1,
    .browse-solo-title {
        font-size: 1.2rem;
        font-weight: 800;
        letter-spacing: -0.03em;
    }

    .page-header p {
        font-size: 0.84rem;
        font-weight: 500;
    }

    .profile-card {
        padding: 1.15rem;
        border-color: rgba(212, 168, 83, 0.14);
        border-radius: 14px;
        box-shadow: 0 6px 20px rgba(0, 0, 0, 0.18);
    }

    .profile-card h2,
    .section-title {
        font-weight: 700;
    }

    .profile-card .form-group input:not([type="file"]):not([type="checkbox"]):not([type="radio"]),
    .profile-card .form-group select,
    .form-group textarea,
    .filter-bar .filter-field select {
        min-height: 44px;
        font-size: 1rem;
        font-weight: 500;
    }

    .form-group label {
        font-weight: 600;
        font-size: 0.8rem;
    }

    .filter-bar {
        flex-direction: column;
        align-items: stretch;
        gap: 0.5rem;
        padding: 0.8rem;
        background: linear-gradient(165deg, rgba(212, 168, 83, 0.04), var(--surface));
        border: 1px solid rgba(212, 168, 83, 0.12);
        border-radius: 13px;
    }

    .filter-bar .filter-field {
        min-width: 0;
    }

    .filter-bar .btn {
        width: 100%;
    }

    .browse-tabs {
        flex-wrap: nowrap;
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
        scroll-snap-type: x mandatory;
        gap: 0.35rem;
        padding: 0.38rem;
        margin-bottom: 0.75rem;
        border-color: rgba(212, 168, 83, 0.1);
        background: rgba(17, 17, 22, 0.95);
    }

    .browse-tab {
        flex: 0 0 auto;
        scroll-snap-align: start;
        min-width: auto;
        padding: 0.62rem 1.05rem;
        white-space: nowrap;
    }

    .browse-tab.active {
        background: linear-gradient(135deg, rgba(212, 168, 83, 0.18), rgba(166, 124, 46, 0.1));
        border: 1px solid rgba(212, 168, 83, 0.28);
        box-shadow: 0 3px 12px rgba(212, 168, 83, 0.14);
    }

    .browse-tab-label {
        font-size: 0.78rem;
        font-weight: 700;
        letter-spacing: 0.05em;
    }

    .browse-tab.active .browse-tab-label {
        font-size: 0.8rem;
        font-weight: 800;
        color: var(--accent-light);
    }

    .job-id-card {
        min-height: auto;
    }

    .job-id-price-pill {
        min-width: 6.5rem;
        padding: 0.4rem 0.85rem;
    }

    .browse-create-bar {
        flex-direction: column;
        align-items: stretch;
        gap: 0.45rem;
    }

    .browse-create-bar .btn {
        width: 100%;
    }

    .page-actions {
        flex-direction: column;
        gap: 0.5rem;
    }

    .page-actions .btn {
        width: 100%;
    }

    .form-actions {
        flex-direction: column;
        gap: 0.5rem;
    }

    .form-actions .btn {
        width: 100%;
    }

    /* İlan detay & başvurular */
    .job-venue-banner {
        padding: 0.9rem;
        gap: 0.85rem;
        border-color: rgba(212, 168, 83, 0.18);
    }

    .job-venue-banner-logo {
        width: 50px;
        height: 50px;
        border-radius: 11px;
        border: 1px solid rgba(212, 168, 83, 0.15);
    }

    .job-venue-name {
        font-size: 1.15rem;
        font-weight: 800;
    }

    .job-detail-header h2 {
        font-size: 1.2rem;
        font-weight: 800;
    }

    .job-detail-desc {
        font-size: 0.92rem;
        font-weight: 500;
        line-height: 1.65;
    }

    .job-meta span {
        font-weight: 600;
        font-size: 0.76rem;
        background: rgba(212, 168, 83, 0.06);
        border: 1px solid rgba(212, 168, 83, 0.1);
    }

    .applicant-card {
        flex-direction: column;
        align-items: stretch;
        padding: 0.95rem;
        border-color: rgba(212, 168, 83, 0.1);
    }

    .applicant-card > .applicant-avatar {
        width: 48px;
        height: 48px;
    }

    .applicant-name {
        font-size: 1.05rem;
        font-weight: 800;
    }

    .applicant-actions {
        flex-direction: column;
    }

    .applicant-actions .btn {
        width: 100%;
        min-height: 42px;
        font-weight: 700;
    }
}

/* Panel dashboard mobil */
@media (max-width: 768px) {
    .dash-hero {
        flex-direction: row;
        align-items: center;
        padding: 1rem;
        border-color: rgba(212, 168, 83, 0.12);
        box-shadow: 0 6px 22px rgba(0, 0, 0, 0.2);
    }

    .dash-avatar {
        width: 56px;
        height: 56px;
        border-color: rgba(212, 168, 83, 0.25);
    }

    .dash-progress {
        margin-top: 0;
        align-self: center;
    }

    .dash-name {
        font-size: 1.18rem;
        font-weight: 800;
    }

    .dash-meta {
        font-size: 0.78rem;
        font-weight: 600;
    }

    .dash-stats {
        grid-template-columns: repeat(2, 1fr);
        gap: 0.5rem;
    }

    .dash-stat {
        padding: 0.9rem 0.7rem;
        border-color: rgba(212, 168, 83, 0.12);
        background: linear-gradient(165deg, rgba(212, 168, 83, 0.05), transparent);
    }

    .dash-stat-value {
        font-size: 1.55rem;
        font-weight: 700;
        color: var(--primary);
    }

    .dash-stat-label {
        font-size: 0.68rem;
        font-weight: 700;
        letter-spacing: 0.05em;
        text-transform: uppercase;
    }

    .dash-action-row {
        padding: 0.9rem 0.95rem;
        border-color: rgba(212, 168, 83, 0.08);
    }

    .dash-action-title {
        font-size: 0.94rem;
        font-weight: 700;
    }

    .dash-action-desc {
        font-weight: 500;
    }

    .dash-action-icon {
        width: 42px;
        height: 42px;
        background: rgba(212, 168, 83, 0.09);
        border: 1px solid rgba(212, 168, 83, 0.14);
        border-radius: 12px;
    }
}

/* Profil sayfası mobil */
@media (max-width: 768px) {
    .profile-page-header h1 {
        font-size: 1.25rem;
        font-weight: 800;
    }

    .profile-identity-card {
        padding: 1.5rem 1.2rem;
        border-color: rgba(212, 168, 83, 0.18);
        box-shadow: 0 8px 28px rgba(0, 0, 0, 0.25);
    }

    .profile-avatar {
        width: 100px;
        height: 100px;
    }

    .profile-identity-name {
        font-size: 1.15rem;
        font-weight: 800;
    }

    .profile-form-actions {
        flex-direction: column;
    }

    .profile-form-actions .btn {
        width: 100%;
    }
}

/* Ana sayfa mobil */
@media (max-width: 768px) {
    .home-logo {
        flex: 1;
        min-width: 0;
    }

    .home-header {
        display: flex;
        flex-wrap: wrap;
        align-items: center;
        padding: calc(0.55rem + env(safe-area-inset-top, 0px)) 0.85rem 0.55rem;
        gap: 0.5rem;
        background: rgba(8, 8, 12, 0.97);
        backdrop-filter: blur(16px);
        -webkit-backdrop-filter: blur(16px);
        border-bottom: 1px solid rgba(212, 168, 83, 0.14);
        box-shadow: 0 4px 20px rgba(0, 0, 0, 0.28);
    }

    .home-logo a {
        font-size: 1.22rem;
        font-weight: 800;
    }

    .home-header-tools {
        display: flex;
        align-items: center;
        gap: 0.4rem;
        order: 2;
        z-index: 210;
    }

    .home-menu-toggle {
        display: none !important;
    }

    .home-nav {
        display: none !important;
    }

    .home-nav-guest {
        display: flex;
        align-items: center;
        gap: 0.45rem;
    }

    .home-nav-guest a {
        font-size: 0.82rem;
        font-weight: 700;
        text-decoration: none;
        color: var(--text-muted);
        padding: 0.4rem 0.55rem;
    }

    .home-nav-guest .btn-nav-primary {
        padding: 0.45rem 0.75rem;
        font-size: 0.8rem;
        min-height: auto;
        margin-left: 0;
    }

    body:has(.mob-tabbar) .home-footer {
        padding-bottom: calc(4.5rem + env(safe-area-inset-bottom, 0px));
    }

    .welcome-strip {
        padding: 0.75rem 0.85rem 0;
    }

    .welcome-strip-inner {
        padding: 0.8rem 0.95rem;
        border: 1px solid rgba(212, 168, 83, 0.12);
        background: linear-gradient(135deg, rgba(212, 168, 83, 0.06), transparent);
    }

    .welcome-strip h1 {
        font-size: 1.02rem;
        font-weight: 800;
    }

    .hero-compact {
        padding: 2rem 1rem 1.5rem;
    }

    .hero h1 {
        font-size: 1.6rem;
        font-weight: 800;
        letter-spacing: -0.03em;
    }

    .hero p {
        font-weight: 500;
    }

    .home-section-compact {
        padding: 1rem 0.85rem 1.75rem;
    }

    .section-title-inline {
        font-size: 1.08rem;
        font-weight: 800;
    }

    .home-filter-compact {
        padding: 0.7rem;
        border-color: rgba(212, 168, 83, 0.1);
    }

    .stats-bar-compact {
        margin: 0.75rem 0.85rem 0;
        padding: 0.8rem 1rem;
        border: 1px solid rgba(212, 168, 83, 0.1);
        background: linear-gradient(165deg, rgba(212, 168, 83, 0.05), transparent);
    }

    .stat-number {
        font-size: 1.3rem;
        font-weight: 800;
        color: var(--primary);
    }

    .stat-label {
        font-weight: 600;
    }

    .home-footer {
        padding-bottom: calc(1.5rem + env(safe-area-inset-bottom, 0px));
    }
}

/* Giriş / kayıt */
@media (max-width: 480px) {
    .auth-page {
        padding: 1rem 0.85rem;
        align-items: center;
        justify-content: center;
        padding-top: calc(1.25rem + env(safe-area-inset-top, 0px));
    }

    .auth-container {
        max-width: 100%;
    }

    .auth-card {
        padding: 1.4rem;
        border-color: rgba(212, 168, 83, 0.14);
        box-shadow: 0 10px 32px rgba(0, 0, 0, 0.28);
    }

    .auth-card h1 {
        font-weight: 800;
    }

    .auth-logo a {
        font-size: 1.55rem;
        font-weight: 800;
    }

    .auth-card .form-group input:not([type="file"]):not([type="checkbox"]):not([type="radio"]),
    .auth-card .form-group select {
        min-height: 44px;
        font-size: 1rem;
        font-weight: 500;
    }
}

/* Mesajlar */
@media (max-width: 768px) {
    .msg-page .app-main {
        padding: 0;
        max-width: none;
    }

    .msg-inbox-top {
        padding: 1.1rem 1rem 0.85rem;
    }

    .msg-inbox-top h1 {
        font-size: 1.45rem;
        font-weight: 800;
        letter-spacing: -0.04em;
    }

    .msg-inbox-top p {
        font-weight: 500;
    }

    .msg-row {
        padding: 0.95rem 1rem;
        min-height: 72px;
    }

    .msg-row-name {
        font-weight: 700;
        font-size: 0.98rem;
    }

    .msg-row-preview {
        font-weight: 500;
    }

    .msg-avatar {
        width: 48px;
        height: 48px;
        border: 2px solid rgba(212, 168, 83, 0.15);
    }

    .msg-empty-icon {
        background: rgba(212, 168, 83, 0.12);
    }

    .msg-empty h3 {
        font-weight: 800;
    }

    .msg-page:not(.msg-thread-page) .app-main-inner,
    .msg-page:not(.msg-thread-page) .dashboard-content {
        padding-bottom: calc(0.85rem + env(safe-area-inset-bottom, 0px));
    }

    .msg-back {
        width: 40px;
        height: 40px;
        font-weight: 400;
    }

    .msg-toolbar-name {
        font-weight: 700;
    }

    .msg-thread-page .msg-bubble {
        font-weight: 500;
    }

    .msg-thread-page .msg-bubble-wrap.mine .msg-bubble {
        background: linear-gradient(135deg, rgba(168, 85, 247, 0.88), rgba(99, 102, 241, 0.85));
        color: #f5f3ff;
        font-weight: 600;
    }
}

/* Mobil alt menü — hamburger yerine */
.mob-tabbar {
    display: none;
}

@media (max-width: 768px) {
    .mob-tabbar {
        display: flex;
        position: fixed;
        left: 0;
        right: 0;
        bottom: 0;
        z-index: 120;
        align-items: stretch;
        justify-content: space-around;
        gap: 0.15rem;
        padding: 0.4rem 0.5rem calc(0.45rem + env(safe-area-inset-bottom, 0px));
        background: rgba(12, 12, 16, 0.94);
        backdrop-filter: blur(20px) saturate(1.2);
        -webkit-backdrop-filter: blur(20px) saturate(1.2);
        border-top: 1px solid rgba(212, 168, 83, 0.2);
        box-shadow:
            0 -4px 24px rgba(0, 0, 0, 0.35),
            0 0 32px rgba(212, 168, 83, 0.05);
    }

    .mob-tab {
        flex: 1;
        display: flex;
        flex-direction: column;
        align-items: center;
        justify-content: center;
        gap: 0.2rem;
        min-height: 52px;
        padding: 0.35rem 0.25rem;
        border-radius: 12px;
        text-decoration: none;
        color: var(--text-muted);
        font-size: 0.65rem;
        font-weight: 700;
        letter-spacing: 0.01em;
        transition: color 0.2s, background 0.2s, box-shadow 0.2s;
    }

    .mob-tab svg {
        width: 22px;
        height: 22px;
        flex-shrink: 0;
    }

    .mob-tab-icon-wrap {
        position: relative;
        display: flex;
        align-items: center;
        justify-content: center;
    }

    .mob-tab-badge {
        position: absolute;
        top: -5px;
        right: -9px;
        min-width: 16px;
        height: 16px;
        padding: 0 4px;
        background: var(--primary);
        color: #1a1408;
        font-size: 0.58rem;
        font-weight: 800;
        line-height: 16px;
        text-align: center;
        border-radius: 999px;
        box-shadow: 0 0 10px rgba(212, 168, 83, 0.45);
    }

    .mob-tab.active {
        color: var(--primary);
        background: linear-gradient(180deg, rgba(212, 168, 83, 0.14), rgba(212, 168, 83, 0.04));
        box-shadow: 0 0 16px rgba(212, 168, 83, 0.12);
    }

    .mob-tab:active {
        transform: scale(0.97);
    }

    .mob-tabbar-4 .mob-tab {
        padding: 0.3rem 0.15rem;
        font-size: 0.58rem;
        gap: 0.15rem;
    }

    .mob-tabbar-4 .mob-tab svg {
        width: 20px;
        height: 20px;
    }

}
