/* ConfigVault - Matching Dashboard Theme */

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

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    background: linear-gradient(135deg, #1e293b 0%, #334155 50%, #1e293b 100%);
    min-height: 100vh;
    color: #e2e8f0;
    line-height: 1.6;
    padding: 20px;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
}

/* Header */
header {
    text-align: center;
    margin-bottom: 32px;
    background: rgba(30, 41, 59, 0.7);
    backdrop-filter: blur(10px);
    border-radius: 12px;
    padding: 30px 20px;
    border: 1px solid rgba(59, 130, 246, 0.3);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.2);
}

h1 {
    font-size: 2.2em;
    color: #60a5fa;
    margin-bottom: 10px;
    font-weight: 600;
    letter-spacing: -0.025em;
}

.subtitle {
    color: #94a3b8;
    font-size: 1.1em;
    font-weight: 400;
}

h2 {
    color: #60a5fa;
    margin-bottom: 20px;
    font-size: 1.4em;
    font-weight: 600;
    padding-bottom: 8px;
    border-bottom: 1px solid rgba(52, 211, 153, 0.3);
}

h3 {
    color: #60a5fa;
    margin-bottom: 15px;
    font-size: 1.2em;
    font-weight: 600;
}

/* Cards */
.card {
    background: rgba(30, 41, 59, 0.7);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(59, 130, 246, 0.3);
    border-radius: 12px;
    padding: 28px;
    margin-bottom: 28px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.2);
    position: relative;
    overflow: hidden;
}

.card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, #3b82f6, #34d399);
    opacity: 0.7;
}

.info-card {
    background: rgba(30, 41, 59, 0.5);
    border-color: rgba(52, 211, 153, 0.3);
}

/* Apps Grid */
.apps-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
    gap: 16px;
    margin-top: 16px;
}

.app-item {
    background: rgba(51, 65, 85, 0.6);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(59, 130, 246, 0.2);
    border-radius: 8px;
    padding: 18px;
    text-align: center;
    cursor: pointer;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.app-item::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, #3b82f6, #34d399);
    opacity: 0;
    transition: opacity 0.3s ease;
}

.app-item:hover {
    background: rgba(59, 130, 246, 0.15);
    border-color: rgba(52, 211, 153, 0.4);
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.3);
}

.app-item:hover::before {
    opacity: 1;
}

.app-item.selected {
    border-color: #34d399;
    background: rgba(52, 211, 153, 0.1);
}

.app-item.selected::before {
    opacity: 1;
}

.app-emoji {
    font-size: 2.2em;
    margin-bottom: 8px;
}

.app-name {
    font-size: 0.95em;
    color: #f1f5f9;
    font-weight: 500;
}

.app-keys {
    font-size: 0.8em;
    color: #94a3b8;
    margin-top: 6px;
}

/* Form Elements */
.form-group {
    margin-bottom: 24px;
}

label {
    display: block;
    margin-bottom: 10px;
    color: #cbd5e1;
    font-weight: 500;
    font-size: 0.95em;
}

.input {
    width: 100%;
    padding: 14px 16px;
    background: rgba(51, 65, 85, 0.6);
    border: 1px solid rgba(59, 130, 246, 0.3);
    border-radius: 8px;
    color: #e2e8f0;
    font-size: 1em;
    font-family: inherit;
    transition: all 0.3s ease;
}

.input:focus {
    outline: none;
    border-color: #34d399;
    background: rgba(51, 65, 85, 0.8);
    box-shadow: 0 0 0 3px rgba(52, 211, 153, 0.1);
}

select.input {
    cursor: pointer;
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%2394a3b8' d='M6 9L1 4h10z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 12px center;
    padding-right: 36px;
}

input[type="file"] {
    padding: 12px;
    cursor: pointer;
}

input[type="file"]::file-selector-button {
    background: linear-gradient(135deg, #3b82f6, #34d399);
    color: #000;
    border: none;
    padding: 8px 16px;
    border-radius: 6px;
    font-weight: 600;
    cursor: pointer;
    margin-right: 12px;
    transition: all 0.3s ease;
}

input[type="file"]::file-selector-button:hover {
    background: linear-gradient(135deg, #34d399, #3b82f6);
}

input[type="checkbox"] {
    width: auto;
    margin-right: 10px;
    cursor: pointer;
    accent-color: #34d399;
}

small {
    display: block;
    color: #94a3b8;
    font-size: 0.85em;
    margin-top: 6px;
}

/* Buttons */
.btn {
    padding: 14px 32px;
    border: none;
    border-radius: 8px;
    font-size: 1em;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    text-transform: none;
    letter-spacing: 0.3px;
    font-family: inherit;
}

.btn-primary {
    background: linear-gradient(135deg, #3b82f6, #34d399);
    color: #000;
    box-shadow: 0 4px 12px rgba(59, 130, 246, 0.3);
}

.btn-primary:hover {
    background: linear-gradient(135deg, #34d399, #3b82f6);
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(52, 211, 153, 0.4);
}

.btn-primary:active {
    transform: translateY(0);
}

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

/* Status Messages */
.status {
    margin-top: 18px;
    padding: 14px 18px;
    border-radius: 8px;
    font-size: 0.95em;
    display: none;
    border: 1px solid transparent;
}

.status.show {
    display: block;
}

.status.success {
    background: rgba(52, 211, 153, 0.1);
    border-color: #34d399;
    color: #34d399;
}

.status.error {
    background: rgba(239, 68, 68, 0.1);
    border-color: #ef4444;
    color: #fca5a5;
}

.status.info {
    background: rgba(59, 130, 246, 0.1);
    border-color: #3b82f6;
    color: #60a5fa;
}

/* Info Messages */
.info {
    color: #94a3b8;
    font-style: italic;
}

/* Lists */
ul {
    list-style: none;
    padding-left: 0;
}

ul li {
    padding: 10px 0;
    padding-left: 28px;
    position: relative;
    color: #cbd5e1;
    line-height: 1.6;
}

ul li:before {
    content: "▸";
    position: absolute;
    left: 0;
    color: #34d399;
    font-weight: bold;
}

ul li strong {
    color: #60a5fa;
}

code {
    background: rgba(51, 65, 85, 0.8);
    padding: 3px 8px;
    border-radius: 4px;
    color: #34d399;
    font-family: 'Courier New', 'Consolas', monospace;
    font-size: 0.9em;
    border: 1px solid rgba(52, 211, 153, 0.2);
}

/* Footer */
footer {
    text-align: center;
    padding: 24px;
    color: #94a3b8;
    font-size: 0.9em;
    margin-top: 40px;
    background: rgba(30, 41, 59, 0.5);
    backdrop-filter: blur(10px);
    border-radius: 12px;
    border: 1px solid rgba(59, 130, 246, 0.2);
}

footer p {
    margin: 0;
}

/* Scrollbar */
::-webkit-scrollbar {
    width: 10px;
}

::-webkit-scrollbar-track {
    background: rgba(51, 65, 85, 0.3);
    border-radius: 5px;
}

::-webkit-scrollbar-thumb {
    background: rgba(52, 211, 153, 0.4);
    border-radius: 5px;
}

::-webkit-scrollbar-thumb:hover {
    background: rgba(52, 211, 153, 0.6);
}

/* Responsive */
@media (max-width: 768px) {
    body {
        padding: 16px;
    }

    .container {
        max-width: 100%;
    }

    header {
        padding: 24px 16px;
        margin-bottom: 24px;
    }

    h1 {
        font-size: 1.8em;
    }

    .subtitle {
        font-size: 1em;
    }

    .card {
        padding: 20px;
        margin-bottom: 20px;
    }

    h2 {
        font-size: 1.2em;
    }

    .apps-grid {
        grid-template-columns: repeat(auto-fill, minmax(130px, 1fr));
        gap: 12px;
    }

    .app-item {
        padding: 14px;
    }

    .app-emoji {
        font-size: 1.8em;
    }

    .btn {
        padding: 12px 24px;
        font-size: 0.95em;
    }
}

@media (max-width: 480px) {
    header {
        padding: 20px 12px;
    }

    h1 {
        font-size: 1.6em;
    }

    .apps-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 10px;
    }

    .card {
        padding: 16px;
    }
}
