py-learn / src /app /reading /reading.component.css
Anupriya
duplicate removed
a5d3fab
.reading-container {
font-family: 'Segoe UI', sans-serif;
background-size: auto;
background-position: center;
background-attachment: fixed;
width: 100%;
height: 100%;
}
.main-container {
width: 85%;
margin: 5vh auto;
border: 9px solid var(--main-accent-color);
border-radius: 1.5vw;
background: #fff;
padding: 2vw;
box-shadow: 0 .4vw 1vw rgba(0,0,0,.1);
height: 76vh;
position: relative;
background: #fff;
overflow: visible;
}
.intro-section.split {
padding-inline: 1vw;
display: block;
}
.split-shell {
width: 100%;
max-width: none;
margin: 0 auto;
display: grid;
grid-template-columns: minmax(320px, 38%) 1fr;
align-items: center;
}
.split-left {
display: grid;
place-items: center;
}
.intro-illustration {
width: 60%;
}
.hero-title {
font-size: 2.5vw;
font-weight: 800;
color: #006780;
margin-bottom: 20px;
font-family: raleway;
}
.hero-copy {
font-size: 1.4vw;
text-align: justify;
margin-bottom: 3vw;
}
.form-row {
display: flex;
align-items: center;
gap: 12px;
margin-top: 12px;
}
.row-label {
min-width: 140px;
font-weight: 700;
color: #006780;
font-size: 1.3vw;
}
.input-wrap, .select-wrap {
position: relative;
flex: 1;
}
.input-wrap input,
.select-wrap select {
width: 100%;
min-width: 220px;
font-size: 1.1rem;
padding: 14px 44px 14px 40px;
border-radius: 12px;
border: 1px solid #cfe2e0;
background: #fff;
color: #0e3e45;
outline: 0;
transition: border-color .2s, box-shadow .2s;
box-sizing: border-box;
}
.select-wrap select,
.select-wrap option {
font-size: 1.1rem;
}
.input-wrap input::placeholder {
color: #93a3b8;
}
.input-wrap input:focus, .select-wrap select:focus {
border-color: #009688;
box-shadow: 0 0 0 3px rgba(0,150,136,.12);
}
.icon-search, .icon-level {
position: absolute;
left: 12px;
top: 50%;
transform: translateY(-50%);
width: 18px;
height: 18px;
opacity: .8;
pointer-events: none;
}
.icon-search::before {
content: "🔎";
font-size: 16px;
}
.icon-level::before {
content: "🎯";
font-size: 16px;
}
.badge {
position: absolute;
right: 10px;
top: 50%;
transform: translateY(-50%);
font-size: 12px;
padding: 4px 8px;
border-radius: 999px;
border: 1px solid #cfe2e0;
background: #f7fcfb;
color: #0e3e45;
}
.badge[data-level="easy"] {
border-color: #bfe6d8;
color: #1b7f57;
background: #ecfbf4;
}
.badge[data-level="medium"] {
border-color: #c7e3f4;
color: #0b74a6;
background: #eef8ff;
}
.badge[data-level="hard"] {
border-color: #f9dfc8;
color: #b35a11;
background: #fff3e9;
}
.intro-section.split .suggestion-box {
position: absolute;
top: calc(100% + 8px);
left: 0;
z-index: 20;
width: 100%;
max-height: 200px;
overflow: auto;
padding: 6px;
border-radius: 12px;
border: 1px solid #cfe2e0;
background: #fff;
box-shadow: 0 12px 28px rgba(0,0,0,.12);
}
.intro-section.split .suggestion-box span {
display: block;
padding: 10px 12px;
border-radius: 10px;
cursor: pointer;
color: #0e3e45;
}
.intro-section.split .suggestion-box span:hover,
.intro-section.split .suggestion-box span.active {
background: #f1fbfa;
}
.input-wrap.clearable {
position: relative;
}
.input-wrap .has-clear {
padding-right: 44px;
}
.clear-btn {
right: 12px;
top: 4px;
position: absolute;
background: #009688;
border: none;
width: 44px;
height: 44px;
border-radius: 50%;
display: flex;
align-items: center;
justify-content: center;
font-size: 2vw;
color: black;
cursor: pointer;
z-index: 2010;
box-shadow: 0 2px 8px rgba(93, 145, 195, 0.18);
transition: background 0.2s, color 0.2s;
}
.clear-btn:hover {
background: white;
color: black;
border: 3px solid #009688;
}
@media (max-width: 980px) {
.split-shell {
grid-template-columns: 1fr;
gap: 16px;
}
.row-label {
min-width: 110px;
}
}
:root {
--passage-font: 21px;
}
.reading-head {
display: grid;
grid-template-columns: 44px 1fr auto;
align-items: center;
gap: 10px;
margin-bottom: 6px;
}
.reading-title {
margin: 0;
text-align: center;
color: #006780;
font-size: clamp(20px, 2.2vw, 39px);
letter-spacing: .3px;
font-weight: 800;
}
.head-actions {
display: flex;
gap: 8px;
}
.head-actions .icon-btn {
background: #f7fcfb;
border: 1px solid #cfe2e0;
border-radius: 8px;
padding: 0.4em 1.1em;
font-size: 1.2vw;
color: #009688;
font-weight: 700;
cursor: pointer;
transition: background 0.15s, border-color 0.15s, color 0.15s;
outline: none;
min-width: 2.5em;
min-height: 2.5em;
display: flex;
align-items: center;
justify-content: center;
}
.head-actions .icon-btn:hover,
.head-actions .icon-btn.active {
background: #e0f7f4;
border-color: #009688;
color: #00695c;
}
.head-actions .icon-btn[aria-pressed="true"] {
background: #b2dfdb;
color: #004d40;
}
.reading-meta {
display: flex;
flex-wrap: wrap;
gap: 8px;
margin: 4px 4px 12px;
}
.chip {
display: inline-flex;
align-items: center;
gap: 6px;
padding: 6px 10px;
border-radius: 999px;
font-weight: 600;
font-size: 13px;
border: 1px solid #d9ecea;
background: #f7fcfb;
color: #0e3e45;
}
.chip-level[data-level="easy"] {
border-color: #bfe6d8;
background: #ecfbf4;
color: #1b7f57;
}
.chip-level[data-level="medium"] {
border-color: #c7e3f4;
background: #eef8ff;
color: #0b74a6;
}
.chip-level[data-level="hard"] {
border-color: #f9dfc8;
background: #fff3e9;
color: #b35a11;
}
.passage-shell {
position: relative;
border: 1px solid #e7f1f0;
border-radius: 14px;
background: #f3efef;
padding: 14px 16px;
box-shadow: inset 0 1px 0 rgba(255,255,255,.7);
max-height: 43vh;
overflow: auto;
font-size: 1.4vw;
line-height: 1.8;
}
.passage-shell::-webkit-scrollbar {
width: 12px;
}
.passage-shell::-webkit-scrollbar-thumb {
background: #cfe2e0;
border-radius: 10px;
border: 3px solid #fff;
}
.passage-shell::-webkit-scrollbar-track {
background: #f7fcfb;
}
.passage-text {
font-family: Georgia, "Times New Roman", serif;
font-size: var(--passage-font);
line-height: 1.5;
color: #1e3a3f;
text-align: left;
hyphens: auto;
white-space: pre-wrap;
word-wrap: break-word;
}
.passage-text span {
transition: background-color 0.3s ease;
}
.passage-text .highlight {
background-color: yellow;
}
.passage-text::first-letter {
float: left;
font-size: 2.6em;
line-height: .9;
padding-right: 6px;
padding-top: 2px;
color: #0f7f78;
font-weight: 700;
}
.reading-actions {
display: flex;
gap: 10px;
justify-content: center;
margin-top: 30px;
}
.back {
grid-column: 1 / 2;
}
@media (max-width: 720px) {
.reading-title {
font-size: 22px;
}
}
.mcq-card {
width: 100%;
margin: 0;
background: #fff;
border: 1px solid #d9ecea;
border-radius: 16px;
padding: 16px;
box-shadow: 0 10px 24px rgba(0,0,0,.06);
}
.mcq-card__header {
display: grid;
grid-template-columns: 44px 1fr 44px;
align-items: center;
gap: 10px;
margin-bottom: 10px;
font-size: 2vw;
}
.mcq-card__title {
margin: 0;
text-align: center;
color: #0e3e45;
font-weight: 800;
letter-spacing: .2px;
}
.mcq-card__actions {
display: flex;
justify-content: flex-end;
}
.quiz-pill {
display: flex;
align-items: flex-start;
gap: 10px;
padding: 12px 14px;
border-radius: 12px;
border: 1px solid #e6f0ef;
background: #f8fbfb;
color: #0e3e45;
font-size: 1.5vw;
}
.quiz-question-pill {
margin-bottom: 3vw;
}
.qq-label {
font-weight: 700;
color: #0b74a6;
white-space: nowrap;
}
.qq-text {
flex: 1;
line-height: 1.6;
}
.quiz-options {
list-style: none;
margin: 0;
padding: 0;
display: grid;
grid-template-columns: 1fr 1fr;
gap: 10px;
}
@media (max-width: 720px) {
.quiz-options {
grid-template-columns: 1fr;
}
}
.quiz-option-pill {
display: flex;
align-items: center;
gap: 10px;
padding: 12px 14px;
border-radius: 12px;
border: 1px solid #dfe9e7;
background: #ffffff;
cursor: pointer;
transition: box-shadow .15s, transform .05s, border-color .15s, background .15s;
}
.quiz-option-pill:hover {
box-shadow: 0 8px 18px rgba(0,0,0,.06);
background: #f7fbfb;
}
.quiz-option-pill .slot {
font-weight: 700;
color: #0b74a6;
min-width: 26px;
}
.quiz-option-pill .opt-text {
color: #0e3e45;
}
.quiz-option-pill.is-selected {
border-color: #a8d8d3;
background: #eefaf8;
}
.quiz-option-pill.is-correct {
border-color: #6cc090;
background: #ecfbf4;
}
.quiz-option-pill.is-incorrect {
border-color: #f2b0a9;
background: #fff1ef;
}
.visually-hidden {
position: absolute !important;
inset: auto auto auto auto !important;
width: 1px;
height: 1px;
overflow: hidden;
clip: rect(1px,1px,1px,1px);
white-space: nowrap;
}
.answer-status {
display: flex;
flex-wrap: wrap;
align-items: normal;
gap: 8px;
margin-top: 12px;
justify-content: center;
font-size: 1vw;
margin-top: 2vw;
}
.status-chip {
padding: 6px 10px;
border-radius: 999px;
font-weight: 700;
font-size: 12px;
}
.status-chip.ok {
background: #ecfbf4;
color: #1b7f57;
border: 1px solid #bfe6d8;
}
.status-chip.nope {
background: #ffe9e7;
color: #b1241a;
border: 1px solid #f4b2ab;
}
.status-help {
color: #3a5b60;
}
.mcq-card__footer {
display: flex;
gap: 10px;
justify-content: end;
margin-top: 6vw;
align-items: flex-end;
justify-content: space-between;
}
.loader-overlay {
position: absolute;
top: 0;
left: 0;
width: 100%;
height: 100%;
display: flex;
justify-content: center;
align-items: center;
z-index: 1000;
}
.loader {
font-size: 15px;
width: 1.5em;
height: 1.5em;
border-radius: 50%;
position: relative;
text-indent: -9999em;
animation: mulShdSpin 1.1s infinite ease;
transform: translateZ(0);
}
@keyframes mulShdSpin {
0%, 100% {
box-shadow: 0em -3em 0em 0em #808080, 2.2em -2.2em 0 0em rgba(128, 128, 128, 0.2), 3em 0em 0 0em rgba(128, 128, 128, 0.2), 2.2em 2.2em 0 0em rgba(128, 128, 128, 0.2), 0em 3em 0 0em rgba(128, 128, 128, 0.2), -2.2em 2.2em 0 0em rgba(128, 128, 128, 0.2), -3em 0em 0 0em rgba(128, 128, 128, 0.5), -2.2em -2.2em 0 0em rgba(128, 128, 128, 0.7);
}
12.5% {
box-shadow: 0em -3em 0em 0em rgba(128, 128, 128, 0.7), 2.2em -2.2em 0 0em #808080, 3em 0em 0 0em rgba(128, 128, 128, 0.2), 2.2em 2.2em 0 0em rgba(128, 128, 128, 0.2), 0em 3em 0 0em rgba(128, 128, 128, 0.2), -2.2em 2.2em 0 0em rgba(128, 128, 128, 0.2), -3em 0em 0 0em rgba(128, 128, 128, 0.2), -2.2em -2.2em 0 0em rgba(128, 128, 128, 0.5);
}
25% {
box-shadow: 0em -3em 0em 0em rgba(128, 128, 128, 0.5), 2.2em -2.2em 0 0em rgba(128, 128, 128, 0.7), 3em 0em 0 0em #808080, 2.2em 2.2em 0 0em rgba(128, 128, 128, 0.2), 0em 3em 0 0em rgba(128, 128, 128, 0.2), -2.2em 2.2em 0 0em rgba(128, 128, 128, 0.2), -3em 0em 0 0em rgba(128, 128, 128, 0.2), -2.2em -2.2em 0 0em rgba(128, 128, 128, 0.2);
}
37.5% {
box-shadow: 0em -3em 0em 0em rgba(128, 128, 128, 0.2), 2.2em -2.2em 0 0em rgba(128, 128, 128, 0.5), 3em 0em 0 0em rgba(128, 128, 128, 0.7), 2.2em 2.2em 0 0em #808080, 0em 3em 0 0em rgba(128, 128, 128, 0.2), -2.2em 2.2em 0 0em rgba(128, 128, 128, 0.2), -3em 0em 0 0em rgba(128, 128, 128, 0.2), -2.2em -2.2em 0 0em rgba(128, 128, 128, 0.2);
}
50% {
box-shadow: 0em -3em 0em 0em rgba(128, 128, 128, 0.2), 2.2em -2.2em 0 0em rgba(128, 128, 128, 0.2), 3em 0em 0 0em rgba(128, 128, 128, 0.5), 2.2em 2.2em 0 0em rgba(128, 128, 128, 0.7), 0em 3em 0 0em #808080, -2.2em 2.2em 0 0em rgba(128, 128, 128, 0.2), -3em 0em 0 0em rgba(128, 128, 128, 0.2), -2.2em -2.2em 0 0em rgba(128, 128, 128, 0.2);
}
62.5% {
box-shadow: 0em -3em 0em 0em rgba(128, 128, 128, 0.2), 2.2em -2.2em 0 0em rgba(128, 128, 128, 0.2), 3em 0em 0 0em rgba(128, 128, 128, 0.2), 2.2em 2.2em 0 0em rgba(128, 128, 128, 0.5), 0em 3em 0 0em rgba(128, 128, 128, 0.7), -2.2em 2.2em 0 0em #808080, -3em 0em 0 0em rgba(128, 128, 128, 0.2), -2.2em -2.2em 0 0em rgba(128, 128, 128, 0.2);
}
75% {
box-shadow: 0em -3em 0em 0em rgba(128, 128, 128, 0.2), 2.2em -2.2em 0 0em rgba(128, 128, 128, 0.2), 3em 0em 0 0em rgba(128, 128, 128, 0.2), 2.2em 2.2em 0 0em rgba(128, 128, 128, 0.2), 0em 3em 0 0em rgba(128, 128, 128, 0.5), -2.2em 2.2em 0 0em rgba(128, 128, 128, 0.7), -3em 0em 0 0em #808080, -2.2em -2.2em 0 0em rgba(128, 128, 128, 0.2);
}
87.5% {
box-shadow: 0em -3em 0em 0em rgba(128, 128, 128, 0.2), 2.2em -2.2em 0 0em rgba(128, 128, 128, 0.2), 3em 0em 0 0em rgba(128, 128, 128, 0.2), 2.2em 2.2em 0 0em rgba(128, 128, 128, 0.2), 0em 3em 0 0em rgba(128, 128, 128, 0.2), -2.2em 2.2em 0 0em rgba(128, 128, 128, 0.5), -3em 0em 0 0em rgba(128, 128, 128, 0.7), -2.2em -2.2em 0 0em #808080;
}
}
.popup-overlay {
position: fixed;
top: 0;
left: 0;
width: 100vw;
height: 100vh;
background-color: rgba(0, 0, 0, 0.5);
display: flex;
justify-content: center;
align-items: center;
z-index: 1000;
}
.popup-content {
background-color: #fff;
padding: 2vw;
border-radius: 0.5vw;
box-shadow: 0 0.4vw 0.8vw rgba(0, 0, 0, 0.3);
text-align: center;
max-width: 40vw;
width: 80%;
}
.popup-content p {
font-size: 1.4vw;
color: #dc3545;
margin-bottom: 1vw;
}
@keyframes popupScale {
from {
transform: scale(.96);
opacity: .85;
}
to {
transform: scale(1);
opacity: 1;
}
}
.input-wrap.locked input {
background: #f7f9fb;
border-color: #dfe9e7;
color: #93a3b8;
cursor: not-allowed;
}
.input-wrap.locked .icon-search {
opacity: .5;
}
.input-wrap.locked::after {
content: "";
position: absolute;
inset: 0;
border-radius: 12px;
pointer-events: auto;
}
.field-hint {
margin: 6px 2px 0;
font-size: 12px;
color: #738a95;
display: inline-flex;
align-items: center;
gap: 6px;
}
.lock-icon::before {
content: "🔒";
font-size: 14px;
line-height: 1;
}
.input-wrap .has-clear {
padding-right: 44px;
}
.icon-img {
width: 4.5vw;
cursor: pointer;
transition: transform 0.3s;
}
.icon-img:hover, .icon-img:focus {
transform: scale(1.1);
}
.passage-text .highlight {
background-color: yellow;
}
.congrats-overlay {
position: fixed;
inset: 0;
display: grid;
place-items: center;
}
.congrats-card {
text-align: center;
margin: 47px auto;
padding: 40px;
background: white;
border-radius: 15px;
width: 70vw;
height: 70vh;
display: flex;
flex-direction: column;
justify-content: center;
align-items: center;
font-family: 'Pacifico', cursive;
position: relative;
z-index: 1;
box-shadow: 0 .4vw 1vw rgba(0, 0, 0, .1);
border: 9px solid var(--main-accent-color);
top: 3vw;
}
.congrats-card h2 {
margin: 8px 0 6px;
color: #0e3e45;
font-weight: 800;
color: #4ca1af;
margin-bottom: 15px;
font-size: 2.5vw;
white-space: nowrap;
overflow: hidden;
text-overflow: ellipsis;
text-align: center;
}
.congrats-card p {
margin: 0 0 16px;
color: #0e3e45;
margin-bottom: 15px;
font-size: 2.5vw;
white-space: nowrap;
overflow: hidden;
text-overflow: ellipsis;
text-align: center;
}
.score-badge {
display: inline-flex;
align-items: baseline;
gap: 6px;
margin-bottom: 10px;
padding: 10px 14px;
border-radius: 999px;
background: #eef7f6;
color: #0e3e45;
font-weight: 800;
margin-bottom: 15px;
font-size: 2.5vw;
white-space: nowrap;
overflow: hidden;
text-overflow: ellipsis;
text-align: center;
}
.user-guide-close-icon {
right: -21px;
top: -21px;
}