/* ===========================
   Math Learning Hour
   Addition - Grade 2
=========================== */

*{
    margin:0;
    padding:0;
    box-sizing:border-box;
}

body{
    font-family:Arial, Helvetica, sans-serif;
    background:#f4f8fc;
    color:#333;
    line-height:1.6;
}

/* ===========================
   Header
=========================== */

header{
    background:#2c7be5;
    color:white;
    text-align:center;
    padding:40px 20px;
}

header h1{
    font-size:40px;
    margin-bottom:10px;
}

.subtitle{
    font-size:20px;
}

/* ===========================
   Main Container
=========================== */

.container{
    max-width:900px;
    margin:40px auto;
    padding:20px;
}

/* ===========================
   Sections
=========================== */

.lesson,
.quiz-section,
.content,
#resultSection{
    background:white;
    padding:30px;
    border-radius:15px;
    margin-bottom:35px;
    box-shadow:0 5px 18px rgba(0,0,0,0.12);
}

.lesson h2,
.quiz-section h2,
.content h2{
    color:#2c7be5;
    margin-bottom:15px;
}

.lesson p,
.content p,
.content li{
    font-size:18px;
    margin-bottom:15px;
}

/* ===========================
   Example Box
=========================== */

.example-box{
    background:#eef6ff;
    border-left:6px solid #2c7be5;
    padding:20px;
    margin-top:25px;
    border-radius:10px;
}

.example-box h3{
    margin-bottom:20px;
}

.sum{
    width:170px;
    margin:25px auto;
    text-align:right;
    font-size:34px;
    font-weight:bold;
}

.sum hr{
    border:2px solid #333;
    margin:8px 0;
}

.answer{
    color:#28a745;
}

/* ===========================
   Quiz Box
=========================== */

.quiz-box{
    text-align:center;
}

/* ===========================
   Progress Bar
=========================== */

.progress{
    width:100%;
    height:18px;
    background:#ddd;
    border-radius:20px;
    overflow:hidden;
    margin-bottom:25px;
}

#progressBar{
    width:10%;
    height:100%;
    background:#28a745;
    transition:0.4s;
}

/* ===========================
   Question
=========================== */

.question-number{
    font-size:20px;
    font-weight:bold;
    margin-bottom:25px;
}

.question{
    width:180px;
    margin:30px auto;
    text-align:right;
    font-size:48px;
    font-weight:bold;
}

.question hr{
    border:2px solid black;
    margin:8px 0;
}

/* ===========================
   Input
=========================== */

input[type="number"]{
    width:280px;
    padding:15px;
    font-size:24px;
    text-align:center;
    border:2px solid #2c7be5;
    border-radius:10px;
    outline:none;
}

input[type="number"]:focus{
    border-color:#28a745;
}

/* Remove arrows */

input::-webkit-inner-spin-button,
input::-webkit-outer-spin-button{
    -webkit-appearance:none;
    margin:0;
}

input[type="number"]{
    appearance: textfield;
    -moz-appearance: textfield;
}

/* ===========================
   Buttons
=========================== */

button{
    padding:14px 30px;
    font-size:18px;
    border:none;
    border-radius:10px;
    cursor:pointer;
    margin:10px;
    transition:0.3s;
}

#checkBtn{
    background:#28a745;
    color:white;
}

#checkBtn:hover{
    background:#1e7d34;
}

#nextBtn{
    background:#2c7be5;
    color:white;
}

#nextBtn:hover{
    background:#1e63bc;
}

/* ===========================
   Feedback
=========================== */

#feedback{
    font-size:22px;
    font-weight:bold;
    margin-top:25px;
    min-height:35px;
}

.correct{
    color:#28a745;
}

.wrong{
    color:#dc3545;
}

/* ===========================
   Score
=========================== */

.score{
    font-size:24px;
    margin-top:20px;
    font-weight:bold;
}

/* ===========================
   Result Section
=========================== */

#resultSection{
    text-align:center;
}

#resultSection h2{
    color:#28a745;
    font-size:38px;
    margin-bottom:20px;
}

#resultSection h3{
    font-size:48px;
    color:#2c7be5;
    margin:20px 0;
}

#resultSection button{
    background:#ff9800;
    color:white;
}

#resultSection button:hover{
    background:#e08700;
}

/* ===========================
   SEO Content
=========================== */

.content ul{
    padding-left:25px;
}

.content li{
    margin-bottom:12px;
}

.content h3{
    margin-top:25px;
    color:#444;
}

/* ===========================
   Footer
=========================== */

footer{
    text-align:center;
    background:#2c7be5;
    color:white;
    padding:25px;
    margin-top:50px;
}

/* ===========================
   Utility
=========================== */

.hidden{
    display:none;
}

/* ===========================
   Responsive
=========================== */

@media(max-width:768px){

header h1{
    font-size:30px;
}

.subtitle{
    font-size:18px;
}

.lesson,
.quiz-section,
.content,
#resultSection{
    padding:20px;
}

.question{
    font-size:34px;
}

input[type="number"]{
    width:180px;
    font-size:22px;
}

button{
    width:100%;
    margin-top:15px;
}

.sum{
    font-size:28px;
}

#resultSection h3{
    font-size:38px;
}

}
/* ===========================
   Quick Examples
=========================== */

.examples{
    margin-top:40px;
}

.example-grid{
    display:grid;
    grid-template-columns:repeat(auto-fit,minmax(180px,1fr));
    gap:18px;
    margin-top:20px;
}

.example-card{
    background:#f8fbff;
    border:2px solid #d9e9ff;
    border-radius:12px;
    padding:18px;
    text-align:center;
    box-shadow:0 3px 10px rgba(0,0,0,.08);
}

.example-card h3{
    color:#2c7be5;
    font-size:20px;
    margin-bottom:15px;
}

.example-card p{
    margin-top:15px;
    font-size:15px;
}

/* ===========================
   Addition Table
=========================== */

.addition-table{
    margin:auto;
    border-collapse:collapse;
}

.addition-table td{
    width:30px;
    height:30px;
    text-align:center;
    font-size:28px;
    font-weight:bold;
}

.operator{
    color:#2c7be5;
    width:20px;
}

.answer-row{
    color:#28a745;
}

.line{
    width:100%;
    border-top:4px solid #333;
    margin:2px 0;
}

/* ===========================
   Carry Box
=========================== */

.carry td{
    height:18px;
}

.carry-box{
    display:inline-flex;
    justify-content:center;
    align-items:center;
    width:16px;
    height:16px;
    background:#ff9800;
    color:#fff;
    font-size:11px;
    font-weight:bold;
    border-radius:4px;
}
/* ===========================
   Golden Rule
=========================== */


.golden-rule{
    margin:40px 0;
}

.rule-box{
    background:#fff8e1;
    border:3px solid #f4c542;
    border-radius:12px;
    padding:25px;
    text-align:center;
}

.rule-text{
    font-size:20px;
    margin-bottom:20px;
}

.highlight{
    color:#e65100;
    font-weight:bold;
}

.golden-table{
    margin:20px auto;
    border-collapse:collapse;
}

.golden-table td{
    width:35px;
    height:35px;
    text-align:center;
    font-size:32px;
    font-weight:bold;
}

.golden-table .operator{
    color:#2c7be5;
}

.line{
    border-top:4px solid #333;
    width:100%;
}

.pointer{
    margin-top:10px;
    font-size:18px;
    color:#d32f2f;
    font-weight:bold;
}

.note{
    margin-top:20px;
    font-size:18px;
    color:#333;
}
.arrow-row td{
    font-size:28px;
    color:#e53935;
    padding-top:5px;
}

.arrow-text td{
    font-size:14px;
    color:#e53935;
    font-weight:bold;
}
.top-nav{
    max-width:900px;
    margin:20px auto;
    text-align:center;

}

.home-btn{
    display:inline-block;
    background:#2c7be5;
    color:#fff;
    text-decoration:none;
    padding:10px 18px;
    border-radius:8px;
    font-weight:bold;
    transition:.3s;
}

.home-btn:hover{
    background:#1b5fc8;
}