css_content = """/* ================================
   LAYOUTGPCP.CSS — Layout interno SGPC
   Sidebar, Topbar, Main Content,
   Footer, Responsive, Utilities
================================ */

/* ---- Variáveis ---- */
:root {
    --primary-color: #2196F3;
    --primary-dark: #1976D2;
    --primary-light: #42A5F5;
    --secondary-color: #1E88E5;
    --danger: #e74c3c;
    --success: #27ae60;
    --warning: #f39c12;
    --info: #3498db;
    --dark: #2c3e50;
    --light: #ecf0f1;
    --gray-100: #f8f9fa;
    --gray-200: #e9ecef;
    --gray-300: #dee2e6;
    --gray-400: #adb5bd;
    --gray-500: #6c757d;
    --gray-600: #495057;
    --gray-700: #343a40;
    --gray-800: #212529;
    --shadow-sm: 0 2px 4px rgba(0, 0, 0, 0.1);
    --shadow-md: 0 4px 12px rgba(0, 0, 0, 0.15);
    --shadow-lg: 0 8px 24px rgba(0, 0, 0, 0.15);
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

/* ---- Reset ---- */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    height: 100%;
}

body {
    height: 100%;
    background-color: #f5f7fa;
    color: var(--dark);
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    overflow-x: hidden;
}

/* ================================
   WRAPPER STICKY FOOTER
================================ */
#layout-wrapper {
    min-height: 100%;
    display: grid;
    grid-template-rows: auto 1fr auto;
    grid-template-columns: 100%;
}

/* ================================
   SIDEBAR
================================ */
.sidebar {
    position: fixed;
    left: 0;
    top: 0;
    width: 260px;
    height: 100vh;
    background: linear-gradient(135deg, #2196F3 0%, #1976D2 100%);
    color: white;
    overflow-y: auto;
    z-index: 999;
    box-shadow: var(--shadow-lg);
    transition: var(--transition);
}

.sidebar::-webkit-scrollbar {
    width: 6px;
}

.sidebar::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.1);
}

.sidebar::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.3);
    border-radius: 3px;
}

.sidebar::-webkit-scrollbar-thumb:hover {
    background: rgba(255, 255, 255, 0.5);
}

.sidebar-header {
    height: 70px;
    padding: 0 1.5rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    display: flex;
    align-items: center;
    justify-content: center;
}

.sidebar-brand {
    display: flex;
    align-items: center;
    justify-content: center;
    text-decoration: none;
    color: white;
    font-weight: 700;
    font-size: 1.6rem;
    letter-spacing: 2.5px;
    transition: var(--transition);
}

.sidebar-brand:hover {
    transform: scale(1.05);
    letter-spacing: 3.5px;
}

.sidebar-brand span {
    color: white;
    text-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
}

.sidebar-menu {
    padding: 1rem 0;
}

.menu-title {
    padding: 0.75rem 1.5rem;
    font-size: 0.9rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 1.2px;
    color: #ffffff !important;
    margin-top: 1rem;
    background: rgba(255, 255, 255, 0.15);
    border-left: 3px solid rgba(255, 255, 255, 0.5);
}

.menu-item {
    position: relative;
    transition: var(--transition);
}

.menu-item > a {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.75rem 1.5rem;
    color: rgba(255, 255, 255, 0.9);
    text-decoration: none;
    transition: var(--transition);
    font-weight: 500;
    position: relative;
}

.menu-item > a:hover {
    background-color: rgba(255, 255, 255, 0.15);
    color: white;
    padding-left: 1.75rem;
}

.menu-item.active > a {
    background-color: rgba(255, 255, 255, 0.25);
    color: white;
    border-left: 3px solid white;
    padding-left: 1.47rem;
}

.menu-item > a i {
    font-size: 1.25rem;
    width: 24px;
    text-align: center;
}

.badge {
    margin-left: auto;
    background-color: #e74c3c;
    color: white;
    padding: 0.25rem 0.5rem;
    border-radius: 4px;
    font-size: 0.65rem;
    font-weight: 600;
}

.submenu {
    display: none;
    background-color: rgba(0, 0, 0, 0.15);
}

.menu-item.active .submenu,
.submenu.show {
    display: block;
}

.submenu-item {
    padding: 0.6rem 1.5rem 0.6rem 3.5rem;
    color: rgba(255, 255, 255, 0.8);
    text-decoration: none;
    display: block;
    transition: var(--transition);
    font-size: 0.9rem;
}

.submenu-item:hover {
    color: white;
    padding-left: 3.75rem;
    background-color: rgba(255, 255, 255, 0.1);
}

.submenu-item.active {
    color: white;
    border-left: 2px solid white;
    padding-left: 3.48rem;
}

/* ================================
   TOPBAR
================================ */
.topbar {
    position: fixed;
    top: 0;
    left: 260px;
    right: 0;
    height: 70px;
    background: white;
    border-bottom: 1px solid var(--gray-200);
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 2rem;
    z-index: 998;
    box-shadow: var(--shadow-sm);
    transition: var(--transition);
}

.topbar-left {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.toggle-sidebar {
    background: none;
    border: none;
    font-size: 1.5rem;
    color: var(--dark);
    cursor: pointer;
    transition: var(--transition);
    display: none;
}

.toggle-sidebar:hover {
    color: var(--primary-color);
}

.topbar-title {
    font-size: 1.25rem;
    font-weight: 600;
    color: var(--dark);
}

.topbar-right {
    display: flex;
    align-items: center;
    gap: 1.5rem;
}

.user-menu {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.user-avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: linear-gradient(135deg, #2196F3 0%, #1976D2 100%);
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 0.9rem;
    cursor: pointer;
    transition: var(--transition);
    text-decoration: none;
}

.user-avatar:hover {
    transform: scale(1.1);
    box-shadow: 0 4px 12px rgba(33, 150, 243, 0.4);
}

.user-info {
    text-align: right;
}

.user-name {
    font-weight: 600;
    color: var(--dark);
    font-size: 0.9rem;
    margin-bottom: 2px;
    cursor: pointer;
    transition: var(--transition);
    text-decoration: none;
}

.user-name:hover {
    color: var(--primary-color);
}

.user-role {
    font-size: 0.75rem;
    color: var(--gray-500);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.logout-btn {
    background: linear-gradient(135deg, #2196F3 0%, #1976D2 100%);
    color: white;
    border: none;
    padding: 0.5rem 1rem;
    border-radius: 6px;
    font-size: 0.9rem;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
}

.logout-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(33, 150, 243, 0.4);
    background: linear-gradient(135deg, #1976D2 0%, #1565C0 100%);
}

/* ================================
   MAIN CONTENT
================================ */
.main-content {
    margin-left: 260px;
    margin-top: 70px;
    margin-bottom: 53px;
    padding: 2rem;
    transition: var(--transition);
    min-height: calc(100vh - 70px - 53px);
}

/* ================================
   FOOTER
================================ */
.footer {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: white;
    border-top: 1px solid var(--gray-200);
    padding: 1rem 2rem;
    text-align: center;
    color: var(--gray-500);
    font-size: 0.85rem;
    z-index: 997;
    transition: var(--transition);
}

.footer p {
    margin: 0;
}

/* ================================
   RESPONSIVE
================================ */
@media (max-width: 1024px) {
    .sidebar {
        width: 220px;
    }

    .topbar {
        left: 220px;
    }

    .main-content {
        margin-left: 220px;
    }

    .topbar-title {
        display: none;
    }
}

@media (max-width: 768px) {
    .sidebar {
        transform: translateX(-100%);
        width: 280px;
    }

    .sidebar.show {
        transform: translateX(0);
        z-index: 1000;
    }

    .topbar {
        left: 0;
        padding: 0 1rem;
    }

    .toggle-sidebar {
        display: block;
    }

    .main-content {
        margin-left: 0;
    }

    .footer {
        left: 0;
    }

    .topbar-right {
        gap: 1rem;
    }

    .user-info {
        display: none;
    }
}

/* ================================
   UTILITY CLASSES
================================ */
.cor {
    color: #e74c3c;
}

.radius {
    border-radius: 10px;
}

.blue {
    color: var(--primary-color);
}

.linhasRetas {
    white-space: nowrap;
}

/* ================================
   SCROLLBAR
================================ */
::-webkit-scrollbar {
    width: 8px;
    height: 8px;
}

::-webkit-scrollbar-track {
    background: var(--gray-100);
}

::-webkit-scrollbar-thumb {
    background: var(--gray-400);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--primary-color);
}
"""

with open('/root/layoutgpcp.css', 'w', encoding='utf-8') as f:
    f.write(css_content)

print(f"layoutgpcp.css gerado com {len(css_content.splitlines())} linhas")