/* ========================================================= */
/* PHPJS / INF03 */
/* ========================================================= */

.example-box{

    background:var(--surface);

    border-radius:22px;

    padding:35px;

    margin:40px 0;

    border:1px solid var(--border);

    box-shadow:
    0 8px 24px rgba(0,0,0,0.08);

    transition:.35s;

    position:relative;

    overflow:hidden;
}

.example-box:hover{

    transform:translateY(-4px);

    box-shadow:
    0 16px 34px rgba(14,165,233,0.16);
}

/* ========================================================= */
/* NUMBER */
/* ========================================================= */

.example-number{

    position:absolute;

    top:0;

    right:0;

    background:
    linear-gradient(
    135deg,
    #0ea5e9,
    #0284c7
    );

    color:white;

    padding:12px 22px;

    border-bottom-left-radius:18px;

    font-weight:bold;

    font-size:18px;
}

/* ========================================================= */
/* TITLE */
/* ========================================================= */

.example-title{

    font-size:32px;

    font-weight:800;

    color:var(--text);

    margin-bottom:25px;

    display:flex;

    align-items:center;

    gap:12px;
}

/* ========================================================= */
/* THEORY */
/* ========================================================= */

.theory-box{

    background:#f0f9ff;

    border-left:7px solid #0ea5e9;

    padding:22px;

    border-radius:16px;

    margin:20px 0;

    line-height:1.8;
}

.theory-box h4{

    margin-top:0;

    color:#0369a1;

    font-size:22px;
}

/* ========================================================= */
/* DESCRIPTION */
/* ========================================================= */

.description-box{

    background:#fefce8;

    border-left:7px solid #facc15;

    padding:22px;

    border-radius:16px;

    margin:20px 0;

    line-height:1.8;
}

.description-box h4{

    margin-top:0;

    color:#a16207;

    font-size:22px;
}

/* ========================================================= */
/* CODE */
/* ========================================================= */

.code-box{

    background:#0f172a;

    border-radius:18px;

    padding:25px;

    margin:25px 0;

    overflow:auto;

    border:1px solid #1e293b;
}

.code-box code{

    color:#dbeafe;

    font-family:
    Consolas,
    Monaco,
    monospace;

    font-size:16px;

    line-height:1.8;

    white-space:pre-wrap;

    display:block;
}

/* ========================================================= */
/* DEMO */
/* ========================================================= */

.demo-box{

    background:var(--surface-soft);

    border:2px dashed #38bdf8;

    border-radius:18px;

    padding:25px;

    margin-top:25px;
}

/* ========================================================= */
/* RESULT */
/* ========================================================= */

.result-box{

    background:var(--surface);

    border-radius:16px;

    padding:20px;

    margin-top:20px;

    border:2px solid var(--border);

    min-height:60px;

    font-size:18px;

    transition:.3s;
}

.result-box:hover{
    border-color:#38bdf8;
}

/* ========================================================= */
/* INPUT */
/* ========================================================= */

.demo-input,
.demo-select{

    padding:12px 14px;

    border-radius:12px;

    border:1px solid #94a3b8;

    font-size:16px;

    margin:6px;
}

.demo-input{

    width:140px;
}

.demo-input:focus,
.demo-select:focus{

    outline:none;

    border-color:#0ea5e9;

    box-shadow:
    0 0 0 4px rgba(14,165,233,0.12);
}

/* ========================================================= */
/* BUTTON */
/* ========================================================= */

.run-btn{

    background:
    linear-gradient(
    135deg,
    #0ea5e9,
    #0284c7
    );

    color:white;

    border:none;

    border-radius:14px;

    padding:14px 28px;

    font-size:17px;

    font-weight:bold;

    cursor:pointer;

    transition:.35s;

    margin-top:15px;
}

.run-btn:hover{

    transform:
    translateY(-2px)
    scale(1.03);

    background:
    linear-gradient(
    135deg,
    #0284c7,
    #075985
    );

    box-shadow:
    0 10px 20px rgba(2,132,199,0.25);
}

/* ========================================================= */
/* INFO */
/* ========================================================= */

.info-box{

    background:#ecfeff;

    border-left:6px solid #06b6d4;

    border-radius:14px;

    padding:18px;

    margin:20px 0;

    line-height:1.7;
}

/* ========================================================= */
/* TASKS */
/* ========================================================= */

.exercise-box{

    background:#f0fdf4;

    border-left:6px solid #22c55e;

    padding:22px;

    border-radius:16px;

    margin:25px 0;
}

.exam-task{

    background:#fff7ed;

    border-left:6px solid #fb923c;

    padding:22px;

    border-radius:16px;

    margin:25px 0;

    line-height:1.8;
}

.quiz-box{

    background:#faf5ff;

    border-left:6px solid #a855f7;

    border-radius:16px;

    padding:22px;

    margin-top:25px;
}

/* ========================================================= */
/* DARK MODE */
/* ========================================================= */

html[data-theme='dark'] .theory-box{

    background:#082f49;

    border-left:7px solid #38bdf8;

    color:#e0f2fe;
}

html[data-theme='dark'] .description-box{

    background:#422006;

    border-left:7px solid #facc15;

    color:#fef3c7;
}

html[data-theme='dark'] .demo-box{
    background:#0f172a;
}

html[data-theme='dark'] .result-box{

    background:#111827;

    border-color:#334155;

    color:#f8fafc;
}

html[data-theme='dark'] .exercise-box{

    background:#052e16;

    color:#dcfce7;
}

html[data-theme='dark'] .exam-task{

    background:#431407;

    color:#ffedd5;
}

html[data-theme='dark'] .quiz-box{

    background:#2e1065;

    color:#f3e8ff;
}

/* ========================================================= */
/* RESPONSIVE */
/* ========================================================= */

@media(max-width:768px){

    .example-box{
        padding:22px;
    }

    .example-title{
        font-size:24px;
    }

    .run-btn{
        width:100%;
    }

    .demo-input{
        width:100%;
    }
}