.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.7rem;
    padding: 0.7rem 1.8rem;
    font-size: 0.9rem;
    font-weight: 600;
    text-transform: uppercase;
    border: none;
    border-radius: 50px;
    cursor: pointer;
    transition: var(--transition);
    letter-spacing: 1px;
    line-height: 1.5;
    position: relative;
    overflow: hidden;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.15);
}

.btn i {
    line-height: 1;
}

.btn:disabled {
    cursor: not-allowed;
    opacity: 0.6;
}

.btn-primary {
    background: var(--gradient);
    color: var(--primary) !important;
    box-shadow: 0 6px 20px rgba(0, 224, 255, 0.25);
}

.btn-primary:hover:not(:disabled) {
    background: linear-gradient(135deg, var(--accent-dark), var(--accent));
    box-shadow: 0 8px 25px rgba(0, 224, 255, 0.35);
    transform: translateY(-3px);
}

.btn-secondary {
    background: var(--glass);
    color: var(--text-primary);
    border: 1px solid var(--glass-border);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
}

.btn-secondary:hover:not(:disabled) {
    background: rgba(255, 255, 255, 0.1);
    border-color: rgba(255, 255, 255, 0.15);
    transform: translateY(-3px);
    color: var(--text-primary);
}

.light-theme .btn-secondary:hover:not(:disabled) {
    background: rgba(0, 0, 0, 0.05);
    border-color: rgba(0, 0, 0, 0.1);
}

.btn-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: transparent;
    border: none;
    color: var(--text-secondary);
    font-size: 1.25rem;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    cursor: pointer;
    transition: var(--transition);
}

.btn-icon:hover {
    color: var(--accent);
    background-color: var(--glass);
}

.main-content {
    padding: 0 2rem 4rem;
}

.section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2rem;
}

.section-title {
    font-family: 'Orbitron', sans-serif;
    font-size: clamp(1.6rem, 4vw, 2rem);
    font-weight: 600;
    position: relative;
    padding-bottom: 0.7rem;
}

.section-title::after {
    content: '';
    position: absolute;
    left: 0;
    bottom: 0;
    height: 4px;
    width: 70px;
    background: var(--gradient);
    border-radius: 3px;
}

.section-subtitle {
    font-family: 'Orbitron', sans-serif;
    font-size: 1.7rem;
    font-weight: 600;
    padding-bottom: 0.8rem;
    margin-bottom: 2rem;
    border-bottom: 1px solid var(--glass-border);
    position: relative;
    color: var(--text-primary);
}

.filters {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
    margin-bottom: 2rem;
}

.filter-select {
    appearance: none;
    -webkit-appearance: none;
    -moz-appearance: none;
    padding: 0.7rem 2.8rem 0.7rem 1.4rem;
    font-size: 0.9rem;
    color: var(--text-primary);
    background-color: var(--secondary);
    background-image: url("data:image/svg+xml;charset=UTF-8,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='%23f0f0f5'%3e%3cpath fill-rule='evenodd' d='M1.646 4.646a.5.5 0 0 1 .708 0L8 10.293l5.646-5.647a.5.5 0 0 1 .708.708l-6 6a.5.5 0 0 1-.708 0l-6-6a.5.5 0 0 1 0-.708z'/%3e%3c/svg%3e");
    background-repeat: no-repeat;
    background-position: right 1rem center;
    background-size: 1rem;
    border: 1px solid var(--glass-border);
    border-radius: 50px;
    cursor: pointer;
    transition: var(--transition);
}

.light-theme .filter-select {
     background-image: url("data:image/svg+xml;charset=UTF-8,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='%231f2937'%3e%3cpath fill-rule='evenodd' d='M1.646 4.646a.5.5 0 0 1 .708 0L8 10.293l5.646-5.647a.5.5 0 0 1 .708.708l-6 6a.5.5 0 0 1-.708 0l-6-6a.5.5 0 0 1 0-.708z'/%3e%3c/svg%3e");
}

.filter-select option {
    background: var(--primary);
    color: var(--text-primary);
    border: none;
}

.filter-select:focus {
    outline: none;
    border-color: var(--accent);
    box-shadow: 0 0 0 3px rgba(0, 224, 255, 0.2);
}

.spinner {
    display: none;
    width: 45px;
    height: 45px;
    border: 5px solid rgba(240, 240, 245, 0.2);
    border-top: 5px solid var(--accent);
    border-radius: 50%;
    animation: spin 1s linear infinite;
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    z-index: 1050;
}

.light-theme .spinner {
    border: 5px solid rgba(0, 0, 0, 0.1);
    border-top: 5px solid var(--accent-dark);
}

#consoleOutput {
    border: 1px solid var(--glass-border);
    padding: 15px;
    margin: 20px 0;
    height: 250px;
    overflow-y: scroll;
    background-color: rgba(10, 10, 15, 0.9);
    color: var(--text-secondary);
    font-family: monospace;
    font-size: 0.85rem;
    border-radius: var(--border-radius-md);
    display: none;
    box-shadow: inset 0 0 10px rgba(0, 0, 0, 0.2);
}

.light-theme #consoleOutput {
    background-color: var(--primary);
}

#consoleOutput .console-log-entry {
    margin-bottom: 6px;
    line-height: 1.4;
    word-break: break-word;
    white-space: pre-wrap;
}

#consoleOutput .log-time {
    color: var(--accent);
    margin-right: 8px;
    font-weight: 500;
}

#consoleOutput .log-message {
    color: var(--text-secondary);
}

#consoleOutput .log-error .log-message {
    color: var(--danger);
}

#consoleOutput .log-warning .log-message {
    color: var(--warning);
}

#consoleOutput .log-success .log-message {
    color: var(--success);
}

.form-control {
    background-color: var(--glass);
    border: 1px solid var(--glass-border);
    color: var(--text-primary);
    border-radius: var(--border-radius-sm);
    padding: .6rem 1rem;
}
.form-control:focus {
    background-color: var(--glass);
    color: var(--text-primary);
    border-color: var(--accent);
    box-shadow: 0 0 0 3px rgba(0,224,255,.2);
}
.form-control::placeholder {
    color: var(--text-secondary);
}
.form-label {
    color: var(--text-primary);
    font-weight: 500;
}

.toggle-switch {
    position: relative;
    display: inline-block;
    width: 50px;
    height: 28px;
}
.toggle-switch input {
    opacity: 0;
    width: 0;
    height: 0;
}
.toggle-switch label {
    position: absolute;
    cursor: pointer;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: var(--glass-border);
    transition: .4s;
    border-radius: 28px;
}
.toggle-switch label:before {
    position: absolute;
    content: "";
    height: 20px;
    width: 20px;
    left: 4px;
    bottom: 4px;
    background-color: white;
    transition: .4s;
    border-radius: 50%;
}
.toggle-switch input:checked + label {
    background: var(--gradient);
}
.toggle-switch input:checked + label:before {
    transform: translateX(22px);
}

@media (max-width: 768px) {
    .section-title {
        font-size: 1.5rem;
    }
}