/* RestoPOS Web Panel — Global CSS */

body {
    font-family: 'Plus Jakarta Sans', 'Roboto', system-ui, sans-serif;
    background-color: var(--mud-palette-background, #F5F5F5);
}

#blazor-error-ui {
    background: #EF5350;
    bottom: 0;
    box-shadow: 0 -1px 2px rgba(0, 0, 0, 0.2);
    display: none;
    left: 0;
    padding: 0.6rem 1.25rem 0.7rem 1.25rem;
    position: fixed;
    width: 100%;
    z-index: 1000;
    color: white;
}

    #blazor-error-ui .dismiss {
        cursor: pointer;
        position: absolute;
        right: 0.75rem;
        top: 0.5rem;
    }

.mud-table-cell {
    padding: 10px 16px !important;
}

/* ── Arama kutusu metin rengi fix (temaya uyumlu) ── */
.mud-input input,
.mud-input textarea {
    color: var(--mud-palette-text-primary) !important;
}

.mud-input .mud-input-slot {
    color: var(--mud-palette-text-primary) !important;
}

.mud-input input::placeholder,
.mud-input textarea::placeholder {
    color: var(--mud-palette-text-secondary) !important;
    opacity: 1;
}

.text-center {
    text-align: center;
}

/* ══════════════════════════════════════
   PORTAL — Login & Index sayfaları
   ══════════════════════════════════════ */

.portal-page {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #F0F2F5;
    padding: 24px;
}

.lang-row {
    position: fixed;
    top: 16px;
    right: 16px;
    z-index: 100;
}

.portal-card {
    background: #fff;
    border-radius: 16px;
    box-shadow: 0 4px 24px rgba(0,0,0,0.10);
    padding: 40px 36px 36px;
    width: 100%;
    max-width: 420px;
}

.portal-logo {
    text-align: center;
    margin-bottom: 20px;
}

    .portal-logo img {
        height: 64px;
        object-fit: contain;
    }

.portal-title {
    font-size: 22px;
    font-weight: 700;
    color: #1a1a2e;
    text-align: center;
    margin: 0 0 6px;
}

.portal-subtitle {
    font-size: 14px;
    color: #666;
    text-align: center;
    margin: 0 0 24px;
}

/* ── Tab row ── */
.tab-row {
    display: flex;
    background: #F0F2F5;
    border-radius: 10px;
    padding: 4px;
    gap: 4px;
    margin-bottom: 24px;
}

.tab-btn {
    flex: 1;
    padding: 10px 8px;
    border: none;
    border-radius: 8px;
    background: transparent;
    color: #666;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    transition: all 0.2s;
}

    .tab-btn.active {
        background: #0D47A1;
        color: #fff;
        box-shadow: 0 2px 8px rgba(13,71,161,0.3);
    }

    .tab-btn:not(.active):hover {
        background: #e0e4ef;
        color: #333;
    }

/* ── Tab content ── */
.tab-content {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.tab-desc {
    color: #666;
    font-size: 14px;
    text-align: center;
    margin: 0 0 8px;
}

/* ── Portal form ── */
.portal-form {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

    .form-group label {
        font-size: 13px;
        font-weight: 500;
        color: #444;
    }

    .form-group input {
        padding: 11px 14px;
        border: 1.5px solid #e0e0e0;
        border-radius: 8px;
        font-size: 15px;
        outline: none;
        transition: border 0.2s;
        background: #fafafa;
        color: #1a1a2e;
    }

        .form-group input:focus {
            border-color: #0D47A1;
            background: #fff;
        }

/* ── Submit button ── */
.portal-submit,
.portal-submit-link {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    width: 100%;
    padding: 13px;
    background: #0D47A1;
    color: #fff;
    border: none;
    border-radius: 8px;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    text-decoration: none;
    transition: background 0.2s;
    letter-spacing: 0.5px;
}

    .portal-submit:hover,
    .portal-submit-link:hover {
        background: #1565C0;
        color: #fff;
    }

    .portal-submit:disabled {
        background: #90a4c8;
        cursor: not-allowed;
    }

/* ── Error ── */
.portal-error {
    background: #FFEBEE;
    color: #C62828;
    border-radius: 8px;
    padding: 10px 14px;
    font-size: 13px;
    text-align: center;
}

/* ── Coming soon ── */
.coming-soon-box {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;
    padding: 24px 0 8px;
}

.coming-soon-icon {
    font-size: 40px;
    color: #bbb;
}

.coming-soon-text {
    color: #888;
    font-size: 14px;
    text-align: center;
}

/* ── Back link ── */
.back-link {
    display: inline-block;
    color: #0D47A1;
    font-size: 13px;
    text-decoration: none;
    margin-bottom: 16px;
}

    .back-link:hover {
        text-decoration: underline;
    }

/* ── Tenant select ── */
.tenant-select {
    margin-top: 20px;
    border-top: 1px solid #eee;
    padding-top: 16px;
}

    .tenant-select h3 {
        font-size: 14px;
        color: #555;
        margin-bottom: 10px;
        text-align: center;
    }

.tenant-btn {
    display: block;
    width: 100%;
    padding: 10px;
    margin-bottom: 8px;
    background: #F0F2F5;
    border: 1.5px solid #e0e0e0;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 500;
    color: #1a1a2e;
    cursor: pointer;
    transition: all 0.2s;
}

    .tenant-btn:hover {
        background: #0D47A1;
        color: #fff;
        border-color: #0D47A1;
    }

/* ══════════════════════════════════════
   MEMBER (ŞUBE) — Dark redesign refinements
   Sadece member bölümünü etkiler; Super Admin'e dokunmaz.
   ══════════════════════════════════════ */

/* Sidebar grup başlıkları */
.rp-member-drawer .mud-nav-group > .mud-nav-link,
.rp-member-drawer .mud-typography-overline {
    letter-spacing: 1.4px;
}

/* Nav link — hover & aktif vurgu çubuğu */
.rp-member-drawer .mud-nav-link {
    border-radius: 8px;
    margin: 1px 8px;
    font-size: 0.86rem;
    font-weight: 500;
    transition: background 0.15s, color 0.15s;
}

.rp-member-drawer .mud-nav-link:hover {
    background: rgba(255, 255, 255, 0.05);
}

.rp-member-drawer .mud-nav-link.active {
    background: rgba(59, 130, 246, 0.12);
    color: var(--mud-palette-primary);
    font-weight: 700;
    position: relative;
}

    .rp-member-drawer .mud-nav-link.active::before {
        content: "";
        position: absolute;
        left: 0;
        top: 6px;
        bottom: 6px;
        width: 3px;
        border-radius: 0 3px 3px 0;
        background: var(--mud-palette-primary);
    }

    .rp-member-drawer .mud-nav-link.active .mud-nav-link-icon {
        color: var(--mud-palette-primary);
    }

/* Kart yüzeyleri — yumuşak kenarlık + radius */
.rp-member-content .mud-paper {
    border: 1px solid rgba(255, 255, 255, 0.06);
    border-radius: 14px;
}

/* İnce, koyu kaydırma çubuğu */
.rp-member-drawer ::-webkit-scrollbar,
.rp-member-content ::-webkit-scrollbar {
    width: 8px;
    height: 8px;
}

.rp-member-drawer ::-webkit-scrollbar-thumb,
.rp-member-content ::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.12);
    border-radius: 8px;
}

/* Parasal / kod alanları için mono yazı tipi yardımcı sınıfı */
.rp-mono {
    font-family: 'JetBrains Mono', ui-monospace, monospace;
}

/* ── Drawer iç düzen: nav (kayar) + alt kullanıcı kartı ── */
.rp-drawer-inner {
    display: flex;
    flex-direction: column;
    height: 100%;
    min-height: 0;
}

.rp-drawer-nav {
    flex: 1 1 auto;
    min-height: 0;
    overflow-y: auto;
}

.rp-user-card {
    flex: 0 0 auto;
    display: flex;
    align-items: center;
    gap: 10px;
    margin: 8px;
    padding: 10px 12px;
    border-radius: 10px;
    background: #141A28;
    border: 1px solid rgba(255, 255, 255, 0.06);
}

.rp-user-avatar {
    width: 34px;
    height: 34px;
    flex-shrink: 0;
    border-radius: 9px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    font-weight: 800;
    color: #fff;
    background: linear-gradient(135deg, #3B82F6, #8B5CF6);
}

.rp-user-meta {
    min-width: 0;
}

.rp-user-name {
    font-size: 12.5px;
    font-weight: 700;
    color: #F2F4F8;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.rp-user-role {
    font-size: 10.5px;
    color: #7B8493;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* ── Bölüm başlığı ── */
.rp-section-title {
    font-size: 11px;
    font-weight: 800;
    letter-spacing: 1.6px;
    text-transform: uppercase;
    color: #7B8493;
    margin-bottom: 12px;
    padding-left: 2px;
}

/* ── KPI kartı ── */
.rp-kpi-card {
    position: relative;
    overflow: hidden;
    background: #141A28;
    border: 1px solid rgba(255, 255, 255, 0.06);
    border-radius: 14px;
    padding: 16px;
    height: 100%;
    transition: box-shadow 0.15s, transform 0.15s;
}

    .rp-kpi-card:hover {
        box-shadow: 0 6px 24px rgba(0, 0, 0, 0.30);
        transform: translateY(-2px);
    }

.rp-kpi-accent {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
}

.rp-kpi-head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    margin-bottom: 6px;
}

.rp-kpi-label {
    font-size: 10px;
    font-weight: 700;
    letter-spacing: 1.2px;
    text-transform: uppercase;
    color: #7B8493;
}

.rp-kpi-icon {
    width: 28px;
    height: 28px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.rp-kpi-value {
    font-size: 26px;
    font-weight: 800;
    letter-spacing: -0.5px;
    line-height: 1.1;
}

.rp-kpi-foot {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-top: 6px;
}

.rp-kpi-sub {
    font-size: 11px;
    color: #7B8493;
}

.rp-kpi-delta {
    font-size: 10px;
    font-weight: 700;
    white-space: nowrap;
}
