/* Visual Content Enhancements - Premium CSS Diagrams */

/* --- ROOT VARIABLES --- */
:root {
    --visual-primary: #4F46E5;
    --visual-primary-light: #EEF2FF;
    --visual-accent: #10B981;
    --visual-accent-light: #D1FAE5;
    --visual-danger: #EF4444;
    --visual-danger-light: #FEE2E2;
    --visual-text: #1F2937;
    --visual-bg: #FFFFFF;
    --visual-border: #E5E7EB;
    --visual-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
}

/* --- COMMON CONTAINER --- */
.uk-visual-container {
    background: #F9FAFB;
    border-radius: 12px;
    padding: 32px;
    margin: 40px 0;
    border: 1px solid var(--visual-border);
    overflow: hidden;
    /* For floats/safety */
}

.uk-visual-title {
    text-align: center;
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--visual-text);
    margin-bottom: 32px;
    position: relative;
    display: inline-block;
    width: 100%;
}

.uk-visual-title::after {
    content: '';
    display: block;
    width: 60px;
    height: 4px;
    background: var(--visual-primary);
    margin: 12px auto 0;
    border-radius: 2px;
}

/* --- MIND MAP (CSS TREE) --- */
.uk-mindmap {
    display: flex;
    justify-content: center;
    align-items: center;
    flex-wrap: wrap;
    gap: 40px;
    position: relative;
}

.uk-mm-center {
    background: var(--visual-primary);
    color: white;
    padding: 24px;
    border-radius: 50%;
    width: 140px;
    height: 140px;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    font-weight: 800;
    font-size: 1.125rem;
    box-shadow: 0 10px 15px -3px rgba(79, 70, 229, 0.4);
    position: relative;
    z-index: 2;
    border: 4px solid white;
}

.uk-mm-branches {
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
    justify-content: center;
    max-width: 800px;
}

.uk-mm-node {
    background: white;
    border: 2px solid var(--visual-border);
    border-radius: 12px;
    padding: 20px;
    width: 220px;
    text-align: left;
    transition: transform 0.2s, box-shadow 0.2s;
    position: relative;
    box-shadow: var(--visual-shadow);
}

.uk-mm-node:hover {
    transform: translateY(-5px);
    box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1);
    border-color: var(--visual-primary);
}

.uk-mm-node h4 {
    font-size: 1rem;
    font-weight: 700;
    margin-top: 0;
    margin-bottom: 8px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.uk-mm-node p {
    font-size: 0.875rem;
    color: #6B7280;
    margin: 0;
    line-height: 1.4;
}

/* Status Colors */
.uk-mm-node.status-active {
    border-top: 4px solid var(--visual-accent);
}

.uk-mm-node.status-suspended {
    border-top: 4px solid #F59E0B;
}

.uk-mm-node.status-revoked {
    border-top: 4px solid var(--visual-danger);
}

.uk-mm-node.status-pending {
    border-top: 4px solid #6366F1;
}

/* Status Icons */
.uk-mm-node.status-active i {
    color: var(--visual-accent);
}

.uk-mm-node.status-suspended i {
    color: #F59E0B;
}

.uk-mm-node.status-revoked i {
    color: var(--visual-danger);
}

/* --- FUNNEL DIAGRAM --- */
.uk-funnel {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    max-width: 600px;
    margin: 0 auto;
}

.uk-funnel-step {
    background: white;
    width: 100%;
    padding: 20px 30px;
    text-align: center;
    position: relative;
    color: white;
    font-weight: 600;
    clip-path: polygon(0% 0%, 100% 0%, 90% 100%, 10% 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-direction: column;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
}

.uk-funnel-step:nth-child(1) {
    width: 100%;
    background: #4F46E5;
    z-index: 5;
    padding-bottom: 30px;
}

.uk-funnel-step:nth-child(2) {
    width: 90%;
    background: #6366F1;
    z-index: 4;
    padding-bottom: 30px;
    clip-path: polygon(0% 0%, 100% 0%, 88% 100%, 12% 100%);
}

.uk-funnel-step:nth-child(3) {
    width: 80%;
    background: #818CF8;
    z-index: 3;
    padding-bottom: 30px;
    clip-path: polygon(0% 0%, 100% 0%, 85% 100%, 15% 100%);
}

.uk-funnel-step:nth-child(4) {
    width: 70%;
    background: #10B981;
    z-index: 2;
    clip-path: none;
    border-radius: 0 0 12px 12px;
    padding: 25px;
}

.uk-funnel-label {
    font-size: 1.1rem;
    margin-bottom: 4px;
}

.uk-funnel-desc {
    font-size: 0.85rem;
    opacity: 0.9;
    font-weight: 400;
}

/* --- PROCESS FLOW (HORIZONTAL) --- */
.uk-process-flow {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
    counter-reset: process-counter;
}

.uk-process-card {
    background: white;
    padding: 24px;
    border-radius: 12px;
    border: 1px solid var(--visual-border);
    position: relative;
    box-shadow: var(--visual-shadow);
}

.uk-process-card::before {
    counter-increment: process-counter;
    content: counter(process-counter);
    position: absolute;
    top: -15px;
    left: 20px;
    width: 32px;
    height: 32px;
    background: var(--visual-primary);
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    box-shadow: 0 4px 6px -1px rgba(79, 70, 229, 0.3);
}

.uk-process-card h4 {
    margin-top: 10px;
    margin-bottom: 10px;
    color: var(--visual-primary);
    font-weight: 700;
}

/* --- GOV.UK STYLE CALLOUT --- */
.uk-gov-callout {
    border-left: 8px solid #0b0c0c;
    background: #f3f2f1;
    padding: 20px;
    margin: 30px 0;
}

.uk-gov-callout h4 {
    margin-top: 0;
    font-weight: 700;
}

.uk-gov-link {
    display: inline-block;
    margin-top: 10px;
    font-weight: 600;
    color: #1d70b8;
    text-decoration: underline;
}

.uk-gov-link:hover {
    color: #003078;
    background-color: inherit;
    text-decoration-thickness: 3px;
}