* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Inter', 'Nunito Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    background: linear-gradient(135deg, #F8FBFF 0%, #E8F4FD 25%, #DDF4FF 50%, #C3E4FD 75%, #B3D9FF 100%);
    min-height: 100vh;
    padding: 20px;
    position: relative;
    overflow-x: hidden;
    color: #2C3E50;
    line-height: 1.6;
}

body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><defs><pattern id="grid" width="20" height="20" patternUnits="userSpaceOnUse"><path d="M 20 0 L 0 0 0 20" fill="none" stroke="rgba(74,144,226,0.08)" stroke-width="0.5"/></pattern></defs><rect width="100" height="100" fill="url(%23grid)"/></svg>');
    pointer-events: none;
    z-index: 0;
}

/* Floating Shapes Animation */
.floating-shapes {
    position: fixed;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 1;
}

.shape {
    position: absolute;
    border-radius: 50%;
    background: linear-gradient(45deg, rgba(173, 216, 230, 0.4), rgba(135, 206, 235, 0.3));
    animation: float 8s ease-in-out infinite;
    backdrop-filter: blur(2px);
}

.shape:nth-child(1) {
    width: 120px;
    height: 120px;
    top: 10%;
    left: 10%;
    animation-delay: 0s;
}

.shape:nth-child(2) {
    width: 80px;
    height: 80px;
    top: 15%;
    right: 15%;
    animation-delay: 2s;
}

.shape:nth-child(3) {
    width: 100px;
    height: 100px;
    bottom: 20%;
    left: 20%;
    animation-delay: 4s;
}

.shape:nth-child(4) {
    width: 60px;
    height: 60px;
    bottom: 15%;
    right: 25%;
    animation-delay: 1s;
}

@keyframes float {
    0%, 100% { transform: translateY(0px) rotate(0deg); opacity: 0.6; }
    50% { transform: translateY(-30px) rotate(180deg); opacity: 1; }
}

/* Container */
.container {
    max-width: 900px;
    margin: 0 auto;
    position: relative;
    z-index: 2;
}

/* Header */
.header {
    text-align: center;
    margin-bottom: 40px;
    animation: slideDown 0.8s ease-out;
}

.logo-container {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 20px;
    margin-bottom: 20px;
}

.logo-icon {
    animation: logoFloat 3s ease-in-out infinite;
}

@keyframes logoFloat {
    0%, 100% { transform: translateY(0px); }
    50% { transform: translateY(-5px); }
}

.logo-text {
    text-align: left;
}

.logo {
    font-family: 'Inter', sans-serif;
    font-size: 3.5rem;
    font-weight: 700;
    background: linear-gradient(45deg, #4A90E2, #87CEEB, #ADD8E6);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: 5px;
    text-shadow: 0 0 30px rgba(74, 144, 226, 0.3);
    letter-spacing: -0.02em;
}

.subtitle {
    color: #5A6C7D;
    font-size: 1.1rem;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 1px;
}

/* Form Container */
.form-container {
    background: rgba(255, 255, 255, 0.9);
    backdrop-filter: blur(20px);
    border-radius: 24px;
    padding: 40px;
    border: 1px solid rgba(173, 216, 230, 0.5);
    box-shadow: 
        0 20px 40px rgba(74, 144, 226, 0.08),
        0 10px 25px rgba(135, 206, 235, 0.06),
        inset 0 1px 0 rgba(255, 255, 255, 0.8);
    animation: slideUp 0.8s ease-out;
    position: relative;
    z-index: 10;
}

/* Animations */
@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

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

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateX(-20px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Messages */
.success-message {
    display: none;
    background: rgba(144, 238, 144, 0.15);
    border: 1px solid rgba(144, 238, 144, 0.4);
    color: #28A745;
    padding: 20px;
    border-radius: 16px;
    margin-bottom: 25px;
    text-align: center;
    font-weight: 500;
    font-size: 1.1rem;
    box-shadow: 0 4px 12px rgba(144, 238, 144, 0.1);
}

.error-message {
    display: none;
    background: rgba(255, 182, 193, 0.15);
    border: 1px solid rgba(255, 182, 193, 0.4);
    color: #DC3545;
    padding: 20px;
    border-radius: 16px;
    margin-bottom: 25px;
    text-align: center;
    font-weight: 500;
    font-size: 1.1rem;
    box-shadow: 0 4px 12px rgba(255, 182, 193, 0.1);
}

/* Loading Indicator */
.loading-indicator {
    text-align: center;
    padding: 30px;
    color: #5A6C7D;
    margin-bottom: 20px;
    background: rgba(173, 216, 230, 0.08);
    border-radius: 20px;
    border: 1px solid rgba(173, 216, 230, 0.2);
    box-shadow: 0 4px 12px rgba(74, 144, 226, 0.05);
}

.spinner {
    width: 40px;
    height: 40px;
    border: 4px solid rgba(173, 216, 230, 0.3);
    border-top: 4px solid #87CEEB;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin: 0 auto 15px;
}

/* Init Error */
.init-error {
    background: rgba(255, 182, 193, 0.1);
    border: 1px solid rgba(255, 182, 193, 0.3);
    color: #DC3545;
    padding: 25px;
    border-radius: 20px;
    margin-bottom: 20px;
    text-align: center;
    box-shadow: 0 4px 12px rgba(255, 182, 193, 0.08);
}

.init-error h3 {
    margin-bottom: 10px;
    color: #DC3545;
    font-size: 1.2rem;
    font-weight: 600;
}

.init-error button {
    margin-top: 15px;
    padding: 12px 24px;
    background: linear-gradient(135deg, #FF6B6B, #FF8E8E);
    color: white;
    border: none;
    border-radius: 12px;
    cursor: pointer;
    font-family: 'Inter', sans-serif;
    font-weight: 500;
    transition: all 0.3s ease;
    box-shadow: 0 4px 12px rgba(255, 107, 107, 0.3);
}

.init-error button:hover {
    background: linear-gradient(135deg, #FF5252, #FF7979);
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(255, 107, 107, 0.4);
}

/* Form Sections */
.form-section {
    margin-bottom: 35px;
    padding-bottom: 30px;
    border-bottom: 1px solid rgba(173, 216, 230, 0.2);
    position: relative;
}

.form-section:last-of-type {
    border-bottom: none;
    margin-bottom: 0;
}

.section-title {
    color: #4A90E2;
    font-size: 1.3rem;
    font-weight: 600;
    margin-bottom: 20px;
    padding-bottom: 10px;
    border-bottom: 2px solid rgba(173, 216, 230, 0.3);
    display: flex;
    align-items: center;
    gap: 10px;
}

.section-title::before {
    content: '';
    width: 4px;
    height: 20px;
    background: linear-gradient(45deg, #87CEEB, #ADD8E6);
    border-radius: 2px;
}

/* Form Groups */
.form-group {
    margin-bottom: 25px;
    animation: fadeIn 0.6s ease-out forwards;
    opacity: 0;
    position: relative;
}

.form-group:nth-child(1) { animation-delay: 0.1s; }
.form-group:nth-child(2) { animation-delay: 0.2s; }
.form-group:nth-child(3) { animation-delay: 0.3s; }
.form-group:nth-child(4) { animation-delay: 0.4s; }
.form-group:nth-child(5) { animation-delay: 0.5s; }
.form-group:nth-child(6) { animation-delay: 0.6s; }
.form-group:nth-child(7) { animation-delay: 0.7s; }

label {
    display: block;
    color: #34495E;
    font-weight: 600;
    margin-bottom: 8px;
    font-size: 1rem;
}

.help-text {
    color: #7B8794;
    font-size: 0.9rem;
    margin-top: 5px;
    display: block;
}

/* Form Controls */
input, select, textarea {
    width: 100%;
    padding: 16px 20px;
    border: 2px solid rgba(173, 216, 230, 0.3);
    border-radius: 16px;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    color: #2C3E50;
    font-size: 1rem;
    font-family: 'Inter', sans-serif;
    transition: all 0.3s ease;
    box-shadow: 0 2px 8px rgba(74, 144, 226, 0.05);
}

input::placeholder, textarea::placeholder {
    color: #A0AEC0;
}

input:focus, select:focus, textarea:focus {
    outline: none;
    border-color: #87CEEB;
    background: rgba(255, 255, 255, 1);
    box-shadow: 
        0 0 0 3px rgba(135, 206, 235, 0.15),
        0 4px 12px rgba(74, 144, 226, 0.1);
    transform: translateY(-2px);
}

select {
    cursor: pointer;
}

select option {
    background: white;
    color: #2C3E50;
    padding: 12px;
}

select:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    background: #F7FAFC;
}

textarea {
    min-height: 120px;
    resize: vertical;
    line-height: 1.6;
}

/* E-Bus Select Dropdown with Search Styles */
.ebus-search-container {
    position: relative;
    display: block;
    width: 100%;
    z-index: 1000;
}

.ebus-select-wrapper {
    position: relative;
    width: 100%;
}

.searchable-select-container {
    position: relative;
    width: 100%;
}

.searchable-select-input {
    width: 100%;
    padding: 16px 50px 16px 20px;
    border: 2px solid rgba(173, 216, 230, 0.3);
    border-radius: 16px;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    color: #2C3E50;
    font-size: 1rem;
    font-family: 'Inter', sans-serif;
    transition: all 0.3s ease;
    cursor: pointer;
    z-index: 1000;
    position: relative;
    box-shadow: 0 2px 8px rgba(74, 144, 226, 0.05);
}

.searchable-select-input:focus {
    outline: none;
    border-color: #87CEEB;
    background: rgba(255, 255, 255, 1);
    box-shadow: 
        0 0 0 3px rgba(135, 206, 235, 0.15),
        0 4px 12px rgba(74, 144, 226, 0.1);
    transform: translateY(-2px);
    z-index: 1000;
}

.searchable-select-input::placeholder {
    color: #A0AEC0;
    font-style: italic;
}

.hidden-select {
    display: none;
}

.select-arrow {
    position: absolute;
    right: 20px;
    top: 50%;
    transform: translateY(-50%);
    color: #7B8794;
    font-size: 0.8rem;
    pointer-events: none;
    transition: transform 0.2s ease;
}

.searchable-select-container.open .select-arrow {
    transform: translateY(-50%) rotate(180deg);
}

.searchable-dropdown {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: rgba(255, 255, 255, 0.98);
    backdrop-filter: blur(20px);
    border: 2px solid #87CEEB;
    border-top: none;
    border-radius: 0 0 16px 16px;
    box-shadow: 
        0 10px 25px rgba(74, 144, 226, 0.1),
        0 8px 15px rgba(135, 206, 235, 0.08);
    z-index: 1000;
    max-height: 350px;
    overflow: hidden;
    margin-top: -2px;
    animation: slideDown 0.2s ease-out;
}

.dropdown-search {
    padding: 12px 15px;
    border-bottom: 1px solid rgba(173, 216, 230, 0.2);
    background: rgba(173, 216, 230, 0.05);
    z-index: 1000;
}

.dropdown-search-input {
    width: 100%;
    padding: 10px 15px;
    border: 1px solid rgba(173, 216, 230, 0.3);
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.9);
    color: #2C3E50;
    font-size: 0.95rem;
    font-family: 'Inter', sans-serif;
    transition: all 0.2s ease;
}

.dropdown-search-input:focus {
    outline: none;
    border-color: #87CEEB;
    background: rgba(255, 255, 255, 1);
    box-shadow: 0 0 0 2px rgba(135, 206, 235, 0.15);
}

.dropdown-search-input::placeholder {
    color: #A0AEC0;
    font-style: italic;
}

.dropdown-options {
    max-height: 280px;
    overflow-y: auto;
}

.dropdown-option {
    padding: 12px 20px;
    cursor: pointer;
    border-bottom: 1px solid rgba(173, 216, 230, 0.1);
    transition: all 0.2s ease;
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.dropdown-option:last-child {
    border-bottom: none;
    border-radius: 0 0 14px 14px;
}

.dropdown-option:hover,
.dropdown-option.active {
    background: rgba(173, 216, 230, 0.15);
    color: #4A90E2;
    transform: translateX(3px);
}

.dropdown-option.loading {
    background: rgba(173, 216, 230, 0.08);
    color: #7B8794;
    cursor: default;
    font-style: italic;
    text-align: center;
    padding: 16px 20px;
}

.dropdown-option.loading:hover {
    background: rgba(173, 216, 230, 0.08);
    transform: none;
}

.dropdown-option.no-results {
    background: rgba(255, 182, 193, 0.08);
    color: #DC3545;
    cursor: default;
    font-style: italic;
    text-align: center;
    padding: 16px 20px;
}

.dropdown-option.no-results:hover {
    background: rgba(255, 182, 193, 0.08);
    transform: none;
}

.option-name {
    font-weight: 600;
    color: #2C3E50;
    font-size: 1rem;
    line-height: 1.2;
}

.option-type {
    font-size: 0.85rem;
    color: #7B8794;
    font-weight: 400;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.dropdown-option:hover .option-name,
.dropdown-option.active .option-name {
    color: #4A90E2;
}

/* Device Details Styles */
.device-details-container {
    background: rgba(173, 216, 230, 0.05);
    border: 1px solid rgba(173, 216, 230, 0.2);
    border-radius: 20px;
    padding: 20px;
    margin-top: 10px;
    box-shadow: 0 4px 12px rgba(74, 144, 226, 0.05);
}

.device-section {
    margin-bottom: 20px;
}

.device-section:last-child {
    margin-bottom: 0;
}

.device-section-title {
    color: #4A90E2;
    font-size: 1rem;
    font-weight: 600;
    margin-bottom: 12px;
    display: flex;
    align-items: center;
    gap: 8px;
    padding-bottom: 8px;
    border-bottom: 1px solid rgba(173, 216, 230, 0.2);
}

.device-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 15px;
    margin-top: 10px;
}

.device-field {
    display: flex;
    flex-direction: column;
}

.device-field label {
    font-size: 0.9rem;
    font-weight: 500;
    color: #4A5568;
    margin-bottom: 5px;
}

.device-field input,
.device-field select {
    padding: 12px 16px;
    border: 1px solid rgba(173, 216, 230, 0.3);
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.9);
    font-size: 0.95rem;
    transition: all 0.2s ease;
    box-shadow: 0 2px 6px rgba(74, 144, 226, 0.03);
}

.device-field input:focus,
.device-field select:focus {
    outline: none;
    border-color: #87CEEB;
    background: rgba(255, 255, 255, 1);
    box-shadow: 0 0 0 2px rgba(135, 206, 235, 0.15);
}

.device-field input::placeholder {
    color: #A0AEC0;
    font-style: italic;
}

/* Animation for showing/hiding device details */
#deviceDetailsSection {
    overflow: hidden;
    transition: all 0.3s ease;
    max-height: 0;
    opacity: 0;
    margin-bottom: 0;
}

#deviceDetailsSection.show {
    max-height: 500px;
    opacity: 1;
    margin-bottom: 25px;
}

#holderInfoSection {
    margin-top: 15px;
    padding-top: 15px;
    border-top: 1px dashed rgba(173, 216, 230, 0.3);
}

/* File Upload Styles */
.file-upload {
    position: relative;
    display: block;
    width: 100%;
}

.file-input {
    opacity: 0;
    position: absolute;
    z-index: -1;
}

.file-label {
    display: block;
    width: 100%;
    cursor: pointer;
    transition: all 0.3s ease;
}

.file-upload-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 30px 20px;
    border: 2px dashed rgba(173, 216, 230, 0.4);
    border-radius: 20px;
    background: linear-gradient(135deg, rgba(173, 216, 230, 0.03), rgba(135, 206, 235, 0.06));
    text-align: center;
    color: #5A6C7D;
    transition: all 0.3s ease;
    box-shadow: 0 4px 12px rgba(74, 144, 226, 0.03);
}

.file-upload-content:hover {
    border-color: #87CEEB;
    background: linear-gradient(135deg, rgba(173, 216, 230, 0.06), rgba(135, 206, 235, 0.1));
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(74, 144, 226, 0.05);
}

.file-upload.drag-over .file-upload-content {
    border-color: #90EE90;
    background: linear-gradient(135deg, rgba(144, 238, 144, 0.06), rgba(152, 251, 152, 0.1));
    transform: translateY(-2px);
}

.file-icon {
    font-size: 2rem;
    margin-bottom: 10px;
    opacity: 0.8;
}

.file-text {
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.file-text strong {
    color: #4A90E2;
    font-size: 1.1rem;
    font-weight: 600;
}

.file-types {
    font-size: 0.85rem;
    color: #7B8794;
    margin-top: 5px;
}

/* File List Styles */
.file-list {
    margin-top: 15px;
}

.file-item {
    background: rgba(173, 216, 230, 0.06);
    border: 1px solid rgba(173, 216, 230, 0.2);
    border-radius: 16px;
    padding: 15px;
    margin-bottom: 10px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    transition: all 0.2s ease;
    box-shadow: 0 2px 8px rgba(74, 144, 226, 0.03);
}

.file-item:hover {
    background: rgba(173, 216, 230, 0.1);
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(74, 144, 226, 0.05);
}

.file-item.valid {
    border-color: rgba(144, 238, 144, 0.3);
    background: rgba(144, 238, 144, 0.05);
}

.file-item.error {
    border-color: rgba(255, 182, 193, 0.3);
    background: rgba(255, 182, 193, 0.05);
}

.file-icon-display {
    font-size: 1.5rem;
    margin-right: 12px;
}

.file-info {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.file-name {
    font-weight: 600;
    color: #2C3E50;
    font-size: 0.95rem;
}

.file-meta {
    display: flex;
    gap: 12px;
}

.file-size {
    color: #7B8794;
    font-size: 0.85rem;
}

.file-type {
    color: #7B8794;
    font-size: 0.85rem;
}

.file-actions {
    display: flex;
    align-items: center;
    gap: 8px;
}

.file-status.valid {
    color: #28A745;
    font-size: 1.2rem;
}

.file-status.error {
    color: #DC3545;
    font-size: 1.2rem;
}

.remove-file {
    background: linear-gradient(135deg, #FF6B6B, #FF8E8E);
    color: white;
    border: none;
    border-radius: 10px;
    padding: 8px 12px;
    cursor: pointer;
    font-size: 0.85rem;
    font-weight: 500;
    transition: all 0.2s ease;
    box-shadow: 0 2px 6px rgba(255, 107, 107, 0.2);
}

.remove-file:hover {
    background: linear-gradient(135deg, #FF5252, #FF7979);
    transform: translateY(-1px);
    box-shadow: 0 4px 10px rgba(255, 107, 107, 0.3);
}

.file-errors {
    margin-top: 6px;
}

.error-message {
    color: #DC3545;
    font-size: 0.8rem;
    margin-bottom: 2px;
}

.files-warning {
    background: rgba(255, 182, 193, 0.1);
    border: 1px solid rgba(255, 182, 193, 0.3);
    border-radius: 12px;
    padding: 12px;
    margin-bottom: 15px;
}

.warning-content {
    display: flex;
    align-items: center;
    gap: 8px;
    color: #DC3545;
    font-size: 0.9rem;
    font-weight: 500;
}

.warning-icon {
    font-size: 1.1rem;
}

.files-summary {
    background: rgba(173, 216, 230, 0.08);
    border: 1px solid rgba(173, 216, 230, 0.2);
    border-radius: 16px;
    padding: 16px;
    margin-top: 15px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.summary-info {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.summary-row {
    display: flex;
    justify-content: space-between;
    min-width: 200px;
}

.summary-label {
    color: #5A6C7D;
    font-size: 0.9rem;
}

.summary-value {
    color: #2C3E50;
    font-weight: 600;
    font-size: 0.9rem;
}

.summary-actions {
    margin-left: 20px;
}

.clear-files-btn {
    background: linear-gradient(135deg, #FFA726, #FFB74D);
    color: white;
    border: none;
    border-radius: 10px;
    padding: 8px 16px;
    cursor: pointer;
    font-size: 0.85rem;
    font-weight: 500;
    transition: all 0.2s ease;
    box-shadow: 0 2px 6px rgba(255, 167, 38, 0.2);
}

.clear-files-btn:hover {
    background: linear-gradient(135deg, #FF9800, #FFA726);
    transform: translateY(-1px);
    box-shadow: 0 4px 10px rgba(255, 167, 38, 0.3);
}

.no-files {
    color: #A0AEC0;
    font-style: italic;
    text-align: center;
    padding: 20px;
    background: rgba(173, 216, 230, 0.03);
    border-radius: 16px;
    border: 1px dashed rgba(173, 216, 230, 0.2);
}

/* Submit Button */
.submit-btn {
    width: 100%;
    padding: 20px;
    background: linear-gradient(135deg, #87CEEB, #4A90E2);
    border: none;
    border-radius: 20px;
    color: white;
    font-size: 1.2rem;
    font-weight: 600;
    font-family: 'Inter', sans-serif;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 8px 20px rgba(74, 144, 226, 0.3);
    margin-top: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
}

.submit-btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 12px 28px rgba(74, 144, 226, 0.4);
    background: linear-gradient(135deg, #ADD8E6, #4682B4);
}

.submit-btn:active {
    transform: translateY(-1px);
}

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

.btn-icon {
    font-size: 1.1rem;
}

/* Debug Panel Styles */
#debugPanel {
    position: fixed;
    top: 20px;
    right: 20px;
    width: 400px;
    max-height: 80vh;
    background: rgba(44, 62, 80, 0.95);
    color: white;
    border-radius: 20px;
    padding: 25px;
    font-family: 'Courier New', monospace;
    font-size: 0.85rem;
    overflow-y: auto;
    z-index: 10000;
    border: 1px solid rgba(173, 216, 230, 0.2);
    box-shadow: 
        0 20px 40px rgba(0, 0, 0, 0.1),
        0 10px 20px rgba(0, 0, 0, 0.05);
    animation: slideUp 0.8s ease-out;
}

#debugPanel h4 {
    margin-bottom: 15px;
    color: #87CEEB;
    font-family: 'Inter', sans-serif;
    font-size: 1.1rem;
}

#debugOutput {
    max-height: 300px;
    overflow-y: auto;
    padding: 15px;
    background: rgba(255, 255, 255, 0.08);
    border-radius: 12px;
    margin-bottom: 15px;
    border: 1px solid rgba(173, 216, 230, 0.2);
}

.debug-btn {
    margin-top: 10px;
    margin-right: 10px;
    padding: 8px 16px;
    background: linear-gradient(135deg, #87CEEB, #4A90E2);
    color: white;
    border: none;
    border-radius: 10px;
    cursor: pointer;
    font-family: 'Inter', sans-serif;
    font-size: 0.9rem;
    font-weight: 500;
    transition: all 0.2s ease;
    box-shadow: 0 2px 6px rgba(74, 144, 226, 0.2);
}

.debug-btn:hover {
    background: linear-gradient(135deg, #ADD8E6, #4682B4);
    transform: translateY(-1px);
    box-shadow: 0 4px 10px rgba(74, 144, 226, 0.3);
}

.debug-btn-danger {
    background: linear-gradient(135deg, #FF6B6B, #FF8E8E);
}

.debug-btn-danger:hover {
    background: linear-gradient(135deg, #FF5252, #FF7979);
}

.debug-toggle {
    position: fixed;
    bottom: 20px;
    right: 20px;
    width: 60px;
    height: 60px;
    border-radius: 50%;
    background: linear-gradient(135deg, #87CEEB, #4A90E2);
    color: white;
    border: none;
    font-size: 1.4rem;
    cursor: pointer;
    z-index: 9999;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(74, 144, 226, 0.3);
}

.debug-toggle:hover {
    background: linear-gradient(135deg, #ADD8E6, #4682B4);
    transform: scale(1.1);
    box-shadow: 0 6px 20px rgba(74, 144, 226, 0.4);
}

/* Responsive Design */
@media (max-width: 768px) {
    .container {
        padding: 0 15px;
    }
    
    .form-container {
        padding: 30px 20px;
    }
    
    .logo-container {
        flex-direction: column;
        gap: 15px;
    }
    
    .logo-text {
        text-align: center;
    }
    
    .logo {
        font-size: 2.8rem;
    }
    
    .subtitle {
        font-size: 1rem;
    }
    
    .section-title {
        font-size: 1.2rem;
    }
    
    #debugPanel {
        width: 90%;
        right: 5%;
        left: 5%;
    }
    
    .debug-toggle {
        bottom: 15px;
        right: 15px;
        width: 50px;
        height: 50px;
        font-size: 1.2rem;
    }
    
    /* E-Bus Select Responsive */
    .searchable-dropdown {
        max-height: 300px;
    }
    
    .dropdown-options {
        max-height: 230px;
    }
    
    .dropdown-option {
        padding: 10px 16px;
    }
    
    /* Device Details Responsive */
    .device-row {
        grid-template-columns: 1fr;
        gap: 12px;
    }
    
    .device-details-container {
        padding: 15px;
    }
    
    .device-section-title {
        font-size: 0.9rem;
    }
    
    .files-summary {
        flex-direction: column;
        gap: 12px;
        align-items: stretch;
    }
    
    .summary-actions {
        margin-left: 0;
    }
}

@media (max-width: 480px) {
    body {
        padding: 15px;
    }
    
    .form-container {
        padding: 25px 15px;
        border-radius: 20px;
    }
    
    .logo {
        font-size: 2.2rem;
    }
    
    .section-title {
        font-size: 1.1rem;
    }
    
    input, select, textarea {
        padding: 14px 16px;
        font-size: 0.95rem;
        border-radius: 14px;
    }
    
    /* E-Bus Select Mobile Styles */
    .searchable-select-input {
        padding: 14px 45px 14px 16px;
        font-size: 0.95rem;
        border-radius: 14px;
    }
    
    .select-arrow {
        right: 16px;
        font-size: 0.7rem;
    }
    
    .searchable-dropdown {
        max-height: 250px;
        border-radius: 0 0 14px 14px;
    }
    
    .dropdown-options {
        max-height: 180px;
    }
    
    .dropdown-option {
        padding: 8px 14px;
    }
    
    .option-name {
        font-size: 0.9rem;
    }
    
    .option-type {
        font-size: 0.75rem;
    }
    
    .submit-btn {
        font-size: 1.1rem;
        padding: 18px;
        border-radius: 18px;
    }
    
    /* Device Details Mobile */
    .device-field input,
    .device-field select {
        padding: 10px 12px;
        font-size: 0.9rem;
        border-radius: 10px;
    }
    
    .device-section-title {
        font-size: 0.85rem;
    }
    
    .device-details-container {
        border-radius: 16px;
    }
    
    .file-upload-content {
        padding: 25px 15px;
        border-radius: 16px;
    }
    
    .file-item {
        border-radius: 12px;
        padding: 12px;
    }
    
    .file-icon-display {
        font-size: 1.3rem;
        margin-right: 10px;
    }
    
    .remove-file {
        padding: 6px 10px;
        border-radius: 8px;
        font-size: 0.8rem;
    }
    
    .files-summary {
        border-radius: 12px;
        padding: 12px;
    }
    
    .clear-files-btn {
        padding: 6px 12px;
        border-radius: 8px;
        font-size: 0.8rem;
    }
}