* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}
body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    min-height: 100vh;
    padding: 40px 20px;
}
.container {
    max-width: 1100px;
    margin: 0 auto;
    background-color: white;
    padding: 50px 20px;
    border-radius: 16px;
    box-shadow: 0 20px 60px rgba(0,0,0,0.3);
}
h1 {
    text-align: center;
    color: #2c3e50;
    margin-bottom: 40px;
    font-size: 32px;
    font-weight: 600;
    letter-spacing: 1px;
}
.form-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 15px;
}
.form-group {
    margin-bottom: 5px;
}
.form-group.full-width {
    grid-column: 1 / -1;
}
label {
    display: block;
    margin-bottom: 8px;
    font-weight: 500;
    color: #34495e;
    font-size: 14px;
}
input[type="text"],
input[type="number"],
input[type="date"],
select,
textarea {
    width: 100%;
    max-width: 100%;
    padding: 12px 16px;
    border: 2px solid #e0e0e0;
    border-radius: 8px;
    font-size: 15px;
    transition: all 0.3s ease;
    background-color: #fafafa;
    box-sizing: border-box;
}
input[type="date"] {
    -webkit-appearance: none;
    -moz-appearance: none;
    appearance: none;
}
input[type="date"]::-webkit-calendar-picker-indicator {
    cursor: pointer;
    opacity: 0.6;
}
input[type="date"]::-webkit-calendar-picker-indicator:hover {
    opacity: 1;
}
input[type="number"]::-webkit-inner-spin-button,
input[type="number"]::-webkit-outer-spin-button {
    -webkit-appearance: none;
    margin: 0;
}
input[type="number"]::-webkit-inner-spin-button {
    -webkit-appearance: none;
    cursor: pointer;
    display: block;
    width: 20px;
    height: 50%;
    text-align: center;
    line-height: 25px;
}
input[type="number"]::-webkit-inner-spin-button:hover {
    background-color: #e0e0e0;
}
input[type="number"]::-webkit-inner-spin-button:active {
    background-color: #d0d0d0;
}
input[type="number"]::-webkit-inner-spin-button::-webkit-spin-up {
    border-bottom: 1px solid #e0e0e0;
}
input[type="number"]::-webkit-inner-spin-button::-webkit-spin-down {
    border-top: 1px solid #e0e0e0;
}
input[type="number"]::-moz-inner-spin-button,
input[type="number"]::-moz-outer-spin-button {
    -moz-appearance: none;
    margin: 0;
}
input[type="number"]::-moz-inner-spin-button {
    -moz-appearance: none;
    cursor: pointer;
    display: block;
    width: 20px;
    height: 50%;
    text-align: center;
    line-height: 25px;
}
input[type="number"]::-moz-inner-spin-button:hover {
    background-color: #e0e0e0;
}
input[type="number"]::-moz-inner-spin-button:active {
    background-color: #d0d0d0;
}
input[type="text"]:focus,
input[type="number"]:focus,
input[type="date"]:focus,
select:focus,
textarea:focus {
    outline: none;
    border-color: #667eea;
    background-color: white;
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
}
input[type="text"]:hover,
input[type="number"]:hover,
input[type="date"]:hover,
select:hover,
textarea:hover {
    border-color: #b0b0b0;
}
textarea {
    resize: vertical;
    min-height: 150px;
    font-family: inherit;
}
.radio-group {
    display: flex;
    gap: 30px;
    padding: 10px 16px;
    background-color: #fafafa;
    border: 2px solid #e0e0e0;
    border-radius: 8px;
}
.radio-group label {
    font-weight: normal;
    display: flex;
    align-items: center;
    cursor: pointer;
    margin-bottom: 0;
}
.radio-group input[type="radio"] {
    margin-right: 8px;
    width: 18px;
    height: 18px;
    cursor: pointer;
}

/* 产品搜索样式 */
.search-wrapper {
    position: relative;
    width: 100%;
}

.product-suggestions {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: white;
    border: 2px solid #667eea;
    border-radius: 8px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
    max-height: 200px;
    overflow-y: auto;
    z-index: 1000;
    list-style: none;
    padding: 8px 0;
    margin: 4px 0 0 0;
    display: none;
}

.product-suggestions li {
    padding: 10px 16px;
    cursor: pointer;
    transition: all 0.2s ease;
    font-size: 14px;
    color: #34495e;
}

.product-suggestions li:hover {
    background-color: #f0f4ff;
    color: #667eea;
}

.product-suggestions li.highlighted {
    background-color: #f0f4ff;
    color: #667eea;
}
.file-upload {
    border: 2px dashed #d0d0d0;
    padding: 40px;
    text-align: center;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s ease;
    background-color: #fafafa;
}
.file-upload:hover {
    border-color: #667eea;
    background-color: #f0f4ff;
}
.file-upload input[type="file"] {
    display: none;
}
.file-upload p {
    margin: 5px 0;
    color: #666;
}
.file-upload p:first-child {
    font-size: 16px;
    font-weight: 500;
    color: #333;
}
.submit-btn {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 16px 40px;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    font-size: 16px;
    font-weight: 600;
    width: 100%;
    margin-top: 30px;
    transition: all 0.3s ease;
    letter-spacing: 1px;
}
.submit-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 20px rgba(102, 126, 234, 0.4);
}
.submit-btn:active {
    transform: translateY(0);
}
@media (max-width: 768px) {
    .form-grid {
        grid-template-columns: 1fr;
    }
    .container {
        padding: 30px 20px;
    }
    h1 {
        font-size: 24px;
    }
}

.admin-buttons {
    display: flex;
    flex-direction: column;
    gap: 20px;
    max-width: 400px;
    margin: 0 auto;
}

.admin-btn {
    display: block;
    width: 66.67%;
    padding: 15px 30px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    font-size: 16px;
    font-weight: 600;
    text-decoration: none;
    transition: all 0.3s ease;
    text-align: center;
    margin: 0 auto;
}

.admin-btn:hover:not(.disabled) {
    transform: translateY(-2px);
    box-shadow: 0 10px 20px rgba(102, 126, 234, 0.4);
}

.admin-btn.disabled {
    background: #ccc;
    cursor: not-allowed;
    opacity: 0.6;
}

.admin-btn.logout-btn {
    background: linear-gradient(135deg, #ff6b6b 0%, #ee5a5a 100%);
}

.admin-btn.logout-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 20px rgba(255, 107, 107, 0.4);
}

.footer-mark {
    text-align: center;
    margin: 20px auto 0;
    font-size: 14px;
    font-weight: 500;
    color: rgba(255, 255, 255, 0.8);
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
    max-width: 1100px;
    padding: 0 20px;
}

.beian-info {
    text-align: center;
    margin: 10px auto 0;
    font-size: 14px;
    max-width: 1100px;
    padding: 0 20px;
}

.beian-info a {
    color: rgba(255, 255, 255, 0.8);
    text-decoration: none;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
}

.beian-info a:hover {
    text-decoration: underline;
}
@font-face {
    font-family: 'RuiSongCu';
    src: url('/assets/fonts/锐字云字库锐宋粗简-闪(REEJI-CloudRuiSongCuGB-Flash).ttf') format('truetype');
    font-weight: bold;
    font-style: normal;
}
@font-face {
    font-family: 'SourceHanSerifCN';
    src: url('/assets/fonts/SourceHanSerifCN-Bold.otf') format('opentype');
    font-weight: bold;
    font-style: normal;
}
@media screen and (orientation: portrait) {
    .rotate-device {
        display: flex !important;
    }
}
.rotate-device {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.9);
    z-index: 9999;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    color: white;
    text-align: center;
    padding: 20px;
}
.rotate-device-icon {
    font-size: 60px;
    margin-bottom: 20px;
    animation: rotate 2s infinite;
}
@keyframes rotate {
    0% { transform: rotate(0deg); }
    25% { transform: rotate(90deg); }
    50% { transform: rotate(90deg); }
    75% { transform: rotate(0deg); }
    100% { transform: rotate(0deg); }
}
.rotate-device-text {
    font-size: 18px;
    line-height: 1.6;
}
.main-layout {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 30px;
    margin-top: 30px;
}
.data-section {
    background: #fafafa;
    border: 2px solid #e0e0e0;
    border-radius: 8px;
    padding: 25px;
    align-self: start;
}
.data-section h2 {
    color: #2c3e50;
    margin-bottom: 20px;
    font-size: 20px;
    font-weight: 600;
}
.data-list {
    list-style: none;
    padding: 0;
    margin: 0;
}
.data-item {
    padding: 10px 0;
    border-bottom: 1px solid #e0e0e0;
    cursor: pointer;
    transition: background-color 0.2s ease;
    display: flex;
    justify-content: space-between;
    align-items: center;
}
.data-checkbox {
    width: 18px;
    height: 18px;
    cursor: pointer;
    margin-right: 6px;
}
.data-item-content {
    flex: 1;
    display: flex;
    align-items: center;
}
.data-item:hover {
    background-color: #f0f4ff;
}
.data-item:last-child {
    border-bottom: none;
}
.data-item.selected {
    background-color: #e8f4fd;
    border-left: 4px solid #667eea;
}
.data-label {
    color: #666;
    font-size: 14px;
}
.data-value {
    color: #2c3e50;
    font-size: 16px;
    font-weight: 500;
}
.data-meta {
    font-size: 12px;
    color: #999;
    margin-top: 5px;
}
.edit-btn {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border: none;
    border-radius: 6px;
    padding: 6px 15px;
    cursor: pointer;
    font-size: 12px;
    font-weight: 600;
    transition: all 0.3s ease;
}
.edit-btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 8px rgba(102, 126, 234, 0.3);
}
.empty-data {
    text-align: center;
    padding: 40px 20px;
    color: #999;
}
.select-all-container {
    display: flex;
    align-items: center;
    padding: 10px 0;
    border-bottom: 1px solid #e0e0e0;
}
.select-all-checkbox {
    width: 18px;
    height: 18px;
    cursor: pointer;
    margin-right: 8px;
}
.select-all-container label {
    cursor: pointer;
    color: #666;
    font-size: 14px;
}
input.issue-number-input {
    margin-left: auto;
    padding: 6px !important;
    border: 1px solid #ddd !important;
    border-radius: 4px !important;
    font-size: 14px !important;
    width: 80px !important;
    max-width: 80px !important;
    flex-shrink: 0;
    text-align: left;
    box-sizing: border-box;
    cursor: text;
    background-color: #fff !important;
}
.preview-section {
    background: #fafafa;
    border: 2px solid #e0e0e0;
    border-radius: 8px;
    padding: 25px 25px 25px 25px;
    padding-top: 90px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-start;
    min-height: 400px;
    position: relative;
}
.preview-section h2 {
    color: #2c3e50;
    margin-bottom: 20px;
    font-size: 20px;
    font-weight: 600;
}
.preview-container {
    width: 100%;
    height: auto;
    overflow: visible;
    position: relative;
    display: flex;
    justify-content: center;
    align-items: flex-start;
}
.generate-poster-btn {
    position: absolute;
    top: 25px;
    left: 25px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border: none;
    border-radius: 8px;
    padding: 12px 30px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 6px rgba(102, 126, 234, 0.2);
}
.generate-poster-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 12px rgba(102, 126, 234, 0.4);
}
.generate-poster-btn:active {
    transform: translateY(0);
}
.preview-placeholder {
    text-align: center;
    color: #999;
    width: 414px;
    min-height: 400px;
    background-image: url('/assets/images/bg.png');
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    padding: 22px 15px 15px;
    margin: 0 auto;
    box-sizing: border-box;
}
.poster-content {
    background-image: url('/assets/images/grain.png');
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    width: 100%;
    height: 100%;
    border-radius: 8px;
    padding: 0 1.66px 12px;
}
.poster-title {
    margin: 0;
    padding: 6.66px 2.66px 2px 13.32px;
    font-size: 16px;
    font-weight: bold;
    color: #333;
    text-align: left;
    font-family: 'SourceHanSerifCN', "Source Han Serif CN", "Noto Serif CJK SC", "思源宋体", "STSong", "SimSun", serif;
}
.poster-divider {
    width: 100%;
    height: 6.66px;
    background-image: url('/assets/images/titleBoder.png');
    background-size: 100% 100%;
    background-repeat: no-repeat;
    background-position: center;
}
.poster-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 6.66px 13.32px 0;
}
.poster-header-left {
    font-size: 50px;
    font-weight: normal;
    color: #333;
    font-family: 'RuiSongCu', "Source Han Serif CN", "Noto Serif CJK SC", "思源宋体", "STSong", "SimSun", serif;
    margin-top: 6px;
}
.poster-header-right {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 3.33px;
}
.poster-date {
    font-size: 17.32px;
    font-weight: bold;
    color: #333;
    font-family: 'SourceHanSerifCN', "Source Han Serif CN", "Noto Serif CJK SC", "思源宋体", "STSong", "SimSun", serif;
}
.poster-issue {
    font-size: 15px;
    font-weight: bold;
    color: #333;
    font-family: 'SourceHanSerifCN', "Source Han Serif CN", "Noto Serif CJK SC", "思源宋体", "STSong", "SimSun", serif;
    background-color: #f6d53a;
    padding: 0 3px;
}
.poster-header-border {
    width: 100%;
    height: 6.66px;
    background-image: url('/assets/images/headerBoder.png');
    background-size: contain;
    background-repeat: repeat-x;
    background-position: center;
    margin-top: -2px;
}
.poster-background-text {
    font-size: 22.64px;
    font-weight: bold;
    color: #333;
    font-family: "SimSun", "宋体", "Songti SC", "STSong", serif;
    text-align: center;
    padding: 30px 0 0;
    letter-spacing: 4px;
    position: relative;
    z-index: 10;
    transform: translateX(3px);
}
.poster-background-border {
    width: 110px;
    height: 12px;
    background-image: url('/assets/images/textBorder.png');
    background-size: 110px 12px;
    background-repeat: no-repeat;
    margin: -10px auto 0;
    position: relative;
    z-index: 1;
}
.poster-content-text {
    padding: 20px 0 0 10px;
    text-align: left;
    font-family: "SimSun", "宋体", "Songti SC", "STSong", serif;
    font-size: 15.84px;
    font-weight: bold;
}
.poster-content-border {
    width: 306px;
    height: 3px;
    background-image: url('/assets/images/contentBoder.png');
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    margin: 10px auto 0;
}
.poster-content-item {
    display: flex;
    margin-bottom: 8px;
    line-height: 1.2;
}
.poster-content-label {
    color: #000;
    min-width: 70px;
    flex-shrink: 0;
}
.poster-content-value {
    color: #000;
    flex: 1;
}
.poster-content-value.underline {
    flex: none;
    display: inline;
    border-bottom: 1px solid currentColor;
}
.underline {
    display: inline;
    border-bottom: 1px solid currentColor;
}
.poster-case-text {
    font-size: 22.64px;
    font-weight: bold;
    color: #333;
    font-family: "SimSun", "宋体", "Songti SC", "STSong", serif;
    text-align: center;
    padding: 30px 0 0;
    letter-spacing: 4px;
    position: relative;
    z-index: 10;
    transform: translateX(3px);
}
.poster-case-border {
    width: 110px;
    height: 12px;
    background-image: url('/assets/images/textBorder.png');
    background-size: 110px 12px;
    background-repeat: no-repeat;
    margin: -10px auto 0;
    position: relative;
    z-index: 1;
}
.poster-case-content {
    padding: 30px 10px 0;
    font-size: 15.77px;
    font-weight: bold;
    color: #000;
    font-family: "SimSun", "宋体", "Songti SC", "STSong", serif;
    line-height: 1.4;
}
.poster-case-content p {
    margin: 0 0 18px 0;
    text-align: justify;
}
.poster-case-content p:last-child {
    margin-bottom: 0;
}
.poster-background {
    width: 20px;
    height: 20px;
    background-color: #EDD35A;
    border: 1px solid white;
}
.poster-case-book {
    padding: 15px 10px 0;
    text-align: center;
}
.poster-case-book img {
    max-width: 70%;
    height: auto;
    display: block;
    margin: 0 auto;
}
.poster-logo {
    padding: 20px 5px 0;
    text-align: center;
}
.poster-logo img {
    width: 100%;
    height: auto;
    display: block;
    margin: 0 auto;
}
.pagination {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 10px;
    margin-top: 20px;
}
.pagination-btn {
    padding: 8px 16px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    font-size: 14px;
    font-weight: 600;
    transition: all 0.3s ease;
}
.pagination-btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 8px rgba(102, 126, 234, 0.3);
}
.pagination-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    transform: none;
}
.pagination-info {
    color: #666;
    font-size: 14px;
}
@media (max-width: 768px) {
    .main-layout {
        grid-template-columns: 1fr;
    }
    .preview-placeholder {
        width: 248.4px;
        min-height: 240px;
        padding: 13.2px 11.2px 9px;
    }
    .poster-content {
        padding: 0 1px 4px;
    }
    .poster-title {
        padding: 4px 1.6px 1.2px 8px;
        font-size: 9.6px;
    }
    .poster-divider {
        height: 4px;
    }
    .poster-header {
        padding: 4px 8px;
    }
    .poster-header-left {
        font-size: 32px;
    }
    .poster-header-right {
        gap: 2px;
    }
    .poster-date {
        font-size: 10.4px;
    }
    .poster-issue {
        font-size: 15px;
    }
    .poster-header-border {
        height: 4px;
    }
    .poster-background-text {
        font-size: 14px;
        font-weight: bold;
        padding: 18.5px 0 0;
        letter-spacing: 2.5px;
        position: relative;
        z-index: 10;
        transform: translateX(1px);
        font-family: "SimSun", "宋体", "Songti SC", "STSong", serif;
    }
    .poster-background-border {
        width: 36.6px;
        height: 4px;
        background-image: url('/assets/images/textBorder.png');
        background-size: 36.6px 4px;
        background-repeat: no-repeat;
        margin: -6.2px auto 0;
        position: relative;
        z-index: 1;
    }
    .poster-content-text {
        padding: 6.6px 0 0 3.33px;
        text-align: left;
        font-family: "SimSun", "宋体", "Songti SC", "STSong", serif;
        font-size: 5.2752px;
        font-weight: bold;
    }
    .poster-content-border {
        width: 102px;
        height: 1px;
        background-image: url('/assets/images/contentBoder.png');
        background-size: cover;
        background-position: center;
        background-repeat: no-repeat;
        margin: 3.3px auto 0;
    }
    .poster-case-text {
        font-size: 7.546666666666667px;
        font-weight: bold;
        color: #333;
        font-family: "SimSun", "宋体", "Songti SC", "STSong", serif;
        text-align: center;
        padding: 10px 0 0;
        letter-spacing: 1.3333333333333333px;
        position: relative;
        z-index: 10;
        transform: translateX(1px);
    }
    .poster-case-border {
        width: 36.666666666666664px;
        height: 4px;
        background-image: url('/assets/images/textBorder.png');
        background-size: 36.666666666666664px 4px;
        background-repeat: no-repeat;
        margin: -3.3333333333333335px auto 0;
        position: relative;
        z-index: 1;
    }
    .poster-case-content {
        padding: 10px 3.33px 0;
        font-size: 5.256666666666667px;
        font-weight: bold;
        color: #000;
        font-family: "SimSun", "宋体", "Songti SC", "STSong", serif;
        line-height: 1.4;
    }
    .poster-case-content p {
        margin: 0 0 5px 0;
        text-align: justify;
    }
    .poster-case-content p:last-child {
        margin-bottom: 0;
    }
    .poster-case-book {
        padding: 3.33px 3.33px 0;
        text-align: center;
    }
    .poster-case-book img {
        max-width: 70%;
        height: auto;
        display: block;
        margin: 0 auto;
    }
    .poster-logo {
        padding: 6.66px 1.665px 0;
        text-align: center;
    }
    .poster-logo img {
        width: 100%;
        height: auto;
        display: block;
        margin: 0 auto;
    }
    .poster-content-item {
        margin-bottom: 2.6px;
        line-height: 1.2;
    }
    .poster-content-label {
        min-width: 23.3px;
        color: #000;
    }
    .poster-content-value {
        color: #000;
    }
    .poster-content-value.underline {
        display: inline;
        border-bottom: 0.333px solid currentColor;
    }
    .underline {
        display: inline;
        border-bottom: 0.333px solid currentColor;
    }
}