/* CenTrust Capital ERP - SAP Fiori Style */
:root {
    /* SAP Fiori 3 Color Palette */
    --sap-blue: #0854a0;
    --sap-button-blue: #0a6ed1;
    --sap-shell-color: #354a5f;
    --sap-tile-background: #ffffff;
    --sap-tile-border: #d9d9d9;
    --sap-text: #32363a;
    --sap-light-text: #6a6d70;
    --sap-page-background: #f7f7f7;
    --sap-header-background: #ffffff;
    --sap-header-border: #e5e5e5;
    --sap-green: #107e3e;
    --sap-red: #bb0000;
    --sap-yellow: #e9730c;
    --sap-success: #107e3e;
    --sap-error: #bb0000;
    --sap-warning: #e9730c;
    --sap-information: #0a6ed1;
    --sap-link: #0854a0;
    --sap-border-radius: 0.25rem;
    --sap-content-padding: 1rem;
    --sap-shell-header-height: 2.75rem;
    --sap-tile-margin: 0.5rem;
}

body {
    font-family: "72", "72full", "Segoe UI", Arial, Helvetica, sans-serif;
    margin: 0;
    padding: 0;
    background-color: var(--sap-page-background);
    color: var(--sap-text);
    font-size: 0.875rem;
    line-height: 1.4;
}

/* Login Page Styles - SAP Fiori Style */
.login-container {
    width: 100%;
    height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background-color: var(--sap-page-background);
}

.login-form {
    width: 400px;
    padding: 1.5rem;
    background-color: var(--sap-tile-background);
    border-radius: var(--sap-border-radius);
    box-shadow: 0 0 0.25rem rgba(0, 0, 0, 0.15);
}

.login-form h2 {
    color: var(--sap-text);
    margin-bottom: 1rem;
    text-align: center;
    font-weight: normal;
    font-size: 1.5rem;
}

.login-logo {
    text-align: center;
    margin-bottom: 1.5rem;
}

.login-logo h1 {
    color: var(--sap-gray);
    font-size: 24px;
    margin: 0;
}

.form-group {
    margin-bottom: 1rem;
}

.form-group label {
    display: block;
    margin-bottom: 0.25rem;
    font-weight: normal;
    color: var(--sap-text);
    font-size: 0.875rem;
}

.form-group input {
    width: 100%;
    padding: 0.375rem 0.5rem;
    border: 1px solid var(--sap-tile-border);
    border-radius: var(--sap-border-radius);
    box-sizing: border-box;
    height: 2.25rem;
    font-size: 0.875rem;
}

.form-group input:focus {
    border-color: var(--sap-link);
    outline: none;
    box-shadow: 0 0 0 1px var(--sap-link);
}

.btn {
    display: inline-block;
    padding: 0.25rem 0.625rem;
    background-color: var(--sap-button-blue);
    color: white;
    border-radius: var(--sap-border-radius);
    cursor: pointer;
    border: 1px solid var(--sap-button-blue);
    font-size: 0.875rem;
    font-weight: normal;
    transition: background-color 0.2s;
    height: 2.25rem;
    line-height: 1.75rem;
    min-width: 4rem;
    text-align: center;
}

.btn-primary {
    background-color: var(--sap-button-blue);
    color: white;
    width: 100%;
}

.btn-primary:hover {
    background-color: #085caf;
    border-color: #085caf;
}

.alert {
    padding: 10px;
    margin-bottom: 15px;
    border-radius: 4px;
}

.alert-danger {
    background-color: #ffebeb;
    color: var(--sap-error);
    border: 1px solid var(--sap-error);
}

/* Main App Layout - SAP Fiori Shell */
.app-container {
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

/* Fiori-like shell header */
.shell-header {
    height: var(--sap-shell-header-height);
    background-color: var(--sap-shell-color);
    color: white;
    display: flex;
    align-items: center;
    padding: 0 1rem;
    box-shadow: 0 1px 0 0 rgba(0, 0, 0, 0.1);
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 100;
}

.shell-logo {
    display: flex;
    align-items: center;
}

.shell-logo img {
    height: 1.75rem;
    margin-right: 0.5rem;
    background-color: white;
    padding: 0.25rem;
    border-radius: var(--sap-border-radius);
}

.shell-title {
    font-size: 1rem;
    font-weight: normal;
}

.shell-actions {
    margin-left: auto;
    display: flex;
    align-items: center;
}

.shell-username {
    margin-right: 1rem;
    font-size: 0.875rem;
}

.app-layout {
    display: flex;
    margin-top: var(--sap-shell-header-height);
    min-height: calc(100vh - var(--sap-shell-header-height));
}

/* Fiori-like sidebar */
.sidebar {
    width: 250px;
    background-color: white;
    color: var(--sap-text);
    border-right: 1px solid var(--sap-header-border);
    height: calc(100vh - var(--sap-shell-header-height));
    position: fixed;
    top: var(--sap-shell-header-height);
    overflow-y: auto;
}

.main-content {
    flex: 1;
    margin-left: 250px;
    display: flex;
    flex-direction: column;
}

.content {
    flex: 1;
    padding: var(--sap-content-padding);
    background-color: var(--sap-page-background);
}

/* Sidebar */
.sidebar-header {
    padding: 1rem;
    background-color: white;
    border-bottom: 1px solid var(--sap-header-border);
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.sidebar-header h2 {
    margin: 0;
    font-size: 1rem;
    font-weight: normal;
    margin-top: 0.5rem;
    color: var(--sap-text);
}

.sidebar-header img {
    background-color: white;
    padding: 0.25rem;
    border-radius: var(--sap-border-radius);
    height: 2rem;
}

.sidebar-menu {
    list-style: none;
    padding: 0;
    margin: 0;
}

.sidebar-menu li {
    padding: 0;
}

.sidebar-menu li a {
    display: flex;
    align-items: center;
    padding: 0.75rem 1rem;
    color: var(--sap-text);
    text-decoration: none;
    transition: background-color 0.2s;
    border-left: 0.1875rem solid transparent;
    font-size: 0.875rem;
}

.sidebar-menu li a:hover, .sidebar-menu li a.active {
    background-color: rgba(8, 84, 160, 0.1);
    border-left: 0.1875rem solid var(--sap-link);
    color: var(--sap-link);
}

.sidebar-menu li a i {
    margin-right: 0.75rem;
    font-size: 1rem;
    width: 1.25rem;
    text-align: center;
    color: var(--sap-light-text);
}

/* Dashboard - SAP Fiori Tiles */
.dashboard {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(11.25rem, 1fr));
    grid-gap: var(--sap-tile-margin);
    margin-bottom: 1.5rem;
}

.card {
    background-color: var(--sap-tile-background);
    border-radius: var(--sap-border-radius);
    box-shadow: 0 0 0.125rem rgba(0, 0, 0, 0.1);
    padding: 1rem;
    height: 100%;
    transition: box-shadow 0.2s;
}

.card:hover {
    box-shadow: 0 0 0.25rem rgba(0, 0, 0, 0.15);
}

.card-header {
    margin-bottom: 0.75rem;
    border-bottom: 1px solid var(--sap-header-border);
    padding-bottom: 0.5rem;
}

.card-header h3 {
    margin: 0;
    color: var(--sap-text);
    font-size: 0.875rem;
    font-weight: normal;
}

.kpi {
    text-align: center;
    padding: 0.5rem;
}

.kpi-value {
    font-size: 2rem;
    font-weight: 400;
    color: var(--sap-link);
    margin: 0.5rem 0;
}

.kpi-label {
    color: var(--sap-light-text);
    font-size: 0.875rem;
}

/* Tables - SAP Fiori Style */
.table-container {
    background-color: var(--sap-tile-background);
    border-radius: var(--sap-border-radius);
    box-shadow: 0 0 0.125rem rgba(0, 0, 0, 0.1);
    overflow: hidden;
    margin-bottom: 1.5rem;
}

.table-header {
    padding: 1rem;
    border-bottom: 1px solid var(--sap-header-border);
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.table-header h3 {
    margin: 0;
    color: var(--sap-text);
    font-size: 1rem;
    font-weight: normal;
}

table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.875rem;
}

table th, table td {
    padding: 0.75rem 1rem;
    text-align: left;
    border-bottom: 1px solid var(--sap-header-border);
}

table th {
    background-color: #fafafa;
    font-weight: normal;
    color: var(--sap-text);
    border-bottom: 1px solid var(--sap-header-border);
}

table tr:hover {
    background-color: rgba(8, 84, 160, 0.05);
}

table tr:last-child td {
    border-bottom: none;
}

/* Search Box */
.search-box {
    margin-bottom: 20px;
}

.search-box input {
    padding: 10px;
    border: 1px solid var(--sap-border);
    border-radius: 4px;
    width: 300px;
    max-width: 100%;
}

.search-box button {
    padding: 10px 15px;
    background-color: var(--sap-blue);
    color: white;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    margin-left: 10px;
}

/* Error Pages */
.error-container {
    text-align: center;
    padding: 50px 20px;
}

.error-code {
    font-size: 100px;
    color: var(--sap-gray);
    margin: 0;
}

.error-message {
    font-size: 24px;
    color: var(--sap-gray);
    margin: 10px 0 30px;
}

.error-container .btn {
    padding: 12px 30px;
}

/* Responsive */
@media (max-width: 768px) {
    .app-container {
        flex-direction: column;
    }
    
    .sidebar {
        width: 100%;
        height: auto;
    }
    
    .dashboard {
        grid-template-columns: 1fr;
    }
}
