/* 全局页面样式 */
body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    margin: 0;
    padding: 0;
    background-color: #ffffff; /* iOS风格的浅灰背景 */
}

/* 头部样式 */
header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background-color: #ffffff;
    color: #333;
    height: 100px; /* 根据需要调整高度 */
    padding: 0 20px; /* 调整左右内边距 */
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}

header h1 {
    flex: 1; /* 标题占据左边 */
    
    margin: 0;
}

.right-container {
    display: flex;
    flex: 1; /* 让右边部分占据剩余的空间 */
    justify-content: flex-end; /* 将右边的两个 div 靠右对齐 */
}

/* 调整 .right-container 内的 div 样式 */
.right-container div {
    border: 1px solid #ccc;
    padding: 10px;
    margin-left: 10px; /* 两个子 div 之间的间距 */
}

/* iOS 风格 login-button 按钮 */
.login-button {
    background-color: #76b2f1; /* iOS 风格蓝色 */
    color: white;
    padding: 12px 0; /* 让按钮的高度保持一致,内容居中 */
    border-radius: 15px; /* 圆角按钮 */
    font-size: 14px; /* 较小字体以适应60px的宽度 */
    font-weight: 600;
    cursor: pointer; /* 鼠标悬停时的手型指针 */
    transition: background-color 0.3s ease;
    border: none;
    width: 60px; /* 限制宽度为60px */
    text-align: center; /* 内容居中对齐 */
    overflow: hidden; /* 如果文字超过,隐藏多余部分 */
    white-space: nowrap; /* 避免换行 */
    text-overflow: ellipsis; /* 用省略号表示超出的文字 */
    margin-left: 10px; /* 跟其他 div 保持一致的间距 */
    flex-shrink: 0; /* 确保按钮不会缩放 */
}

.login-button:hover {
    background-color: #005bb5; /* 悬停时的颜色变深 */
}


/* login-modal 样式 - 隐藏模态框 */
/* iOS 风格的模态框背景 */
.login-modal {
    display: none; /* 初始隐藏 */
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.4); /* iOS 风格的半透明背景 */
    justify-content: center;
    align-items: center;
}

/* iOS 风格的模态框内容 */
.login-modal-content {
    background-color: #ffffff;
    padding: 20px;
    border-radius: 15px; /* iOS 风格的圆角 */
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2); /* iOS 风格的阴影效果 */
    max-width: 400px;
    width: 80%;
    text-align: center;
    animation: fadeIn 0.3s ease-in-out; /* 动画效果 */
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    position: relative; /* 设置相对定位 */
}


/* 关闭按钮 iOS 风格 */
.login-modal-close {
    position: absolute;
    top: 10px;
    right: 10px;
    font-size: 24px;
    color: #007aff; /* iOS 蓝色 */
    cursor: pointer;
    font-weight: bold;
    z-index: 1001; /* 确保在模态框内容的上方 */
}

/* 模态框中的文本样式 */
#userInfoContainer p {
    margin: 10px 0; /* 增加上下间距 */
    font-size: 16px; /* iOS 字体大小 */
    color: #333; /* 深灰色字体 */
    font-weight: 500;
    line-height: 1.5; /* 增加行高 */
}

/* iOS 风格的弹出动画 */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: scale(0.95); /* 轻微缩放效果 */
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}

/* iOS 风格退出按钮 */
.logout-button {
    background-color: #ff3b30; /* iOS 风格红色 */
    color: white;
    padding: 12px 20px;
    border-radius: 15px; /* 圆角 */
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: background-color 0.3s ease;
    border: none;
    width: 100%; /* 占满模态框的宽度 */
    margin-top: 20px; /* 增加与其他元素的距离 */
}

.logout-button:hover {
    background-color: #d12a1f; /* 悬停时颜色稍深 */
}

/*----------------*/


/* 容器布局:包含侧边栏和主内容 */
.container {
    display: flex;
    /*height: calc(100vh - 70px);  视口高度减去头部高度 */
    height: 100vh; 
}

/* 侧边栏样式 */
/* 固定侧边栏 */
aside {

    top: 0;
    left: 0;
    width: 200px; /* 侧边栏的宽度 */
    height: 100vh; /* 高度占满视口 */
    background-color: #2c3e50; /* 背景颜色 */
    color: #ffffff;
    display: flex;
    flex-direction: column;
    align-items: center;
    padding-top: 20px;
    box-shadow: 2px 0 5px rgba(0, 0, 0, 0.1); /* 添加阴影效果 */
 
}

/* 侧边栏内的导航菜单 */
nav ul {
    list-style: none; /* 去除默认的列表样式 */
    padding: 0;
    width: 100%; /* 使菜单项占满宽度 */
}

nav ul li {
    width: 100%; /* 每个菜单项占满整个宽度 */
    margin-bottom: 10px; /* 菜单项之间的间距 */
}

nav ul li a {
    display: flex; /* 使图标和文字并排显示 */
    align-items: center; /* 垂直居中 */
    padding: 15px 20px; /* 内边距 */
    color: #ffffff; /* 文字颜色 */
    text-decoration: none; /* 去掉下划线 */
    font-size: 16px; /* 字体大小 */
    font-weight: 500; /* 字体粗细 */
    transition: background 0.3s; /* 背景色的过渡效果 */
}

nav ul li a.active,
nav ul li a:hover {
    background-color: #1abc9c; /* 激活和悬停状态的背景颜色 */
    color: #ffffff; /* 保持文字为白色 */
    border-radius: 5px; /* 添加圆角 */
}

/* 图标样式(假设使用 FontAwesome 或其他图标库) */
nav ul li a i {
    font-size: 20px; /* 图标大小 */
    margin-right: 10px; /* 图标和文字的间距 */
}


/* 主内容区域 */
main {
    flex: 1; /* 占据剩余宽度 */
    padding: 20px;
    overflow-y: scroll; /* 启用垂直滚动 */
    background-color: #ecf0f1; /* 浅灰色背景 */
    height: auto; /* 自动调整高度 */
}



/* 瀑布流容器样式,每行最多显示4个卡片 */
.license-info-container {
    display: flex;
    
    flex-wrap: wrap;
    gap: 20px; /* 卡片之间的间距 */
}

/* 卡片样式 */
.license-info-card {
    position: relative;
    width: calc(25% - 20px); /* 每行4个卡片,减去间距 */
    background-color: #ffffff; /* 白色背景 */
    border-radius: 15px; /* iOS风格的圆角 */
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.05); /* 轻微柔和的阴影 */
    overflow: hidden;
    transition: transform 0.3s ease-in-out, box-shadow 0.3s ease-in-out; /* 过渡效果 */
    margin-bottom: 20px;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif; /* iOS 系统字体 */
    padding-bottom: 20px; /* 添加底部填充,以防止内容溢出 */
}

/* 悬停效果 */
.license-info-card:hover {
    transform: translateY(-3px); /* 悬停时轻微向上浮动 */
    box-shadow: 0 15px 25px rgba(0, 0, 0, 0.1); /* 悬停时增加阴影效果 */
}

/* 卡片顶部蓝色区域 */
.license-info-card-header {
    background-color: #007aff; /* iOS风格的蓝色 */
    height: 50px; /* 顶部蓝色部分的高度 */
    border-top-left-radius: 15px;
    border-top-right-radius: 15px;
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 10px;
    text-align: center;
    color: white; /* 项目名称字体颜色为白色 */
}

/* 标题样式:现在位于蓝色区域 */
.card-title {
    font-size: 20px; /* 标题字体加大 */
    font-weight: 600; /* 标题字体加粗 */
    color: white; /* 项目名称字体颜色为白色,和背景颜色形成对比 */
    margin: 0;
    line-height: 1.2; /* 行间距 */
}

/* 副标题和其他文本样式 */
.license-info-card-content {
    padding: 20px;
    color: #333;
}

.card-text {
    margin: 10px 0; /* 增加字段之间的间距 */
    font-size: 18px; /* 提高字体大小 */
    color: #3a3a3c; /* 中灰色,符合iOS风格 */
    line-height: 1.6; /* 行间距调整,确保更好的可读性 */
}

/* 许可证状态的颜色 */
.license-status-green {
    color: #34c759; /* iOS的绿色 */
}

.license-status-yellow {
    color: #ffcc00; /* iOS的黄色 */
}

.license-status-red {
    color: #ff3b30; /* iOS的红色 */
}



/*这部分代码仅在设备屏幕宽度小于或等于 768 像素时生效
*/
@media (max-width: 768px) {
  /* 小屏幕下卡片调整为每行显示2个 */
    .license-info-card {
        width: calc(50% - 20px);
        height: auto; /* 调整小屏幕下的高度 */
    }
}


/*-----------------*/

/* 响应式设计,适配小屏幕 */
@media (max-width: 768px) {
    .license-info-modal-content.show {
        width: 90vw; /* 在小屏设备中宽度为90% */
        height: 90vh; /* 高度为90% */
    }
}

/* 模态框样式,初始隐藏 */
.license-info-modal {
    display: none; /* 初始隐藏模态框 */
    position: fixed; /* 固定位置,模态框将一直可见,随页面滚动保持位置 */
    top: 0;
    left: 0;
    width: 100%; /* 宽度占据整个屏幕 */
    height: 100%; /* 高度占据整个屏幕 */
    background-color: rgba(0, 0, 0, 0.2); /* 半透明背景,模态框弹出时背景变暗 */
    justify-content: center; /* 居中模态框水平 */
    align-items: center; /* 居中模态框垂直 */
    /* z-index: 1000; 保证模态框在所有元素之上显示 */
    overflow: hidden; /* 禁止模态框背景滚动 */
}


/* 模态框内容样式,带有圆角和阴影 */
.license-info-modal-content {
    background-color: white; /* 模态框内部背景色为白色 */
    padding: 20px; /* 内部填充 */
    border-radius: 20px; /* 设置较大的圆角,符合iOS风格 */
    position: absolute; /* 使用绝对定位 */
    transform-origin: center; /* 动画从中心展开 */
    opacity: 0; /* 初始透明度为0,不可见 */
    transition: opacity 0.3s ease, transform 0.3s ease; /* 使用渐变效果使模态框逐渐显示 */
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1); /* 模态框阴影,增加浮动感 */
    max-height: 80vh; /* 最大高度不超过视口的80% */
    overflow-y: auto; /* 如果内容超出高度则滚动 */
}
/* 模态框的初始缩放效果,配合过渡动画 */
.license-info-modal-content {
    transform: scale(0.95); /* 初始有轻微缩放效果 */
}
/* 动画结束后的模态框样式,设置为80%大小且居中 */
.license-info-modal-content.show {
    opacity: 1; /* 动画显示模态框 */
    width: 80vw; /* 宽度占据视口80% */
    height: 70vh; /* 高度占据视口70% */
    top: 50%; /* 垂直居中 */
    left: 50%; /* 水平居中 */
    transform: translate(-50%, -50%) scale(1); /* 完全居中,且带有缩放效果 */
}





/* 关闭按钮样式 */
.license-info-close {
    position: absolute; /* 绝对定位,确保关闭按钮在模态框的右上角 */
    top: 10px;
    right: 20px;
    font-size: 28px; /* 关闭按钮的字体大小 */
    color: #007aff; /* iOS风格的蓝色 */
    cursor: pointer; /* 鼠标悬停时显示手指图标 */
    font-weight: 600; /* 设置按钮的字体粗细 */
}

/* 模态框上半部分的样式 */
.license-info-modal-header {
    display: flex;
    flex-direction: column;
    align-items: center;
    margin-bottom: 20px;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}

/* 标题的 iOS 风格 */
.license-info-modal-header h2 {
    font-size: 24px;
    font-weight: 600;
    color: #333;
    margin-bottom: 10px;
}

/* 按钮组的样式 */
.license-info-modal-button-group {
    display: flex;
    justify-content: space-around;
    width: 100%;
    margin-top: 10px;
}

/* 组样式:每组数据方框 */
.license-info-group-box {
    border: 1px solid #ccc; /* 灰色边框 */
    border-radius: 8px; /* 设置圆角 */
    padding: 15px; /* 内部填充 */
    margin-bottom: 15px; /* 组之间的间隔 */
    background-color: #f9f9f9; /* 设置浅灰色背景 */
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1); /* 设置轻微的阴影 */
}

.license-info-group-box p {
    margin: 5px 0;
    font-size: 16px;
    color: #333;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif; /* 符合 iOS 风格的字体 */
}

.license-info-group-title {
    font-weight: 600;
    margin-bottom: 10px;
    color: #007aff; /* iOS 风格的蓝色标题 */
}


.license-info-modal-button {
    padding: 12px 20px;
    background-color: #007aff; /* iOS风格的蓝色按钮 */
    color: white; /* 按钮字体颜色为白色 */
    border: none;
    border-radius: 12px; /* 设置圆角按钮 */
    font-size: 16px;
    font-weight: 500;
    cursor: pointer; /* 鼠标悬停时显示手指图标 */
    transition: background-color 0.3s ease; /* 背景颜色过渡效果 */
}

.license-info-modal-button:hover {
    background-color: #005bb5; /* 按钮的悬停效果 */
}

.license-info-modal-button:disabled {
    background-color: #ccc;
    cursor: not-allowed;
}

/* 模态框下半部分的样式 */
.license-info-modal-body {
    overflow-y: auto; /* 当内容超出容器时,启用垂直滚动条 */
    flex-grow: 1; /* 占据模态框的剩余空间 */
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    color: #3a3a3c; /* 字体颜色为深灰色 */
    font-size: 18px;
    line-height: 1.6; /* 行高 */
}

/* 添加滚动条样式,符合iOS的滑动效果 */
.license-info-modal-body::-webkit-scrollbar {
    width: 6px;
}

.license-info-modal-body::-webkit-scrollbar-thumb {
    background-color: rgba(0, 0, 0, 0.2);
    border-radius: 3px;
}


/* 分页按钮组样式 */
.license-info-modal-pagination {
    display: flex;
    justify-content: center;
    margin-top: 20px;
}

.license-info-modal-pagination button {
    padding: 10px 15px;
    margin: 0 5px;
    background-color: #007aff;
    color: white;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    font-size: 16px;
    transition: background-color 0.3s ease;
}

.license-info-modal-pagination button:hover {
    background-color: #005bb5; /* 鼠标悬停时按钮背景颜色变深 */
}

.license-info-modal-pagination button:disabled {
    background-color: #ccc; /* 禁用时按钮为灰色 */
    cursor: not-allowed;
}

/* 分页下拉框样式 */
.license-info-modal-pagination select {
    padding: 10px 15px;
    margin: 0 5px;
    background-color: #007aff;
    color: white;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    font-size: 16px;
    transition: background-color 0.3s ease;
}

/* 下拉框中的选项样式 */
.license-info-modal-pagination select option {
    background-color: white; /* 默认背景颜色 */
    color: black; /* 默认字体颜色 */
}

/* 鼠标悬停选项时 */
.license-info-modal-pagination select option:hover {
    background-color: #007aff; /* 鼠标悬停时选项变为蓝色 */
    color: white; /* 悬停时字体颜色变为白色 */
}

/* 选中的选项的样式 */
.license-info-modal-pagination select option:checked {
    background-color: #ccc; /* 当前选中的选项背景为蓝色 */
    color: white; /* 当前选中的选项字体颜色为白色 */
}

/* 侧边栏的菜单项与搜索框保持间距 */
nav ul {
    padding-top: 20px;
}

/* 活跃菜单项样式 */
nav ul li a.active {
    background-color: #007aff;
    color: white;
}


/*进度条-----------------------------------------------------*/
/* 模态框的基础样式 */
.loading-modal {
    position: fixed;
    z-index: 9999;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    display: flex;
    justify-content: center;
    align-items: center;
}

.loading-modal-content {
    background-color: white;
    padding: 20px;
    border-radius: 8px;
    text-align: center;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
}

.spinner {
    border: 4px solid rgba(0, 0, 0, 0.1);
    border-left-color: #09f;
    border-radius: 50%;
    width: 40px;
    height: 40px;
    animation: spin 1s linear infinite;
    margin-bottom: 10px;
}

@keyframes spin {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

/* Loading message text style */
.loading-modal p {
    margin: 0;
    font-size: 16px;
    color: #333;
}


/* 用户管理模态框------------------------------------------------------ */
/* 用户管理模态框的背景层 */
/* 响应式设计,适配小屏幕 */
/* 用户管理模态框的背景层 */




/* 搜索栏样式*/
/* 搜索框和下拉框容器样式 */
.search-container {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 10px 0;
    background-color: #ffffff;
 
}


/* License 状态下拉框、日期输入框和搜索框的样式 */
#license-status-filter, #start-date, #end-date, #search-bar {
    width: 18%;
    padding: 12px;
    border-radius: 15px;
    border: none;
    background-color: #ffffff;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
    font-size: 16px;
    color: #333;
    transition: all 0.3s ease;
}

/* 日期框在获得焦点时的效果 */
#start-date:focus, #end-date:focus {
    outline: none;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.2);
}

/* 确定按钮样式 */
/* 确定按钮和返回按钮的统一样式 */
#submit-button,
#reset-button {
    padding: 12px 20px;
    background-color: #007aff; /* iOS风格的蓝色按钮 */
    color: white;
    border: none;
    border-radius: 15px;
    font-size: 16px;
    cursor: pointer;
    transition: background-color 0.3s ease;
}

/* 鼠标悬停时按钮效果 */
#submit-button:hover,
#reset-button:hover {
    background-color: #005bb5;
}




/*-----------------分发*/



/*------------分发历史模态框*/
/* 分发历史模态框整体样式 */
.distributionHistory-modal {
    display: none; /* 默认隐藏 */
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5); /* 半透明背景 */
    justify-content: center;
    align-items: center;
    overflow: hidden;
}

/* 分发历史模态框内容样式 */
.distributionHistory-modal-content {
    background-color: #fff;
    width: 400px; /* 模态框的宽度 */
    max-width: 90%; /* 最大宽度为视口的90% */
    padding: 20px;
    border-radius: 10px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3); /* 轻微阴影 */
    position: relative;
    text-align: center;
}

/* 分发历史模态框关闭按钮样式 */
.distributionHistory-modal-close {
    position: absolute;
    top: 10px;
    right: 15px;
    font-size: 24px;
    color: #333;
    cursor: pointer;
}

/* 分发历史模态框标题样式 */
.distributionHistory-modal-header h2,
.distributionHistory-modal-body h2 {
    font-size: 20px;
    font-weight: bold;
    margin-bottom: 15px;
    color: #333;
}

/* 分发历史模态框邮箱部分样式 */
.distributionHistory-modal-email-section {
    margin-bottom: 20px;
}

.distributionHistory-modal-email-section h2 {
    font-size: 18px;
    margin-bottom: 10px;
    color: #007bff;
}

/* 分发历史模态框用户部分样式 */
.distributionHistory-modal-user-section {
    margin-top: 20px;
}

.distributionHistory-modal-user-section h2 {
    font-size: 18px;
    margin-bottom: 10px;
    color: #28a745;
}

/* 分发历史模态框的输入框区域样式 */
.distributionHistory-modal-inputs,
.distributionHistory-modal-user-inputs {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
}

.distributionHistory-modal-inputs div,
.distributionHistory-modal-user-inputs div {
    margin-bottom: 10px;
}

.distributionHistory-modal input[type="checkbox"] {
    margin-right: 10px;
}

.distributionHistory-modal-label {
    font-size: 16px;
    color: #555;
    cursor: pointer;
}

/* 分发历史模态框确认按钮样式 */
.distributionHistory-modal-confirm-button {
    background-color: #007bff;
    color: white;
    padding: 10px 20px;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    margin-top: 20px;
    font-size: 16px;
}

.distributionHistory-modal-confirm-button:hover {
    background-color: #0056b3;
}

/* 分发历史模态框用户选择框容器样式 */
.distributionHistory-modal-user-select-container {
    margin-bottom: 15px;
    width: 100%;
    display: flex;
    justify-content: center; /* 居中 */
}

/* 分发历史模态框专属下拉框样式 */
.distributionHistory-modal-user-select {
    width: 80%; /* 下拉框的宽度 */
    padding: 10px;
    border-radius: 8px;
    border: 1px solid #ccc;
    font-size: 16px;
    background-color: #f9f9f9; /* 浅灰背景 */
    color: #333; /* 字体颜色 */
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1); /* 轻微阴影 */
    transition: border-color 0.3s ease;
}

.distributionHistory-modal-user-select:focus {
    border-color: #007bff; /* 焦点时的边框颜色 */
    outline: none; /* 去掉默认的焦点样式 */
    box-shadow: 0 0 5px rgba(0, 123, 255, 0.5); /* 焦点时的阴影效果 */
}

/* 下拉框的选项样式 */
.distributionHistory-modal-user-select option {
    background-color: white; /* 默认背景颜色 */
    color: black; /* 默认字体颜色 */
}

/* 悬停选项时的样式 */
.distributionHistory-modal-user-select option:hover {
    background-color: #007bff; /* 悬停时选项的背景颜色 */
    color: white; /* 悬停时字体颜色 */
}

/* 选中的选项的样式 */
.distributionHistory-modal-user-select option:checked {
    background-color: #0056b3; /* 选中的选项的背景颜色 */
    color: white; /* 选中的选项的字体颜色 */
}

/* 分发历史模态框添加用户按钮样式 */
.distributionHistory-modal-add-user-button {
    padding: 10px 15px;
    background-color: #007bff;
    color: white;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    margin-top: 10px;
    transition: background-color 0.3s ease;
}

.distributionHistory-modal-add-user-button:hover {
    background-color: #0056b3;
}