/* 基础样式 */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Segoe UI', 'Microsoft YaHei', sans-serif;
}

body {
    background-color: #f5f7fa;
    color: #333;
    line-height: 1.6;
    font-size: 14px;
    padding-bottom: 70px; /* 给底部导航留空间 */
}

.mobile-container {
    max-width: 100%;
    margin: 0 auto;
    background-color: #fff;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    overflow-x: hidden;
}

/* 头部样式 */
.mobile-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 15px;
    background: linear-gradient(135deg, #1e5799 0%,#207cca 51%,#2989d8 100%);
    color: white;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    position: sticky;
    top: 0;
    z-index: 100;
}

.header-row {
    display: flex;
    width: 100%;
    justify-content: space-between;
    align-items: center;
}

.mobile-header .logo {
    display: flex;
    align-items: center;
    gap: 12px;
}

.mobile-header .logo img {
    width: 45px;
    height: 45px;
    border-radius: 5px;
    border: 2px solid rgba(255,255,255,0.3);
    background-color: white;
    padding: 3px;
}

.logo-text {
    display: flex;
    flex-direction: column;
}

.mobile-header .logo h1 {
    font-size: 18px;
    font-weight: bold;
    margin-bottom: 2px;
    text-shadow: 0 1px 2px rgba(0,0,0,0.2);
}

.mobile-header .logo .subtitle {
    font-size: 10px;
    opacity: 0.9;
    letter-spacing: 0.5px;
}

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

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 8px;
    border-radius: 50%;
    text-decoration: none;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 14px;
    border: none;
    width: 36px;
    height: 36px;
    box-shadow: 0 2px 5px rgba(0,0,0,0.2);
}

.btn-primary {
    background-color: #4a6cf7;
    color: white;
}

.btn-secondary {
    background-color: #6c757d;
    color: white;
}

.btn-success {
    background-color: #28a745;
    color: white;
}

.btn-danger {
    background-color: #dc3545;
    color: white;
}

/* 公告栏 */
.mobile-announcement {
    background: linear-gradient(to right, #fff8e1, #ffecb3);
    padding: 8px 15px;
    border-bottom: 1px solid #ffd54f;
    font-size: 12px;
    color: #5d4037;
    position: sticky;
    top: 69px;
    z-index: 90;
}

.mobile-announcement marquee {
    overflow: hidden;
}

/* 主内容区 */
.mobile-content {
    padding: 15px;
    flex: 1;
}

.mobile-tab {
    display: none;
}

.mobile-tab.active {
    display: block;
}

.card {
    background-color: white;
    border-radius: 15px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.08);
    margin-bottom: 20px;
    overflow: hidden;
    transition: transform 0.3s ease;
}

.card:hover {
    transform: translateY(-3px);
}

.card-title {
    font-size: 18px;
    padding: 16px;
    background: linear-gradient(135deg, #f8f9fa, #e9ecef);
    border-bottom: 1px solid #dee2e6;
    display: flex;
    align-items: center;
    gap: 10px;
    color: #1e5799;
    font-weight: 600;
}

.card-title i {
    color: #4a6cf7;
    font-size: 20px;
}

/* 表单样式 */
form {
    padding: 15px;
}

.form-group {
    margin-bottom: 16px;
    flex: 1;
    position: relative; /* 为建议框定位 */
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 500;
    color: #495057;
    font-size: 14px;
}

.form-group input, 
.form-group select {
    width: 100%;
    padding: 14px;
    border: 1px solid #ced4da;
    border-radius: 10px;
    font-size: 15px;
    transition: all 0.3s;
    background-color: #f8f9fa;
    box-shadow: inset 0 1px 3px rgba(0,0,0,0.05);
}

.form-group input:focus, 
.form-group select:focus {
    border-color: #4a6cf7;
    outline: none;
    background-color: #fff;
    box-shadow: 0 0 0 3px rgba(74, 108, 247, 0.15);
}

.form-row {
    display: flex;
    gap: 15px;
    margin-bottom: 0;
    flex-wrap: nowrap; /* 强制双排布局 */
}

.time-display {
    display: flex;
    align-items: center;
    flex-wrap: nowrap; /* 防止换行 */
    gap: 5px; /* 添加间距 */
    width: 100%; /* 确保容器宽度100% */
}

.time-display i {
    margin-right: 12px;
    color: #4a6cf7;
    font-size: 18px;
}

.time-display span {
    flex: 1;
    font-weight: 500;
}

.btn-group {
    display: flex;
    gap: 12px;
    margin-top: 25px;
}

.btn-group .btn {
    flex: 1;
    padding: 14px;
    font-size: 15px;
    border-radius: 10px;
    width: auto;
    height: auto;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    font-weight: 600;
}

/* 通联记录列表 */
.card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 16px;
    background: linear-gradient(135deg, #f8f9fa, #e9ecef);
    border-bottom: 1px solid #dee2e6;
}

.log-list {
    padding: 15px;
}

.log-item {
    border: 1px solid #e9ecef;
    border-radius: 12px;
    margin-bottom: 15px;
    overflow: hidden;
    box-shadow: 0 3px 8px rgba(0,0,0,0.05);
    transition: all 0.3s ease;
}

.log-item:hover {
    transform: translateY(-3px);
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
}

.log-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 14px 16px;
    background: linear-gradient(135deg, #f1f5f9, #e2e8f0);
    border-bottom: 1px solid #e9ecef;
}

.callsign {
    font-weight: bold;
    font-size: 17px;
    color: #1e5799;
}

.log-time {
    font-size: 13px;
    color: #6c757d;
    background-color: rgba(108, 117, 125, 0.1);
    padding: 4px 8px;
    border-radius: 20px;
}

/* 修改点：调整为3列布局 */
.log-details {
    display: grid;
    grid-template-columns: repeat(3, 1fr); /* 改为3列布局 */
    padding: 14px 16px;
    gap: 12px;
}

.detail-item {
    font-size: 13px; /* 缩小字体适应更多内容 */
    padding: 8px;
    background-color: #f8f9fa;
    border-radius: 8px;
}

.detail-item strong {
    display: block;
    color: #495057;
    font-weight: 500;
    margin-bottom: 5px;
    font-size: 13px;
}

.empty-state {
    text-align: center;
    padding: 40px 20px;
    color: #6c757d;
}

.empty-state i {
    font-size: 50px;
    color: #ced4da;
    margin-bottom: 15px;
    opacity: 0.7;
}

.empty-state p {
    margin-bottom: 8px;
    font-size: 15px;
}

/* 联系我们 - 竖向排列 */
.contact-vertical {
    display: flex;
    flex-direction: column;
    gap: 15px;
    padding: 0 16px 16px;
}

.contact-item {
    display: flex;
    align-items: center;
    padding: 14px;
    background: linear-gradient(135deg, #f8f9fa, #e9ecef);
    border-radius: 12px;
    border: 1px solid #e9ecef;
    box-shadow: 0 2px 5px rgba(0,0,0,0.05);
}

.contact-icon {
    width: 42px;
    height: 42px;
    background: linear-gradient(135deg, #4a6cf7, #1e5799);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-right: 14px;
    color: white;
    font-size: 20px;
    box-shadow: 0 3px 8px rgba(74, 108, 247, 0.2);
}

.contact-text h4 {
    font-size: 15px;
    margin-bottom: 5px;
    color: #1a1a1a;
}

.contact-text p {
    font-size: 14px;
    color: #495057;
}

.qr-code-container {
    padding: 0 16px 20px;
}

.section-title {
    font-size: 18px;
    margin-bottom: 15px;
    color: #1e5799;
    font-weight: 600;
    text-align: center;
    padding: 10px 0;
    border-bottom: 1px solid #e9ecef;
}

.qr-row {
    display: flex;
    gap: 20px;
    justify-content: center;
    flex-wrap: nowrap; /* 强制双排布局 */
}

.qr-code-box {
    text-align: center;
    flex: 1;
    min-width: 140px;
}

.qr-code-box h4 {
    margin-bottom: 12px;
    font-size: 16px;
    color: #1e5799;
    font-weight: 600;
}

.qr-code {
    width: 140px;
    height: 140px;
    border: 1px solid #e9ecef;
    border-radius: 12px;
    overflow: hidden;
    margin: 0 auto;
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
    background-color: white;
    padding: 8px;
}

.qr-code img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    border-radius: 8px;
}

/* 底部导航 */
.mobile-footer {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    display: flex;
    background-color: white;
    box-shadow: 0 -4px 15px rgba(0,0,0,0.1);
    z-index: 100;
    padding: 8px 0;
    border-top: 1px solid #e9ecef;
}

.nav-item {
    flex: 1;
    text-align: center;
    padding: 8px 0;
    color: #6c757d;
    font-size: 12px;
    cursor: pointer;
    transition: all 0.3s ease;
    position: relative;
}

.nav-item i {
    display: block;
    font-size: 22px;
    margin-bottom: 5px;
    transition: all 0.3s ease;
}

.nav-item.active {
    color: #4a6cf7;
    transform: translateY(-5px);
}

.nav-item.active i {
    color: #4a6cf7;
    transform: scale(1.15);
}

.nav-item::after {
    content: '';
    position: absolute;
    bottom: -8px;
    left: 50%;
    transform: translateX(-50%);
    width: 6px;
    height: 6px;
    background-color: #4a6cf7;
    border-radius: 50%;
    opacity: 0;
    transition: all 0.3s ease;
}

.nav-item.active::after {
    opacity: 1;
    bottom: 2px;
}

/* 通知 */
.notification {
    position: fixed;
    bottom: 90px;
    left: 50%;
    transform: translateX(-50%) translateY(100px);
    background: linear-gradient(135deg, #4a6cf7, #1e5799);
    color: white;
    padding: 14px 30px;
    border-radius: 30px;
    box-shadow: 0 5px 20px rgba(0,0,0,0.2);
    display: flex;
    align-items: center;
    gap: 12px;
    z-index: 1000;
    opacity: 0;
    transition: all 0.3s ease;
}

.notification.show {
    opacity: 1;
    transform: translateX(-50%) translateY(0);
}

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

/* 下载提示 */
.download-info {
    background: linear-gradient(135deg, #fff8e1, #ffecb3);
    border-left: 4px solid #ffc107;
    padding: 12px 15px;
    margin: 15px;
    border-radius: 8px;
    font-size: 14px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.download-info i {
    color: #ff9800;
    font-size: 20px;
}

.download-info a {
    color: #1e5799;
    font-weight: 600;
    text-decoration: none;
}

/* 动画效果 */
@keyframes fadeIn {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

.card {
    animation: fadeIn 0.5s ease forwards;
}

.highlight {
    background: linear-gradient(135deg, #e3f2fd, #bbdefb);
    border-left: 4px solid #2196f3;
    padding: 15px;
    margin: 15px 0;
    border-radius: 8px;
    font-weight: 500;
}

/* 移动版提示弹窗 */
.mobile-warning-modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: rgba(0,0,0,0.5);
    z-index: 2000;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.modal-content {
    background-color: white;
    border-radius: 15px;
    width: 100%;
    max-width: 400px;
    overflow: hidden;
    box-shadow: 0 10px 30px rgba(0,0,0,0.3);
    animation: modalAppear 0.4s ease;
}

@keyframes modalAppear {
    from { transform: translateY(50px); opacity: 0; }
    to { transform: translateY(0); opacity: 1; }
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 16px 20px;
    background: linear-gradient(135deg, #1e5799, #4a6cf7);
    color: white;
}

.modal-header h3 {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 18px;
    font-weight: 600;
}

.close-btn {
    background: none;
    border: none;
    color: white;
    font-size: 28px;
    cursor: pointer;
    opacity: 0.8;
    transition: opacity 0.3s;
}

.close-btn:hover {
    opacity: 1;
}

.modal-body {
    padding: 20px;
    font-size: 16px;
    line-height: 1.6;
    color: #333;
    border-bottom: 1px solid #eee;
}

.checkbox-group {
    margin-top: 20px;
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 14px;
}

.modal-footer {
    padding: 16px 20px;
    display: flex;
    justify-content: flex-end;
}

.modal-footer .btn {
    padding: 10px 25px;
    border-radius: 8px;
    font-size: 16px;
    width: auto;
    height: auto;
}

/* 响应式调整 */
@media (max-width: 480px) {
    .modal-content {
        max-width: 100%;
    }
}

/* 新增：可展开区块样式 */
.accordion-container {
    padding: 0 15px 15px;
}

.accordion-item {
    margin-bottom: 12px;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0,0,0,0.08);
    transition: all 0.3s ease;
}

.accordion-header {
    display: flex;
    align-items: center;
    padding: 16px;
    background: linear-gradient(135deg, #f8f9fa, #e9ecef);
    cursor: pointer;
    font-weight: 600;
    color: #1e5799;
    justify-content: space-between;
    transition: all 0.3s ease;
}

.accordion-header i:first-child {
    margin-right: 12px;
    font-size: 18px;
    width: 24px;
    text-align: center;
}

.accordion-header i:last-child {
    transition: transform 0.3s ease;
}

.accordion-item.active .accordion-header i:last-child {
    transform: rotate(180deg);
}

.accordion-content {
    max-height: 0;
    overflow: hidden;
    background-color: white;
    transition: max-height 0.3s ease;
    padding: 0 16px;
}

.accordion-item.active .accordion-content {
    max-height: 500px; /* 可根据内容调整 */
    padding: 16px;
    border-top: 1px solid #e9ecef;
}

/* 设备型号建议框样式 - 修复后 */
#device-model-suggestions {
    position: absolute;
    width: 100%;
    background: white;
    border: 1px solid #dadce0;
    border-top: none;
    border-radius: 0 0 8px 8px;
    max-height: 200px;
    overflow-y: auto;
    z-index: 10000; /* 确保足够高 */
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
    display: none;
}

.suggestion-item {
    padding: 12px 15px;
    border-bottom: 1px solid #eee;
    cursor: pointer;
    transition: background 0.2s;
    font-size: 16px;
}

.suggestion-item:last-child {
    border-bottom: none;
}

.suggestion-item:hover, 
.suggestion-item:active {
    background-color: #f5f7fa;
}

/* 日期时间输入框样式 */
.datetime-input {
    flex: 1;
    min-width: 0; /* 防止溢出 */
    border: none;
    background: transparent;
    font-size: 15px;
    padding: 0;
    font-weight: 500;
    resize: vertical;
    min-height: 30px;
    width: auto; /* 自动宽度 */
    max-width: none; /* 不限制最大宽度 */
}

/* 防止原生日期/时间控件溢出 */
input[type="date"], input[type="time"] {
    max-width: 100%;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* 调整时间显示容器 */
.time-display {
    display: flex;
    align-items: center;
    flex-wrap: nowrap;
    gap: 5px;
    width: 100%;
}

/* 确保按钮可见 */
.custom-datetime-btn {
    padding: 8px 12px;
    border-radius: 8px;
    color: white;
    border: none;
    white-space: nowrap;
    cursor: pointer;
    font-size: 12px;
    flex-shrink: 0; /* 防止按钮被压缩 */
}

/* 新增频率下拉菜单样式 */
.frequency-container {
    position: relative;
    width: 100%;
}

.frequency-input-group {
    display: flex;
}

#frequency {
    flex: 1;
    border-top-right-radius: 0;
    border-bottom-right-radius: 0;
}

.frequency-dropdown-btn {
    width: 40px;
    background-color: #f8f9fa;
    border: 1px solid #ced4da;
    border-left: none;
    border-radius: 0 10px 10px 0;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.3s;
}

.frequency-dropdown-btn:hover {
    background-color: #e9ecef;
}

.frequency-dropdown {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: white;
    border: 1px solid #dadce0;
    border-radius: 0 0 8px 8px;
    max-height: 200px;
    overflow-y: auto;
    display: none;
    z-index: 1000;
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
}

.frequency-item {
    padding: 10px 15px;
    border-bottom: 1px solid #eee;
    cursor: pointer;
    transition: background 0.2s;
    font-size: 15px;
}

.frequency-item:last-child {
    border-bottom: none;
}

.frequency-item:hover {
    background-color: #f5f7fa;
}
/* 信号报告选择框样式 */
#signal-select {
    padding: 10px;
    border: 1px solid #ced4da;
    border-radius: 10px;
    font-size: 15px;
    transition: all 0.3s;
    background-color: #f8f9fa;
    box-shadow: inset 0 1px 3px rgba(0,0,0,0.05);
    width: 100%;
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3e%3cpath fill='none' stroke='%23343a40' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M2 5l6 6 6-6'/%3e%3c/svg%3e");
    background-repeat: no-repeat;
    background-position: right 0.75rem center;
    background-size: 16px 12px;
    appearance: none;
}

#signal-select:focus {
    border-color: #4a6cf7;
    outline: none;
    box-shadow: 0 0 0 3px rgba(74, 108, 247, 0.15);
}

/* 信号报告输入框样式 */
#signal {
    padding: 10px;
    border: 1px solid #ced4da;
    border-radius: 10px;
    font-size: 15px;
    transition: all 0.3s;
    background-color: #f8f9fa;
    box-shadow: inset 0 1px 3px rgba(0,0,0,0.05);
    text-align: center;
    font-weight: bold;
    color: #1e5799;
}

#signal:focus {
    border-color: #4a6cf7;
    outline: none;
    box-shadow: 0 0 0 3px rgba(74, 108, 247, 0.15);
}