/* static/css/style.css */

body {
    font-family: sans-serif;
    margin: 20px;
    background-color: #f4f4f4;
    color: #333;
    display: flex; 
    justify-content: center; 
    align-items: flex-start; 
    min-height: 100vh; 
}

.container {
    background-color: #fff;
    padding: 20px;
    border-radius: 8px;
    box-shadow: 0 0 10px rgba(0,0,0,0.1);
    max-width: 700px;
    width: 100%; 
    margin-top: 20px; 
    margin-bottom: 20px; 
}

.controls { 
    margin-bottom: 20px;
}

.name-selector-container .name-selector-title {
    font-weight: bold;
    margin-bottom: 10px;
    text-align: center; 
}

.name-selector {
    display: flex;
    flex-direction: column; 
    gap: 8px; 
    align-items: center; 
}

.name-row {
    display: flex;
    justify-content: center; 
    gap: 10px; /* 稍微减小名字之间的间距 */
    flex-wrap: wrap; 
    width: 100%; /* 让行占据全部可用宽度，方便内部对齐 */
}

.name-option {
    display: flex;
    align-items: center; 
    gap: 5px; 
    min-width: 120px; /* 修改：为每个选项设置一个最小宽度以帮助对齐 */
    justify-content: flex-start; /* 让单选按钮和文本在选项内部靠左对齐 */
    padding: 5px; /* 给选项一些内边距 */
    /* border: 1px solid #eee; */ /* 可选：为每个选项添加边框以便调试对齐 */
    /* box-sizing: border-box; */
}

.name-option label {
    cursor: pointer; 
}
.name-option input[type="radio"] {
    cursor: pointer;
    margin-right: 3px; /* 单选按钮和标签之间微调 */
}


.calendar-navigation {
    margin-bottom: 20px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

#calendar-table {
    width: 100%;
    border-collapse: collapse; 
    margin-bottom: 20px;
    table-layout: fixed; 
}

#calendar-table th { 
    border: 2px solid #ddd; 
    padding: 10px 0;
    background-color: #f0f0f0;
    text-align: center;
    height: 50px;
    box-sizing: border-box;
}

#calendar-table td { 
    padding: 0;
    text-align: center;
    height: 60px;
    box-sizing: border-box;
    border: 2px solid #ddd; 
    background-color: transparent; 
}

#calendar-table td:not(.padding) {
    cursor: pointer;
    vertical-align: middle;
}

#calendar-table td.padding {
    background-color: #f9f9f9;
    cursor: default;
    border: 2px solid #e0e0e0; 
}

#calendar-table td.selected {
    background-color: transparent; 
    border: 3px solid #007bff;   
    background-image: repeating-linear-gradient(
        45deg,
        rgba(0, 123, 255, 0.2), 
        rgba(0, 123, 255, 0.2) 1px,
        transparent 1px,
        transparent 6px 
    );
}

#calendar-table td.common-available {
    background-color: #a0e7a0; 
    /* border: 2px solid #5cb85c; */ 
}

#calendar-table td.selected.common-available {
    background-color: #a0e7a0; 
    border: 3px solid #007bff; 
}

#save-availability {
    padding: 10px 15px;
    background-color: #007bff;
    color: white;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    display: block;
    margin: 20px auto;
    width: fit-content; 
}

#save-availability:hover {
    background-color: #0056b3;
}

.timezone-info {
    margin-bottom: 20px;
    padding: 10px;
    background-color: #f8f9fa;
    border-radius: 4px;
    border: 1px solid #eee;
}
.timezone-info h3 {
    margin-top: 0;
    margin-bottom: 10px;
    font-size: 1.1em;
    text-align: center;
}
#timezone-table {
    width: 100%;
    border-collapse: collapse;
    margin-bottom: 10px;
}
#timezone-table th, #timezone-table td {
    border: 1px solid #ddd;
    padding: 8px;
    text-align: center;
}
#timezone-table th {
    background-color: #e9ecef;
}
.timezone-note {
    font-size: 0.9em;
    color: #6c757d;
    text-align: center;
}

.common-availability {
    margin-top: 20px;
    padding: 10px;
    background-color: #f8f9fa;
    border-radius: 4px;
}
.common-availability h3 {
    margin-top: 0;
    margin-bottom: 10px;
    font-size: 1.1em;
}
.common-availability ul {
    list-style-type: none;
    padding-left: 0;
    margin-bottom: 0;
}
.common-availability ul li {
    padding: 5px 0;
    border-bottom: 1px dashed #eee; 
}
.common-availability ul li:last-child {
    border-bottom: none;
}
