/* Mobile-only refinement; desktop styles remain untouched. */
@media (max-width:800px){
 body .background-grid{grid-template-columns:minmax(0,1fr)!important;gap:18px}
 body #background-summary .background-grid>*{min-width:0;padding:22px!important}
 body #background-summary .micro-heading{display:flex;flex-wrap:wrap;gap:6px 12px;font-size:17px;line-height:1.5;word-break:keep-all}
 body #background-summary .micro-heading span{font-size:13px;overflow-wrap:break-word}
 body #background-summary .certificate-columns{display:grid;grid-template-columns:minmax(0,1fr)!important;gap:18px}
 body #background-summary .certificate-columns .credential-brands{display:grid;grid-template-columns:minmax(0,1fr)!important;gap:18px;padding:0!important;margin:0;border:0}
 body #background-summary .certificate-columns .credential-brands>li{display:block!important;min-width:0}
 body #background-summary .certificate-columns .credential-name{display:block;font-size:16px;line-height:1.5;margin-bottom:5px;white-space:nowrap}
 body #background-summary .certificate-columns .credential-korean{font-size:14px;line-height:1.7;word-break:normal;overflow-wrap:break-word}
 body #background-summary .hero-career-list{display:grid;grid-template-columns:minmax(0,1fr)!important;gap:18px}
 body #background-summary .hero-career-list p{font-size:14px;line-height:1.7}
 body .hero .hero-learning-steps{font-size:15px!important;line-height:1.8}
 body .hero .hero-learning-steps li{font-size:15px!important;line-height:1.8;margin-bottom:14px}
 body .hero .actions{display:grid;grid-template-columns:minmax(0,1fr);gap:10px}
 body .hero .actions .button{font-size:15px;min-height:48px;padding:14px 12px;white-space:normal}
 body #education-overview .overview-grid{grid-template-columns:minmax(0,1fr);gap:16px}
 body #education-overview .overview-card{min-width:0;padding:20px}
 body #education-overview .overview-card>p{font-size:14px;line-height:1.7}
 body #education-overview .overview-options button{min-height:48px}
 body #education-overview .overview-options button strong{font-size:15px}
 body #education-overview .overview-options button span{font-size:13px}
 body #education-selection.mobile-inline-selection{grid-column:1/-1;margin:0 0 8px;width:100%;min-width:0}
 body #education-selection :is(#goal-panel,#level-panel,.role-panel,.job-section){padding:20px!important}
 body #education-selection p,body #education-selection li{font-size:15px;line-height:1.8;overflow-wrap:break-word}
 body #education-selection h3{font-size:23px;line-height:1.5;word-break:keep-all}
 body #ax-additions :is(.intro,.course-panel p,.course-panel li,.advanced-panel p,.advanced-panel li){font-size:15px;line-height:1.8}
 body #ax-additions :is(#course-tabs,#advanced-tabs) button{font-size:14px;min-height:48px}
 body #materials .philosophy-principles{padding:4px 18px}
 body #materials .philosophy-principles article{gap:8px;padding:20px 0}
 body #materials .philosophy-principles p{font-size:15px;line-height:1.8}
 body #materials .philosophy-principles h3{font-size:19px}
 body #contact .form-row{grid-template-columns:minmax(0,1fr);gap:16px}
 body #contact :is(input,select,textarea){font-size:16px;min-width:0;width:100%;min-height:48px}
 body #contact label{font-size:14px}
 body #contact .button{min-height:48px;font-size:15px;white-space:normal}
}

/* Keep the philosophy heading above its principles on phones. */
@media(max-width:800px){
 body #materials.philosophy-section>.philosophy-intro{grid-column:1;grid-row:1;order:0}
 body #materials.philosophy-section>.philosophy-principles{grid-column:1;grid-row:2;order:1}
}
