/* TiruSera Master Stylesheet v2.6 
   Aesthetic: Technical Architectural / Industrial Drafting
   Synced for: Auth, Client Dashboard, Admin HQ, and Payment Vaults
*/

@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;600;800&family=Roboto+Mono:wght@400;700&display=swap');

:root {
    --olive: #556B2F;
    --gold: #D4AF37;
    --dark-grey: #2C3E50;
    --black-accent: #1a1a1a;
    --paper-white: #FBFAF8;
    --grid-line: #EDEDEB;
    --border-color: #dddddd;
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    --sidebar-width: 260px;
    --success: #2ecc71;
    --warning: #f39c12;
    --danger: #e74c3c;
    --white: #ffffff;
    --light-grey: #f5f5f5;
    --text-muted: #888;
}

/* --- Global Reset & Drafting Grid --- */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Inter', sans-serif;
    background-color: var(--paper-white);
    /* Drafting Grid Effect */
    background-image:
        linear-gradient(var(--grid-line) 1px, transparent 1px),
        linear-gradient(90deg, var(--grid-line) 1px, transparent 1px);
    background-size: 50px 50px;
    color: var(--dark-grey);
    line-height: 1.6;
}

/* --- Top Bar --- */
.top-bar {
    background-color: var(--olive);
    color: white;
    padding: 10px 10%;
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-family: 'Roboto Mono', monospace;
    font-size: 0.7rem;
}

.lang-select {
    appearance: none;
    -webkit-appearance: none;
    -moz-appearance: none;
    background-color: transparent;
    border: none;
    color: var(--black-accent);
    font-family: 'Roboto Mono', monospace;
    font-size: 0.7rem;
    font-weight: bold;
    cursor: pointer;
    padding-right: 15px;
    background-image: url("data:image/svg+xml;charset=US-ASCII,%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20width%3D%22292.4%22%20height%3D%22292.4%22%3E%3Cpath%20fill%3D%22%231a1a1a%22%20d%3D%22M287%2069.4a17.6%2017.6%200%200%200-13-5.4H18.4c-5%200-9.3%201.8-12.9%205.4A17.6%2017.6%200%200%200%200%2082.2c0%205%201.8%209.3%205.4%2012.9l128%20127.9c3.6%203.6%207.8%205.4%2012.8%205.4s9.2-1.8%2012.8-5.4L287%2095c3.5-3.5%205.4-7.8%205.4-12.8%200-5-1.9-9.2-5.5-12.8z%22%2F%3E%3C%2Fsvg%3E");
    background-repeat: no-repeat;
    background-position: right center;
    background-size: 8px;
}

.lang-select option {
    color: black;
    background: white;
}

/* --- Navigation & Header --- */
header {
    background: rgba(255, 255, 255, 0.98);
    backdrop-filter: blur(10px);
    border-bottom: 2px solid var(--black-accent);
    padding: 15px 10%;
    display: flex;
    justify-content: space-between;
    align-items: center;
    position: sticky;
    top: 0;
    z-index: 1000;
}

.logo {
    font-size: 1.6rem;
    font-weight: 800;
    letter-spacing: -1.5px;
    color: var(--black-accent);
    text-decoration: none;
}

.logo span {
    color: var(--olive);
}

.nav-list {
    display: flex;
    list-style: none;
    gap: 30px;
    align-items: center;
}

.nav-list a {
    text-decoration: none;
    color: var(--dark-grey);
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
    font-family: 'Roboto Mono', monospace;
    transition: var(--transition);
}

.nav-list a:hover {
    color: var(--olive);
}

/* --- Component: Technical Labels --- */
.tech-label {
    font-family: 'Roboto Mono', monospace;
    font-size: 0.65rem;
    background: var(--black-accent);
    color: white;
    padding: 4px 12px;
    display: inline-block;
    letter-spacing: 2px;
    text-transform: uppercase;
}

/* --- Component: Stat Cards (Dashboard) --- */
.stat-card {
    text-decoration: none;
    color: inherit;
    display: block;
    border-left-width: 5px;
    border-left-style: solid;
}

.stat-card h4 {
    font-family: 'Roboto Mono', monospace;
    font-size: 0.65rem;
    color: #888;
    text-transform: uppercase;
}

.stat-card h2 {
    font-size: 3rem;
    margin: 10px 0;
    font-weight: 800;
}

.stat-card p {
    font-size: 0.7rem;
    color: #999;
}

.stat-card--olive {
    border-left-color: var(--olive);
}

.stat-card--olive h2 {
    color: var(--olive);
}

.stat-card--gold {
    border-left-color: var(--gold);
}

.stat-card--gold h2 {
    color: var(--gold);
}

.stat-card--orange {
    border-left-color: #f59e0b;
}

.stat-card--orange h2 {
    color: #f59e0b;
}

.stat-card--blue {
    border-left-color: #3498db;
}

.stat-card--blue h2 {
    color: #3498db;
}

/* --- Component: Dashboard Widgets --- */
.health-matrix {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 15px;
}

.health-matrix div small {
    color: #888;
    font-size: 0.65rem;
    font-family: 'Roboto Mono';
}

.health-matrix div span {
    font-weight: 800;
}

.health-matrix-online {
    color: var(--success);
}

.health-matrix-offline {
    color: var(--danger);
}

/* --- Component: Project Cards --- */
.card,
.login-box {
    background: white;
    border: 1px solid var(--border-color);
    border-left: 5px solid var(--black-accent);
    padding: 30px;
    transition: var(--transition);
}

.card:hover {
    border-color: var(--olive);
    box-shadow: 15px 15px 0px rgba(85, 107, 47, 0.05);
}

/* --- Card Welcome Animation --- */
.animate-on-scroll {
    opacity: 0;
    transform: translateY(25px);
    transition: opacity 0.6s ease-out, transform 0.6s ease-out;
}

.animate-on-scroll.is-visible {
    opacity: 1;
    transform: translateY(0);
}

/* --- Progress Tracking --- */
.progress-container {
    background: #eee;
    height: 8px;
    width: 100%;
    margin: 15px 0;
    overflow: hidden;
}

.progress-bar {
    height: 100%;
    background: var(--olive);
    width: 0%;
    transition: width 1s ease-in-out;
}

/* --- Badge System --- */
.badge {
    padding: 4px 10px;
    border-radius: 12px;
    font-size: 0.7rem;
    font-weight: bold;
    font-family: 'Roboto Mono';
    text-transform: uppercase;
    color: white;
    display: inline-block;
}

.status-active,
.status-verified,
.status-success {
    background-color: var(--olive);
}

.status-pending,
.status-warning {
    background-color: var(--warning);
}

.status-completed,
.status-info {
    background-color: #3498db;
}

.status-on-hold,
.status-muted {
    background-color: #95a5a6;
}

.status-cancelled,
.status-danger {
    background-color: var(--danger);
}

.status-fully-paid {
    background-color: var(--black-accent);
}

/* --- Stepper System --- */
.stepper-wrapper {
    display: flex;
    margin-top: 10px;
}

.stepper-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    flex: 1;
    position: relative;
}

.stepper-item::before {
    content: "";
    position: absolute;
    top: 10px;
    left: -50%;
    width: 100%;
    height: 2px;
    background-color: #e0e0e0;
    z-index: 1;
}

.stepper-item:first-child::before {
    content: none;
}

.step-counter {
    z-index: 2;
    width: 22px;
    height: 22px;
    border-radius: 50%;
    background-color: #e0e0e0;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.75rem;
    font-weight: bold;
    color: white;
    border: 2px solid white;
    box-shadow: 0 0 0 1px #eee;
}

.step-name {
    font-size: 0.7rem;
    color: #a0a0a0;
    margin-top: 8px;
    font-family: 'Roboto Mono', monospace;
    font-weight: bold;
}

.stepper-item.completed .step-counter {
    background-color: var(--olive);
}

.stepper-item.completed+.stepper-item::before {
    background-color: var(--olive);
}

.stepper-item.completed .step-name {
    color: var(--olive);
}

.stepper-item.active .step-counter {
    background-color: var(--warning);
}

.stepper-item.active .step-name {
    color: var(--warning);
}

/* --- Dashboard Grid System --- */
.dash-grid-stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 30px;
    margin-bottom: 40px;
}

/* --- Security: Watermark & Lock --- */
.preview-wrapper {
    position: relative;
    border: 2px solid var(--black-accent);
    background: #000;
}

.watermark-overlay {
    position: absolute;
    inset: 0;
    pointer-events: none;
    background-image: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" width="150" height="150"><text x="50%" y="50%" text-anchor="middle" fill="rgba(255,255,255,0.1)" font-family="Roboto Mono" font-size="12" transform="rotate(-45 75 75)">UNVERIFIED_DRAFT</text></svg>');
    z-index: 5;
}

.milestone-lock {
    position: absolute;
    inset: 0;
    background: rgba(26, 26, 26, 0.9);
    color: white;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    z-index: 10;
    padding: 20px;
    text-align: center;
}

/* --- Dashboard Common Blocks --- */
.page-intro {
    margin-bottom: 40px;
}

.page-intro h1 {
    font-size: 2.5rem;
    font-weight: 800;
    margin: 0;
}

.page-intro p {
    color: #666;
    margin-top: 10px;
}

.success-box {
    background: #e8f5e9;
    color: #2e7d32;
    padding: 20px;
    margin-bottom: 30px;
    border-left: 5px solid #4caf50;
    border-radius: 4px;
}

.error-box {
    background: #fee2e2;
    color: #b91c1c;
    padding: 20px;
    margin-bottom: 30px;
    border-left: 5px solid #ef4444;
    border-radius: 4px;
}

/* --- Admin Specifics --- */
.admin-sidebar {
    width: var(--sidebar-width);
    background: var(--black-accent);
    color: white;
    padding: 40px 20px;
    border-right: 5px solid var(--olive);
    position: sticky;
    top: 0;
    height: 100vh;
    overflow-y: auto;
}

.sidebar-header {
    font-size: 0.65rem;
    color: #888;
    margin: 25px 0 15px;
    letter-spacing: 1px;
    font-family: 'Roboto Mono';
    font-weight: bold;
    text-transform: uppercase;
    border-bottom: 1px solid #333;
    padding-bottom: 5px;
}

.admin-table {
    width: 100%;
    border-collapse: collapse;
    background: white;
}

.admin-table th {
    background: #f8f8f8;
    padding: 15px;
    font-family: 'Roboto Mono';
    font-size: 0.7rem;
    text-transform: uppercase;
    border-bottom: 2px solid var(--black-accent);
}

.admin-table td {
    padding: 15px;
    border-bottom: 1px solid #eee;
    vertical-align: middle;
    font-size: 0.85rem;
}

/* --- Buttons --- */
.btn-olive {
    background: var(--olive);
    color: white;
    padding: 12px 24px;
    border: none;
    font-family: 'Roboto Mono';
    font-weight: 700;
    text-decoration: none;
    display: inline-block;
    transition: var(--transition);
}

.btn-olive:hover {
    background: var(--black-accent);
}

.btn-outline {
    border: 1px solid var(--black-accent);
    color: var(--black-accent);
    padding: 12px 24px;
    text-decoration: none;
    font-family: 'Roboto Mono';
}

/* --- Layout Utils --- */
.grid-2 {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 30px;
}

.grid-3 {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 30px;
}

#sidebar-overlay {
    display: none;
}

@media (max-width: 900px) {

    .grid-2,
    .grid-3 {
        grid-template-columns: 1fr;
    }

    header {
        padding: 15px 5%;
    }

    /* Mobile Sidebar (Off-canvas) */
    .admin-sidebar {
        position: fixed !important;
        left: 0;
        top: 0;
        height: 100vh !important;
        z-index: 2000;
        transform: translateX(-100%);
        width: 260px !important;
    }

    .admin-sidebar.mobile-visible {
        transform: translateX(0);
    }

    #mobile-menu-toggle {
        display: block !important;
        position: fixed;
        top: 15px;
        left: 15px;
        z-index: 2001;
        background: var(--black-accent);
        color: white;
        border: none;
        padding: 5px 12px;
        border-radius: 4px;
        font-size: 1.5rem;
        cursor: pointer;
        box-shadow: 0 2px 5px rgba(0, 0, 0, 0.2);
        line-height: 1;
    }

    #sidebar-overlay.active {
        display: block;
        position: fixed;
        top: 0;
        left: 0;
        width: 100%;
        height: 100%;
        background: rgba(0, 0, 0, 0.5);
        z-index: 1999;
        backdrop-filter: blur(2px);
    }

    .dash-content {
        padding: 20px !important;
    }

    /* --- Client Portal Responsive (Hamburger) --- */
    .hamburger-btn {
        display: block !important;
        background: none;
        border: none;
        font-size: 1.8rem;
        cursor: pointer;
        color: var(--black-accent);
        padding: 5px;
    }

    /* --- Client Portal Responsive --- */
    header {
        flex-direction: row !important;
        flex-wrap: wrap;
        justify-content: space-between;
        gap: 0 !important;
        height: auto !important;
        padding: 15px 5% !important;
    }

    header nav {
        display: none;
        width: 100%;
        margin-top: 20px;
        border-top: 1px solid #eee;
        padding-top: 20px;
    }

    header .nav-list {
        flex-direction: column;
        gap: 20px;
        text-align: center;
    }

    header .user-menu {
        display: none;
        width: 100%;
        justify-content: center;
        flex-wrap: wrap;
        margin-top: 20px;
        border-top: 1px solid #eee;
        padding-top: 20px;
    }

    /* Responsive Project Cards */
    .project-card {
        grid-template-columns: 1fr !important;
        gap: 15px !important;
        text-align: center;
    }

    .project-card>div {
        grid-column: 1 / -1 !important;
    }

    .project-card .stepper-wrapper {
        flex-wrap: wrap;
        gap: 10px;
    }

    /* Admin Widgets */
    .timeline-stats {
        grid-template-columns: 1fr !important;
    }

    /* Chat Form */
    .chat-input-area {
        flex-direction: column;
        align-items: stretch !important;
    }

    .chat-input-area input[type="text"] {
        margin-bottom: 10px;
    }

    /* Mobile Menu Active State */
    header.mobile-active nav,
    header.mobile-active .user-menu {
        display: flex;
    }
}

/* --- Back to Top Button --- */
.back-to-top-btn {
    position: fixed;
    bottom: 25px;
    right: 25px;
    display: none;
    /* Hidden by default */
    width: 45px;
    height: 45px;
    background-color: var(--olive);
    color: white;
    text-align: center;
    line-height: 45px;
    font-size: 1.8rem;
    border-radius: 4px;
    text-decoration: none;
    transition: var(--transition);
    z-index: 999;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.2);
}

.back-to-top-btn:hover {
    background-color: var(--black-accent);
    transform: translateY(-3px);
}

/* --- Notification Dropdown --- */
.notification-wrapper {
    position: relative;
    display: inline-block;
}

.notification-dropdown {
    display: none;
    position: absolute;
    top: 150%;
    right: 0;
    background-color: white;
    min-width: 320px;
    box-shadow: 0px 8px 16px 0px rgba(0, 0, 0, 0.2);
    z-index: 1001;
    border-radius: 4px;
    border: 1px solid #eee;
    font-size: 0.9rem;
}

.notification-header {
    padding: 10px 15px;
    font-weight: bold;
    border-bottom: 1px solid #eee;
    font-family: 'Roboto Mono', monospace;
    font-size: 0.8rem;
}

.notification-body {
    max-height: 300px;
    overflow-y: auto;
}

.notification-item {
    display: flex;
    gap: 10px;
    padding: 10px 15px;
    border-bottom: 1px solid #f9f9f9;
    text-decoration: none;
    color: inherit;
    transition: background-color 0.2s;
}

.notification-item:hover {
    background-color: #f4f4f4;
}

.notification-icon {
    font-size: 1.2rem;
}

.notification-title {
    font-weight: 600;
    font-size: 0.85rem;
}

.notification-time {
    font-size: 0.7rem;
    color: #888;
}

/* Responsive Table Wrapper */
.data-table-container {
    overflow-x: auto !important;
}

/* Hamburger Button Default (Desktop) */
.hamburger-btn {
    display: none;
}

/* Login Type Toggle */
.login-type-toggle {
    display: flex;
    background: #333;
    padding: 5px;
    border-radius: 4px;
    margin-bottom: 20px;
}

.type-btn {
    flex: 1;
    background: transparent;
    border: none;
    color: #888;
    padding: 10px;
    cursor: pointer;
    font-family: 'Roboto Mono', monospace;
    font-size: 0.8rem;
    font-weight: bold;
    transition: var(--transition);
    border-radius: 2px;
}

.type-btn:hover {
    color: white;
}

.type-btn.active {
    background: #444;
    color: white;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.2);
}

.type-btn[data-type="manager"].active {
    color: var(--gold);
}

.admin-table .due-date-overdue {
    color: var(--danger);
    font-weight: bold;
}

/* --- Manager Theme (Golden) --- */
body.manager-theme .tech-label {
    background: var(--gold);
    color: black;
}

body.manager-theme .btn-olive {
    background: var(--gold);
    color: black;
}

body.manager-theme .btn-olive:hover {
    background: #b8860b;
}

body.manager-theme .admin-sidebar {
    border-right-color: var(--black-accent);
}

/* Manager Sidebar Specifics */
.manager-theme-sidebar {
    background-color: var(--gold) !important;
    color: var(--black-accent) !important;
}

.manager-theme-sidebar .logo,
.manager-theme-sidebar .logo span {
    color: var(--black-accent) !important;
}

.manager-theme-sidebar .sidebar-header {
    color: var(--black-accent);
    border-bottom-color: rgba(0, 0, 0, 0.2);
}

.manager-theme-sidebar a {
    color: var(--black-accent) !important;
}

.manager-theme-sidebar a:hover {
    color: white !important;
    background: rgba(0, 0, 0, 0.1);
}

.manager-theme-sidebar .profile-wrapper {
    border-color: var(--black-accent) !important;
}

.manager-theme-sidebar input[name="q"] {
    background: rgba(0, 0, 0, 0.1) !important;
    color: var(--black-accent) !important;
    border-color: rgba(0, 0, 0, 0.2) !important;
}

.manager-theme-sidebar input[name="q"]::placeholder {
    color: rgba(0, 0, 0, 0.5) !important;
}

/* Before/After Slider Styles */
.ba-container {
    position: relative;
    width: 100%;
    max-width: 900px;
    height: 500px;
    margin: 0 auto;
    overflow: hidden;
    border: 4px solid var(--black-accent);
    border-radius: 4px;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.1);
}

.ba-before,
.ba-after {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    overflow: hidden;
}

.ba-before img,
.ba-after img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: left;
    display: block;
}

.ba-after {
    width: 50%;
    border-right: 3px solid var(--olive);
    z-index: 2;
}

.ba-range {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0;
    cursor: ew-resize;
    z-index: 10;
    margin: 0;
}

.ba-handle {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 40px;
    height: 40px;
    background: var(--olive);
    border-radius: 50%;
    z-index: 3;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    pointer-events: none;
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.5);
}

.ba-handle::after {
    content: '↔';
    font-weight: bold;
}

.ba-label {
    position: absolute;
    bottom: 20px;
    background: rgba(0, 0, 0, 0.8);
    color: white;
    padding: 5px 12px;
    font-family: 'Roboto Mono', monospace;
    font-size: 0.8rem;
    z-index: 4;
    border-radius: 2px;
}

.ba-before .ba-label {
    right: 20px;
}

.ba-after .ba-label {
    left: 20px;
}

/* --- Landing Page Refactor --- */
.hero-section {
    background: var(--black-accent);
    color: white;
    padding: 140px 10% 100px;
    position: relative;
    overflow: hidden;
    min-height: 80vh;
    display: flex;
    align-items: center;
}

.hero-bg-line {
    position: absolute;
    top: 0;
    right: 20%;
    width: 1px;
    height: 100%;
    background: rgba(255, 255, 255, 0.05);
}

.hero-bg-grid {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0.05;
    pointer-events: none;
    background-image: radial-gradient(var(--olive) 1px, transparent 1px);
    background-size: 40px 40px;
}

.hero-content {
    position: relative;
    z-index: 2;
    max-width: 850px;
}

.hero-label {
    border: 1px solid var(--olive);
    color: var(--olive);
    margin-bottom: 20px;
}

.hero-title {
    font-size: 4.2rem;
    font-weight: 800;
    line-height: 1.1;
    margin: 20px 0;
    letter-spacing: -2px;
}

.hero-desc {
    font-size: 1.3rem;
    opacity: 0.8;
    margin-bottom: 40px;
    line-height: 1.6;
    font-weight: 300;
    max-width: 600px;
}

.hero-actions {
    display: flex;
    gap: 20px;
    flex-wrap: wrap;
}

.btn-lg {
    padding: 18px 40px;
    font-size: 1rem;
}

.btn-outline-white {
    color: white;
    border-color: rgba(255, 255, 255, 0.3);
}

.btn-cta-secondary {
    padding: 15px 40px;
    font-size: 1rem;
    text-decoration: none;
    display: inline-block;
    background: var(--black-accent);
    color: var(--olive);
    font-weight: 800;
    letter-spacing: 1px;
}

.btn-gold-accent {
    background: var(--black-accent);
    color: var(--gold);
}

.section-std {
    padding: 100px 10%;
    background: #fff;
}

.section-alt {
    padding: 100px 10%;
    background: #f4f4f2;
}

.section-border-top {
    border-top: 1px solid #eee;
}

.feature-card {
    border: none;
    padding: 0 0 0 25px;
    box-shadow: none;
    background: transparent;
}

.feature-card h3 {
    font-size: 1.4rem;
    margin-bottom: 15px;
    font-weight: 800;
}

.feature-card p {
    color: #666;
    font-size: 1rem;
    line-height: 1.6;
}

.border-left-olive {
    border-left: 4px solid var(--olive);
}

.border-left-black {
    border-left: 4px solid var(--black-accent);
}

.showcase-header {
    margin-bottom: 50px;
}

.section-title {
    font-size: 2.5rem;
    font-weight: 800;
    margin-top: 20px;
}

.section-subtitle {
    color: #666;
    max-width: 700px;
    margin: 10px auto;
}

.service-card {
    padding: 50px;
    background: white;
    transition: transform 0.3s;
}

.service-card h3 {
    font-size: 2rem;
    font-weight: 800;
    margin-bottom: 20px;
}

.service-card p {
    color: #666;
    margin-bottom: 30px;
    line-height: 1.7;
}

.service-list {
    list-style: none;
    padding: 0;
    margin-bottom: 30px;
    font-family: 'Roboto Mono';
    font-size: 0.85rem;
    color: #555;
}

.service-list li {
    margin-bottom: 10px;
}

.border-top-black {
    border-top: 5px solid var(--black-accent);
}

.border-top-olive {
    border-top: 5px solid var(--olive);
}

.staffing-desc {
    color: #666;
    font-size: 1.1rem;
    line-height: 1.6;
    margin-bottom: 30px;
}

.staffing-list {
    list-style: none;
    padding: 0;
    margin-bottom: 40px;
    font-family: 'Roboto Mono';
    font-size: 0.9rem;
    color: #555;
}

.staffing-list li {
    margin-bottom: 15px;
}

.virtual-office {
    background: #f9f9f9;
    padding: 40px;
    border-radius: 4px;
    border: 1px dashed #ddd;
    text-align: center;
}

.cta-section {
    padding: 120px 10%;
    background: var(--black-accent);
    color: white;
    text-align: center;
    position: relative;
}

.cta-bg-grid {
    position: absolute;
    inset: 0;
    opacity: 0.05;
    background-image: linear-gradient(var(--olive) 1px, transparent 1px), linear-gradient(90deg, var(--olive) 1px, transparent 1px);
    background-size: 40px 40px;
}

.cta-content {
    position: relative;
    z-index: 2;
}

.cta-title {
    font-size: 3.5rem;
    font-weight: 800;
    margin: 20px 0 30px;
    letter-spacing: -2px;
}

.cta-desc {
    font-size: 1.2rem;
    color: #aaa;
    max-width: 600px;
    margin: 0 auto 50px;
}

.text-center {
    text-align: center;
}

.mb-20 {
    margin-bottom: 20px;
}

.mb-50 {
    margin-bottom: 50px;
}

.mt-50 {
    margin-top: 50px;
}

.gap-40 {
    gap: 40px;
}

.gap-50 {
    gap: 50px;
}

.gap-60 {
    gap: 60px;
}

.align-center {
    align-items: center;
}

.dash-content {
    padding: 40px;
    flex: 1;
}

/* --- Admin & Manager Dashboard Layout --- */
@media (min-width: 901px) {
    .admin-layout {
        display: grid;
        grid-template-columns: var(--sidebar-width) 1fr;
        min-height: 100vh;
    }
    .admin-layout.dashboard-view .dash-content {
        display: grid;
        grid-template-columns: 1fr 380px;
        gap: 30px;
        padding: 40px;
        align-items: flex-start;
    }
}

.admin-sidebar a[href*="type=system_logs"] {
    display: none !important;
}

.dashboard-main {
    display: flex;
    flex-direction: column;
    gap: 30px;
}

.dashboard-sidebar {
    display: flex;
    flex-direction: column;
    gap: 30px;
    position: sticky;
    top: 20px;
}

/* Phase Form in Admin */
.phase-form-row {
    display: grid;
    grid-template-columns: 1fr 120px 80px;
    gap: 10px;
    align-items: center;
    margin-bottom: 10px;
}

.phase-form-row input[type="text"],
.phase-form-row input[type="number"] {
    padding: 8px;
    border: 1px solid #ddd;
    border-radius: 3px;
    font-size: 0.8rem;
}

.delete-phase-label {
    font-size: 0.7rem;
    color: #e74c3c;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 4px;
}

/* Stage Notification & Pulse */
.stage-notification {
    background-color: #e0f2fe;
    color: #0369a1;
    padding: 12px;
    border-radius: 4px;
    margin-bottom: 20px;
    text-align: center;
    font-family: 'Roboto Mono', monospace;
    font-size: 0.8rem;
    border: 1px solid #bae6fd;
    animation: fadeInUp 0.5s ease-out;
    box-shadow: 0 2px 5px rgba(0,0,0,0.05);
}

@keyframes fadeInUp { from { opacity: 0; transform: translateY(5px); } to { opacity: 1; transform: translateY(0); } }

/* Receipt Modal */
.receipt-modal { display: none; position: fixed; z-index: 2000; padding-top: 50px; left: 0; top: 0; width: 100%; height: 100%; overflow: auto; background-color: rgba(0,0,0,0.9); }
.receipt-modal-content { margin: auto; display: block; width: 80%; max-width: 700px; animation: zoom 0.6s; }
.receipt-close-btn { position: absolute; top: 15px; right: 35px; color: #f1f1f1; font-size: 40px; font-weight: bold; transition: 0.3s; cursor: pointer; }
.receipt-close-btn:hover { color: #bbb; text-decoration: none; cursor: pointer; }
@keyframes zoom { from {transform:scale(0)} to {transform:scale(1)} }

.live-indicator { color: #e74c3c; animation: blink 2s infinite; font-size: 0.5em; vertical-align: middle; margin-left: 10px; display: inline-block; }
@keyframes blink { 0% { opacity: 1; } 50% { opacity: 0.4; } 100% { opacity: 1; } }

/* Manager Theme Overrides */
body.manager-theme .stepper-item.completed .step-counter { background-color: var(--gold); }
body.manager-theme .stepper-item.completed + .stepper-item::before { background-color: var(--gold); }
body.manager-theme .stepper-item.completed .step-name { color: var(--gold); font-weight: bold; }

/* Global Modal Styles (Unified) */
.modal { display: none; position: fixed; z-index: 2000; left: 0; top: 0; width: 100%; height: 100%; overflow: auto; background-color: rgba(0,0,0,0.5); backdrop-filter: blur(2px); }
.modal-content { background-color: #fefefe; margin: 5% auto; padding: 25px; border: 1px solid #888; width: 90%; max-width: 600px; border-radius: 4px; position: relative; box-shadow: 0 4px 20px rgba(0,0,0,0.2); animation: zoom 0.3s; }
.close-btn { color: #aaa; float: right; font-size: 28px; font-weight: bold; cursor: pointer; line-height: 1; }
.close-btn:hover, .close-btn:focus { color: black; text-decoration: none; cursor: pointer; }

/* --- Dark Mode Overrides --- */
body.dark-mode { background-color: #121212 !important; color: #e0e0e0 !important; }
body.dark-mode .card, body.dark-mode .admin-sidebar, body.dark-mode header { background-color: #1e1e1e !important; border-color: #333 !important; color: #e0e0e0 !important; }
body.dark-mode input, body.dark-mode select, body.dark-mode textarea { background-color: #2c2c2c !important; border-color: #444 !important; color: #fff !important; }
body.dark-mode .nav-list a { color: #e0e0e0 !important; }
body.dark-mode .modal-content { background-color: #1e1e1e; border-color: #333; color: #e0e0e0; }
body.dark-mode .stepper-item::before { background-color: #333; }
body.dark-mode .stepper-item.completed + .stepper-item::before { background-color: var(--olive); }
body.dark-mode .step-counter { background-color: #333; }
body.dark-mode .stepper-item.completed .step-counter { background-color: var(--olive); }
body.dark-mode .stepper-item.active .step-counter { background-color: #f39c12; }
body.dark-mode .proj-card-header { background: #2c2c2c; border-color: #444; }

/* --- Auth Pages --- */
.auth-page { background: #1a1a1a; color: white; }
.auth-page main { min-height: 100vh; display: flex; align-items: center; justify-content: center; padding: 20px; }
.login-wrapper { width: 100%; max-width: 400px; }

/* --- Client Dashboard --- */
.dashboard-grid { display: grid; grid-template-columns: 1fr 360px; gap: 30px; align-items: start; }
.dashboard-sidebar { grid-column: 2; }
.main-content { grid-column: 1; }
@media (max-width: 1024px) { 
    .dashboard-grid { grid-template-columns: 1fr; } 
    .dashboard-sidebar { grid-column: 1; order: 2; }
    .main-content { grid-column: 1; order: 1; }
}

/* Notification Dropdown */
.notif-dropdown { position: absolute; top: 40px; right: -10px; width: 300px; background: white; border: 1px solid #eee; border-radius: 4px; box-shadow: 0 5px 15px rgba(0,0,0,0.1); z-index: 1000; display: none; }
.notif-dropdown.show { display: block; }
.notif-header { padding: 10px 15px; border-bottom: 1px solid #eee; font-weight: bold; font-size: 0.8rem; color: #333; display: flex; justify-content: space-between; align-items: center; }
.notif-list { list-style: none; padding: 0; margin: 0; max-height: 250px; overflow-y: auto; }
.notif-item { padding: 10px 15px; border-bottom: 1px solid #f9f9f9; font-size: 0.8rem; color: #555; cursor: pointer; transition: background 0.2s; }
.notif-item:hover { background: #fdfdfb; }
.notif-item:last-child { border-bottom: none; }
.notif-time { font-size: 0.65rem; color: #999; display: block; margin-top: 3px; font-family: 'Roboto Mono'; }
.notif-footer { padding: 10px; text-align: center; border-top: 1px solid #eee; background: #fafafa; }
.notif-footer a { font-size: 0.7rem; color: var(--olive); text-decoration: none; font-weight: bold; }
body.dark-mode .notif-dropdown { background: #1e1e1e; border-color: #333; }
body.dark-mode .notif-header { border-color: #333; color: #e0e0e0; }
body.dark-mode .notif-item { border-color: #333; color: #ccc; }
body.dark-mode .notif-item:hover { background: #2c2c2c; }
body.dark-mode .notif-footer { background: #2c2c2c; border-color: #333; }

/* Stepper Pulse Animation */
@keyframes pulse-orange { 0% { box-shadow: 0 0 0 0 rgba(243, 156, 18, 0.7); } 70% { box-shadow: 0 0 0 10px rgba(243, 156, 18, 0); } 100% { box-shadow: 0 0 0 0 rgba(243, 156, 18, 0); } }
.stepper-item.pulse .step-counter { animation: pulse-orange 2s infinite; }

/* --- Tabs Component --- */
.tabs {
    display: flex;
    border-bottom: 1px solid #ddd;
    margin-bottom: 20px;
    background: #fff;
    border-radius: 4px 4px 0 0;
    overflow-x: auto;
}

.tab-link {
    padding: 15px 20px;
    cursor: pointer;
    text-decoration: none;
    color: #555;
    font-weight: 600;
    font-size: 0.8rem;
    border-bottom: 3px solid transparent;
    transition: all 0.2s;
    background: #fff;
    display: inline-block;
    white-space: nowrap;
}

.tab-link:hover {
    background: #f9f9f9;
    color: var(--olive);
}

.tab-link.active {
    border-bottom-color: var(--olive);
    color: var(--olive);
    background: #fdfdfb;
}

.tab-content {
    display: none;
    animation: fadeIn 0.3s;
}

.tab-content.active {
    display: block;
}

@keyframes fadeIn { from { opacity: 0; } to { opacity: 1; } }

/* --- Project Card Internal Grid --- */
.proj-card-header { padding: 15px 25px; background: #fafafa; border-bottom: 1px solid #eee; display: flex; justify-content: space-between; align-items: center; }
.proj-card-body { padding: 25px; }
.proj-details-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 30px; margin-top: 25px; }
.proj-card-footer { background: #f9f9f9; padding: 15px 25px; border-top: 1px solid #eee; display: flex; justify-content: space-between; align-items: center; font-size: 0.75rem; color: #666; }
@media (max-width: 768px) { .proj-details-grid { grid-template-columns: 1fr; } }

/* --- Password Strength Meter --- */
#passStrength { height: 3px; background: #eee; width: 100%; margin-bottom: 25px; position: relative; }
#strengthBar { width: 0%; height: 100%; background: var(--olive); transition: 0.3s; }

/* --- Compact Mode Overrides --- */
body.compact-mode { font-size: 0.85rem; }
body.compact-mode .card { padding: 15px; }
body.compact-mode .admin-sidebar { padding-top: 20px; width: 220px; }
body.compact-mode .sidebar-nav ul li a { padding: 8px 15px; }
body.compact-mode .admin-layout { grid-template-columns: 220px 1fr; }

/* --- Font Size Overrides --- */
html.font-small { font-size: 14px; }
html.font-medium { font-size: 16px; }
html.font-large { font-size: 18px; }

/* --- Toggle Switch (Checkbox style) --- */
.toggle-switch { position: relative; display: inline-block; width: 40px; height: 20px; }
.toggle-switch input { opacity: 0; width: 0; height: 0; }
.slider { position: absolute; cursor: pointer; top: 0; left: 0; right: 0; bottom: 0; background-color: #ccc; transition: .4s; border-radius: 20px; }
.slider:before { position: absolute; content: ""; height: 16px; width: 16px; left: 2px; bottom: 2px; background-color: white; transition: .4s; border-radius: 50%; }
input:checked + .slider { background-color: var(--olive); }
input:checked + .slider:before { transform: translateX(20px); }

/* --- Print Styles --- */
@media print {
    h2 { font-size: 18pt; color: #333; page-break-after: avoid; }
    .logo { font-size: 24pt !important; font-weight: 800; color: #000; }
    .no-print, .btn-olive, header, .sidebar, footer { display: none !important; }
}

/* --- Permission Grid System --- */
.perm-modal-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
    gap: 12px;
    margin-bottom: 25px;
}

.perm-item {
    display: flex;
    gap: 12px;
    padding: 12px;
    background: #f9f9f9;
    border: 1px solid #eee;
    border-radius: 4px;
    align-items: flex-start;
    cursor: pointer;
    transition: var(--transition);
}

.perm-item:hover {
    background: #f0f0f0;
    border-color: var(--olive);
}

.perm-item .bold { font-weight: 700; font-size: 0.8rem; display: block; margin-bottom: 2px; color: var(--black-accent); }
.text-xs { font-size: 0.7rem; }
.lh-tight { line-height: 1.3; }