/*
Theme Name: Business Portal App Theme
Theme URI: https://example.com/
Author: You
Author URI: https://example.com/
Description: A glassy, neon-accented, app-style business portal theme with full-width layout, sidebar navigation, animated UI, and dark/light mode.
Version: 1.0
License: GNU GPL v2 or later
Text Domain: business-portal-app
*/

@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700&display=swap');

:root {
    --bp-bg: #f5f7fb;
    --bp-bg-elevated: rgba(255, 255, 255, 0.7);
    --bp-bg-header: rgba(255, 255, 255, 0.85);
    --bp-bg-sidebar: rgba(255, 255, 255, 0.9);
    --bp-border-subtle: rgba(148, 163, 184, 0.35);
    --bp-text: #0f172a;
    --bp-text-muted: #6b7280;
    --bp-accent: #3b82f6;
    --bp-accent-soft: rgba(59, 130, 246, 0.12);
    --bp-accent-2: #22c55e;
    --bp-danger: #ef4444;
    --bp-radius-lg: 1.25rem;
    --bp-radius-md: 0.9rem;
    --bp-radius-sm: 0.6rem;
    --bp-shadow-soft: 0 18px 40px rgba(15, 23, 42, 0.12);
    --bp-shadow-strong: 0 30px 80px rgba(15, 23, 42, 0.18);
}

/* Dark mode variables */
.bp-dark {
    --bp-bg: #020617;
    --bp-bg-elevated: rgba(15, 23, 42, 0.9);
    --bp-bg-header: rgba(15, 23, 42, 0.96);
    --bp-bg-sidebar: rgba(15, 23, 42, 0.98);
    --bp-border-subtle: rgba(55, 65, 81, 0.9);
    --bp-text: #e5e7eb;
    --bp-text-muted: #9ca3af;
    --bp-shadow-soft: 0 18px 40px rgba(15, 23, 42, 0.75);
    --bp-shadow-strong: 0 30px 80px rgba(15, 23, 42, 0.9);
}

*,
*::before,
*::after {
    box-sizing: border-box;
}

html, body {
    margin: 0;
    padding: 0;
}

body {
    font-family: 'Inter', system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    background: radial-gradient(circle at top left, #e0ecff, var(--bp-bg) 55%);
    color: var(--bp-text);
    line-height: 1.6;
}

/* App shell */
.bp-app {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

/* Header / top nav */
.bp-header {
    position: sticky;
    top: 0;
    z-index: 40;
    backdrop-filter: blur(18px);
    -webkit-backdrop-filter: blur(18px);
    background: var(--bp-bg-header);
    border-bottom: 1px solid var(--bp-border-subtle);
}

.bp-header-inner {
    max-width: 1440px;
    margin: 0 auto;
    padding: 0.65rem 1.5rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
}

/* Logo */
.bp-logo {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    text-decoration: none;
}

.bp-logo-mark {
    width: 38px;
    height: 38px;
    border-radius: 1rem;
    background:
        radial-gradient(circle at 30% 20%, #a5b4fc, transparent 55%),
        radial-gradient(circle at 70% 80%, #22c55e, transparent 55%),
        linear-gradient(135deg, #0f172a, #1d4ed8);
    box-shadow:none;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #e5e7eb;
    font-weight: 700;
    font-size: 1.1rem;
}

.bp-logo-text {
    display: flex;
    flex-direction: column;
}

.bp-logo-text strong {
    font-size: 1rem;
    letter-spacing: 0.04em;
}

.bp-logo-text span {
    font-size: 0.75rem;
    color: var(--bp-text-muted);
}

/* Header right controls */
.bp-header-right {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

/* Top nav (simple links) */
.bp-top-nav {
    display: flex;
    align-items: center;
    gap: 0.25rem;
}

.bp-top-nav ul {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    gap: 0.25rem;
}

.bp-top-nav li {
    margin: 0;
    padding: 0;
}

.bp-top-nav a {
    text-decoration: none;
    color: var(--bp-text-muted);
    font-size: 0.85rem;
    padding: 0.3rem 0.7rem;
    border-radius: 999px;
    transition: background 0.15s ease, color 0.15s ease, transform 0.06s ease;
}

.bp-top-nav a:hover,
.bp-top-nav .current-menu-item > a,
.bp-top-nav .current_page_item > a {
    background: rgba(148, 163, 184, 0.25);
    color: var(--bp-text);
    transform: translateY(-1px);
}

/* Theme toggle button */
.bp-theme-toggle {
    border-radius: 999px;
    border: 1px solid var(--bp-border-subtle);
    background: radial-gradient(circle at 0% 0%, rgba(129, 140, 248, 0.3), transparent 55%);
    padding: 0.3rem 0.6rem;
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    cursor: pointer;
    font-size: 0.8rem;
    color: var(--bp-text-muted);
}

.bp-theme-toggle span {
    font-size: 1rem;
}

.bp-header-portal-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 999px;
    padding: 0.35rem 0.9rem;
    border: none;
    background: linear-gradient(135deg, #3b82f6, #22c55e);
    color: #0b1120;
    font-size: 0.8rem;
    font-weight: 600;
    text-decoration: none;
    box-shadow:none;
    cursor: pointer;
    transition: transform 0.08s ease, box-shadow 0.08s ease, opacity 0.1s ease;
}

.bp-header-portal-btn:hover {
    transform: translateY(-1px);
    opacity: 0.95;
    box-shadow:none;
}

/* App shell: sidebar + main */
.bp-shell {
    max-width: 1440px;
    margin: 0 auto;
    padding: 1.1rem 1.5rem 1.8rem;
    display: grid;
    grid-template-columns: 260px minmax(0, 1fr);
    gap: 1.2rem;
}

/* Sidebar nav */
.bp-sidebar {
    background: var(--bp-bg-sidebar);
    backdrop-filter: blur(22px);
    -webkit-backdrop-filter: blur(22px);
    border-radius: var(--bp-radius-lg);
    border: 1px solid var(--bp-border-subtle);
    box-shadow:none;
    padding: 1rem;
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    min-height: calc(100vh - 120px);
    position: sticky;
    top: 82px;
}

.bp-sidebar-title {
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 0.18em;
    color: var(--bp-text-muted);
    margin-bottom: 0.4rem;
}

.bp-sidebar-menu {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    flex-direction: column;
    gap: 0.15rem;
}

/* Make wp_nav_menu output look nice in sidebar as well */
.bp-sidebar-menu .menu-item a,
.bp-sidebar .menu-item a {
    display: flex;
    align-items: center;
    gap: 0.6rem;
    padding: 0.5rem 0.65rem;
    border-radius: var(--bp-radius-md);
    text-decoration: none;
    color: var(--bp-text-muted);
    font-size: 0.9rem;
    transition: background 0.12s ease, transform 0.04s ease, box-shadow 0.12s ease, color 0.12s ease;
}

.bp-sidebar-menu .menu-item a::before,
.bp-sidebar .menu-item a::before {
    content: '';
    width: 8px;
    height: 8px;
    border-radius: 999px;
    background: radial-gradient(circle at 30% 30%, #a5b4fc, #3b82f6);
    opacity: 0.65;
}

.bp-sidebar-menu .current-menu-item > a,
.bp-sidebar .current-menu-item > a,
.bp-sidebar-menu .menu-item a:hover,
.bp-sidebar .menu-item a:hover {
    background: linear-gradient(135deg, rgba(59, 130, 246, 0.12), rgba(34, 197, 94, 0.12));
    color: var(--bp-text);
    box-shadow:none;
    transform: translateY(-1px);
}

/* Sidebar footer mini status */
.bp-sidebar-status {
    margin-top: auto;
    padding-top: 0.75rem;
    border-top: 1px dashed var(--bp-border-subtle);
    font-size: 0.8rem;
    color: var(--bp-text-muted);
}

/* Main content */
.bp-main {
    display: flex;
    flex-direction: column;
    gap: 1.1rem;
}

/* Hero / page title wrapper */
.bp-page-header {
    background: var(--bp-bg-elevated);
    backdrop-filter: blur(22px);
    -webkit-backdrop-filter: blur(22px);
    border-radius: var(--bp-radius-lg);
    border: 1px solid var(--bp-border-subtle);
    padding: 1rem 1.25rem;
    box-shadow:none;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 0.75rem;
}

.bp-page-header h1 {
    font-size: 1.4rem;
    margin: 0;
}

.bp-page-header p {
    margin: 0.2rem 0 0;
    font-size: 0.9rem;
    color: var(--bp-text-muted);
}

.bp-page-header-meta {
    font-size: 0.8rem;
    text-align: right;
    color: var(--bp-text-muted);
}

/* Content card */
.bp-main-card {
    background: var(--bp-bg-elevated);
    backdrop-filter: blur(22px);
    -webkit-backdrop-filter: blur(22px);
    border-radius: var(--bp-radius-lg);
    border: 1px solid var(--bp-border-subtle);
    box-shadow:none;
    padding: 1.2rem 1.4rem;
}

.bp-main-card h1,
.bp-main-card h2,
.bp-main-card h3 {
    margin-top: 0;
}

.bp-main-card p {
    color: var(--bp-text-muted);
}

/* Buttons */
.bp-btn,
button,
input[type="submit"] {
    font-family: inherit;
}

.bp-btn-primary {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.35rem;
    padding: 0.55rem 1.15rem;
    border-radius: 999px;
    border: none;
    background: linear-gradient(135deg, #3b82f6, #6366f1);
    color: #f9fafb;
    font-weight: 600;
    font-size: 0.92rem;
    cursor: pointer;
    text-decoration: none;
    box-shadow:none;
    transition: transform 0.08s ease, box-shadow 0.08s ease, opacity 0.1s ease;
}

.bp-btn-primary:hover {
    opacity: 0.96;
    transform: translateY(-1px);
    box-shadow:none;
}

/* App-like mobile bottom nav */
.bp-mobile-nav {
    position: fixed;
    bottom: 0;
    inset-inline: 0;
    z-index: 35;
    display: none;
    padding: 0.3rem 0.9rem 0.5rem;
    background: rgba(255, 255, 255, 0.85);
    backdrop-filter: blur(18px);
    -webkit-backdrop-filter: blur(18px);
    border-top: 1px solid var(--bp-border-subtle);
}

.bp-dark .bp-mobile-nav {
    background: rgba(15, 23, 42, 0.96);
}

.bp-mobile-nav-inner {
    max-width: 640px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    gap: 0.4rem;
}

.bp-mobile-nav-btn {
    flex: 1;
    border-radius: 999px;
    border: none;
    padding: 0.35rem 0.6rem;
    background: transparent;
    color: var(--bp-text-muted);
    font-size: 0.75rem;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.2rem;
    cursor: pointer;
}

.bp-mobile-nav-btn span {
    font-size: 1.1rem;
}

/* Footer */
.bp-footer {
    margin-top: auto;
    padding: 0.8rem 1.5rem 1.2rem;
    font-size: 0.8rem;
    color: var(--bp-text-muted);
}

.bp-footer-inner {
    max-width: 1440px;
    margin: 0 auto;
    display: flex;
    justify-content: flex-start;
}

/* Basic content styles */
.bp-main-card a {
    color: var(--bp-accent);
    text-decoration: none;
}

.bp-main-card a:hover {
    text-decoration: underline;
}

.bp-main-card ul,
.bp-main-card ol {
    padding-left: 1.2rem;
}

/* Forms */
input[type="text"],
input[type="email"],
input[type="password"],
input[type="number"],
input[type="search"],
input[type="url"],
textarea,
select {
    width: 100%;
    border-radius: 0.7rem;
    border: 1px solid var(--bp-border-subtle);
    padding: 0.55rem 0.7rem;
    background: rgba(255, 255, 255, 0.8);
    color: var(--bp-text);
    font-family: inherit;
    font-size: 0.95rem;
}

.bp-dark input[type="text"],
.bp-dark input[type="email"],
.bp-dark input[type="password"],
.bp-dark input[type="number"],
.bp-dark input[type="search"],
.bp-dark input[type="url"],
.bp-dark textarea,
.bp-dark select {
    background: rgba(15, 23, 42, 0.9);
}

/* Responsive */
@media (max-width: 960px) {
    .bp-shell {
        grid-template-columns: minmax(0, 1fr);
        padding-inline: 1rem;
    }

    .bp-sidebar {
        position: fixed;
        inset: 60px 0 auto 0;
        max-width: 280px;
        margin-inline: auto;
        transform: translateY(-110%);
        opacity: 0;
        pointer-events: none;
        transition: transform 0.2s ease, opacity 0.2s ease;
        min-height: auto;
    }

    .bp-sidebar.bp-sidebar-open {
        transform: translateY(0);
        opacity: 1;
        pointer-events: auto;
    }

    .bp-header-inner {
        padding-inline: 1rem;
    }

    .bp-mobile-nav {
        display: block;
    }
}

@media (max-width: 640px) {
    .bp-header-inner {
        gap: 0.6rem;
    }

    .bp-top-nav {
        display: none;
    }

    .bp-page-header {
        flex-direction: column;
        align-items: flex-start;
    }

    .bp-page-header-meta {
        text-align: left;
    }
}


/* Desktop: ensure main area is at least 1000px next to the 260px sidebar */
@media (min-width: 1280px) {
    .bp-shell {
        grid-template-columns: 260px minmax(1000px, 1fr);
    }
}

/* Mobile: let content breathe a bit more */
@media (max-width: 768px) {
    .bp-main {
        width: 90%;
        max-width: 90%;
        margin-inline: auto;
    }
}


/* Mobile content width fix */
@media (max-width: 768px) {
    .bp-main {
        width: 95% !important;
        max-width: 95% !important;
        margin-inline: auto !important;
    }

    body {
        font-size: 0.9rem;
    }

    .bp-main-card {
        padding: 1rem;
    }
}
