/* WP CAD System - Global Star Citizen Style */

:root {
    --cad-bg: #0b111a;
    --cad-glass: rgba(16, 24, 39, 0.7);
    --cad-accent: #00d4ff;
    --cad-accent-dim: rgba(0, 212, 255, 0.2);
    --cad-text: #e2e8f0;
    --cad-text-dim: #94a3b8;
    --cad-alert: #ff3e3e;
    --cad-border: rgba(0, 212, 255, 0.3);
    --cad-font-main: 'Inter', sans-serif;
    --cad-font-header: 'Orbitron', sans-serif;
}

/* Base Wrapper */
.cad-system-wrapper {
    font-family: var(--cad-font-main);
    background: var(--cad-bg);
    color: var(--cad-text);
    padding: 20px;
    border-radius: 12px;
    border: 1px solid var(--cad-border);
    box-shadow: 0 0 50px rgba(0, 0, 0, 0.5);
    margin: 20px 0;
}

/* Panels / Boxes */
.cad-panel {
    background: var(--cad-glass);
    backdrop-filter: blur(10px);
    border: 1px solid var(--cad-border);
    border-radius: 8px;
    padding: 20px;
    margin-bottom: 20px;
    position: relative;
    overflow: hidden;
}

.cad-panel::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    width: 4px;
    height: 100%;
    background: var(--cad-accent);
    box-shadow: 0 0 10px var(--cad-accent);
}

.cad-panel h3,
.cad-panel h4 {
    margin-top: 0;
    font-family: var(--cad-font-header);
    color: var(--cad-accent);
    border-bottom: 1px solid var(--cad-border);
    padding-bottom: 10px;
    margin-bottom: 20px;
    text-transform: uppercase;
    letter-spacing: 1px;
}

/* Badges */
.cad-badge {
    background: var(--cad-accent-dim);
    color: var(--cad-accent);
    padding: 4px 10px;
    border-radius: 4px;
    font-size: 0.85em;
    display: inline-block;
    border: 1px solid var(--cad-border);
}

.cad-badge-alert {
    background: rgba(255, 62, 62, 0.1);
    color: var(--cad-alert);
    border-color: rgba(255, 62, 62, 0.3);
}

.cad-badge-success {
    background: rgba(0, 255, 127, 0.1);
    color: #00ff7f;
    border-color: rgba(0, 255, 127, 0.3);
}

/* Buttons */
.cad-btn {
    background: var(--cad-accent);
    color: var(--cad-bg);
    border: none;
    padding: 10px 20px;
    border-radius: 4px;
    font-family: var(--cad-font-header);
    font-weight: bold;
    cursor: pointer;
    transition: all 0.3s ease;
    text-transform: uppercase;
    font-size: 0.8em;
    display: inline-block;
    text-align: center;
    text-decoration: none;
}

.cad-btn:hover {
    background: white;
    box-shadow: 0 0 20px white;
    transform: translateY(-2px);
    color: var(--cad-bg);
}

.cad-btn-danger {
    background: var(--cad-alert);
}

/* Form Elements */
.cad-input,
.cad-select,
.cad-textarea {
    width: 100%;
    background: rgba(0, 0, 0, 0.5);
    border: 1px solid var(--cad-border);
    color: white;
    padding: 14px 10px;
    border-radius: 4px;
    outline: none;
    margin-bottom: 15px;
    cursor: pointer;
}

.cad-select option {
    padding: 10px;
}

.cad-input:focus,
.cad-select:focus,
.cad-textarea:focus {
    border-color: var(--cad-accent);
    box-shadow: 0 0 10px var(--cad-accent-dim);
}

.cad-select option {
    background-color: var(--cad-bg);
    color: var(--cad-text);
}

/* Animations */
@keyframes cad-pulse {
    0% {
        opacity: 0.6;
    }

    50% {
        opacity: 1;
    }

    100% {
        opacity: 0.6;
    }
}

.cad-pulse {
    animation: cad-pulse 2s infinite ease-in-out;
}

@keyframes cad-blink {
    50% {
        opacity: 0;
    }
}

.cad-blink {
    animation: cad-blink 1.5s linear infinite;
}

/* Grid / Utility */
.cad-grid-2 {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
}

.cad-flex-between {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

/* Tabs */
.cad-tab-btn {
    transition: all 0.3s ease;
}

.cad-tab-btn:hover {
    background: rgba(255, 255, 255, 0.05) !important;
    color: white !important;
}

.cad-tab-content {
    animation: fadeIn 0.3s ease-in-out;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(5px); }
    to { opacity: 1; transform: translateY(0); }
}

/* Prevent double-boxing for panels inside tabs */
.cad-tab-content .cad-panel {
    background: transparent;
    border: none;
    box-shadow: none;
    padding: 0;
    margin: 0;
}
.cad-tab-content .cad-panel::before {
    display: none;
}