/* Credentials Management Page Styles */

.credentials-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
    margin: 20px 0;
}

.credentials-section {
    background: var(--card-bg);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    padding: 25px;
}

.credentials-section h2 {
    margin-bottom: 10px;
    font-size: 20px;
}

.section-description {
    color: var(--text-secondary);
    font-size: 14px;
    margin-bottom: 20px;
}

.form-group {
    position: relative;
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    font-weight: 600;
    margin-bottom: 8px;
    color: var(--text-primary);
}

.form-group input {
    width: 100%;
    padding: 12px;
    border: 1px solid var(--border-color);
    border-radius: 6px;
    font-size: 14px;
    background: var(--input-bg);
    color: var(--text-primary);
    transition: border-color 0.3s;
}

.form-group input[type="password"] {
    padding-right: 70px; /* Make room for the Show button */
}

.form-group input:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(0, 123, 255, 0.1);
}

.form-group small {
    display: block;
    margin-top: 5px;
    color: var(--text-secondary);
    font-size: 12px;
}

.toggle-password {
    position: absolute;
    right: 10px;
    top: 38px;
    background: transparent;
    border: none;
    cursor: pointer;
    font-size: 14px;
    padding: 5px 10px;
    color: var(--text-secondary);
    transition: color 0.3s;
}

.toggle-password:hover {
    color: var(--primary-color);
}

.button-group {
    display: flex;
    gap: 15px;
    margin-top: 30px;
    flex-wrap: wrap;
}

.btn {
    padding: 12px 24px;
    border: none;
    border-radius: 6px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s;
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.btn-primary {
    background: var(--primary-color);
    color: white;
}

.btn-primary:hover {
    background: #0056b3;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 123, 255, 0.3);
}

.btn-secondary {
    background: var(--secondary-color);
    color: white;
}

.btn-secondary:hover {
    background: #5a6268;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(108, 117, 125, 0.3);
}

.alert {
    padding: 15px 20px;
    border-radius: 6px;
    margin: 20px 0;
    border-left: 4px solid;
}

.alert-info {
    background: #d1ecf1;
    border-color: #17a2b8;
    color: #0c5460;
}

.alert-warning {
    background: #fff3cd;
    border-color: #ffc107;
    color: #856404;
}

.info-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
    margin: 20px 0;
}

.info-card {
    background: var(--card-bg);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    padding: 20px;
}

.info-card h3 {
    color: var(--text-primary);
    margin-top: 0;
    margin-bottom: 15px;
    font-size: 16px;
}

.info-card ul {
    list-style: none;
    padding-left: 0;
    margin: 0;
}

.info-card ul li {
    padding: 6px 0;
    padding-left: 20px;
    position: relative;
    color: var(--text-primary);
    font-size: 13px;
    line-height: 1.5;
}

.info-card ul li:before {
    content: "•";
    position: absolute;
    left: 5px;
    color: var(--primary-color);
    font-weight: bold;
}

.info-card code {
    background: var(--code-bg);
    padding: 2px 4px;
    border-radius: 3px;
    font-family: 'Courier New', monospace;
    font-size: 12px;
}

.message {
    padding: 15px 20px;
    border-radius: 6px;
    margin: 20px 0;
    font-weight: 500;
}

.message.success {
    background: #d4edda;
    color: #155724;
    border: 1px solid #c3e6cb;
}

.message.error {
    background: #f8d7da;
    color: #721c24;
    border: 1px solid #f5c6cb;
}

/* Dark mode adjustments */
body.dark-mode .alert-info {
    background: #1a3a42;
    color: #9fcddc;
}

body.dark-mode .alert-warning {
    background: #3d3417;
    color: #f7d794;
}

body.dark-mode .message.success {
    background: #1e4620;
    color: #a5d6a7;
}

body.dark-mode .message.error {
    background: #4a1a1f;
    color: #ef9a9a;
}

/* Responsive */
@media (max-width: 1200px) {
    .info-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 968px) {
    .credentials-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 768px) {
    .credentials-section,
    .info-card {
        padding: 20px;
    }

    .button-group {
        flex-direction: column;
    }

    .btn {
        width: 100%;
        justify-content: center;
    }
}
