:root {
    --blue: #0A5FFF;
    --orange: #FF7A00;
    --black: #111827;
    --dark: #111827;
    --dark2: #1f2937;
    --gray: #f3f4f6;
    --muted: #6b7280;
    --border: #e5e7eb;
    --white: #ffffff;
    --red: #dc2626;
    --green: #16a34a;
}

* { box-sizing: border-box; }

body {
    margin: 0;
    font-family: Arial, Helvetica, sans-serif;
    background: linear-gradient(135deg, #f8fafc 0%, #eef2ff 100%);
    color: var(--black);
}

.app-layout {
    display: flex;
    min-height: 100vh;
}

.sidebar {
    width: 292px;
    background:
        radial-gradient(circle at top left, rgba(10,95,255,.35), transparent 35%),
        linear-gradient(180deg, #111827 0%, #0b1220 100%);
    color: var(--white);
    padding: 24px 18px;
    position: sticky;
    top: 0;
    height: 100vh;
    box-shadow: 12px 0 35px rgba(17,24,39,.18);
    flex: 0 0 292px;
}

.sidebar-brand {
    background: rgba(255,255,255,.06);
    border: 1px solid rgba(255,255,255,.08);
    border-radius: 20px;
    padding: 16px;
    margin-bottom: 18px;
    display: flex;
    align-items: center;
    gap: 12px;
}

.sidebar-omni-logo {
    width: 52px;
    height: 52px;
    border-radius: 15px;
    object-fit: contain;
    background: white;
    padding: 5px;
}

.sidebar-brand-title {
    font-size: 18px;
    font-weight: 900;
    line-height: 1.15;
}

.sidebar-brand-title span { color: var(--orange); }

.sidebar-brand-subtitle {
    color: #9ca3af;
    font-size: 12px;
    margin-top: 5px;
}

.sidebar-account-box {
    background: rgba(31,41,55,.92);
    border: 1px solid rgba(255,255,255,.08);
    padding: 15px;
    border-radius: 18px;
    display: flex;
    gap: 13px;
    align-items: center;
    margin-bottom: 22px;
}

.sidebar-company-logo,
.sidebar-company-avatar {
    width: 56px;
    height: 56px;
    border-radius: 16px;
    flex: 0 0 auto;
}

.sidebar-company-logo {
    object-fit: cover;
    background: white;
    border: 2px solid rgba(255,255,255,.2);
}

.sidebar-company-avatar {
    background: linear-gradient(135deg, var(--orange), #ff9f43);
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 900;
    font-size: 24px;
}

.sidebar-account-info strong {
    display: block;
    font-size: 15px;
    line-height: 1.2;
}

.sidebar-account-info small {
    display: block;
    color: #9ca3af;
    margin-top: 5px;
    font-size: 13px;
}

.sidebar-nav a {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 13px 14px;
    color: #e5e7eb;
    text-decoration: none;
    border-radius: 14px;
    margin-bottom: 7px;
    font-weight: 800;
    transition: .18s ease;
}

.sidebar-nav a:hover,
.sidebar-nav a.active {
    background: linear-gradient(135deg, var(--blue), #0047c7);
    color: white;
    transform: translateX(3px);
}

.sidebar-nav a.logout {
    color: #fecaca;
    margin-top: 14px;
}

.main {
    flex: 1;
    padding: 34px;
    overflow: hidden;
}

.page-hero {
    background:
        radial-gradient(circle at top right, rgba(255,122,0,.24), transparent 30%),
        linear-gradient(135deg, var(--blue), #083b9f);
    color: white;
    border-radius: 28px;
    padding: 30px;
    box-shadow: 0 25px 60px rgba(10,95,255,.22);
    margin-bottom: 24px;
    position: relative;
    overflow: hidden;
}

.page-hero h1 { margin: 0; font-size: 34px; letter-spacing: -.4px; }
.page-hero p { margin: 9px 0 0; color: #dbeafe; max-width: 760px; line-height: 1.6; }

.hero-row {
    position: relative;
    z-index: 1;
    display: flex;
    justify-content: space-between;
    gap: 20px;
    align-items: center;
}

.hero-actions { display: flex; gap: 10px; flex-wrap: wrap; justify-content: flex-end; }

.card,
.content-card,
.stat-card {
    background: white;
    border: 1px solid rgba(229,231,235,.85);
    box-shadow: 0 18px 45px rgba(17,24,39,.08);
}

.card,
.content-card { padding: 24px; border-radius: 24px; }
.stat-card { border-radius: 22px; padding: 20px; }

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    background: var(--orange);
    color: white;
    padding: 12px 18px;
    border-radius: 14px;
    text-decoration: none;
    font-weight: 900;
    border: none;
    cursor: pointer;
    white-space: nowrap;
    box-shadow: 0 10px 25px rgba(255,122,0,.22);
}

.btn.blue { background: var(--blue); box-shadow: 0 10px 25px rgba(10,95,255,.18); }
.btn.gray { background: #6b7280; box-shadow: none; }
.btn.red { background: var(--red); box-shadow: none; }
.btn.light { background: white; color: var(--blue); box-shadow: 0 10px 25px rgba(255,255,255,.14); }

.alert { padding: 13px 15px; border-radius: 12px; margin-bottom: 16px; font-weight: 700; }
.success { background: #dcfce7; color: #166534; }
.error { background: #fee2e2; color: #991b1b; }
.hint { color: var(--muted); font-size: 14px; margin-top: 8px; }

input, select, textarea {
    width: 100%;
    padding: 13px 14px;
    border: 1px solid #d1d5db;
    border-radius: 13px;
    font-size: 15px;
    font-family: inherit;
}

input:focus, select:focus, textarea:focus {
    outline: none;
    border-color: var(--blue);
    box-shadow: 0 0 0 4px rgba(10,95,255,.12);
}

label { display: block; font-weight: 800; margin-bottom: 7px; font-size: 14px; }
textarea { resize: vertical; min-height: 150px; }
.readonly { background: #f9fafb; color: #4b5563; }
.grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px; }
.full { grid-column: 1 / -1; }

.table-wrap { overflow-x: auto; }
table { width: 100%; border-collapse: collapse; }
th, td { padding: 14px 12px; border-bottom: 1px solid #e5e7eb; text-align: left; vertical-align: top; }
th { background: #111827; color: white; }
th:first-child { border-radius: 12px 0 0 0; }
th:last-child { border-radius: 0 12px 0 0; }

@media (max-width: 980px) {
    .app-layout { display: block; }
    .sidebar { width: 100%; height: auto; position: relative; flex: auto; }
    .main { padding: 18px; }
    .hero-row { display: block; }
    .hero-actions { justify-content: flex-start; margin-top: 18px; }
    .grid { grid-template-columns: 1fr; }
}

/* Public home page compatibility */
.home-bg { background: linear-gradient(135deg, #0A5FFF 0%, #111827 65%, #FF7A00 140%); min-height: 100vh; }
.hero { max-width: 1180px; margin: 0 auto; padding: 28px; }
.hero .nav { display: flex; align-items: center; justify-content: space-between; margin-bottom: 70px; }
.hero .logo { color: white; font-size: 26px; font-weight: 900; }
.hero .logo span { color: #FF7A00; }
.hero .nav a { color: white; text-decoration: none; margin-left: 14px; font-weight: 800; }
.hero-card { max-width: 760px; background: rgba(255,255,255,.12); border: 1px solid rgba(255,255,255,.18); padding: 44px; border-radius: 28px; color: white; box-shadow: 0 25px 70px rgba(0,0,0,.22); }
.hero-card h1 { font-size: 52px; margin: 0 0 12px; }
.hero-card p { font-size: 19px; line-height: 1.65; color: #e5e7eb; }
.hero .alert { background: #dcfce7; color: #166534; max-width: 760px; }
.btn.big { font-size: 18px; padding: 16px 24px; }
