/* 通用样式 */
body {
    margin: 0;
    font-family: Arial, sans-serif;
    background-color: #e0e0e0; /* A light grey background to enhance the relief effect */
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
    flex-direction: column;
    box-shadow: inset 10px 10px 20px rgba(0, 0, 0, 0.1), inset -10px -10px 20px rgba(255, 255, 255, 0.7); /* Relief effect for the entire page */
    background-image: url('path-to-your-pattern/european-pattern.png'); /* Set the background image */
    background-repeat: no-repeat;
    background-position: center;
    background-size: contain;
}

h1, h2 {
    margin: 20px 0;
    text-align: center; /* Center the text for all headings */
}

button, input[type="submit"] {
    background-color: #007aff;
    color: white;
    border: none;
    border-radius: 5px;
    padding: 10px;
    font-size: 16px;
    cursor: pointer;
    margin-top: 10px;
    transition: background-color 0.3s;
}

button:hover, input[type="submit"]:hover {
    background-color: #005bb5;
}

label {
    font-size: 14px;
    margin-bottom: 5px;
}

input[type="text"], input[type="email"], input[type="password"], textarea {
    padding: 10px;
    margin-bottom: 15px;
    border: 1px solid #ccc;
    border-radius: 4px;
    font-size: 14px;
    box-sizing: border-box;
}

/* 顶栏样式 */
#top-bar {
    width: 100%;
    background-color: #007aff;
    color: white;
    padding: 10px 0;
    display: flex;
    justify-content: space-between;
    align-items: center;
    position: fixed;
    top: 0;
    left: 0;
    z-index: 1000;
    box-shadow: 0px 4px 6px rgba(0, 0, 0, 0.1); /* Subtle shadow for the top bar */
}

.top-bar-link {
    color: white;
    text-decoration: none;
    padding: 0 20px;
    font-size: 16px;
}

.top-bar-link:hover {
    text-decoration: underline;
}

/* 页面容器样式 */
.container {
    margin-top: 60px; /* Leave space for the top bar */
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    min-height: calc(100vh - 60px);
    padding: 20px;
    box-sizing: border-box;
    background: #f0f0f0;
    border-radius: 10px;
    box-shadow: inset 10px 10px 20px rgba(0, 0, 0, 0.1), inset -10px -10px 20px rgba(255, 255, 255, 0.7); /* Stronger Relief effect for the container */
}

.content-wrapper {
    background-color: #ffffff;
    padding: 40px;
    border-radius: 10px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    width: 100%;
    max-width: 800px;
    text-align: left;
}

.content-wrapper p {
    line-height: 1.6;
    margin: 10px 0;
    color: #333;
    font-size: 16px;
}

/* 主页样式 */
.home-page {
    margin-top: 60px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    min-height: calc(100vh - 60px);
    padding: 20px;
    box-sizing: border-box;
}

#home-container {
    display: flex;
    justify-content: center;
    align-items: center;
    flex-wrap: wrap;
    max-width: 1200px;
    padding: 20px;
    box-sizing: border-box;
}

.button-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
    width: 100%;
}

.survey-block {
    background-color: white;
    color: #007aff;
    border: 2px solid #007aff;
    border-radius: 5px;
    padding: 20px;
    font-size: 16px;
    cursor: pointer;
    text-align: center;
    display: flex;
    justify-content: center;
    align-items: center;
    flex-direction: column;
    transition: background-color 0.3s, color 0.3s, border-color 0.3s;
}

.survey-block:hover {
    background-color: #007aff;
    color: white;
    border-color: #005bb5;
}

.survey-block h2 {
    margin: 10px 0;
}

.survey-block p {
    margin: 0;
    font-size: 14px;
    color: #555;
    text-align: center; /* Center the description text */
}

/* 登录页面样式 */
.login-page {
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: calc(100vh - 60px);
    padding: 20px;
    box-sizing: border-box;
}

.login-content {
    background-color: #fff;
    padding: 40px;
    border: 1px solid #ddd;
    border-radius: 8px;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
    width: 100%;
    max-width: 400px;
    text-align: center;
}

form {
    display: flex;
    flex-direction: column;
}

/* 调查页面样式 */
.survey-page {
    margin-top: 60px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    min-height: calc(100vh - 60px);
    padding: 20px;
    box-sizing: border-box;
}

#survey-container {
    background: #ffffff;
    padding: 40px;
    border-radius: 10px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    max-width: 800px;
    width: 90%;
    text-align: center;
    position: relative;
    margin: auto;
}

.option {
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 5px 0;
}

.option input[type="checkbox"] {
    margin-right: 10px;
}

.button-container {
    text-align: center;
    margin-top: 20px;
}

#acknowledge-btn {
    background-color: #4CAF50; /* Green */
    color: white;
    padding: 10px 20px;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    font-size: 16px;
}

#acknowledge-btn:hover {
    background-color: #45a049;
}


.next-button {
    margin-left: auto;
}

/* 感谢页面样式 */
.thank-you-container {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    height: 100vh;
    text-align: center;
    background-color: #f9f9f9;
}

.thank-you-container h1 {
    font-size: 2.5em;
    margin-bottom: 20px;
}

.thank-you-container p {
    font-size: 1.2em;
    color: #666;
}

/* 分析页面样式 */
.analyze-page {
    margin-top: 60px;
    padding: 20px;
    display: flex;
    flex-direction: column;
    align-items: center;
    min-height: calc(100vh - 60px);
}

#analysis-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    max-width: 800px;
    width: 100%;
    margin: auto;
}

#analysis-results {
    margin-top: 20px;
}

canvas {
    max-width: 100%;
    margin: auto;
}

/* Dashboard Page Specific Styles */
.dashboard-page {
    margin-top: 60px;
    padding: 20px;
    background-color: #fafafa;
    display: flex;
    flex-direction: column;
    align-items: center;
    min-height: calc(100vh - 60px);
}

#dashboard-container {
    max-width: 1000px;
    margin: 0 auto;
    padding: 20px;
    background-color: white;
    border-radius: 10px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

.survey-data h2 {
    margin-bottom: 20px;
}

table {
    width: 100%;
    border-collapse: collapse;
}

th, td {
    padding: 10px;
    text-align: left;
    border-bottom: 1px solid #ddd;
}

th {
    background-color: #007aff;
    color: white;
}

tr:hover {
    background-color: #f1f1f1;
}

/* 继承样式 */
.dashboard-page {
    margin-top: 60px;
    padding: 20px;
    background-color: #fafafa;
    display: flex;
    flex-direction: column;
    align-items: center;
    min-height: calc(100vh - 60px);
}

#dashboard-container {
    max-width: 1000px;
    margin: 0 auto;
    padding: 20px;
    background-color: white;
    border-radius: 10px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

.survey-data h2 {
    margin-bottom: 20px;
}

table {
    width: 100%;
    border-collapse: collapse;
}

th, td {
    padding: 10px;
    text-align: left;
    border-bottom: 1px solid #ddd;
}

th {
    background-color: #007aff;
    color: white;
}

tr:hover {
    background-color: #f1f1f1;
}

/* 新增样式 */
.user-section {
    margin-bottom: 40px;
}

.user-info {
    display: flex;
    flex-wrap: wrap;
    align-items: center; /* 保持所有元素垂直居中 */
    gap: 20px;
    margin-bottom: 20px;
}

.user-info h3 {
    margin: 0;
}

.user-info p {
    margin: 0;
}

.actions-section {
    margin-top: 20px;
    text-align: center;
}

.actions-section button {
    margin: 0 10px;
    padding: 10px 20px;
    font-size: 16px;
    background-color: #007aff;
    color: white;
    border: none;
    border-radius: 5px;
    cursor: pointer;
}

.actions-section button:hover {
    background-color: #005bb5;
}

.no-data {
    color: #777;
    text-align: center;
    font-size: 18px;
}

.survey-block.disabled {
    background-color: #ccc; /* Grey color to indicate disabled */
    color: #888; /* Lighter text */
    cursor: not-allowed; /* Change cursor to indicate it's not clickable */
}

.survey-block.disabled:hover {
    background-color: #ccc; /* No hover effect */
}
