:root {
    --primary-red: #e64a19;
    --primary-hover: #e64a19;
    --bg-overlay: rgba(255, 255, 255, 0.9);
    --text-main: #333;
    --text-light: #666;
    --border-color: #ddd;
    --bg-gradient: linear-gradient(180deg, #e64a19 0%, #f4f4f4 40%);
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, "Microsoft YaHei", sans-serif;
}

body {
    background-color: #e64a19;
    color: var(--text-main);
    line-height: 1.5;
    /* Simulate the background pattern */
    /* background-image: radial-gradient(#e0e0e0 15%, transparent 16%), radial-gradient(#e0e0e0 15%, transparent 16%); */
    background-size: 20px 20px;
    background-position: 0 0, 10px 10px;
}

/* Container */
.container {
    max-width: 600px; /* Mobile focused */
    margin: 0 auto;
    padding: 10px;
    position: relative;
    z-index: 2;
    min-height: 100vh;
}

/* Header Banner */
.main-header {
    background: url('images/20251231100923_147_6.jpg') no-repeat center center;
    background-size: 100% 100%;
    height: 180px;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    color: white;
    text-align: center;
    box-shadow: 0 4px 6px rgba(0,0,0,0.1);
}

.main-header::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: transparent;
}

.header-content {
    display: none;
}

.header-content h1 {
    font-size: 24px;
    font-weight: bold;
    text-shadow: 0 2px 4px rgba(0,0,0,0.3);
    margin-bottom: 10px;
}

/* Skyline decoration placeholder */
.skyline-decoration {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 40px;
    background: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 20" preserveAspectRatio="none"><path d="M0 20 L0 10 L10 10 L10 5 L20 5 L20 15 L30 15 L30 8 L40 8 L40 20 Z" fill="rgba(255,255,255,0.2)"/></svg>');
    background-size: 100px 100%;
}

/* Cards/Sections */
.card {
    background: white;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.05);
    margin-top: -40px;
    margin-bottom: 20px;
    overflow: hidden;
}

.section-header {
    padding: 15px;
    border-bottom: 1px solid #eee;
    background: #e64a19;
}

.section-header.center {
    text-align: center;
}

.section-header h2 {
    font-size: 18px;
    font-weight: bold;
    color: white;
}

.section-body {
    padding: 20px;
}

/* View Handling */
.view {
    display: none;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.view.active {
    display: block;
    opacity: 1;
}

/* Rule Content */
.rule-content {
    font-size: 14px;
    color: #444;
    height: 400px;
    overflow-y: auto;
    padding-right: 10px;
    margin-bottom: 20px;
    text-align: justify;
}

.rule-content p {
    margin-bottom: 10px;
}

/* Checkbox */
.agreement-area {
    margin: 20px 0;
    padding-top: 15px;
    border-top: 1px solid #eee;
}

.checkbox-container {
    display: block;
    position: relative;
    padding-left: 30px;
    cursor: pointer;
    font-size: 15px;
    user-select: none;
}

.checkbox-container input {
    position: absolute;
    opacity: 0;
    cursor: pointer;
    height: 0;
    width: 0;
}

.checkmark {
    position: absolute;
    top: 2px;
    left: 0;
    height: 18px;
    width: 18px;
    border: 1px solid #ccc;
    border-radius: 3px;
    background-color: #fff;
}

.checkbox-container:hover input ~ .checkmark {
    border-color: #999;
}

.checkbox-container input:checked ~ .checkmark {
    background-color: var(--primary-red);
    border-color: var(--primary-red);
}

.checkmark:after {
    content: "";
    position: absolute;
    display: none;
}

.checkbox-container input:checked ~ .checkmark:after {
    display: block;
}

.checkbox-container .checkmark:after {
    left: 6px;
    top: 2px;
    width: 4px;
    height: 8px;
    border: solid white;
    border-width: 0 2px 2px 0;
    transform: rotate(45deg);
}

/* Buttons */
.action-buttons {
    display: flex;
    gap: 15px;
    justify-content: center;
    margin-top: 20px;
}

.btn {
    flex: 1;
    padding: 12px 0;
    border: none;
    border-radius: 4px;
    font-size: 16px;
    cursor: pointer;
    transition: all 0.3s;
    font-weight: bold;
}

.btn-primary {
    background-color: var(--primary-red);
    color: white;
}

.btn-primary:disabled {
    background-color: #ccc;
    cursor: not-allowed;
}

.full-width {
    width: 100%;
}

/* Unit Grid */
.unit-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 15px;
}

.unit-btn {
    background-color: #e64a19; /* Slightly orange/red */
    color: white;
    border: none;
    padding: 15px 10px;
    font-size: 13px;
    border-radius: 4px;
    cursor: pointer;
    min-height: 60px;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    transition: transform 0.1s, background-color 0.2s;
}

.unit-btn:hover {
    background-color: #e64a19;
    transform: translateY(-1px);
}

/* Form Styling */
.form-group {
    margin-bottom: 20px;
}

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

.required {
    color: #e64a19;
    margin-left: 4px;
}

input[type="text"],
textarea {
    width: 100%;
    padding: 10px;
    border: 1px solid #ddd;
    border-radius: 2px;
    font-size: 14px;
    background: #fff;
    box-shadow: inset 0 1px 2px rgba(0,0,0,0.05);
}

input[type="text"]:focus,
textarea:focus {
    border-color: var(--primary-red);
    outline: none;
}

.readonly-input {
    background-color: #e0e0e0;
    color: #333;
    cursor: not-allowed;
    border-color: #ccc;
}

/* Upload Box */
.upload-box {
    width: 80px;
    height: 80px;
    border: 1px solid #eee;
    background-color: #f5f5f5;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
}

.upload-box input {
    position: absolute;
    width: 100%;
    height: 100%;
    opacity: 0;
    cursor: pointer;
}

.plus-icon {
    font-size: 40px;
    color: #bbb;
    font-weight: 300;
}

/* Captcha */
.captcha-row {
    display: flex;
    gap: 10px;
    align-items: center;
}

.captcha-row input {
    flex: 1;
}

.captcha-img {
    width: 120px;
    height: 42px;
    background: #e8d5e0; /* Pinkish background from screenshot */
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: "Courier New", monospace;
    font-size: 24px;
    letter-spacing: 2px;
    color: #555;
    user-select: none;
    border: 1px solid #ccc;
    position: relative;
    overflow: hidden;
}

.captcha-img::before {
    content: '';
    position: absolute;
    top: 0; left: 0; right: 0; bottom: 0;
    background: linear-gradient(45deg, transparent 45%, rgba(0,0,0,0.1) 50%, transparent 55%);
    background-size: 10px 10px;
}

/* Submit Button */
.submit-btn {
    background-color: #e64a19; /* Orange-red */
    color: white;
    border: none;
    padding: 12px 0;
    font-size: 16px;
    border-radius: 4px;
    cursor: pointer;
    width: 100%;
    margin-top: 10px;
}

/* 分页控件样式 */
.pagination-controls {
    margin-top: 20px;
    display: flex;
    justify-content: center;
}

.pagination {
    display: flex;
    align-items: center;
    gap: 10px;
}

.pagination-btn {
    padding: 8px 16px;
    background-color: #f5f5f5;
    border: 1px solid #ddd;
    border-radius: 4px;
    cursor: pointer;
    font-size: 14px;
    color: #333;
    transition: all 0.2s;
}

.pagination-btn:hover:not(:disabled) {
    background-color: #e0e0e0;
}

.pagination-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.page-numbers {
    display: flex;
    gap: 5px;
}

.page-btn {
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    background-color: #f5f5f5;
    border: 1px solid #ddd;
    border-radius: 4px;
    cursor: pointer;
    font-size: 14px;
    color: #333;
    transition: all 0.2s;
}

.page-btn:hover {
    background-color: #e0e0e0;
}

.page-btn.active {
    background-color: var(--primary-red);
    color: white;
    border-color: var(--primary-red);
}
