/* Contract Page Styles - Matching Project Page */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    background: linear-gradient(135deg, #0c0c0c 0%, #1a1a1a 100%);
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    margin: 0;
    padding: 0;
    min-height: 100vh;
    overflow-x: hidden;
    color: #ecf0f1;
}

/* Fixed Banner - Matching Project Page */
.fixed-banner {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 80px;
    background: linear-gradient(135deg, #2c3e50 0%, #34495e 100%);
    display: flex;
    align-items: center;
    z-index: 1000;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.logo-placeholder {
    margin-left: 40px;
    color: #fff;
    font-size: 32px;
    font-weight: 700;
    letter-spacing: 3px;
    text-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    text-decoration: none;
}

.logo-placeholder::after {
    content: '';
    position: absolute;
    bottom: -8px;
    left: 0;
    width: 0;
    height: 3px;
    background: linear-gradient(90deg, #3498db, #e74c3c);
    transition: width 0.3s ease;
}

.logo-placeholder:hover::after {
    width: 100%;
}

/* Main Content - Matching Project Page */
.main-content {
    margin-top: 80px;
    padding: 30px;
    min-height: calc(100vh - 80px);
}

/* Project Financials Summary */
.project-financials-summary {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(20px);
    border-radius: 16px;
    box-shadow: 0 16px 40px rgba(0, 0, 0, 0.2);
    margin: 0 0 30px 0;
    padding: 0;
    overflow: hidden;
}

.financials-header {
    background: linear-gradient(135deg, #3498db 0%, #2980b9 100%);
    padding: 20px 25px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.financials-header h3 {
    color: #fff;
    font-size: 18px;
    font-weight: 700;
    margin: 0;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
}

.project-id {
    color: rgba(255, 255, 255, 0.9);
    font-size: 14px;
    font-weight: 600;
    background: rgba(255, 255, 255, 0.1);
    padding: 6px 12px;
    border-radius: 6px;
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.financials-content {
    padding: 25px;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
}

.financial-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.financial-item:last-child,
.financial-item.balance {
    border-bottom: none;
    padding-top: 20px;
    border-top: 2px solid rgba(52, 152, 219, 0.3);
    margin-top: 15px;
    grid-column: 1 / -1;
}

.financial-label {
    color: #bdc3c7;
    font-weight: 600;
    font-size: 14px;
    letter-spacing: 0.3px;
}

.financial-value {
    color: #ecf0f1;
    font-weight: 700;
    font-size: 16px;
}

.financial-value.primary {
    color: #3498db;
    font-size: 20px;
    text-shadow: 0 2px 4px rgba(52, 152, 219, 0.3);
}

.financial-item.balance .financial-value {
    color: #f39c12;
    font-size: 18px;
    text-shadow: 0 2px 4px rgba(243, 156, 18, 0.3);
}

/* Contract Header - Matching Project Page */
.contract-header {
    background: linear-gradient(135deg, #2c3e50 0%, #34495e 100%);
    border-radius: 20px;
    padding: 35px;
    margin-bottom: 30px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    border: 1px solid rgba(255, 255, 255, 0.1);
    position: relative;
    overflow: hidden;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.contract-header::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 2px;
    background: linear-gradient(90deg, #3498db, #e74c3c, #f39c12, #2ecc71);
    background-size: 300% 100%;
    animation: gradientShift 3s ease-in-out infinite;
}

@keyframes gradientShift {
    0%, 100% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
}

.contract-title {
    color: #fff;
    font-size: 2.5rem;
    font-weight: 700;
    margin: 0;
    text-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
}

.project-info {
    display: flex;
    align-items: center;
    gap: 16px;
}

#project-name {
    color: #bdc3c7;
    font-size: 1.3rem;
    font-weight: 500;
    margin: 0;
}

.back-to-project-btn {
    background: linear-gradient(135deg, #3498db 0%, #2980b9 100%);
    color: #fff;
    padding: 12px 24px;
    border-radius: 12px;
    text-decoration: none;
    font-weight: 500;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 4px 15px rgba(52, 152, 219, 0.3);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.back-to-project-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(52, 152, 219, 0.4);
    background: linear-gradient(135deg, #2980b9 0%, #3498db 100%);
}

/* Contract Layout */
.contract-layout {
    display: flex;
    gap: 30px;
    min-height: 600px;
}

.contract-sidebar {
    width: 280px;
    background: linear-gradient(135deg, #2c3e50 0%, #34495e 100%);
    border-radius: 20px;
    padding: 30px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    border: 1px solid rgba(255, 255, 255, 0.1);
    height: fit-content;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.contract-sidebar:hover {
    transform: translateY(-2px);
    box-shadow: 0 25px 80px rgba(0, 0, 0, 0.4);
}

.sidebar-btn {
    width: 100%;
    padding: 15px 20px;
    border: none;
    background: rgba(255, 255, 255, 0.05);
    text-align: left;
    border-radius: 12px;
    margin-bottom: 10px;
    cursor: pointer;
    font-weight: 500;
    color: #bdc3c7;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    border: 1px solid rgba(255, 255, 255, 0.1);
    position: relative;
    overflow: hidden;
}

.sidebar-btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.1), transparent);
    transition: left 0.5s ease;
}

.sidebar-btn:hover::before {
    left: 100%;
}

.sidebar-btn:hover {
    background: rgba(255, 255, 255, 0.1);
    color: #fff;
    transform: translateX(5px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
}

.sidebar-btn.active {
    background: linear-gradient(135deg, #3498db 0%, #2980b9 100%);
    color: #fff;
    transform: translateX(5px);
    box-shadow: 0 8px 25px rgba(52, 152, 219, 0.3);
}

.contract-viewport {
    flex: 1;
    background: linear-gradient(135deg, #2c3e50 0%, #34495e 100%);
    border-radius: 20px;
    padding: 30px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    border: 1px solid rgba(255, 255, 255, 0.1);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.contract-viewport:hover {
    transform: translateY(-2px);
    box-shadow: 0 25px 80px rgba(0, 0, 0, 0.4);
}

/* Contract Sections */
.contract-section {
    display: none;
}

.contract-section h2 {
    color: #fff;
    font-size: 2rem;
    font-weight: 700;
    margin-bottom: 30px;
    text-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
}

/* Form Styles - Matching Project Page */
.contract-form-container {
    max-width: 100%;
}

.contract-form {
    background: linear-gradient(135deg, #34495e 0%, #2c3e50 100%);
    border-radius: 20px;
    padding: 30px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.2);
}

.form-section {
    margin-bottom: 40px;
    padding: 25px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 15px;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.form-section h3 {
    color: #fff;
    font-size: 1.3rem;
    font-weight: 600;
    margin-bottom: 20px;
    text-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
}

.form-row {
    display: flex;
    gap: 20px;
    margin-bottom: 20px;
}

.form-group {
    flex: 1;
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 500;
    color: #bdc3c7;
    font-size: 0.95rem;
}

.form-control {
    width: 100%;
    padding: 12px 15px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    font-size: 0.95rem;
    background: rgba(255, 255, 255, 0.05);
    color: #fff;
    transition: all 0.3s ease;
    backdrop-filter: blur(10px);
}

.form-control::placeholder {
    color: #95a5a6;
}

.form-control:focus {
    outline: none;
    border-color: #3498db;
    box-shadow: 0 0 0 3px rgba(52, 152, 219, 0.2);
    background: rgba(255, 255, 255, 0.1);
}

/* Signature Section */
.signature-section {
    display: flex;
    gap: 30px;
    margin-top: 20px;
}

.signature-field {
    flex: 1;
}

.signature-field label {
    color: #fff;
    font-weight: 600;
    margin-bottom: 10px;
    display: block;
}

.signature-box {
    border: 2px dashed rgba(255, 255, 255, 0.3);
    border-radius: 12px;
    padding: 30px;
    text-align: center;
    margin-bottom: 15px;
    min-height: 100px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(255, 255, 255, 0.03);
}

.signature-btn {
    background: linear-gradient(135deg, #3498db 0%, #2980b9 100%);
    color: #fff;
    border: none;
    padding: 12px 25px;
    border-radius: 12px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 4px 15px rgba(52, 152, 219, 0.3);
}

.signature-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(52, 152, 219, 0.4);
}

.signature-info {
    display: flex;
    gap: 15px;
}

.signature-name-input,
.signature-date-input {
    flex: 1;
    padding: 10px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.05);
    color: #fff;
    font-size: 0.9rem;
}

/* Buttons - Matching Project Page */
.form-actions {
    display: flex;
    gap: 15px;
    justify-content: flex-end;
    margin-top: 30px;
    padding-top: 25px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.btn-primary,
.btn-secondary,
.btn-success {
    padding: 12px 25px;
    border: none;
    border-radius: 12px;
    cursor: pointer;
    font-weight: 500;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    text-decoration: none;
    display: inline-block;
    text-align: center;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.btn-primary {
    background: linear-gradient(135deg, #3498db 0%, #2980b9 100%);
    color: #fff;
    box-shadow: 0 4px 15px rgba(52, 152, 219, 0.3);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(52, 152, 219, 0.4);
    background: linear-gradient(135deg, #2980b9 0%, #3498db 100%);
}

.btn-secondary {
    background: linear-gradient(135deg, #95a5a6 0%, #7f8c8d 100%);
    color: #fff;
    box-shadow: 0 4px 15px rgba(149, 165, 166, 0.3);
}

.btn-secondary:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(149, 165, 166, 0.4);
    background: linear-gradient(135deg, #7f8c8d 0%, #95a5a6 100%);
}

.btn-success {
    background: linear-gradient(135deg, #2ecc71 0%, #27ae60 100%);
    color: #fff;
    box-shadow: 0 4px 15px rgba(46, 204, 113, 0.3);
}

.btn-success:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(46, 204, 113, 0.4);
    background: linear-gradient(135deg, #27ae60 0%, #2ecc71 100%);
}

/* Signature Modal - Matching Project Page */
.signature-modal {
    display: none;
    position: fixed;
    z-index: 2000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.7);
    backdrop-filter: blur(5px);
}

.signature-modal-content {
    background: linear-gradient(135deg, #2c3e50 0%, #34495e 100%);
    margin: 3% auto;
    padding: 0;
    border-radius: 20px;
    width: 90%;
    max-width: 600px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    box-shadow: 0 25px 80px rgba(0, 0, 0, 0.5);
    overflow: hidden;
    animation: modalSlideIn 0.3s ease-out;
}

@keyframes modalSlideIn {
    from {
        opacity: 0;
        transform: translateY(-30px) scale(0.95);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

.signature-modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 25px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.signature-modal-header h3 {
    color: #fff;
    font-size: 1.4rem;
    font-weight: 600;
    margin: 0;
}

.signature-modal-close {
    color: #bdc3c7;
    font-size: 28px;
    font-weight: bold;
    cursor: pointer;
    background: none;
    border: none;
    padding: 5px;
    border-radius: 50%;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
}

.signature-modal-close:hover {
    color: #fff;
    background: rgba(231, 76, 60, 0.2);
    transform: rotate(90deg);
}

.signature-modal-body {
    padding: 25px;
}

#signature-pad {
    border: 2px solid rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.95);
    display: block;
    margin: 0 auto 20px;
}

.signature-controls {
    display: flex;
    gap: 10px;
    justify-content: center;
}

.signature-clear-btn,
.signature-save-btn,
.signature-cancel-btn {
    padding: 10px 20px;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    font-weight: 500;
    transition: all 0.3s ease;
}

.signature-clear-btn {
    background: linear-gradient(135deg, #95a5a6 0%, #7f8c8d 100%);
    color: #fff;
}

.signature-save-btn {
    background: linear-gradient(135deg, #2ecc71 0%, #27ae60 100%);
    color: #fff;
}

.signature-cancel-btn {
    background: linear-gradient(135deg, #e74c3c 0%, #c0392b 100%);
    color: #fff;
}

/* Container Sections */
.change-orders-container,
.addendums-container,
.permits-container,
.warranties-container,
.insurance-container {
    background: rgba(255, 255, 255, 0.05);
    border-radius: 15px;
    padding: 30px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    text-align: center;
}

.change-orders-container p,
.addendums-container p,
.permits-container p,
.warranties-container p,
.insurance-container p {
    color: #bdc3c7;
    margin-bottom: 20px;
    font-size: 1.1rem;
}

/* Responsive Design */
@media (max-width: 768px) {
    .contract-layout {
        flex-direction: column;
        gap: 20px;
    }
    
    .contract-sidebar {
        width: 100%;
        display: flex;
        overflow-x: auto;
        gap: 8px;
        padding: 16px;
    }
    
    .sidebar-btn {
        white-space: nowrap;
        margin-bottom: 0;
    }
    
    .form-row {
        flex-direction: column;
        gap: 15px;
    }
    
    .signature-section {
        flex-direction: column;
        gap: 20px;
    }
    
    .form-actions {
        flex-direction: column;
    }
    
    .contract-header {
        flex-direction: column;
        gap: 15px;
        text-align: center;
    }
    
    .project-info {
        flex-direction: column;
    }
}

/* Work Authorization Styles */
.cards-container {
    display: flex;
    flex-direction: column;
    gap: 20px;
    margin-bottom: 20px;
}

.work-auth-card {
    background: rgba(44, 62, 80, 0.95);
    border-radius: 15px;
    padding: 20px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.work-auth-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.4);
}

.work-auth-card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    padding-bottom: 15px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.work-auth-card-header h4 {
    color: #ecf0f1;
    font-size: 1.4rem;
    font-weight: 600;
    margin: 0;
}

.close-btn {
    background: rgba(231, 76, 60, 0.2);
    border: 1px solid rgba(231, 76, 60, 0.4);
    color: #e74c3c;
    width: 30px;
    height: 30px;
    border-radius: 50%;
    font-size: 18px;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}

.close-btn:hover {
    background: rgba(231, 76, 60, 0.3);
    transform: scale(1.1);
}

.work-auth-card-body {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.work-auth-form-row {
    display: flex;
    gap: 20px;
}

.work-auth-form-group {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.work-auth-form-group label {
    color: #bdc3c7;
    font-weight: 500;
    font-size: 0.95rem;
}

.work-auth-signature-section {
    margin-top: 20px;
    padding-top: 20px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.work-auth-signature-section h5 {
    color: #ecf0f1;
    font-size: 1.1rem;
    margin-bottom: 15px;
    font-weight: 600;
}

.signature-row {
    display: flex;
    gap: 30px;
}

.signature-column {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.signature-column label {
    color: #bdc3c7;
    font-weight: 500;
    font-size: 0.95rem;
}

.work-auth-actions {
    display: flex;
    gap: 15px;
    margin-top: 20px;
    padding-top: 20px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.add-card-btn {
    background: linear-gradient(135deg, #27ae60 0%, #2ecc71 100%);
    border: none;
    color: white;
    padding: 15px 30px;
    border-radius: 12px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 4px 15px rgba(39, 174, 96, 0.3);
}

.add-card-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(39, 174, 96, 0.4);
}

.cost-input {
    background: rgba(52, 73, 94, 0.8) !important;
    border: 1px solid rgba(127, 140, 141, 0.3) !important;
    color: #ecf0f1 !important;
}

.total-display {
    background: rgba(39, 174, 96, 0.2) !important;
    border: 2px solid rgba(39, 174, 96, 0.6) !important;
    color: #27ae60 !important;
    font-weight: 700 !important;
    font-size: 16px !important;
    text-shadow: 0 1px 3px rgba(0, 0, 0, 0.5) !important;
}

/* Work Authorization Total Field */
.work-auth-total {
    background: rgba(243, 156, 18, 0.15) !important;
    border: 2px solid rgba(243, 156, 18, 0.6) !important;
    color: #f39c12 !important;
    font-weight: 700 !important;
    font-size: 18px !important;
    text-align: center !important;
    padding: 12px 16px !important;
    border-radius: 8px !important;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.7) !important;
    box-shadow: 0 4px 12px rgba(243, 156, 18, 0.2) !important;
    transition: all 0.3s ease !important;
}

/* Specific styling for the total field above Upgrades section */
.work-auth-card-field .work-auth-total[readonly] {
    background: rgba(255, 255, 255, 0.95) !important;
    color: #2c3e50 !important;
    border: 2px solid #34495e !important;
    font-weight: 700 !important;
    font-size: 18px !important;
    text-align: left !important;
    text-shadow: none !important;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1) !important;
    cursor: not-allowed !important;
}

.work-auth-total:focus {
    border-color: #e67e22 !important;
    box-shadow: 0 0 0 3px rgba(243, 156, 18, 0.3) !important;
    background: rgba(243, 156, 18, 0.25) !important;
}

.authorization-statement {
    background: rgba(52, 152, 219, 0.1);
    border: 1px solid rgba(52, 152, 219, 0.3);
    border-radius: 10px;
    padding: 15px;
    margin-bottom: 20px;
    color: #ecf0f1;
    font-style: italic;
    line-height: 1.6;
}

/* Responsive Design for Work Authorization */
@media (max-width: 768px) {
    .work-auth-form-row {
        flex-direction: column;
        gap: 15px;
    }
    
    .signature-row {
        flex-direction: column;
        gap: 20px;
    }
    
    .work-auth-actions {
        flex-direction: column;
    }
    
    .add-card-btn {
        width: 100%;
    }
}

/* Work Authorization Card Styles (duplicated from RIO styles) */
.work-auth-card {
    background: rgba(44, 62, 80, 0.95);
    border: 1px solid rgba(127, 140, 141, 0.3);
    border-radius: 16px;
    margin-bottom: 30px;
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.4);
    backdrop-filter: blur(10px);
    overflow: hidden;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.work-auth-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 25px 60px rgba(0, 0, 0, 0.5);
    border-color: rgba(52, 152, 219, 0.4);
}

.work-auth-card-header {
    background: linear-gradient(135deg, #34495e 0%, #2c3e50 100%);
    padding: 20px 25px;
    border-bottom: 1px solid rgba(127, 140, 141, 0.2);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.work-auth-card-title {
    color: #3498db;
    font-size: 22px;
    font-weight: 700;
    margin: 0;
    text-shadow: 0 2px 10px rgba(52, 152, 219, 0.3);
}

.delete-card-btn {
    background: rgba(231, 76, 60, 0.2);
    border: 1px solid rgba(231, 76, 60, 0.4);
    color: #e74c3c;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    font-size: 18px;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}

.delete-card-btn:hover {
    background: rgba(231, 76, 60, 0.3);
    transform: scale(1.1);
}

.work-auth-card-body {
    padding: 30px;
}

.work-auth-card-field {
    margin-bottom: 20px;
}

.work-auth-card-field label {
    display: block;
    color: #bdc3c7;
    font-weight: 600;
    font-size: 14px;
    margin-bottom: 8px;
    letter-spacing: 0.5px;
}

.work-auth-card-field input,
.work-auth-card-field select,
.work-auth-card-field textarea {
    width: 100%;
    background: rgba(52, 73, 94, 0.8);
    border: 1px solid rgba(127, 140, 141, 0.3);
    border-radius: 8px;
    padding: 12px 16px;
    color: #ecf0f1;
    font-size: 16px;
    transition: all 0.3s ease;
    backdrop-filter: blur(5px);
}

.work-auth-card-field input:focus,
.work-auth-card-field select:focus,
.work-auth-card-field textarea:focus {
    outline: none;
    border-color: #3498db;
    box-shadow: 0 0 0 3px rgba(52, 152, 219, 0.1);
    background: rgba(52, 73, 94, 0.9);
}

.work-auth-card-field textarea {
    resize: vertical;
    min-height: 80px;
}

.job-name-field input {
    font-size: 18px;
    font-weight: 600;
    background: rgba(52, 152, 219, 0.1);
    border-color: rgba(52, 152, 219, 0.3);
}

.roof-options-section,
.upgrades-section,
.shingle-upgrade-section {
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    padding: 25px;
    margin: 25px 0;
}

.roof-options-section h4,
.upgrades-section h4,
.shingle-upgrade-section h4 {
    color: #3498db;
    font-size: 18px;
    font-weight: 700;
    margin-bottom: 20px;
    border-bottom: 2px solid rgba(52, 152, 219, 0.3);
    padding-bottom: 10px;
}

.upgrade-field {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 8px;
    padding: 15px;
    margin-bottom: 15px;
}

.upgrade-row {
    display: flex;
    align-items: center;
    gap: 15px;
    margin-top: 10px;
}

.upgrade-quantity {
    flex: 1;
    max-width: 120px;
}

.upgrade-rate {
    color: #bdc3c7;
    font-weight: 500;
    white-space: nowrap;
}

.upgrade-total {
    color: #2ecc71;
    font-weight: 700;
    font-size: 16px;
    min-width: 80px;
    text-align: right;
}

.shingle-calculation-row {
    display: flex;
    align-items: center;
    gap: 20px;
    margin-top: 10px;
}

.roof-squares-input {
    flex: 1;
    max-width: 150px;
}

.shingle-total {
    color: #2ecc71;
    font-weight: 700;
    font-size: 16px;
}

.grand-total-section {
    background: linear-gradient(135deg, rgba(39, 174, 96, 0.2) 0%, rgba(46, 204, 113, 0.1) 100%);
    border: 2px solid rgba(39, 174, 96, 0.4);
    border-radius: 12px;
    padding: 20px;
    margin: 25px 0;
    text-align: center;
}

.grand-total-row {
    font-size: 24px;
    color: #2ecc71;
    text-shadow: 0 2px 10px rgba(39, 174, 96, 0.3);
}

.signature-section {
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    padding: 25px;
    margin-top: 25px;
}

.signature-section h4 {
    color: #3498db;
    font-size: 18px;
    font-weight: 700;
    margin-bottom: 20px;
    border-bottom: 2px solid rgba(52, 152, 219, 0.3);
    padding-bottom: 10px;
}

.signature-field {
    margin-bottom: 20px;
}

.signature-input-group {
    display: flex;
    align-items: center;
    gap: 15px;
    margin-top: 10px;
}

.signature-preview {
    flex: 1;
    min-height: 60px;
    background: rgba(255, 255, 255, 0.05);
    border: 2px dashed rgba(127, 140, 141, 0.3);
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 10px;
}

.signature-placeholder {
    color: #7f8c8d;
    font-style: italic;
    font-size: 14px;
}

.sign-button {
    background: linear-gradient(135deg, #3498db 0%, #2980b9 100%);
    border: none;
    color: white;
    padding: 10px 20px;
    border-radius: 8px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 14px;
    white-space: nowrap;
}

.sign-button:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(52, 152, 219, 0.3);
}

.signature-date {
    color: #bdc3c7;
    font-size: 12px;
    min-width: 100px;
    text-align: center;
}

.pdf-generation-section {
    text-align: center;
    margin-top: 25px;
    padding-top: 20px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.generate-pdf-btn {
    background: linear-gradient(135deg, #e67e22 0%, #d35400 100%);
    border: none;
    color: white;
    padding: 15px 30px;
    border-radius: 10px;
    font-size: 16px;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 4px 15px rgba(230, 126, 34, 0.3);
}

.generate-pdf-btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(230, 126, 34, 0.4);
}

/* Cards container */
.cards-container {
    margin-top: 20px;
}

/* Add responsive design for work auth cards */
@media (max-width: 768px) {
    .work-auth-card-body {
        padding: 20px;
    }
    
    .upgrade-row {
        flex-direction: column;
        align-items: stretch;
        gap: 10px;
    }
    
    .upgrade-rate {
        text-align: center;
    }
    
    .upgrade-total {
        text-align: center;
    }
    
    .shingle-calculation-row {
        flex-direction: column;
        align-items: stretch;
        gap: 10px;
    }
    
    .signature-input-group {
        flex-direction: column;
        gap: 10px;
    }
    
    .grand-total-row {
        font-size: 20px;
    }
}
