/* Modern Overrides for E-PO */

/* =========================================
   GLOBAL & LAYOUT
   ========================================= */
body {
    background-color: #f0f2f5; /* Lighter, more modern gray-blue background */
    font-family: 'Roboto', 'Helvetica Neue', Helvetica, Arial, sans-serif; /* Soften the condensed font if possible, or stick to it but lighter weight */
}

#wrapper-main {
    box-shadow: 0 0 20px rgba(0,0,0,0.05);
    background-color: #fff;
    /* max-width is already 1300px in custom.css */
    margin-bottom: 2rem;
    border-radius: 0 0 8px 8px;
}

/* =========================================
   HEADER & NAVIGATION
   ========================================= */
#top-bar {
    height: 4.5rem; /* Taller header */
    line-height: 4.5rem; /* Centering */
    background: #ffffff;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
    border-bottom: 1px solid rgba(0,0,0,0.03);
    /* Ensure it overlays correctly */
}

#logo-header img {
    height: 3rem; /* Larger logo */
    transition: transform 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

#logo-header:hover img {
    transform: scale(1.05);
}

/* User Menu Reset */
#menu-user > li {
    padding: 0 0.25rem;
}

#menu-user > li > a {
    height: 2.8rem;
    line-height: 2.8rem;
    margin-top: 0.85rem; /* (4.5 - 2.8) / 2 = 0.85 */
    padding: 0 1.2rem;
    border-radius: 50px; /* Pill shape */
    font-weight: 600;
    font-size: 0.9rem;
    letter-spacing: 0.5px;
    color: #4a5568; /* Softer dark gray */
    transition: all 0.2s ease;
}

#menu-user > li > a i {
    opacity: 0.7;
    margin-right: 0.5rem;
}

/* Hover State */
#menu-user > li > a:hover {
    background-color: rgba(28, 103, 122, 0.08); /* Brand color tint */
    color: #1c677a; /* Brand color */
    text-decoration: none;
    transform: translateY(-1px);
}

/* Active State */
#menu-user > li > a.active {
    background-color: #1c677a;
    color: #fff;
    box-shadow: 0 4px 6px rgba(28, 103, 122, 0.25);
}

#menu-user > li > a.active::after {
    display: none; /* Remove old border */
}

#menu-user > li > a.active i {
    opacity: 1;
}

/* Separator */
#menu-user > li:contains('|') {
    color: #e2e8f0;
}

/* User Profile Special Styling */
#menu-user > li > a.username {
    border: 1px solid #e2e8f0;
    margin-left: 1rem;
}
#menu-user > li > a.username:hover {
    border-color: #1c677a;
}

/* =========================================
   BUTTONS
   ========================================= */
.button {
    font-family: 'Roboto Condensed', sans-serif;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
    border-radius: 6px;
    border: none;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
    background-image: linear-gradient(to bottom right, rgba(255,255,255,0.1), rgba(0,0,0,0.1));
    background-blend-mode: overlay;
    overflow: hidden;
    position: relative;
    z-index: 1;
}

/* Primary Button (Default Black/Dark) */
.button:not(.grey):not(.accept):not(.reject):not(.withdraw) {
    background-color: #2d3748;
}

.button:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(0,0,0,0.15);
}

/* Accept Button */
.button.accept {
    background-color: #10b981; /* Emerald green */
    box-shadow: 0 4px 6px rgba(16, 185, 129, 0.3);
}
.button.accept:hover {
    background-color: #059669;
    box-shadow: 0 6px 12px rgba(16, 185, 129, 0.4);
}

/* Reject Button */
.button.reject {
    background-color: #ef4444; /* Red 500 */
    box-shadow: 0 4px 6px rgba(239, 68, 68, 0.3);
}
.button.reject:hover {
    background-color: #dc2626;
    box-shadow: 0 6px 12px rgba(239, 68, 68, 0.4);
}

/* Grey/Secondary Button */
.button.grey {
    background-color: #718096;
    color: #fff;
}

/* Icons inside buttons */
.button > i, .button > img {
    right: 1.2rem;
    transition: transform 0.2s ease;
}
.button:hover > i, .button:hover > img {
    transform: translateY(-50%) translateX(3px); /* Slight nudge right */
}

/* =========================================
   TYPOGRAPHY HEADINGS
   ========================================= */
h1, h2, h3 {
    font-weight: 700;
    letter-spacing: -0.5px;
    color: #1a202c;
}

h1 {
    position: relative;
    padding-bottom: 0.5rem;
}

/* =========================================
   FORM INPUTS & STYLING
   ========================================= */

/* Modern Input Styling */
input[type="text"], input[type="password"], textarea, select, input[type="number"], .input-group,
.select-autocomplete {
    background-color: #f7fafc;
    border: 1px solid #e2e8f0;
    border-radius: 6px !important;
    padding: 0.6rem 1rem;
    color: #2d3748;
    font-size: 0.95rem;
    transition: all 0.2s ease-in-out;
    box-shadow: inset 0 1px 2px rgba(0,0,0,0.03);
}

/* Fix input groups - override foundation or custom.css specificity */
.input-group {
    background-color: transparent;
    border: none;
    box-shadow: none;
    padding: 0;
    margin-bottom: 1.5rem; /* Space between fields */
    display: flex;
    align-items: stretch;
}

.input-group > .input-group-field {
    border-radius: 6px !important;
    flex: 1;
    border: 1px solid #e2e8f0;
    box-shadow: inset 0 1px 2px rgba(0,0,0,0.03);
}
.input-group > .input-group-field:focus {
     border-color: #1c677a;
     box-shadow: 0 0 0 3px rgba(28, 103, 122, 0.15);
}

.input-group > .input-group-label {
    background-color: #cbd5e0;
    border: 1px solid #cbd5e0;
    color: #4a5568;
    border-radius: 0 6px 6px 0 !important;
    padding: 0 1rem;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
}

/* When input group has a label on the right */
.input-group > .input-group-field:not(:last-child) {
    border-top-right-radius: 0 !important;
    border-bottom-right-radius: 0 !important;
    border-right: none;
}

/* Focus State */
input:focus, textarea:focus, select:focus, .select-autocomplete:focus {
    background-color: #fff;
    border-color: #1c677a;
    box-shadow: 0 0 0 3px rgba(28, 103, 122, 0.15);
    outline: none;
}

/* Labels */
span.title {
    display: block;
    margin-bottom: 0.4rem;
    font-size: 0.85rem;
    text-transform: uppercase;
    color: #718096;
    font-weight: 700;
    letter-spacing: 0.5px;
}

/* Form Sections */
.block-form .fields, 
.wrapper-page > div {
    background-color: #fff;
    border-radius: 12px;
    box-shadow: 0 4px 6px rgba(0,0,0,0.05); /* Card look */
    padding: 2rem;
    margin-bottom: 2rem;
    border: 1px solid #edf2f7;
}
/* Be specific to override custom.css margins */
.wrapper-page > div {
    margin: 2rem auto;
}

/* Checkboxes */
label.input-checkbox {
    display: inline-flex;
    align-items: center;
    cursor: pointer;
    font-weight: 500;
    color: #4a5568;
}

label.input-checkbox input {
    margin-right: 0.5rem;
    width: 1.2rem;
    height: 1.2rem;
    accent-color: #1c677a;
}

/* Table / Items List */
#request-items .request-item {
    background-color: #fff;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    margin-bottom: 1rem;
    padding: 1.5rem;
    box-shadow: 0 2px 4px rgba(0,0,0,0.02);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

#request-items .request-item:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 16px rgba(0,0,0,0.05);
    border-color: #cbd5e0;
}

/* Striping removal - we use cards now */
#request-items > .request-item:nth-child(2n) {
    background-color: #fff; /* Reset gray background */
}

/* Item Inputs inside the card */
#request-items .request-item .input-group {
    margin-bottom: 0.5rem;
}
#request-items .request-item .title {
    font-size: 0.75rem;
    color: #a0aec0;
}

/* Add Item Button */
#add-request-item {
    background-color: #fff;
    border: 2px dashed #cbd5e0;
    color: #718096;
    border-radius: 8px;
    padding: 1rem 2rem;
    width: 100%;
    margin-top: 1rem;
    transition: all 0.2s;
}

#add-request-item:hover {
    border-color: #1c677a;
    color: #1c677a;
    background-color: rgba(28, 103, 122, 0.05);
}
