/* Custom Test Cases Page Specific Styles */

.container.custom-container {
    max-width: 100%;
    width: 100%;
    padding: 30px 40px;
    box-sizing: border-box;
}

.subtitle {
    color: #666;
    margin-bottom: 25px;
    font-size: 16px;
}

/* Toolbar */
.toolbar {
    display: flex;
    gap: 12px;
    margin-bottom: 25px;
    flex-wrap: wrap;
}

.btn-primary {
    padding: 12px 24px;
    background: linear-gradient(135deg, #007acc, #005a9e);
    color: white;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    font-size: 14px;
    font-weight: 600;
    transition: all 0.3s ease;
    box-shadow: 0 2px 8px rgba(0, 122, 204, 0.3);
}

.btn-primary:hover {
    background: linear-gradient(135deg, #005a9e, #004080);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 122, 204, 0.4);
}

.btn-secondary {
    padding: 12px 24px;
    background: linear-gradient(135deg, #6c757d, #5a6268);
    color: white;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    font-size: 14px;
    font-weight: 600;
    transition: all 0.3s ease;
    box-shadow: 0 2px 8px rgba(108, 117, 125, 0.3);
}

.btn-secondary:hover {
    background: linear-gradient(135deg, #5a6268, #495057);
    transform: translateY(-2px);
}

.btn-danger {
    padding: 12px 24px;
    background: linear-gradient(135deg, #dc3545, #c82333);
    color: white;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    font-size: 14px;
    font-weight: 600;
    transition: all 0.3s ease;
    box-shadow: 0 2px 8px rgba(220, 53, 69, 0.3);
}

.btn-danger:hover {
    background: linear-gradient(135deg, #c82333, #bd2130);
    transform: translateY(-2px);
}

/* Cards Container */
#cards-container {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
    gap: 24px;
    width: 100%;
}

/* Test Case Card */
.test-card {
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    padding: 20px;
    position: relative;
    transition: all 0.3s ease;
    border: 2px solid transparent;
}

.test-card:hover {
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
    transform: translateY(-2px);
}

.test-card.pass {
    border-color: #28a745;
    background: linear-gradient(to bottom right, #fff, #f0fff0);
}

.test-card.fail {
    border-color: #dc3545;
    background: linear-gradient(to bottom right, #fff, #fff5f5);
}

/* Card Header */
.card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 15px;
    padding-bottom: 10px;
    border-bottom: 2px solid #eee;
}

.card-number {
    font-size: 14px;
    font-weight: 700;
    color: #007acc;
    background: #e6f4ff;
    padding: 4px 12px;
    border-radius: 20px;
}

.card-actions {
    display: flex;
    gap: 8px;
}

.status-btn {
    padding: 6px 12px;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    font-size: 12px;
    font-weight: 600;
    transition: all 0.2s ease;
}

.status-btn.pass-btn {
    background: #e8f5e9;
    color: #28a745;
}

.status-btn.pass-btn:hover,
.status-btn.pass-btn.active {
    background: #28a745;
    color: white;
}

.status-btn.fail-btn {
    background: #ffebee;
    color: #dc3545;
}

.status-btn.fail-btn:hover,
.status-btn.fail-btn.active {
    background: #dc3545;
    color: white;
}

.delete-btn {
    background: none;
    border: none;
    color: #999;
    cursor: pointer;
    font-size: 18px;
    padding: 4px 8px;
    border-radius: 4px;
    transition: all 0.2s ease;
}

.delete-btn:hover {
    background: #ffebee;
    color: #dc3545;
}

/* Form Fields */
.form-group {
    margin-bottom: 15px;
}

.form-group label {
    display: block;
    font-size: 12px;
    font-weight: 700;
    color: #555;
    margin-bottom: 6px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.form-group input,
.form-group textarea {
    width: 100%;
    padding: 12px;
    border: 2px solid #e0e0e0;
    border-radius: 8px;
    font-size: 14px;
    transition: all 0.2s ease;
    box-sizing: border-box;
    font-family: inherit;
}

.form-group input:focus,
.form-group textarea:focus {
    outline: none;
    border-color: #007acc;
    box-shadow: 0 0 0 3px rgba(0, 122, 204, 0.15);
}

.form-group input {
    height: 44px;
}

.form-group textarea {
    min-height: 80px;
    resize: vertical;
}

.form-group textarea::-webkit-scrollbar {
    width: 8px;
}

.form-group textarea::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 4px;
}

.form-group textarea::-webkit-scrollbar-thumb {
    background: #ccc;
    border-radius: 4px;
}

.form-group textarea::-webkit-scrollbar-thumb:hover {
    background: #aaa;
}

/* Empty State */
.empty-state {
    text-align: center;
    padding: 60px 20px;
    color: #999;
}

.empty-state .icon {
    font-size: 48px;
    margin-bottom: 15px;
}

.empty-state p {
    font-size: 16px;
    margin-bottom: 20px;
}

/* Responsive Adjustments */
@media (max-width: 768px) {
    .container.custom-container {
        padding: 20px 15px;
    }
    
    #cards-container {
        grid-template-columns: 1fr;
    }
    
    .toolbar {
        flex-direction: column;
    }
    
    .toolbar button {
        width: 100%;
    }
    
    .card-header {
        flex-wrap: wrap;
        gap: 10px;
    }
    
    .card-actions {
        width: 100%;
        justify-content: flex-end;
    }
}

@media (min-width: 1200px) {
    #cards-container {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media (min-width: 1800px) {
    #cards-container {
        grid-template-columns: repeat(4, 1fr);
    }
}

@media (min-width: 2200px) {
    #cards-container {
        grid-template-columns: repeat(5, 1fr);
    }
}

/* Toast Notification */
.toast {
    position: fixed;
    bottom: 30px;
    right: 30px;
    background: #333;
    color: white;
    padding: 15px 25px;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 500;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
    z-index: 1000;
    animation: slideIn 0.3s ease, fadeOut 0.3s ease 2.7s forwards;
}

.toast.success {
    background: linear-gradient(135deg, #28a745, #218838);
}

.toast.error {
    background: linear-gradient(135deg, #dc3545, #c82333);
}

@keyframes slideIn {
    from {
        transform: translateX(100%);
        opacity: 0;
    }
    to {
        transform: translateX(0);
        opacity: 1;
    }
}

@keyframes fadeOut {
    from {
        opacity: 1;
    }
    to {
        opacity: 0;
    }
}

/* Dark Mode Styles for Custom Page */
body.dark-mode .test-card {
    background: #16213e;
    border-color: #0f3460;
}

body.dark-mode .test-card:hover {
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.4);
}

body.dark-mode .card-header {
    border-bottom-color: #0f3460;
}

body.dark-mode .card-number {
    background: #0f3460;
    color: #4da6ff;
}

body.dark-mode .form-group label {
    color: #aaa;
}

body.dark-mode .form-group input,
body.dark-mode .form-group textarea {
    background: #1a1a2e;
    color: #e0e0e0;
    border-color: #0f3460;
}

body.dark-mode .form-group input:focus,
body.dark-mode .form-group textarea:focus {
    border-color: #007acc;
    box-shadow: 0 0 0 3px rgba(0, 122, 204, 0.3);
}

body.dark-mode .form-group input::placeholder,
body.dark-mode .form-group textarea::placeholder {
    color: #666;
}

body.dark-mode .delete-btn {
    color: #777;
}

body.dark-mode .delete-btn:hover {
    background: rgba(220, 53, 69, 0.2);
    color: #ff6b6b;
}

body.dark-mode .test-card.pass {
    background: linear-gradient(to bottom right, #16213e, #1e4620);
    border-color: #28a745;
}

body.dark-mode .test-card.fail {
    background: linear-gradient(to bottom right, #16213e, #4a1a1a);
    border-color: #dc3545;
}

body.dark-mode .empty-state {
    color: #666;
}

