|
|
|
|
|
|
|
body { |
|
font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif; |
|
margin: 0; |
|
background-color: #f0f0f0; |
|
display: flex; |
|
justify-content: center; |
|
align-items: flex-start; |
|
min-height: 100vh; |
|
padding: 20px 0; |
|
box-sizing: border-box; |
|
} |
|
|
|
.screen { |
|
width: 100%; |
|
max-width: 400px; |
|
background-color: #fff; |
|
border: 1px solid #ccc; |
|
min-height: 700px; |
|
box-shadow: 0 2px 8px rgba(0,0,0,0.1); |
|
display: flex; |
|
flex-direction: column; |
|
overflow: hidden; |
|
position: relative; |
|
} |
|
|
|
.header { |
|
display: flex; |
|
align-items: center; |
|
justify-content: space-between; |
|
padding: 10px 15px; |
|
background-color: #f8f8f8; |
|
border-bottom: 1px solid #eee; |
|
flex-shrink: 0; |
|
} |
|
|
|
.header .menu-btn, .header .action-btn { |
|
background: none; |
|
border: none; |
|
font-size: 24px; |
|
cursor: pointer; |
|
padding: 5px; |
|
color: #007bff; |
|
} |
|
.header .menu-btn:active, .header .action-btn:active { |
|
opacity: 0.7; |
|
} |
|
|
|
|
|
.header .action-btn { |
|
|
|
|
|
width: 30px; |
|
height: 30px; |
|
color: #007bff; |
|
|
|
|
|
|
|
|
|
} |
|
|
|
|
|
.header .title { |
|
font-size: 18px; |
|
font-weight: bold; |
|
margin: 0; |
|
text-align: center; |
|
flex-grow: 1; |
|
padding: 0 5px; |
|
white-space: nowrap; |
|
overflow: hidden; |
|
text-overflow: ellipsis; |
|
} |
|
|
|
main { |
|
padding: 15px; |
|
flex-grow: 1; |
|
overflow-y: auto; |
|
} |
|
|
|
|
|
ul.list { |
|
list-style: none; |
|
padding: 0; |
|
margin: 0; |
|
} |
|
|
|
li.list-item { |
|
border-bottom: 1px solid #eee; |
|
display: flex; |
|
align-items: center; |
|
justify-content: space-between; |
|
padding: 0; |
|
} |
|
li.list-item:last-child { |
|
border-bottom: none; |
|
} |
|
|
|
|
|
.list-item-button { |
|
display: flex; |
|
align-items: center; |
|
width: 100%; |
|
padding: 12px 15px; |
|
text-decoration: none; |
|
color: inherit; |
|
background-color: transparent; |
|
border: none; |
|
cursor: pointer; |
|
text-align: left; |
|
} |
|
.list-item-button:hover { |
|
background-color: #f9f9f9; |
|
} |
|
|
|
.list-item-content { |
|
display: flex; |
|
align-items: center; |
|
flex-grow: 1; |
|
margin-right: 10px; |
|
overflow: hidden; |
|
} |
|
|
|
.list-item-icon { |
|
margin-right: 12px; |
|
font-size: 22px; |
|
color: #007bff; |
|
width: 24px; |
|
text-align: center; |
|
flex-shrink: 0; |
|
} |
|
|
|
.list-item-text { |
|
overflow: hidden; |
|
} |
|
|
|
|
|
.list-item-text h3 { |
|
font-size: 16px; |
|
margin: 0 0 4px 0; |
|
font-weight: 500; |
|
white-space: nowrap; |
|
overflow: hidden; |
|
text-overflow: ellipsis; |
|
} |
|
|
|
.list-item-text p { |
|
font-size: 13px; |
|
color: #777; |
|
margin: 0; |
|
white-space: nowrap; |
|
overflow: hidden; |
|
text-overflow: ellipsis; |
|
} |
|
|
|
.list-arrow { |
|
color: #ccc; |
|
font-size: 20px; |
|
flex-shrink: 0; |
|
} |
|
|
|
|
|
.card { |
|
background-color: #fff; |
|
padding: 30px 20px; |
|
border-radius: 12px; |
|
border: 1px solid #eee; |
|
box-shadow: 0 2px 5px rgba(0,0,0,0.05); |
|
text-align: center; |
|
margin: 15px 0; |
|
min-height: 180px; |
|
display: flex; |
|
flex-direction: column; |
|
justify-content: center; |
|
align-items: center; |
|
cursor: pointer; |
|
transition: background-color 0.2s; |
|
} |
|
.card:active { |
|
background-color: #f0f0f0; |
|
} |
|
|
|
.card p.main-text { |
|
margin: 0; |
|
line-height: 1.7; |
|
font-size: 16px; |
|
max-width: 100%; |
|
} |
|
.card p.answer-text { |
|
margin-top: 15px; |
|
font-size: 18px; |
|
font-weight: bold; |
|
color: #007bff; |
|
max-width: 100%; |
|
} |
|
.tap-to-show { |
|
text-align: center; |
|
color: #888; |
|
font-size: 14px; |
|
margin-top: 10px; |
|
cursor: pointer; |
|
padding: 5px; |
|
} |
|
|
|
|
|
.pagination { |
|
display: flex; |
|
justify-content: space-between; |
|
align-items: center; |
|
padding: 15px 0 5px 0; |
|
flex-shrink: 0; |
|
} |
|
.pagination button { |
|
background: none; |
|
border: none; |
|
font-size: 30px; |
|
color: #007bff; |
|
cursor: pointer; |
|
padding: 5px 15px; |
|
border-radius: 8px; |
|
transition: background-color 0.2s; |
|
} |
|
.pagination button:active:not(:disabled) { |
|
background-color: rgba(0, 123, 255, 0.1); |
|
} |
|
|
|
.pagination button:disabled { |
|
color: #ccc; |
|
cursor: default; |
|
} |
|
.pagination span { |
|
font-size: 16px; |
|
font-weight: 500; |
|
} |
|
|
|
|
|
.settings-item { |
|
display: flex; |
|
justify-content: space-between; |
|
align-items: center; |
|
width: 100%; |
|
} |
|
.settings-item span { |
|
flex-grow: 1; |
|
padding-left: 12px; |
|
} |
|
|
|
|
|
.toggle-switch { |
|
position: relative; |
|
display: inline-block; |
|
width: 50px; |
|
height: 24px; |
|
cursor: pointer; |
|
flex-shrink: 0; |
|
} |
|
.toggle-switch input { |
|
opacity: 0; |
|
width: 0; |
|
height: 0; |
|
} |
|
.slider { |
|
position: absolute; |
|
cursor: pointer; |
|
top: 0; |
|
left: 0; |
|
right: 0; |
|
bottom: 0; |
|
background-color: #ccc; |
|
transition: .3s; |
|
border-radius: 24px; |
|
} |
|
.slider:before { |
|
position: absolute; |
|
content: ""; |
|
height: 18px; |
|
width: 18px; |
|
left: 3px; |
|
bottom: 3px; |
|
background-color: white; |
|
transition: .3s; |
|
border-radius: 50%; |
|
} |
|
input:checked + .slider { |
|
background-color: #007bff; |
|
} |
|
input:checked + .slider:before { |
|
transform: translateX(26px); |
|
} |
|
|
|
.section-title { |
|
color: #666; |
|
font-size: 14px; |
|
font-weight: 500; |
|
margin: 20px 0 8px 0; |
|
padding-left: 15px; |
|
} |
|
|
|
.logout { |
|
color: red; |
|
font-weight: bold; |
|
} |
|
|
|
|
|
.input-area { |
|
text-align: center; |
|
padding-top: 40px; |
|
} |
|
.input-area h2 { |
|
font-size: 20px; |
|
font-weight: bold; |
|
margin-bottom: 25px; |
|
line-height: 1.4; |
|
} |
|
.input-area input[type="text"] { |
|
width: calc(100% - 44px); |
|
padding: 12px 15px; |
|
border: 1px solid #ccc; |
|
border-radius: 8px; |
|
font-size: 16px; |
|
margin-bottom: 20px; |
|
box-sizing: border-box; |
|
} |
|
.input-area .generate-button { |
|
background-color: #ff3b30; |
|
color: white; |
|
border: none; |
|
padding: 12px 25px; |
|
font-size: 16px; |
|
font-weight: bold; |
|
border-radius: 25px; |
|
cursor: pointer; |
|
display: inline-flex; |
|
align-items: center; |
|
justify-content: center; |
|
margin: 0 auto 25px auto; |
|
transition: background-color 0.2s, opacity 0.2s; |
|
} |
|
.input-area .generate-button:hover { |
|
background-color: #e03024; |
|
} |
|
.input-area .generate-button:disabled { |
|
background-color: #ff3b30; |
|
opacity: 0.6; |
|
cursor: not-allowed; |
|
} |
|
.input-area .generate-button .button-text { |
|
|
|
} |
|
.input-area .generate-button .icon { |
|
margin-left: 8px; |
|
font-size: 14px; |
|
} |
|
.input-area .loading-spinner { |
|
|
|
} |
|
@keyframes spin { |
|
to { transform: rotate(360deg); } |
|
} |
|
|
|
|
|
.image-placeholder { |
|
width: 85%; |
|
max-width: 300px; |
|
aspect-ratio: 16 / 9; |
|
background-color: #e9e9e9; |
|
border: 1px dashed #ccc; |
|
display: flex; |
|
align-items: center; |
|
justify-content: center; |
|
color: #aaa; |
|
margin: 0 auto; |
|
border-radius: 10px; |
|
overflow: hidden; |
|
} |
|
.image-placeholder img { |
|
display: block; |
|
width: 100%; |
|
height: 100%; |
|
object-fit: cover; |
|
} |
|
.error-message { |
|
color: red; |
|
font-size: 13px; |
|
margin-top: -15px; |
|
margin-bottom: 15px; |
|
min-height: 1em; |
|
text-align: center; |
|
padding: 0 15px; |
|
} |
|
|
|
|
|
|
|
.footer-nav { |
|
position: fixed; |
|
bottom: 0; |
|
left: 0; |
|
width: 100%; |
|
background-color: #f8f8f8; |
|
border-top: 1px solid #e0e0e0; |
|
display: flex; |
|
justify-content: space-around; |
|
padding: 4px 0 calc(env(safe-area-inset-bottom, 0px) + 8px) 0; |
|
box-shadow: 0 -1px 4px rgba(0,0,0,0.08); |
|
z-index: 100; |
|
} |
|
|
|
.footer-nav button { |
|
background: none; |
|
border: none; |
|
cursor: pointer; |
|
padding: 5px; |
|
display: flex; |
|
flex-direction: column; |
|
align-items: center; |
|
font-size: 10px; |
|
color: #888; |
|
flex-grow: 1; |
|
transition: color 0.2s ease; |
|
} |
|
.footer-nav button:active { |
|
opacity: 0.7; |
|
} |
|
|
|
.footer-nav .nav-icon { |
|
font-size: 22px; |
|
margin-bottom: 2px; |
|
} |
|
|
|
.footer-nav button.active { |
|
color: #007bff; |
|
} |
|
|
|
|
|
|
|
main { |
|
padding-bottom: calc(env(safe-area-inset-bottom, 0px) + 80px); |
|
} |
|
|
|
|
|
.loading-spinner { |
|
border: 3px solid rgba(0, 0, 0, 0.1); |
|
border-left-color: #007bff; |
|
border-radius: 50%; |
|
width: 16px; |
|
height: 16px; |
|
animation: spin 1s linear infinite; |
|
display: inline-block; |
|
margin-right: 8px; |
|
vertical-align: middle; |
|
} |
|
|
|
.generate-button .loading-spinner { |
|
border-color: rgba(255, 255, 255, 0.3); |
|
border-left-color: #fff; |
|
} |
|
|
|
@keyframes spin { |
|
0% { transform: rotate(0deg); } |
|
100% { transform: rotate(360deg); } |
|
} |
|
|
|
|
|
|
|
#mode-indicator.loading { |
|
color: #888; |
|
} |
|
|
|
|
|
.option-button { |
|
display: block; |
|
width: calc(100% - 20px); |
|
margin: 10px auto; |
|
padding: 15px; |
|
font-size: 16px; |
|
border: 1px solid #ccc; |
|
border-radius: 8px; |
|
background-color: #fff; |
|
color: #333; |
|
cursor: pointer; |
|
transition: background-color 0.2s, border-color 0.2s, color 0.2s, opacity 0.2s; |
|
text-align: left; |
|
} |
|
.option-button:hover:not(:disabled) { |
|
background-color: #f0f0f0; |
|
} |
|
.option-button:active:not(:disabled) { |
|
background-color: #e0e0e0; |
|
} |
|
|
|
|
|
.option-button.correct { |
|
background-color: #d4edda; |
|
color: #155724; |
|
border-color: #c3e6cb; |
|
font-weight: bold; |
|
} |
|
|
|
.option-button.incorrect { |
|
background-color: #f8d7da; |
|
color: #721c24; |
|
border-color: #f5c6cb; |
|
opacity: 0.8; |
|
} |
|
|
|
.option-button:disabled { |
|
cursor: default; |
|
opacity: 0.7; |
|
} |
|
.option-button.correct:disabled { |
|
opacity: 1; |
|
} |
|
.option-button.incorrect:disabled { |
|
opacity: 0.7; |
|
} |
|
|
|
.option-button.other-disabled:disabled { |
|
background-color: #e9ecef; |
|
color: #6c757d; |
|
border-color: #ced4da; |
|
opacity: 0.6; |
|
} |
|
|
|
|
|
|
|
.correct-effect { |
|
position: fixed; |
|
top: 45%; |
|
left: 50%; |
|
transform: translate(-50%, -50%) scale(0.8); |
|
font-size: 15rem; |
|
color: rgba(0, 190, 0, 0.8); |
|
font-weight: bold; |
|
display: none; |
|
align-items: center; |
|
justify-content: center; |
|
z-index: 1001; |
|
opacity: 0; |
|
transition: opacity 0.3s ease-out, transform 0.3s ease-out; |
|
pointer-events: none; |
|
width: 20rem; |
|
height: 20rem; |
|
|
|
|
|
line-height: 1; |
|
} |
|
|
|
|
|
.correct-effect.show { |
|
display: flex; |
|
opacity: 1; |
|
transform: translate(-50%, -50%) scale(1); |
|
} |
|
|
|
|
|
|
|
|
|
body.dark-mode { |
|
background-color: #121212; |
|
color: #e0e0e0; |
|
} |
|
body.dark-mode .screen { background-color: #1e1e1e; border-color: #333; } |
|
body.dark-mode .header { background-color: #1f1f1f; border-bottom-color: #333; } |
|
body.dark-mode .header .title, body.dark-mode .header .menu-btn, body.dark-mode .header .action-btn { color: #e0e0e0; } |
|
body.dark-mode .footer-nav { background-color: #1f1f1f; border-top-color: #333; } |
|
body.dark-mode .footer-nav button { color: #888; } |
|
body.dark-mode .footer-nav button.active { color: #58a6ff; } |
|
body.dark-mode .card { background-color: #2c2c2c; border-color: #444; color: #e0e0e0; } |
|
body.dark-mode .card:active { background-color: #3a3a3a; } |
|
body.dark-mode .list-item-button:hover { background-color: #3a3a3a; } |
|
body.dark-mode li.list-item { border-bottom-color: #444; } |
|
body.dark-mode .list-item-text h3 { color: #e0e0e0; } |
|
body.dark-mode .list-item-text p { color: #aaa; } |
|
body.dark-mode .list-arrow { color: #aaa; } |
|
body.dark-mode .settings-item span { color: #e0e0e0; } |
|
body.dark-mode .section-title { color: #aaa; } |
|
body.dark-mode input[type="text"] { background-color: #333; border-color: #555; color: #e0e0e0; } |
|
body.dark-mode .generate-button { background-color: #e53e3e; color: white; } |
|
body.dark-mode .generate-button:hover { background-color: #c53030; } |
|
body.dark-mode .generate-button:disabled { background-color: #e53e3e; opacity: 0.6; } |
|
body.dark-mode .error-message { color: #ff7f7f; } |
|
body.dark-mode .option-button { background-color: #444; color: #e0e0e0; border-color: #666; } |
|
body.dark-mode .option-button:hover:not(:disabled) { background-color: #555; } |
|
body.dark-mode .option-button:active:not(:disabled) { background-color: #666; } |
|
body.dark-mode .option-button.correct { background-color: #2a6831; color: #e0e0e0; border-color: #41984b; } |
|
body.dark-mode .option-button.incorrect { background-color: #8b3a3e; color: #ffdddd; border-color: #a85055; opacity: 0.8; } |
|
body.dark-mode .option-button.other-disabled:disabled { background-color: #333; color: #888; border-color: #555; opacity: 0.6; } |
|
body.dark-mode .pagination button { color: #58a6ff; } |
|
body.dark-mode .pagination button:active:not(:disabled) { background-color: rgba(88, 166, 255, 0.15); } |
|
body.dark-mode .pagination button:disabled { color: #666; } |
|
body.dark-mode .tap-to-show { color: #aaa; } |
|
body.dark-mode .mode-indicator { color: #bbb; } |
|
body.dark-mode .toggle-switch .slider { background-color: #555; } |
|
body.dark-mode .toggle-switch input:checked + .slider { background-color: #58a6ff; } |
|
|
|
body.dark-mode .correct-effect { color: rgba(50, 220, 50, 0.85); } |
|
|
|
|
|
|
|
|
|
|
|
.side-menu { |
|
position: fixed; |
|
top: 0; |
|
left: 0; |
|
width: 250px; |
|
height: 100%; |
|
background-color: #ffffff; |
|
box-shadow: 2px 0 5px rgba(0,0,0,0.1); |
|
transform: translateX(-100%); |
|
transition: transform 0.3s ease-in-out; |
|
z-index: 1100; |
|
padding: 20px; |
|
box-sizing: border-box; |
|
display: flex; |
|
flex-direction: column; |
|
overflow-y: auto; |
|
} |
|
|
|
.side-menu.open { |
|
transform: translateX(0); |
|
} |
|
|
|
.side-menu h2 { |
|
margin-top: 30px; |
|
margin-bottom: 20px; |
|
font-size: 20px; |
|
color: #333; |
|
border-bottom: 1px solid #eee; |
|
padding-bottom: 10px; |
|
} |
|
|
|
.side-menu ul { |
|
list-style: none; |
|
padding: 0; |
|
margin: 0; |
|
flex-grow: 1; |
|
} |
|
|
|
.side-menu li { |
|
margin-bottom: 5px; |
|
} |
|
|
|
.side-menu li button { |
|
background: none; |
|
border: none; |
|
padding: 12px 10px; |
|
width: 100%; |
|
text-align: left; |
|
font-size: 16px; |
|
color: #333; |
|
cursor: pointer; |
|
border-radius: 6px; |
|
transition: background-color 0.2s; |
|
display: flex; |
|
align-items: center; |
|
} |
|
.side-menu li button:hover { |
|
background-color: #f0f0f0; |
|
} |
|
.side-menu li button:active { |
|
background-color: #e0e0e0; |
|
} |
|
|
|
.side-menu li hr { |
|
border: none; |
|
border-top: 1px solid #eee; |
|
margin: 15px 0; |
|
} |
|
|
|
.side-menu .logout-menu-item { |
|
color: red; |
|
} |
|
.side-menu .logout-menu-item:hover { |
|
background-color: rgba(255, 0, 0, 0.05); |
|
} |
|
|
|
|
|
.close-menu-btn { |
|
position: absolute; |
|
top: 10px; |
|
right: 15px; |
|
background: none; |
|
border: none; |
|
font-size: 30px; |
|
font-weight: bold; |
|
color: #888; |
|
cursor: pointer; |
|
padding: 5px; |
|
line-height: 1; |
|
} |
|
.close-menu-btn:hover { |
|
color: #333; |
|
} |
|
|
|
|
|
.menu-overlay { |
|
position: fixed; |
|
top: 0; |
|
left: 0; |
|
width: 100%; |
|
height: 100%; |
|
background-color: rgba(0, 0, 0, 0.5); |
|
opacity: 0; |
|
visibility: hidden; |
|
transition: opacity 0.3s ease-in-out, visibility 0s 0.3s; |
|
z-index: 1050; |
|
} |
|
|
|
.menu-overlay.open { |
|
opacity: 1; |
|
visibility: visible; |
|
transition: opacity 0.3s ease-in-out, visibility 0s 0s; |
|
} |
|
|
|
|
|
body.menu-open { |
|
overflow: hidden; |
|
} |
|
|
|
|
|
body.dark-mode .side-menu { |
|
background-color: #2c2c2c; |
|
box-shadow: 2px 0 5px rgba(0,0,0,0.3); |
|
} |
|
body.dark-mode .side-menu h2 { |
|
color: #e0e0e0; |
|
border-bottom-color: #444; |
|
} |
|
body.dark-mode .side-menu li button { |
|
color: #e0e0e0; |
|
} |
|
body.dark-mode .side-menu li button:hover { |
|
background-color: #3a3a3a; |
|
} |
|
body.dark-mode .side-menu li button:active { |
|
background-color: #4a4a4a; |
|
} |
|
body.dark-mode .side-menu li hr { |
|
border-top-color: #444; |
|
} |
|
body.dark-mode .close-menu-btn { |
|
color: #aaa; |
|
} |
|
body.dark-mode .close-menu-btn:hover { |
|
color: #e0e0e0; |
|
} |
|
body.dark-mode .side-menu .logout-menu-item { |
|
color: #ff7f7f; |
|
} |
|
body.dark-mode .side-menu .logout-menu-item:hover { |
|
background-color: rgba(255, 80, 80, 0.1); |
|
} |
|
|
|
|
|
|