/* UAT Recovery - Engineering Portal premium page system */
.engineering-portal-body .ep-main{
    background:linear-gradient(180deg,#f3f6fa 0,#eef3f8 100%);
    min-height:calc(100vh - 67px);
}
.ep-dashboard{padding:28px 28px 42px}
.ep-dashboard-hero{
    display:flex;justify-content:space-between;gap:28px;align-items:flex-end;
    background:linear-gradient(135deg,#07111d,#102338 58%,#1b293a);
    color:#fff;border-radius:18px;padding:32px;
    box-shadow:0 18px 50px rgba(15,23,42,.22);
    border:1px solid rgba(255,255,255,.08)
}
.ep-dashboard-hero h1{margin:0 0 8px;font-size:36px;font-weight:900;color:#fff}
.ep-dashboard-hero p{margin:0;max-width:760px;color:#d5dee9;font-size:15px;line-height:1.6}
.ep-kicker{display:inline-block;margin-bottom:8px;color:#f5d36a;font-size:11px;font-weight:900;text-transform:uppercase;letter-spacing:.14em}
.ep-hero-actions{display:flex;gap:10px;flex-wrap:wrap;justify-content:flex-end}
.ep-secondary-btn{display:inline-block;border:1px solid rgba(255,255,255,.28);color:#fff;border-radius:9px;padding:13px 18px;text-decoration:none;font-weight:900;text-transform:uppercase;font-size:11px;letter-spacing:.04em}
.ep-secondary-btn:hover,.ep-secondary-btn:focus{color:#ffd75e;text-decoration:none;border-color:#d7a928}
.ep-dashboard-grid{display:grid;grid-template-columns:320px 1fr;gap:22px;margin-top:22px}
.ep-profile-card{background:#fff;border:1px solid #e2e8f0;border-radius:16px;padding:24px;box-shadow:0 12px 34px rgba(15,23,42,.08)}
.ep-card-label{font-size:11px;text-transform:uppercase;letter-spacing:.12em;font-weight:900;color:#9a730e;margin-bottom:10px}
.ep-profile-card h2{font-size:22px;margin:0 0 7px;color:#07111d;font-weight:900}
.ep-profile-card p{color:#64748b;margin:0 0 18px;word-break:break-word}
.ep-progress{height:9px;background:#e5e7eb;border-radius:999px;overflow:hidden;margin-bottom:9px}
.ep-progress span{display:block;height:100%;background:linear-gradient(90deg,#d7a928,#f6d76b)}
.ep-profile-card a{display:inline-block;margin-top:16px;color:#9a730e;font-weight:900;text-decoration:none}
.ep-card-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:18px}
.ep-dashboard-card{background:#fff;border:1px solid #e2e8f0;border-radius:16px;padding:22px;box-shadow:0 12px 34px rgba(15,23,42,.08);position:relative;min-height:205px}
.ep-card-count{position:absolute;right:18px;top:18px;background:#07111d;color:#f5d36a;border-radius:12px;padding:8px 12px;font-size:20px;font-weight:900}
.ep-dashboard-card h2{font-size:20px;margin:0 64px 10px 0;color:#07111d;font-weight:900}
.ep-dashboard-card p{color:#475569;line-height:1.55;margin:0 0 14px}
.ep-dashboard-card small{display:block;color:#64748b;line-height:1.45;min-height:38px}
.ep-dashboard-card a{display:inline-block;margin-top:14px;color:#9a730e;font-weight:900;text-decoration:none;text-transform:uppercase;font-size:12px}
.ep-activity-panel{background:#fff;border:1px solid #e2e8f0;border-radius:16px;padding:24px;margin-top:22px;box-shadow:0 12px 34px rgba(15,23,42,.08)}
.ep-section-head h2{margin:0 0 4px;font-weight:900;color:#07111d}
.ep-section-head p{margin:0 0 18px;color:#64748b}
.ep-empty{background:#f8fafc;border:1px dashed #cbd5e1;border-radius:12px;padding:18px;color:#64748b}
.ep-activity-list{display:grid;gap:10px}
.ep-activity-item{display:grid;grid-template-columns:1.2fr 2fr auto;gap:14px;padding:14px 16px;border:1px solid #e2e8f0;border-radius:12px;text-decoration:none;color:#0f172a;background:#fbfdff}
.ep-activity-item:hover{border-color:#d7a928;text-decoration:none;color:#0f172a}
.ep-activity-item strong{font-weight:900}
.ep-activity-item span{color:#64748b}
.ep-activity-item em{font-style:normal;color:#94a3b8;font-size:12px}

.engineering-portal-body .ep-main > h1,
.engineering-portal-body .ep-main > h2{
    max-width:1280px;margin:30px auto 10px;padding:0 24px;color:#07111d;font-weight:900;letter-spacing:-.02em
}
.engineering-portal-body .ep-main > h2{font-size:32px}
.engineering-portal-body .ep-main > p{max-width:1280px;margin:0 auto 18px;padding:0 24px}
.engineering-portal-body .ep-main > h2 + p,
.engineering-portal-body .ep-main .text-muted{color:#64748b!important;font-size:15px;line-height:1.55}
.engineering-portal-body .table{
    width:calc(100% - 48px);max-width:1232px;margin:18px auto 30px;background:#fff;
    border-collapse:separate;border-spacing:0;border:1px solid #e2e8f0;border-radius:16px;overflow:hidden;
    box-shadow:0 12px 34px rgba(15,23,42,.08)
}
.engineering-portal-body .table thead th{
    background:#07111d;color:#f8fafc;border:0!important;text-transform:uppercase;font-size:11px;letter-spacing:.07em;padding:15px 16px!important
}
.engineering-portal-body .table tbody td{border-top:1px solid #e2e8f0!important;padding:14px 16px!important;color:#0f172a;vertical-align:middle!important}
.engineering-portal-body .table-striped>tbody>tr:nth-of-type(odd){background:#fbfdff}
.engineering-portal-body .table a{color:#9a730e;font-weight:900;text-decoration:none}
.engineering-portal-body .alert{
    width:calc(100% - 48px);max-width:1232px;margin:18px auto 30px;border-radius:14px;border:1px solid #dbeafe;
    background:#eff6ff;color:#1e3a8a;padding:18px 20px;box-shadow:0 8px 24px rgba(15,23,42,.05)
}
.engineering-portal-body .btn{border-radius:9px!important;font-weight:900!important;text-transform:uppercase;letter-spacing:.04em;font-size:12px!important;padding:10px 15px!important}
.engineering-portal-body .btn-primary{background:#d7a928!important;border-color:#d7a928!important;color:#07111d!important}
.engineering-portal-body .btn-default{background:#fff!important;border-color:#cbd5e1!important;color:#0f172a!important}
.engineering-portal-body .portal-header,
.engineering-portal-body .portal-empty-state,
.engineering-portal-body .portal-card,
.engineering-portal-body .engineering-portal-card{background:#fff;border:1px solid #e2e8f0;border-radius:16px;box-shadow:0 12px 34px rgba(15,23,42,.08)}
.engineering-portal-body .portal-header{padding:28px;margin:28px auto 20px;max-width:1232px}
.engineering-portal-body .portal-header h1{margin:0 0 8px;color:#07111d;font-size:34px;font-weight:900}
.engineering-portal-body .portal-header p{margin:0;color:#64748b}
.engineering-portal-body .portal-empty-state{padding:28px;margin:18px auto;max-width:1232px}
.engineering-portal-body .portal-table{width:100%}

.ep-resend-panel{margin:18px 0 0;padding:16px 18px;border:1px solid #e7c65a;background:linear-gradient(180deg,#fffaf0,#fffdf8);border-radius:14px;box-shadow:0 10px 26px rgba(15,23,42,.07)}
.ep-resend-panel p{margin:0 0 12px;color:#475569;line-height:1.55;font-size:13px}
.ep-resend-panel .ep-inline-form{margin:0}
.ep-resend-panel .ep-secondary-action{display:block;width:100%;border:0;background:#07111d;color:#f5d36a;border-radius:10px;padding:13px 16px;font-weight:900;text-transform:uppercase;letter-spacing:.04em;font-size:12px;box-shadow:0 8px 20px rgba(15,23,42,.16)}
.ep-resend-panel .ep-secondary-action:hover,.ep-resend-panel .ep-secondary-action:focus{background:#102338;color:#fff}

@media(max-width:1100px){.ep-dashboard-grid{grid-template-columns:1fr}.ep-card-grid{grid-template-columns:repeat(2,minmax(0,1fr))}.ep-dashboard-hero{align-items:flex-start;flex-direction:column}.ep-hero-actions{justify-content:flex-start}}
@media(max-width:800px){.engineering-portal-body .table{display:block;overflow-x:auto;white-space:nowrap}.engineering-portal-body .ep-main > h2,.engineering-portal-body .ep-main > p{padding-left:14px;padding-right:14px}.engineering-portal-body .table,.engineering-portal-body .alert{width:calc(100% - 28px)}}
@media(max-width:720px){.ep-dashboard{padding:18px 14px 28px}.ep-card-grid{grid-template-columns:1fr}.ep-dashboard-hero{padding:24px}.ep-dashboard-hero h1{font-size:28px}.ep-activity-item{grid-template-columns:1fr}.ep-primary-btn{width:100%}.ep-secondary-btn{width:100%;text-align:center}}


/* UAT Hotfix 15 - page polish, card alignment, premium empty states */
.ep-brand-text em{font-size:9px;letter-spacing:.16em;color:#f5d36a}
.ep-dashboard-card{min-height:220px;display:flex;flex-direction:column}
.ep-dashboard-card-head{display:flex;align-items:flex-start;justify-content:space-between;gap:14px;margin-bottom:10px}
.ep-dashboard-card .ep-dashboard-card-head h2{margin:0!important;line-height:1.25;min-height:50px;flex:1}
.ep-dashboard-card .ep-card-count{position:static;flex:0 0 auto;min-width:50px;text-align:center}
.ep-dashboard-card p{padding-right:0!important}
.ep-dashboard-card small{background:#f8fafc;border:1px solid #e2e8f0;border-left:4px solid #d7a928;border-radius:10px;padding:11px 12px;color:#475569;margin-top:auto;min-height:0}
.ep-profile-card a + a{margin-left:12px}
.ep-empty,.engineering-portal-body .alert-info{
    background:linear-gradient(135deg,#fffdf7,#f8fafc)!important;
    border:1px solid #ead07c!important;
    border-left:5px solid #d7a928!important;
    color:#334155!important;
}
.ep-page-shell{max-width:1232px;margin:28px auto 42px;padding:0 24px}
.ep-page-header{background:linear-gradient(135deg,#07111d,#102338);color:#fff;border-radius:18px;padding:28px;box-shadow:0 18px 50px rgba(15,23,42,.18);border:1px solid rgba(255,255,255,.08);margin-bottom:20px}
.ep-page-header h1{margin:0 0 8px;color:#fff;font-size:32px;font-weight:900}
.ep-page-header p{margin:0;color:#d5dee9;line-height:1.55}
.ep-panel{background:#fff;border:1px solid #e2e8f0;border-radius:16px;box-shadow:0 12px 34px rgba(15,23,42,.08);padding:24px;margin-bottom:20px}
.ep-panel h2,.ep-panel h3{margin-top:0;color:#07111d;font-weight:900}
.ep-detail-grid{display:grid;grid-template-columns:220px 1fr;gap:10px 18px}
.ep-detail-grid dt{font-weight:900;color:#334155}
.ep-detail-grid dd{margin:0;color:#0f172a}
.ep-action-row{display:flex;gap:10px;flex-wrap:wrap;margin-top:18px}
.ep-back-link,.engineering-portal-body .ep-back-link{
    display:inline-block;background:#07111d!important;color:#f5d36a!important;border-radius:9px;
    padding:10px 14px;text-decoration:none!important;font-weight:900;text-transform:uppercase;font-size:12px;letter-spacing:.04em
}
.ep-back-link:hover,.ep-back-link:focus{background:#102338!important;color:#fff!important}
.ep-form-card{background:#fff;border:1px solid #e2e8f0;border-radius:16px;box-shadow:0 12px 34px rgba(15,23,42,.08);padding:24px}
.ep-form-card .form-control{border-radius:9px;border:1px solid #cbd5e1;box-shadow:none;min-height:42px}
.ep-form-card textarea.form-control{min-height:120px}
.ep-form-card label{font-weight:900;color:#334155}
.ep-json-panel pre{max-height:420px;overflow:auto;background:#0b1220;color:#dbeafe;border:0;border-radius:12px;padding:16px}
.gbx-auth-required .gbx-auth-actions a{margin-right:8px}
@media(max-width:720px){.ep-detail-grid{grid-template-columns:1fr}.ep-page-shell{padding:0 14px}.ep-page-header{padding:22px}.ep-profile-card a + a{margin-left:0;display:block}}


/* LC Hotfix 16 - consistency fixes */
.ep-profile-card a{display:block;margin-top:12px}
.ep-profile-card a + a{margin-left:0}
.ep-dashboard-card small{display:block!important}
.ep-page-header{position:relative}
.ep-page-header .ep-header-actions{position:absolute;right:24px;top:24px}
.ep-panel .table{width:100%!important;margin:0!important;max-width:none!important;border-radius:0!important;border-left:0!important;border-right:0!important}
.ep-panel.table-flush{padding:0!important;overflow:hidden}
.ep-panel.table-flush .ep-panel-title{padding:20px 24px;margin:0!important}
.ep-panel-heading{font-size:22px;font-weight:900;color:#07111d;margin:0 0 14px}
.ep-back-link,.engineering-portal-body .ep-back-link,.ep-action-row .btn{line-height:1.3!important;display:inline-flex!important;align-items:center!important;justify-content:center!important;min-height:40px}
.ep-action-row .btn-warning{background:#07111d!important;border-color:#07111d!important;color:#f5d36a!important}
.ep-snapshot-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:14px}
.ep-snapshot-card{background:#f8fafc;border:1px solid #e2e8f0;border-radius:12px;padding:16px}
.ep-snapshot-card strong{display:block;color:#07111d;font-size:13px;text-transform:uppercase;letter-spacing:.06em;margin-bottom:6px}
.ep-snapshot-card span{font-size:18px;font-weight:900;color:#0f172a}
.ep-project-link-form{display:flex;gap:10px;flex-wrap:wrap;align-items:flex-end;margin-top:18px}
.ep-project-link-form select{min-width:260px}
@media(max-width:800px){.ep-page-header .ep-header-actions{position:static;margin-top:14px}.ep-snapshot-grid{grid-template-columns:1fr}.ep-project-link-form select{min-width:100%;width:100%}}

/* LC Hotfix 17 */
.ep-dashboard-card small{display:block!important;margin-top:12px}
.ep-card-grid{align-items:stretch}
.ep-dashboard-card{overflow:hidden}
.ep-dashboard-card p{word-break:normal;overflow-wrap:break-word}
.ep-profile-card a{display:block!important;margin-top:12px;text-align:center}
.ep-panel-split{display:flex;align-items:flex-start;justify-content:space-between;gap:20px;margin-bottom:18px}
.ep-panel-title{font-size:22px;font-weight:900;color:#07111d;padding:20px 24px;margin:0}
.ep-quote-ref{padding:16px 0 12px;margin:0 0 18px!important;border-bottom:1px solid #e2e8f0}
.engineering-portal-body .table td,.engineering-portal-body .table th{white-space:normal}
.engineering-portal-body .ep-panel.table-flush .table{border-radius:0!important}
@media(max-width:800px){.ep-panel-split{display:block}.ep-panel-split .ep-action-row{margin-top:14px!important}}


/* LC Hotfix 19 */
.ep-profile-card a{
    text-align:left!important;
    justify-content:flex-start!important;
    display:block!important;
    width:auto!important;
}
.ep-project-link-form select,
.ep-project-link-form select option,
.engineering-portal-body select.form-control,
.engineering-portal-body select.form-control option{
    color:#111827!important;
    background:#fff!important;
}
.ep-quote-ref{
    padding-left:18px!important;
}
.ep-model-assets{
    display:grid;
    grid-template-columns:repeat(3,minmax(0,1fr));
    gap:14px;
}
.ep-model-asset{
    background:#f8fafc;
    border:1px solid #e2e8f0;
    border-radius:12px;
    padding:16px;
    word-break:break-word;
}
.ep-model-asset strong{
    display:block;
    color:#07111d;
    margin-bottom:8px;
    text-transform:uppercase;
    font-size:12px;
    letter-spacing:.06em;
}
@media(max-width:900px){.ep-model-assets{grid-template-columns:1fr}}


/* LC Hotfix 21 */
#PortalCustomerProjectId,
#PortalCustomerProjectId option,
.ep-project-link-form select,
.ep-project-link-form select option,
.engineering-portal-body select.form-control,
.engineering-portal-body select.form-control option{
    color:#111827!important;
    background-color:#ffffff!important;
    -webkit-text-fill-color:#111827!important;
}
.ep-quote-ref{padding-left:20px!important;}
.ep-model-asset a{color:#9a730e!important;font-weight:900;text-decoration:none}

/* LC Hotfix 22 */
#PortalCustomerProjectId,
#PortalCustomerProjectId option,
#gbxPortalSaveModal select,
#gbxPortalSaveModal select option{
    color:#111827!important;
    background:#ffffff!important;
    -webkit-text-fill-color:#111827!important;
}
.ep-detail-grid a.ep-back-link{display:inline-flex!important;width:auto!important}

/* LC Hotfix 23 - force visible project dropdowns */
#PortalCustomerProjectId,
#PortalCustomerProjectId option,
#CustomerProjectId,
#CustomerProjectId option{
    color:#111827!important;
    background:#ffffff!important;
    background-color:#ffffff!important;
    -webkit-text-fill-color:#111827!important;
}

/* Bundle 1 hotfix 2 - saved calculation project dropdown */
.ep-project-link-form .ep-project-select-wrap{
    min-width:340px;
    max-width:520px;
    flex:1 1 340px;
}
.ep-project-link-form .ep-project-select{
    display:block!important;
    width:100%!important;
    min-width:340px!important;
    height:44px!important;
    min-height:44px!important;
    padding:9px 12px!important;
    border:1px solid #9ca3af!important;
    border-radius:0!important;
    color:#111827!important;
    background-color:#ffffff!important;
    -webkit-text-fill-color:#111827!important;
    box-shadow:none!important;
    line-height:24px!important;
    font-weight:600!important;
}
.ep-project-link-form .ep-project-select option{
    color:#111827!important;
    background-color:#ffffff!important;
    -webkit-text-fill-color:#111827!important;
}
.ep-project-link-form .help-block{
    display:block;
    margin:8px 0 0;
    color:#4b5563;
}
@media(max-width:800px){
    .ep-project-link-form .ep-project-select-wrap,
    .ep-project-link-form .ep-project-select{
        min-width:100%!important;
        width:100%!important;
    }
}

/* Runbook UI cleanup - dashboard link focus polish */
.ep-dashboard-card a:focus,
.ep-dashboard-card a:active,
.ep-profile-card a:focus,
.ep-profile-card a:active,
.ep-activity-item:focus,
.ep-activity-item:active,
.ep-primary-btn:focus,
.ep-primary-btn:active,
.ep-secondary-btn:focus,
.ep-secondary-btn:active{
    outline:none;
    box-shadow:none;
}
.ep-dashboard-card a:focus-visible,
.ep-profile-card a:focus-visible,
.ep-activity-item:focus-visible,
.ep-primary-btn:focus-visible,
.ep-secondary-btn:focus-visible{
    outline:2px solid #d7a928;
    outline-offset:3px;
    border-radius:8px;
}

/* Bundle 3.1 - make portal dashboard cards fully clickable without ugly focus borders */
.ep-dashboard-card-link{
    display:flex!important;
    flex-direction:column;
    color:inherit!important;
    text-decoration:none!important;
}
.ep-dashboard-card-link:hover{
    transform:translateY(-3px);
    box-shadow:0 16px 38px rgba(15,23,42,.12);
    border-color:#d7a928;
    color:inherit!important;
    text-decoration:none!important;
}
.ep-dashboard-card-link:focus,
.ep-dashboard-card-link:active{
    outline:none;
    color:inherit!important;
    text-decoration:none!important;
}
.ep-dashboard-card-link:focus-visible{
    outline:2px solid #d7a928;
    outline-offset:3px;
}
.ep-dashboard-card-cta{
    display:inline-block;
    margin-top:14px;
    color:#9a730e;
    font-weight:900;
    text-transform:uppercase;
    font-size:12px;
}


/* Bundle 3.2 - preserve original dashboard card visual style when whole card is clickable */
a.ep-dashboard-card-link,
a.ep-dashboard-card-link:link,
a.ep-dashboard-card-link:visited,
a.ep-dashboard-card-link:hover,
a.ep-dashboard-card-link:active,
a.ep-dashboard-card-link:focus{
    color:inherit!important;
    text-decoration:none!important;
}
a.ep-dashboard-card-link *,
a.ep-dashboard-card-link:hover *,
a.ep-dashboard-card-link:active *,
a.ep-dashboard-card-link:focus *{
    text-decoration:none!important;
}
a.ep-dashboard-card-link h2,
a.ep-dashboard-card-link:hover h2,
a.ep-dashboard-card-link:focus h2{
    color:#07111d!important;
}
a.ep-dashboard-card-link p,
a.ep-dashboard-card-link:hover p,
a.ep-dashboard-card-link:focus p{
    color:#475569!important;
}
a.ep-dashboard-card-link small,
a.ep-dashboard-card-link:hover small,
a.ep-dashboard-card-link:focus small{
    color:#475569!important;
}
a.ep-dashboard-card-link .ep-card-count,
a.ep-dashboard-card-link:hover .ep-card-count,
a.ep-dashboard-card-link:focus .ep-card-count{
    color:#f5d36a!important;
}
a.ep-dashboard-card-link .ep-dashboard-card-cta,
a.ep-dashboard-card-link:hover .ep-dashboard-card-cta,
a.ep-dashboard-card-link:focus .ep-dashboard-card-cta{
    color:#9a730e!important;
}
