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

body, html {
    font-family: Arial, sans-serif;
    background-color: #f8f9fa;
    height: 100vh;
}

.container {
    padding: 8px;
    width: 100%;
    height: 100%;
    display: flex;
    flex-direction: column;
    background-color: #ffffff;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
}

.header {
    background-color: #007bff;
    color: #ffffff;
    padding: 8px 6px;
    font-size: 11px;
    font-weight: bold;
    text-align: left;
}

/* Options Section */
.options {
        display: grid;
        grid-template-columns: repeat(3, 1fr); 
        margin-top: 20px;
        gap: 5px; 
        justify-items: center; 
    }
    
    @media (max-width: 900px) {
        .options {
            grid-template-columns: repeat(2, 1fr);
            gap: 5px; 
        }
    }
    
    @media (max-width: 600px) {
        .options {
            grid-template-columns: 1fr; 
            gap: 5px; 
        }
    }
    
    .option-card {
        background-color: #fff;
        border: 1px solid #ddd;
        border-radius: 8px;
        text-align: center;
        box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
        flex-direction: column;
        justify-content: center;
        align-items: center;
        display: flex;
        flex: 1 1 calc(30% - 10px); 
        padding: 8px; /* Giảm padding bên trong thẻ option */
        width: 80%; /* Điều chỉnh chiều rộng để nhỏ gọn hơn */
        margin: 4px; /* Giảm margin giữa các thẻ */ 

    }
    
    .option-card img {
        height: 50px;
        margin-bottom: 10px;
    }
    
    .option-card:hover {
        transform: translateY(-5px);
    }
    
    .option-card h2 {
        font-size: 1rem; 
        color: #333;
        margin-bottom: 3px; 
    }
    
    .option-card p {
        font-size: 0.9rem; 
        color: #555;
        margin: 0; 
    }



.tag {
    background-color: #0301011c; 
    border-radius: 4px; 
    padding: 2px 6px;
    font-size: 12px;
    display: inline-block; 
    margin-left: 5px;
}

.buttons {
    display: flex;
    gap: 10px;
}

.continue-btn, .guide-btn {
    padding: 10px 20px;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    font-size: 1rem;
    transition: background-color 0.3s;
}

.continue-btn {
    background-color: #0073e6;
    color: white;
}

.continue-btn:hover {
    background-color: #005bb5;
}

.guide-btn {
    background-color: #ddd;
    color: #333;
}

.guide-btn:hover {
    background-color: #ccc;
}
/* Parent container to center content */
.parent-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    width: 100%;
    padding: 20px;
    gap: 40px;
}

/* Header container */
.header-container {
    display: flex;
    align-items: center;
    justify-content: space-between; /* Đảm bảo nút đóng nằm bên phải */
    padding-bottom: 10px;
    margin-bottom: 20px;
}

/* Title styling */
.header-title {
    font-size: 18px;
    margin: 0;
    padding: 10px 10px; /* Giữ padding bên trái và phải ít hơn để tạo không gian cho nút đóng */
    background-color: #007bff;
    color: #f4f7fa;
    font-weight: bold;
    flex-grow: 1; /* Cho phép tiêu đề chiếm không gian còn lại */
}

.close-button {
    background: none;
    border: none;
    font-size: 24px;
    cursor: pointer;
    color: #fefefe;
}

.close-button:hover {
    color: #f0ecec;
}

/* Form group styling */
.form-group {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.difficulty-container {
    display: flex;
    align-items: center;
    gap: 10px;
   
    
}

.difficulty-label {
    font-size: 14px;
}

.difficulty-select {
    padding: 8px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 14px;
 
}

/* Input description */
.input-description {
    padding: 10px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 14px;
}

.input-description:focus {
    border-color: #007bff;
    outline: none;
}

/* CTA Button */
.cta-button {
    background-color: #3e7af2;
    color: #ffffff;
    padding: 12px;
    border: none;
    border-radius: 4px;
    font-size: 16px;
    cursor: pointer;
    width: 100%;
    max-width: 400px;
    margin: 20px auto 0;
    display: block; /* Ensures the button behaves like a block element */
    text-align: center;
    transition: background-color 0.3s;
    
}

.cta-button:hover {
    background-color: #f7f8fb;
}
.description-container {
    display: flex;
    align-items: center; /* Align items vertically centered */
    gap: 10px; /* Space between label and input */
}

.description-label {
    font-size: 14px;
    color: #333;
    white-space: nowrap; /* Prevent label from wrapping */
    width: 120px; /* Fixed width for the label */
}

.input-description {
    padding: 10px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 14px;
    flex: 1; /* Allow the input to take the remaining space */
}

.input-description:focus {
    border-color: #007bff;
    outline: none;
}
.continue-btn {
    display: inline-block;
    background-color: #007bff;
    color: #ffffff;
    padding: 10px 20px;
    border-radius: 4px;
    text-decoration: none;
    font-size: 16px;
    text-align: center;
    cursor: pointer;
}

.continue-btn:hover {
    background-color: #0056b3;
}

/* Wrapper styling */
.content-wrapper {
    background-color: #ffffff; 
    padding: 30px;             
    border-radius: 8px;         
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);   
    margin: 40px auto;  
    width: 100%;       
}
/* Tiêu đề */
.edit-challenge-header {
    font-size: 18px;
    font-weight: bold;
    padding: 16px;
    background-color: #007bff;
    color: #ffffff;
    text-align: left;
    width: 100%;
    box-sizing: border-box; /* Đảm bảo chiều rộng bao phủ màn hình */
    margin-bottom: 0; /* Đảm bảo không có khoảng cách bên dưới */
}

/* Căn giữa toàn bộ nội dung bên dưới tiêu đề */
.edit-challenge-container {
    display: flex;
    flex-direction: column;
    align-items: center; /* Căn giữa theo chiều ngang */
    padding: 0; /* Xóa khoảng cách thừa */
    width: 100%;
    box-sizing: border-box;
}


/* Các nhóm form */
.edit-challenge-form-group {
    margin-bottom: 20px;
    width: 100%;
}

.edit-challenge-form-group label {
    font-weight: bold;
    margin-bottom: 8px;
    font-size: 16px;
    color: #333;
}

/* Các input, select, textarea */
.edit-challenge-form-group input[type="text"],
.edit-challenge-form-group select,
.edit-challenge-form-group textarea {
    width: 100%;
    padding: 12px;
    border: 1px solid #ccc;
    border-radius: 5px;
    font-size: 14px;
    background-color: #fff;
    box-sizing: border-box;
    transition: border-color 0.3s ease;
}

.edit-challenge-form-group input[type="text"]:focus,
.edit-challenge-form-group select:focus,
.edit-challenge-form-group textarea:focus {
    border-color: #007bff;
    outline: none;
}

/* Nút cập nhật */
.update-button {
    background-color: #3498db;
    color: white;
    padding: 12px 20px;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    font-size: 16px;
    width: 100%;
    transition: background-color 0.3s ease;
}

.update-button:hover {
    background-color: #2980b9;
}

/* Responsive cho giao diện di động */
@media (max-width: 768px) {
    .edit-challenge-container {
        padding: 15px;
    }

    .edit-challenge-header {
        font-size: 16px;
    }

    .edit-challenge-form-group input[type="text"],
    .edit-challenge-form-group select,
    .edit-challenge-form-group textarea {
        font-size: 14px;
    }

    .update-button {
        font-size: 18px;
    }
}

/* Khung chứa dòng thông báo */
.starter-code-container {
    background-color: #333; /* Màu nền đen */
    color: #fff; /* Màu chữ trắng */
    padding: 15px; /* Khoảng cách bên trong */
    border-radius: 5px; /* Bo góc mềm mại */
    font-size: 16px; /* Kích thước chữ */
    font-weight: bold; /* Làm đậm chữ */
    margin-top: 20px; /* Khoảng cách phía trên */
    width: 100%; /* Đảm bảo chiều rộng đầy đủ */
    box-sizing: border-box; /* Đảm bảo padding không làm thay đổi chiều rộng */
    text-align: center ; /* Căn trái văn bản */
    overflow: hidden; /* Ngăn không cho phần thừa tràn ra ngoài */
}
.starter-checkbox {
    margin-right: 10px; /* Khoảng cách giữa checkbox và dòng chữ */
    width: 20px; /* Kích thước của checkbox */
    height: 20px; /* Kích thước của checkbox */
    cursor: pointer; /* Thêm con trỏ khi hover vào checkbox */
}

/* Định dạng dấu tick */
.starter-code-container .tick {
    color: #4caf50; /* Màu xanh lá cây cho dấu tick */
    margin-right: 10px; /* Khoảng cách giữa dấu tick và văn bản */
    font-size: 18px; /* Kích thước dấu tick */
}

/* Đảm bảo đáp ứng trên các màn hình nhỏ */
@media (max-width: 768px) {
    .starter-code-container {
        font-size: 14px; /* Giảm kích thước chữ khi trên màn hình nhỏ */
        padding: 10px; /* Giảm padding để phù hợp hơn */
    }
}

  /* Modal hiển thị các thông tin về input và test cases */
.modal {
    display: flex;
    justify-content: center; /* Căn giữa modal */
    align-items: flex-start; /* Căn modal lên phía dưới giao diện */
    position: fixed;
    top: 60px; /* Tạo khoảng cách từ trên xuống (điều chỉnh tùy theo chiều cao của header hoặc giao diện phía trên) */
    left: 50%;
    transform: translateX(-50%); /* Căn giữa theo chiều ngang */
    width: 100%;
    height: calc(100% - 80px); /* Giới hạn chiều cao modal sao cho không che toàn bộ màn hình */
    background-color: rgba(249, 249, 249, 0.947); /* Tạo nền mờ khi mở modal */
    z-index: 9999;
    padding: 20px;
    box-sizing: border-box;
    position: relative; /* Đảm bảo không gây đè lên giao diện cũ */
  }
  
  /* Modal content */
  .modal-content {
    padding: 20px;
    background-color: #fff;
    box-shadow: 0 0 15px rgba(0, 0, 0, 0.1);
    border-radius: 8px;
    width: 100%;
    max-width: 600px; /* Giới hạn chiều rộng modal */
    box-sizing: border-box;
  }
  
  /* Phần input section */
  .input-section {
    margin-bottom: 20px;
  }
  
  .input-section label {
    display: block;
    font-weight: bold;
    margin-bottom: 5px;
  }
  
  .input-section select {
    width: 100%;
    padding: 8px;
    border: 1px solid #ddd;
    border-radius: 5px;
    font-size: 14px;
  }
  
  /* Phần test cases */
  .test-cases {
    margin-top: 20px;
  }
  
  .test-cases label {
    font-weight: bold;
    font-size: 16px;
  }
  
  .test-case-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-top: 10px;
  }
  
  .test-case-row input[type="text"] {
    width: 45%;
    padding: 8px;
    border-radius: 4px;
    border: 1px solid #ddd;
    font-size: 14px;
  }
  
  .test-case-row span {
    font-size: 20px;
    margin: 0 15px;
  }
  
  /* Nút cập nhật */
  .update-button {
    background-color: #3498db;
    color: white;
    padding: 12px 20px;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    width: 100%;
    font-size: 16px;
  }
  
  .update-button:hover {
    background-color: #2980b9;
    transition: background-color 0.3s ease;
  } 

  
