:root {
    --dc-indigo: var(--color-accent-blue);
    --dc-indigo-dark: var(--color-bg-tertiary);
    --dc-red: var(--color-accent-red);
    --dc-yellow: var(--color-accent-yellow);
    --dc-bg: var(--color-bg-primary);
    --dc-card-bg: var(--color-bg-secondary);
    --dc-border: var(--color-border);
    --dc-text: var(--color-text-primary);
    --dc-text-dim: var(--color-text-secondary);
    
    
    --dc-purple: #9c27b0;
    --dc-cyan: #00bcd4;
    --dc-green: #4caf50;
    --dc-orange: #ff9800;
    --dc-red-bright: #f44336;
    
    
    --accent-purple: var(--dc-purple);
    --accent-cyan: var(--dc-cyan);
    --success: var(--dc-green);
    --danger: var(--dc-red-bright);
    --text-muted: var(--dc-text-dim);
}

.dc-container {
    width: 100%;
    max-width: 1300px;
    margin: 0 auto 20px;
    padding: 0;
    font-family: 'Inter', sans-serif;
    color: var(--dc-text);
}

.dc-hero {
    text-align: left;
    margin-bottom: 30px;
}

.dc-title {
    font-size: 2.5rem;
    font-weight: 800;
    line-height: 1.1;
    margin: 20px 0 8px;
    background: linear-gradient(135deg, var(--dc-yellow), var(--dc-red), var(--dc-indigo));
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

.dc-tagline {
    font-size: 1.1rem;
    margin: 0;
    color: var(--dc-text-dim);
}

.dc-arena-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 30px;
}

.dc-card {
    background: var(--dc-card-bg);
    border: 1px solid var(--dc-border);
    border-radius: 12px;
    padding: 20px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.5);
    position: relative;
    display: flex;
    flex-direction: column;
    flex: 1;
}

.dc-side {
    display: flex;
    flex-direction: column;
}

.dc-label-box {
    padding: 10px 15px;
    background: var(--color-bg-tertiary);
    border: 1px solid var(--dc-border);
    border-radius: 8px;
    font-weight: 800;
    letter-spacing: 1.5px;
    font-size: 21px;
    margin-bottom: 20px;
    width: 100%;
    text-align: center;
    box-sizing: border-box;
    text-transform: uppercase;
    backdrop-filter: blur(5px);
}

.dc-attacker-label { color: var(--dc-red); border-color: rgba(229, 57, 53, 0.4); }
.dc-defender-label { color: var(--dc-indigo); border-color: rgba(92, 107, 192, 0.4); }

.dc-controls-row {
    display: flex;
    gap: 15px;
    align-items: center;
    margin-bottom: 25px;
    width: 100%;
    position: relative;
}

.dc-search-box {
    flex: 0 0 50%;
}

.dc-search-box input {
    width: 100%;
    background: var(--dc-bg);
    border: 1px solid var(--dc-border);
    border-radius: 8px;
    padding: 12px;
    color: var(--dc-text);
    font-size: 0.95rem;
    outline: none;
    transition: 0.2s;
}

.dc-search-box input::placeholder {
    color: var(--dc-text-dim);
    opacity: 0.6;
}


.dc-select-btn {
    width: 100%;
    background: var(--dc-bg);
    border: 1px solid var(--dc-border);
    border-radius: 8px;
    padding: 10px 12px;
    color: var(--dc-text);
    font-size: 0.9rem;
    font-weight: 600;
    display: flex;
    justify-content: space-between;
    align-items: center;
    cursor: pointer;
    transition: 0.2s;
    outline: none;
    min-height: 42px;
}

.dc-select-btn:hover {
    border-color: var(--dc-indigo);
    background: var(--color-surface-hover);
}

.dc-item-info {
    display: flex;
    align-items: center;
    gap: 10px;
}

.dc-btn-icon {
    width: 24px;
    height: 24px;
    object-fit: contain;
}

.dc-btn-icon.hidden { display: none; }

.dc-selection-filters {
    flex: 1;
    display: flex;
    gap: 10px;
    position: relative;
}

.dc-filter-btn {
    flex: 1;
    background: rgba(255,255,255,0.05);
    border: 1px solid var(--dc-border);
    color: var(--dc-text);
    padding: 12px 5px;
    border-radius: 8px;
    font-weight: 700;
    cursor: pointer;
    transition: 0.2s;
    font-size: 0.85rem;
    text-align: center;
}

.dc-filter-btn:hover { background: var(--dc-indigo); border-color: var(--dc-yellow); }


.dc-dropdown {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: var(--dc-card-bg);
    border: 1px solid var(--dc-indigo);
    border-radius: 10px;
    z-index: 50;
    margin-top: 5px;
    max-height: 250px;
    overflow-y: auto;
    box-shadow: 0 10px 40px rgba(0,0,0,0.8);
}

.dc-dropdown.hidden { display: none; }

.dc-drop-item {
    padding: 12px 20px;
    cursor: pointer;
    border-bottom: 1px solid rgba(255,255,255,0.05);
    font-weight: 600;
    text-transform: capitalize;
    color: var(--dc-text-dim);
}

.dc-drop-item:hover { background: var(--dc-indigo); color: white; }


.dc-poke-display {
    min-height: 350px;
    border: 2px dashed rgba(92, 107, 192, 0.15);
    border-radius: 12px;
    background: rgba(255,255,255,0.02);
    display: flex;
    align-items: center;
    justify-content: center;
}

.dc-display-empty { color: var(--dc-text-dim); font-style: italic; }

.dc-display-content {
    display: grid;
    grid-template-columns: 220px 1fr;
    width: 100%;
    padding: 30px;
    gap: 30px;
    box-sizing: border-box;
}

.dc-display-left {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 20px;
}

.dc-display-name {
    font-size: 1.6rem;
    font-weight: 900;
    text-transform: uppercase;
    color: var(--dc-yellow);
    letter-spacing: 1px;
    line-height: 1.2;
}

.dc-display-img {
    width: 160px;
    height: 160px;
    object-fit: contain;
    filter: drop-shadow(0 0 20px rgba(255,255,255,0.15));
}

.dc-types {
    display: flex;
    justify-content: center;
    gap: 8px;
    flex-wrap: wrap;
}

.dc-display-right {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.dc-stat-row {
    display: flex;
    align-items: center;
    gap: 15px;
}

.dc-stat-label {
    width: 100px;
    font-size: 0.75rem;
    font-weight: 800;
    color: var(--dc-text-dim);
    text-transform: uppercase;
}

.dc-stat-bar-container {
    flex: 1;
    height: 8px;
    background: rgba(255,255,255,0.05);
    border-radius: 10px;
    overflow: hidden;
}

.dc-stat-bar { height: 100%; border-radius: 10px; }

.dc-stat-val { width: 40px; text-align: right; font-weight: 900; font-size: 0.9rem; }

.dc-stat-total { margin-top: 10px; padding-top: 10px; border-top: 1px solid rgba(255,255,255,0.05); }


.dc-popup {
    position: fixed;
    top: 0; left: 0; right: 0; bottom: 0;
    background: rgba(0,0,0,0.9);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
    padding: 20px;
}

.dc-popup.hidden { display: none; }

.dc-popup-content {
    background: var(--dc-card-bg);
    border: 1px solid var(--dc-indigo);
    border-radius: 20px;
    width: 100%;
    max-width: 900px;
    max-height: 85vh;
    padding: 40px;
    overflow-y: auto;
    position: relative;
}

.dc-popup-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 20px; }


.dc-popup-search {
    width: 100%;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid var(--dc-border);
    border-radius: 12px;
    padding: 15px 20px;
    color: white;
    font-size: 1rem;
    font-weight: 600;
    margin-bottom: 30px;
    outline: none;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: inset 0 2px 4px rgba(0,0,0,0.2);
}

.dc-popup-search:focus {
    border-color: var(--dc-yellow);
    background: rgba(255, 255, 255, 0.07);
    box-shadow: 0 0 15px rgba(253, 216, 53, 0.15), inset 0 2px 4px rgba(0,0,0,0.2);
    transform: translateY(-1px);
}

.dc-popup-search::placeholder {
    color: var(--dc-text-dim);
    opacity: 0.5;
}

.dc-close { font-size: 2.5rem; cursor: pointer; color: var(--dc-text-dim); transition: 0.2s; }
.dc-close:hover { color: white; }

.dc-popup-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
    gap: 20px;
}

.dc-poke-option {
    background: rgba(255,255,255,0.02);
    border: 1px solid var(--dc-border);
    border-radius: 15px;
    padding: 20px;
    text-align: center;
    cursor: pointer;
    transition: 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.dc-poke-option:hover {
    background: var(--dc-indigo-dark);
    transform: translateY(-8px);
    border-color: var(--dc-yellow);
}

.dc-poke-option img { width: 100px; height: 100px; object-fit: contain; }

.dc-poke-option span {
    display: block;
    font-size: 0.85rem;
    font-weight: 800;
    margin-top: 12px;
    text-transform: uppercase;
    color: var(--dc-text);
}

.dc-type-badge {
    padding: 5px 12px;
    border-radius: 6px;
    font-size: 0.75rem;
    font-weight: 900;
    text-transform: uppercase;
    color: white;
}


.dc-type-grass { background: #78C850; box-shadow: 0 0 10px rgba(120, 200, 80, 0.3); }
.dc-type-fire { background: #F08030; box-shadow: 0 0 10px rgba(240, 128, 48, 0.3); }
.dc-type-water { background: #6890F0; box-shadow: 0 0 10px rgba(104, 144, 240, 0.3); }
.dc-type-electric { background: #F8D030; color: #000; }
.dc-type-ice { background: #98D8D8; color: #000; }
.dc-type-fighting { background: #C03028; }
.dc-type-poison { background: #A040A0; }
.dc-type-ground { background: #E0C068; color: #000; }
.dc-type-flying { background: #A890F0; }
.dc-type-psychic { background: #F85888; }
.dc-type-bug { background: #A8B820; }
.dc-type-rock { background: #B8A038; }
.dc-type-ghost { background: #705898; }
.dc-type-dragon { background: #7038F8; }
.dc-type-dark { background: #705848; }
.dc-type-steel { background: #B8B8D0; color: #000; }
.dc-type-fairy { background: #EE99AC; }
.dc-type-normal { background: #A8A878; color: #000; }


.dc-item-preview {
    margin-top: 10px;
    width: 50px;
    height: 50px;
    background: rgba(255,255,255,0.05);
    border: 1px solid rgba(255,255,255,0.1);
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: 0.3s;
    animation: fadeIn 0.3s ease-out;
}

@keyframes fadeIn {
    from { opacity: 0; transform: scale(0.9); }
    to { opacity: 1; transform: scale(1); }
}

.dc-item-preview img {
    max-width: 32px;
    max-height: 32px;
    filter: drop-shadow(0 0 5px rgba(255,255,255,0.2));
}

.dc-item-preview.hidden { display: none; }


@media (max-width: 1200px) {
    .dc-arena-grid { grid-template-columns: 1fr; }
    .dc-container { padding: 0 20px; }
}

@media (max-width: 768px) {
    .dc-display-content { grid-template-columns: 1fr; }
    .dc-controls-row { flex-direction: column; align-items: stretch; }
    .dc-search-box { flex: 1; }
    .dc-selection-filters { flex: 1; }
    .dc-title { font-size: 2rem; }
}


.dc-expansion-section {
    margin-top: 25px;
    padding-top: 25px;
    border-top: 1px solid rgba(255,255,255,0.1);
    animation: slideDown 0.4s ease-out;
}

@keyframes slideDown {
    from { opacity: 0; transform: translateY(-10px); }
    to { opacity: 1; transform: translateY(0); }
}

.dc-expansion-section.hidden { display: none; }

.dc-section-title {
    font-size: 0.85rem;
    font-weight: 900;
    color: var(--dc-yellow);
    text-transform: uppercase;
    letter-spacing: 1.5px;
    margin-bottom: 20px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.dc-section-title::after {
    content: '';
    flex: 1;
    height: 1px;
    background: linear-gradient(90deg, rgba(253, 216, 53, 0.3), transparent);
}

.dc-modifier-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 15px;
    margin-bottom: 25px;
}

.dc-input-group {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.dc-input-group label {
    font-size: 0.75rem;
    font-weight: 700;
    color: var(--dc-text-dim);
    text-transform: uppercase;
}

.dc-input-group input, 
.dc-input-group select {
    background: var(--dc-bg);
    border: 1px solid var(--dc-border);
    border-radius: 8px;
    padding: 10px;
    color: white;
    font-weight: 600;
    outline: none;
    transition: 0.2s;
    font-size: 0.9rem;
}

.dc-input-group select option,
.dc-tera-select option {
    background: #0b1120;
    color: #fff;
}

.dc-input-group input:focus, 
.dc-input-group select:focus {
    border-color: var(--dc-indigo);
    background: rgba(92, 107, 192, 0.1);
}

.dc-ev-section {
    background: rgba(0,0,0,0.2);
    border-radius: 12px;
    padding: 20px;
    margin-bottom: 25px;
}


.dc-tera-section {
    margin-top: 15px;
    padding: 12px;
    background: rgba(255,255,255,0.03);
    border: 1px dashed var(--dc-border);
    border-radius: 12px;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.dc-tera-select {
    width: 100%;
    background: var(--dc-bg);
    border: 1px solid var(--dc-border);
    border-radius: 8px;
    padding: 8px;
    color: var(--dc-text);
    font-weight: 700;
    text-transform: uppercase;
}


.dc-ev-section {
    margin-top: 20px;
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.dc-stat-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0 5px;
    font-size: 0.75rem;
    font-weight: 800;
    color: var(--dc-text-dim);
    text-transform: uppercase;
    letter-spacing: 1px;
}

.dc-stat-labels {
    display: flex;
    gap: 40px;
    margin-right: 5px;
}

.dc-ev-row {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.dc-ev-row label {
    font-size: 0.85rem;
    font-weight: 600;
    display: flex;
    justify-content: space-between;
}

.dc-stat-controls {
    display: flex;
    align-items: center;
    gap: 12px;
}

.dc-slider-wrapper {
    flex: 1;
    position: relative;
    height: 18px;
    display: flex;
    align-items: center;
}

.dc-slider-fill {
    position: absolute;
    left: 0;
    height: 6px;
    background: var(--dc-yellow);
    border-radius: 3px;
    pointer-events: none;
    z-index: 1;
    width: 0%;
    box-shadow: 0 0 10px rgba(253, 216, 53, 0.4);
    transition: width 0.1s ease;
}

[data-theme="light"] .dc-slider-fill {
    background: #f57c00;
    box-shadow: 0 0 10px rgba(245, 124, 0, 0.3);
}

.dc-iv-input {
    width: 45px;
    background: var(--dc-bg);
    border: 1px solid var(--dc-border);
    border-radius: 6px;
    padding: 4px;
    color: var(--dc-text);
    font-size: 0.85rem;
    font-weight: 700;
    text-align: center;
}

.dc-boost-select {
    width: 60px;
    background: var(--dc-bg);
    border: 1px solid var(--dc-border);
    border-radius: 6px;
    padding: 4px;
    color: var(--dc-text);
    font-size: 0.85rem;
    font-weight: 700;
}

.dc-spacer-boost {
    width: 60px;
}

input[type="range"] {
    position: relative;
    z-index: 2;
    -webkit-appearance: none;
    appearance: none;
    width: 100%;
    background: transparent;
    cursor: pointer;
}

input[type="range"]::-webkit-slider-runnable-track {
    width: 100%;
    height: 6px;
    background: rgba(255,255,255,0.1);
    border-radius: 3px;
}

input[type="range"]::-webkit-slider-thumb {
    -webkit-appearance: none;
    height: 18px;
    width: 18px;
    background: var(--dc-yellow);
    border-radius: 50%;
    cursor: pointer;
    margin-top: -6px;
    box-shadow: 0 0 10px rgba(253, 216, 53, 0.4);
    border: 2px solid var(--dc-bg);
}


.dc-health-metrics {
    background: rgba(0,0,0,0.2);
    border-radius: 12px;
    padding: 20px;
}

.dc-hp-display {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.dc-hp-bar-outer {
    width: 100%;
    height: 12px;
    background: rgba(255,255,255,0.05);
    border-radius: 6px;
    overflow: hidden;
    border: 1px solid rgba(255,255,255,0.1);
}

.dc-hp-bar-fill {
    height: 100%;
    background: linear-gradient(90deg, #4caf50, #81c784);
    transition: width 0.3s ease;
    box-shadow: 0 0 15px rgba(76, 175, 80, 0.3);
}

.dc-hp-text {
    text-align: center;
    font-size: 0.85rem;
    font-weight: 800;
    color: var(--dc-text);
    letter-spacing: 0.5px;
}

.dc-hp-text span { color: var(--dc-yellow); }


.dc-input-group select {
    padding-left: 10px;
}

.dc-move-selection {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin-bottom: 25px;
}

.dc-move-selection select {
    width: 100%;
    padding: 12px;
    background: var(--dc-bg);
    border: 1px solid var(--dc-border);
    border-radius: 8px;
    color: white;
    font-weight: 700;
    font-size: 0.95rem;
}

.dc-move-stats {
    display: flex;
    gap: 10px;
}

.dc-move-info-box {
    flex: 1;
    background: var(--color-bg-tertiary);
    border: 1px solid var(--dc-border);
    border-radius: 6px;
    padding: 8px;
    text-align: center;
    font-size: 0.75rem;
    font-weight: 800;
    color: var(--dc-text-dim);
}

.dc-move-info-box span { color: var(--dc-text); display: block; margin-top: 2px; font-size: 0.85rem; }

[data-theme="light"] .dc-move-info-box {
    background: #f1f3f9;
}

.dc-toggles {
    display: flex;
    gap: 20px;
    flex-wrap: wrap;
}

.dc-checkbox {
    display: flex;
    align-items: center;
    gap: 10px;
    cursor: pointer;
}

.dc-checkbox input {
    width: 18px;
    height: 18px;
    cursor: pointer;
    accent-color: var(--dc-yellow);
}

.dc-checkbox span {
    font-size: 0.85rem;
    font-weight: 700;
    color: var(--dc-text);
}


.dc-popup-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(100px, 1fr));
    gap: 15px;
    max-height: 500px;
    overflow-y: auto;
    padding: 10px;
}

.dc-item-option {
    background: var(--dc-bg);
    border: 1px solid var(--dc-border);
    border-radius: 8px;
    padding: 10px;
    text-align: center;
    cursor: pointer;
    transition: 0.2s;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 5px;
}

.dc-item-option:hover {
    border-color: var(--dc-yellow);
    background: var(--color-surface-hover);
    transform: translateY(-2px);
}

.dc-item-option img {
    width: 32px;
    height: 32px;
    object-fit: contain;
}

.dc-item-option span {
    font-size: 0.75rem;
    font-weight: 700;
    color: var(--dc-text);
    text-transform: capitalize;
}


[data-theme="light"] .dc-popup-content {
    background: var(--color-bg-secondary);
    color: var(--color-text-primary);
}

[data-theme="light"] .dc-popup-header {
    border-bottom: 1px solid var(--color-border);
}

[data-theme="light"] .dc-dropdown {
    background: var(--color-bg-secondary);
    border: 1px solid var(--color-border);
    box-shadow: var(--shadow-md);
}

[data-theme="light"] .dc-drop-item {
    color: var(--color-text-primary);
}

[data-theme="light"] .dc-drop-item:hover {
    background: var(--color-surface-hover);
}

[data-theme="light"] .dc-input-group select,
[data-theme="light"] .dc-move-selection select,
[data-theme="light"] .dc-boost-select,
[data-theme="light"] .dc-tera-select,
[data-theme="light"] .dc-select-btn,
[data-theme="light"] .dc-search-box input,
[data-theme="light"] input[type="number"],
[data-theme="light"] input[type="text"] {
    color: var(--color-text-primary) !important;
    background: #ffffff !important;
    border-color: var(--color-border) !important;
}

[data-theme="light"] .dc-filter-btn {
    background: #ffffff;
    border-color: var(--color-border);
    color: var(--color-text-secondary);
}

[data-theme="light"] .dc-filter-btn:hover {
    background: var(--color-bg-tertiary);
    border-color: var(--color-accent-blue);
    color: var(--color-text-primary);
}

[data-theme="light"] select option {
    background: white !important;
    color: var(--color-text-primary) !important;
}


select option {
    background: #1a1c23;
    color: white;
}


.dc-battlefield-box {
    margin-top: 0;
    background: var(--dc-card-bg);
    backdrop-filter: blur(15px);
    -webkit-backdrop-filter: blur(15px);
    border: 1px solid var(--dc-border);
    border-radius: 20px;
    padding: 25px;
    box-shadow: var(--dc-shadow);
    animation: slideDown 0.5s ease-out;
}

.dc-battlefield-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 25px;
}

.dc-battle-mod-group {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.dc-battle-mod-group label {
    font-size: 0.75rem;
    font-weight: 800;
    color: var(--dc-text-dim);
    text-transform: uppercase;
    letter-spacing: 1.5px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.dc-battle-mod-group label i {
    color: var(--dc-yellow);
    font-size: 0.9rem;
}

.dc-field-select {
    width: 100%;
    background: var(--dc-bg);
    border: 1px solid var(--dc-border);
    border-radius: 12px;
    padding: 12px;
    color: var(--dc-text);
    font-weight: 700;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    -webkit-appearance: none;
    appearance: none;
}

.dc-field-select:hover {
    border-color: rgba(253, 216, 53, 0.5);
    background: rgba(255,255,255,0.05);
}

.dc-field-select:focus {
    border-color: var(--dc-yellow);
    outline: none;
    box-shadow: 0 0 15px rgba(253, 216, 53, 0.2);
}

.dc-checkbox-group {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    padding: 12px;
    background: rgba(255,255,255,0.03);
    border-radius: 12px;
    border: 1px solid rgba(255,255,255,0.05);
}


[data-theme="light"] .dc-battlefield-box {
    background: white;
    border-color: var(--color-border);
}

[data-theme="light"] .dc-field-select {
    background: white;
    color: var(--color-text-primary);
    border-color: var(--color-border);
}

[data-theme="light"] .dc-field-select option {
    background: white;
    color: var(--color-text-primary);
}

[data-theme="light"] .dc-checkbox-group {
    background: var(--color-bg-tertiary);
    border-color: var(--color-border);
}


@media (max-width: 1200px) {
    .dc-battlefield-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 600px) {
    .dc-battlefield-grid {
        grid-template-columns: 1fr;
    }
}


.dc-result-hud {
    position: relative;
    margin-top: 0;
    background: linear-gradient(135deg, rgba(20, 20, 30, 0.95), rgba(40, 40, 60, 0.95));
    border: 2px solid rgba(255, 255, 255, 0.1);
    border-radius: 24px;
    padding: 30px;
    box-shadow: 0 0 40px rgba(0, 0, 0, 0.5), inset 0 0 20px rgba(255, 255, 255, 0.05);
    overflow: hidden;
    animation: slideUpHUD 0.6s cubic-bezier(0.2, 0.8, 0.2, 1);
}

.dc-hud-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: repeating-linear-gradient(0deg, rgba(255,255,255,0.03) 0px, transparent 1px, transparent 2px);
    pointer-events: none;
}

@keyframes slideUpHUD {
    from { transform: translateY(50px); opacity: 0; }
    to { transform: translateY(0); opacity: 1; }
}


.dc-result-summary {
    font-size: 1.1rem;
    font-weight: 800;
    text-align: center;
    color: var(--dc-text);
    margin-bottom: 25px;
    letter-spacing: 0.5px;
    text-shadow: 0 0 10px rgba(255, 255, 255, 0.2);
}

.dc-result-summary .vs-label {
    color: var(--dc-yellow);
    margin: 0 10px;
}


.dc-result-main {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 30px;
    margin-bottom: 30px;
    position: relative;
    z-index: 1;
}

.dc-damage-percent {
    font-size: 3.5rem;
    font-weight: 900;
    color: #00f3ff; 
    text-shadow: 0 0 20px rgba(0, 243, 255, 0.4);
    line-height: 1;
}

.dc-damage-hp {
    font-size: 1.2rem;
    font-weight: 700;
    color: var(--dc-text-dim);
    margin-top: 5px;
}


.dc-badge {
    padding: 12px 24px;
    border-radius: 12px;
    font-weight: 900;
    text-transform: uppercase;
    font-size: 0.9rem;
    letter-spacing: 1px;
    background: rgba(255,255,255,0.1);
    border: 1px solid rgba(255,255,255,0.2);
    margin-bottom: 10px;
    text-align: center;
}

.dc-badge.lethal {
    background: rgba(255, 50, 50, 0.2);
    border-color: #ff3232;
    color: #ff3232;
    box-shadow: 0 0 15px rgba(255, 50, 50, 0.3);
    animation: badgeAlert 1s infinite alternate;
}

.dc-badge.safe {
    background: rgba(76, 175, 80, 0.2);
    border-color: #4caf50;
    color: #4caf50;
}

@keyframes badgeAlert {
    from { opacity: 1; transform: scale(1); }
    to { opacity: 0.8; transform: scale(1.05); }
}

.dc-ko-detail {
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--dc-text-dim);
    text-align: center;
}


.dc-result-hp-bar {
    position: relative;
    margin-top: 20px;
}

.dc-hp-bar-track {
    height: 14px;
    background: rgba(0, 0, 0, 0.3);
    border-radius: 7px;
    position: relative;
    overflow: hidden;
    border: 1px solid rgba(255,255,255,0.1);
}

.dc-hp-fill-animated {
    height: 100%;
    background: linear-gradient(90deg, #4caf50, #81c784);
    transition: width 1s cubic-bezier(0.4, 0, 0.2, 1), background-color 0.5s ease;
    border-radius: 7px;
    position: absolute;
    left: 0;
    top: 0;
    z-index: 2;
}

.dc-hp-damage-ghost {
    height: 100%;
    background: rgba(255, 255, 255, 0.2);
    position: absolute;
    left: 0;
    top: 0;
    z-index: 1;
    transition: width 0.5s ease;
}

.dc-hp-markers {
    display: flex;
    justify-content: space-between;
    margin-top: 8px;
}

.dc-hp-markers span {
    font-size: 0.65rem;
    font-weight: 800;
    color: var(--dc-text-dim);
}


[data-theme="light"] .dc-result-hud {
    background: white;
    border-color: var(--color-border);
    box-shadow: var(--shadow-md);
}

[data-theme="light"] .dc-damage-percent {
    color: #f57c00;
}

[data-theme="light"] .dc-display-name {
    color: #f57c00;
}

[data-theme="light"] .dc-section-title {
    color: #f57c00;
}

[data-theme="light"] .dc-hp-text span {
    color: #f57c00;
}

[data-theme="light"] .dc-main-percent {
    background: linear-gradient(180deg, #f57c00 0%, #ff9800 100%);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    filter: drop-shadow(0 0 10px rgba(245, 124, 0, 0.15));
}


[data-theme="light"] .dc-result-hud-v2 {
    background: linear-gradient(180deg, #ffffff 0%, #f0f2ff 100%);
    border-color: #d0d5f5;
    box-shadow: 0 15px 40px rgba(92, 107, 192, 0.15), inset 0 0 20px rgba(92, 107, 192, 0.05);
}

[data-theme="light"] .dc-vs-poke-box {
    background: #f8f9fa;
    border-color: #e0e4f5;
    box-shadow: 0 5px 15px rgba(0,0,0,0.05);
}

[data-theme="light"] .dc-stat-pill {
    background: #ffffff;
    border-color: var(--color-border);
    color: var(--color-text-secondary);
}

[data-theme="light"] .dc-stat-pill span {
    color: var(--color-text-primary);
}

[data-theme="light"] .dc-hp-bar-v2 {
    background: #e0e4f5;
    border-color: #d0d5f5;
}

[data-theme="light"] .dc-sub-hp {
    color: var(--color-text-secondary);
}

[data-theme="light"] .dc-vs-badge {
    box-shadow: 0 0 15px rgba(125, 137, 221, 0.2);
    background: var(--color-accent-blue);
}


@media (max-width: 800px) {
    .dc-result-main {
        flex-direction: column;
        text-align: center;
        gap: 20px;
    }
    .dc-damage-percent {
        font-size: 2.5rem;
    }
}


.dc-result-hud-v2 {
    background: linear-gradient(180deg, rgba(15, 17, 23, 0.95) 0%, rgba(10, 11, 15, 1) 100%);
    border: 1px solid rgba(92, 107, 192, 0.3);
    border-radius: 20px;
    padding: 30px;
    margin-top: 0;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.8), inset 0 0 20px rgba(92, 107, 192, 0.1);
    position: relative;
    overflow: hidden;
    backdrop-filter: blur(10px);
}

.dc-result-hud-v2::before {
    content: '';
    position: absolute;
    top: 0; left: 0; right: 0; height: 1px;
    background: linear-gradient(90deg, transparent, var(--dc-indigo), transparent);
}


.dc-vs-arena {
    display: grid;
    grid-template-columns: 1fr 120px 1fr;
    align-items: center;
    gap: 20px;
    margin-bottom: 30px;
}

.dc-vs-side {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 15px;
}

.dc-vs-poke-box {
    width: 100px;
    height: 100px;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 15px;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 10px 20px rgba(0,0,0,0.3);
    transition: transform 0.3s ease;
}

.dc-vs-poke-box:hover {
    transform: scale(1.05);
}

.dc-vs-poke-box img {
    width: 80px;
    height: 80px;
    object-fit: contain;
    filter: drop-shadow(0 0 10px rgba(255,255,255,0.2));
}

.dc-vs-stats-row {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
    justify-content: center;
}

.dc-stat-pill {
    background: rgba(255, 255, 255, 0.05);
    backdrop-filter: blur(5px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    padding: 4px 10px;
    border-radius: 6px;
    font-size: 0.7rem;
    font-weight: 800;
    color: var(--dc-text-dim);
    letter-spacing: 0.5px;
    text-transform: uppercase;
}

.dc-stat-pill span {
    color: white;
}


.dc-vs-divider {
    display: flex;
    justify-content: center;
    align-items: center;
    position: relative;
}

.dc-vs-badge {
    width: 60px;
    height: 60px;
    background: var(--dc-indigo);
    border: 2px solid var(--dc-yellow);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 900;
    font-size: 1.2rem;
    color: white;
    text-shadow: 0 0 10px rgba(0,0,0,0.5);
    box-shadow: 0 0 20px rgba(92, 107, 192, 0.5), 0 0 40px rgba(253, 216, 53, 0.2);
    z-index: 2;
}


.dc-result-main-v2 {
    text-align: center;
    margin-bottom: 25px;
}

.dc-main-percent {
    font-size: 3.5rem;
    font-weight: 900;
    line-height: 1;
    margin-bottom: 5px;
    background: linear-gradient(180deg, #fff 0%, #aaa 100%);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    filter: drop-shadow(0 0 15px rgba(255,255,255,0.3));
    letter-spacing: -1px;
}

.dc-sub-hp {
    font-size: 1.1rem;
    color: var(--dc-text-dim);
    margin-bottom: 20px;
    font-weight: 600;
}

.dc-verdict-container {
    display: flex;
    justify-content: center;
}

.dc-verdict-badge {
    padding: 8px 25px;
    border-radius: 50px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 1px;
    font-size: 0.9rem;
    box-shadow: 0 5px 15px rgba(0,0,0,0.3);
    transition: all 0.3s ease;
}


.verdict-ohko { background: var(--dc-red); color: white; box-shadow: 0 0 20px rgba(244, 67, 54, 0.4); }
.verdict-2hko { background: var(--dc-yellow); color: black; box-shadow: 0 0 20px rgba(255, 202, 40, 0.4); }
.verdict-safe { background: #4caf50; color: white; box-shadow: 0 0 20px rgba(76, 175, 80, 0.4); }


.dc-hp-bar-v2 {
    width: 100%;
    height: 10px;
    background: rgba(255,255,255,0.05);
    border-radius: 50px;
    overflow: hidden;
    border: 1px solid rgba(255,255,255,0.05);
}

.dc-bar-track {
    width: 100%;
    height: 100%;
    position: relative;
}

.dc-bar-fill-v2 {
    height: 100%;
    width: 100%;
    background: linear-gradient(90deg, #4caf50 0%, #81c784 100%);
    transition: width 0.8s cubic-bezier(0.4, 0, 0.2, 1), background 0.5s ease;
    box-shadow: 0 0 15px rgba(76, 175, 80, 0.3);
}


@keyframes pulseGlow {
    0% { filter: brightness(1); }
    50% { filter: brightness(1.3); }
    100% { filter: brightness(1); }
}

.updating {
    animation: pulseGlow 0.3s ease-in-out;
}


.glass-panel {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    padding: 15px;
    margin-top: 20px;
    backdrop-filter: blur(5px);
}

[data-theme="light"] .glass-panel {
    background: rgba(92, 107, 192, 0.05);
    border-color: rgba(92, 107, 192, 0.1);
}

#ai-coach-suggestions li {
    font-size: 0.85rem;
    margin-bottom: 8px;
    line-height: 1.4;
    color: var(--dc-text);
}

#ai-coach-suggestions li:last-child {
    margin-bottom: 0;
}

@media (max-width: 768px) {
    .dc-container { margin-left: 5px; margin-right: 5px; }
    .dc-vs-arena {
        grid-template-columns: 1fr;
        gap: 30px;
    }
    .dc-vs-divider {
        display: none;
    }
    .dc-main-percent {
        font-size: 2.5rem;
    }
}


#ai-coach-box {
    margin-top: 15px;
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid rgba(156, 39, 176, 0.2);
    border-left: 4px solid var(--accent-purple) !important;
    border-radius: 10px;
    padding: 12px;
    font-size: 13px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
    transition: all 0.3s ease;
    animation: fadeInCoach 0.5s ease-out;
}

#ai-coach-box.hidden, .hidden {
    display: none !important;
}

#ai-coach-suggestions li {
    margin-bottom: 8px;
    line-height: 1.5;
    position: relative;
    padding-left: 5px;
}

#ai-coach-suggestions li:last-child {
    margin-bottom: 0;
}

@keyframes fadeInCoach {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

[data-theme="light"] #ai-coach-box {
    background: rgba(156, 39, 176, 0.05);
    border-color: rgba(156, 39, 176, 0.1);
}


.dc-guide-box {
    margin-top: 3rem;
    background: var(--dc-card-bg);
    border: 1px solid var(--dc-border);
    border-radius: 16px;
    overflow: hidden;
    margin-bottom: 3rem;
}
.dc-guide-box details { width: 100%; }
.dc-guide-box details summary {
    padding: 1.25rem 1.5rem;
    font-weight: 800;
    font-size: 1.1rem;
    color: var(--dc-text);
    cursor: pointer;
    list-style: none;
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: rgba(255,255,255,0.02);
    transition: background .2s;
}
.dc-guide-box details summary::-webkit-details-marker { display: none; }
.dc-guide-box details summary:hover { background: rgba(255,255,255,0.05); }
.dc-guide-box details summary::after {
    content: "▼";
    font-size: 0.8rem;
    transition: transform 0.3s ease;
}
.dc-guide-box details[open] summary::after { transform: rotate(180deg); }
.dc-guide-box details[open] summary { border-bottom: 1px solid var(--dc-border); }

.dc-guide-content {
    padding: 2rem;
    line-height: 1.8;
    color: var(--dc-text-dim);
    font-size: 1rem;
}
.dc-guide-content h2 { color: var(--dc-text); margin: 2.5rem 0 1rem; font-size: 1.5rem; font-weight: 800; }
.dc-guide-content h3 { color: var(--dc-yellow); margin: 2rem 0 1rem; font-size: 1.25rem; font-weight: 800; }
.dc-guide-content h2:first-child, .dc-guide-content h3:first-child { margin-top: 0; }
.dc-guide-content p { margin-bottom: 1.5rem; }
.dc-guide-content p:last-child { margin-bottom: 0; }
.dc-guide-content ul { margin: 0 0 1.5rem 1.5rem; padding: 0; }
.dc-guide-content li { margin-bottom: 0.75rem; list-style-type: disc; }
.dc-guide-content li strong { color: var(--dc-text); }

[data-theme="light"] .dc-guide-box {
    background: white;
}
[data-theme="light"] .dc-guide-box details summary {
    background: #f8f9fa;
    color: var(--color-text-primary);
}
[data-theme="light"] .dc-guide-content {
    color: var(--color-text-secondary);
}
[data-theme="light"] .dc-guide-content h2,
[data-theme="light"] .dc-guide-content li strong {
    color: var(--color-text-primary);
}
