* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}


body {
    font-family: Arial, sans-serif;
    background: #f4f6fb;
    color: #222;
}


/* =========================
   HEADER
   ========================= */

header {
    text-align: center;
    padding: 40px 20px 25px;
}


header h1 {
    font-size: 32px;
    margin-bottom: 10px;
}


header p {
    color: #666;
}


/* =========================
   AUTH STATUS
   ========================= */

.auth-status {
    max-width: 500px;
    margin: 20px auto 0;

    padding: 12px 15px;

    background: white;

    border-radius: 12px;

    display: flex;
    align-items: center;
    justify-content: space-between;

    gap: 10px;

    box-shadow:
        0 4px 15px rgba(0, 0, 0, 0.06);
}


#authStatusText {
    font-weight: bold;
    color: #555;
}


.auth-status button {
    border: none;

    padding: 10px 15px;

    border-radius: 9px;

    background: #222;
    color: white;

    cursor: pointer;

    font-size: 14px;
}


.auth-status button:hover {
    opacity: 0.85;
}


/* =========================
   TOOL CARDS
   ========================= */

.tools {
    display: grid;

    grid-template-columns:
        repeat(auto-fit, minmax(230px, 1fr));

    gap: 18px;

    max-width: 1000px;

    margin: auto;

    padding: 20px;
}


.tool-card {
    background: white;

    padding: 25px;

    border-radius: 18px;

    cursor: pointer;

    transition:
        transform 0.2s,
        box-shadow 0.2s;
}


.tool-card:hover {
    transform: translateY(-5px);

    box-shadow:
        0 8px 25px rgba(0, 0, 0, 0.12);
}


.tool-card span {
    font-size: 38px;
}


.tool-card h2 {
    margin: 12px 0 8px;
}


.tool-card p {
    color: #666;
}


/* =========================
   CALCULATOR
   ========================= */

.calculator {
    display: none;

    width: calc(100% - 40px);

    max-width: 500px;

    margin: 30px auto;

    padding: 30px 20px;

    background: white;

    border-radius: 18px;

    text-align: center;

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


.calculator h2 {
    margin-bottom: 25px;
}


.calculator-description {
    color: #666;
    margin-bottom: 20px;
}


.calculator label {
    display: block;

    margin: 10px;

    color: #555;

    font-weight: bold;
}


.calculator input,
.calculator select {
    width: 100%;

    padding: 14px;

    border: 1px solid #ddd;

    border-radius: 10px;

    font-size: 16px;

    outline: none;

    background: white;
}


.calculator input:focus,
.calculator select:focus {
    border-color: #777;
}


.calculator button {
    margin-top: 20px;

    padding: 13px 25px;

    border: none;

    border-radius: 10px;

    cursor: pointer;

    font-size: 16px;

    background: #222;

    color: white;
}


.calculator button:hover {
    opacity: 0.85;
}


.calculator h3 {
    margin-top: 20px;

    font-size: 20px;
}


/* =========================
   AUTH
   ========================= */

.auth-calculator {
    max-width: 450px;
}


.auth-field {
    display: block;
}


.hidden {
    display: none !important;
}


.auth-message {
    margin-top: 18px;

    min-height: 20px;

    font-weight: bold;

    line-height: 1.5;
}


.auth-switch-button {
    background: #eee !important;

    color: #222 !important;

    width: 100%;
}


.auth-calculator > input {
    margin-bottom: 5px;
}


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

.backButton {
    background: #eee !important;

    color: #222 !important;
}


/* =========================
   MARKS
   ========================= */

.subject-row {
    display: flex;

    gap: 10px;

    margin-bottom: 12px;
}


.subject-row input {
    flex: 1;
}


.subject-row .subject-name {
    min-width: 0;
}


.subject-row .marks {
    max-width: 120px;
}


.remove-subject {
    width: 45px;

    padding: 0 !important;

    margin-top: 0 !important;

    background: #eee !important;

    color: #222 !important;
}


#marksResult {
    margin-top: 25px;

    padding: 18px;

    background: #f4f6fb;

    border-radius: 12px;

    line-height: 1.8;
}


#marksResult h3 {
    margin-bottom: 8px;
}


/* =========================
   CGPA
   ========================= */

.cgpa-row {
    display: flex;

    gap: 10px;

    margin-bottom: 12px;
}


.cgpa-row input {
    flex: 1;
}


.cgpa-row .grade-point {
    max-width: 120px;
}


#cgpaResult {
    margin-top: 25px;

    padding: 18px;

    background: #f4f6fb;

    border-radius: 12px;

    line-height: 1.8;
}


/* =========================
   TIMER
   ========================= */

#timerDisplay {
    font-size: 60px;

    font-weight: bold;

    margin: 30px 0;

    letter-spacing: 2px;
}


.timer-settings {
    display: flex;

    gap: 10px;

    margin-bottom: 20px;
}


.timer-settings input {
    flex: 1;
}


.timer-settings button {
    margin-top: 0;
}


.timer-buttons {
    display: flex;

    justify-content: center;

    gap: 10px;

    flex-wrap: wrap;
}


.timer-buttons button {
    margin-top: 0;
}


#timerMessage {
    margin-top: 20px;

    color: #666;

    font-weight: bold;
}


/* =========================
   TIMETABLE
   ========================= */

.timetable-calculator {
    max-width: 1200px;
}


.timetable-form {
    display: grid;

    grid-template-columns:
        1fr 1fr 1.5fr auto;

    gap: 10px;

    margin-bottom: 30px;
}


.timetable-form button {
    margin-top: 0;
}


.timetable-wrapper {
    width: 100%;

    overflow-x: auto;

    padding-bottom: 10px;
}


.timetable-grid {
    display: grid;

    grid-template-columns:
        repeat(7, minmax(140px, 1fr));

    gap: 10px;

    min-width: 1000px;
}


.day-column {
    min-height: 300px;

    background: #f4f6fb;

    border-radius: 14px;

    overflow: hidden;

    border: 1px solid #e5e5e5;
}


.day-header {
    padding: 14px 8px;

    text-align: center;

    font-weight: bold;

    background: #222;

    color: white;
}


.day-sessions {
    padding: 10px;
}


.session-card {
    background: white;

    border-radius: 10px;

    padding: 12px;

    margin-bottom: 10px;

    box-shadow:
        0 3px 10px rgba(0, 0, 0, 0.08);
}


.session-time {
    font-size: 13px;

    color: #666;

    margin-bottom: 6px;
}


.session-subject {
    font-weight: bold;

    word-break: break-word;
}


.remove-session {
    width: 100%;

    padding: 8px !important;

    margin-top: 10px !important;

    background: #eee !important;

    color: #222 !important;

    font-size: 13px !important;
}


.empty-day {
    text-align: center;

    color: #999;

    font-size: 13px;

    padding: 20px 5px;
}


.clearTimetableButton {
    background: #eee !important;

    color: #222 !important;

    margin-top: 20px !important;
}


/* =========================
   UNIT CONVERTER
   ========================= */

#converterTool {
    max-width: 500px;
}


#converterTool select,
#converterTool input {
    margin-bottom: 12px;
}


.swap-button {
    width: 100%;

    background: #eee !important;

    color: #222 !important;

    margin-top: 5px !important;

    margin-bottom: 12px;
}


#converterResult {
    margin-top: 15px;

    padding: 20px;

    background: #f4f6fb;

    border-radius: 12px;

    font-size: 18px;

    font-weight: bold;

    line-height: 1.6;
}


/* =========================
   FOOTER
   ========================= */

footer {
    text-align: center;

    padding: 30px;

    color: #777;
}


/* =========================
   MOBILE
   ========================= */

@media (max-width: 700px) {

    header {
        padding-top: 30px;
    }


    header h1 {
        font-size: 28px;
    }


    .auth-status {
        flex-direction: column;
    }


    .auth-status button {
        width: 100%;
    }


    .tools {
        grid-template-columns: 1fr;

        padding: 15px;
    }


    .tool-card {
        padding: 22px;
    }


    .calculator {
        width: calc(100% - 30px);

        padding: 25px 18px;
    }


    .subject-row {
        display: grid;

        grid-template-columns:
            1fr 90px 45px;
    }


    .subject-row .marks {
        max-width: none;
    }


    .cgpa-row {
        display: grid;

        grid-template-columns:
            1fr 100px 45px;
    }


    .cgpa-row .grade-point {
        max-width: none;
    }


    #timerDisplay {
        font-size: 48px;
    }


    .timer-buttons {
        flex-direction: column;
    }


    .timer-buttons button {
        width: 100%;
    }


    .timetable-form {
        grid-template-columns: 1fr;
    }


    .timetable-form button {
        width: 100%;
    }


    .timetable-grid {
        min-width: 1050px;
    }
}


/* =========================
   FANCY ALERT MODAL
   ========================= */

.fancy-alert-overlay {
    position: fixed;

    inset: 0;

    z-index: 9999;

    display: flex;

    align-items: center;

    justify-content: center;

    padding: 20px;

    background: rgba(15, 18, 30, 0.62);

    backdrop-filter: blur(10px);

    -webkit-backdrop-filter: blur(10px);

    opacity: 0;

    visibility: hidden;

    pointer-events: none;

    transition:
        opacity 0.25s ease,
        visibility 0.25s ease;
}


.fancy-alert-overlay.show {
    opacity: 1;

    visibility: visible;

    pointer-events: auto;
}


.fancy-alert-card {
    position: relative;

    width: min(430px, 100%);

    padding: 34px 26px 28px;

    text-align: center;

    background: rgba(255, 255, 255, 0.96);

    border: 1px solid rgba(255, 255, 255, 0.8);

    border-radius: 28px;

    box-shadow:
        0 30px 80px rgba(0, 0, 0, 0.25),
        0 8px 30px rgba(0, 0, 0, 0.12);

    transform: translateY(18px) scale(0.94);

    transition:
        transform 0.3s cubic-bezier(.2,.8,.2,1);
}


.fancy-alert-overlay.show .fancy-alert-card {
    transform: translateY(0) scale(1);
}


.fancy-alert-icon {
    width: 76px;

    height: 76px;

    display: flex;

    align-items: center;

    justify-content: center;

    margin: 0 auto 18px;

    font-size: 38px;

    border-radius: 50%;

    background:
        linear-gradient(135deg, #eef2ff, #f5e8ff);

    box-shadow:
        0 10px 30px rgba(80, 70, 160, 0.18);
}


.fancy-alert-card h2 {
    margin: 0 0 10px;

    font-size: 25px;

    font-weight: 800;

    color: #171827;
}


.fancy-alert-card p {
    margin: 0 auto 24px;

    max-width: 340px;

    font-size: 16px;

    line-height: 1.6;

    color: #626477;
}


.fancy-alert-button {
    width: 100% !important;

    margin: 0 !important;

    padding: 14px 20px !important;

    border: 0 !important;

    border-radius: 14px !important;

    background:
        linear-gradient(135deg, #6c63ff, #8b5cf6) !important;

    color: white !important;

    font-size: 16px !important;

    font-weight: 700 !important;

    cursor: pointer;

    box-shadow:
        0 10px 22px rgba(108, 99, 255, 0.28);

    transition:
        transform 0.2s ease,
        box-shadow 0.2s ease;
}


.fancy-alert-button:hover {
    transform: translateY(-2px);

    box-shadow:
        0 14px 28px rgba(108, 99, 255, 0.34);
}


.fancy-alert-close {
    position: absolute;

    top: 12px;

    right: 14px;

    width: 38px !important;

    height: 38px !important;

    margin: 0 !important;

    padding: 0 !important;

    display: flex;

    align-items: center;

    justify-content: center;

    border: 0 !important;

    border-radius: 50% !important;

    background: #f1f2f7 !important;

    color: #666 !important;

    font-size: 26px !important;

    line-height: 1 !important;

    cursor: pointer;
}


.fancy-alert-close:hover {
    background: #e7e8ef !important;

    transform: none !important;
}


body.modal-open {
    overflow: hidden;
}


@media (max-width: 500px) {

    .fancy-alert-card {
        padding: 30px 20px 22px;

        border-radius: 24px;
    }


    .fancy-alert-icon {
        width: 68px;

        height: 68px;

        font-size: 34px;
    }


    .fancy-alert-card h2 {
        font-size: 23px;
    }
}


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

.theme-toggle {
    margin-top: 14px;

    border: 1px solid #ddd;

    padding: 10px 16px;

    border-radius: 999px;

    background: #fff;

    color: #222;

    cursor: pointer;

    font-size: 14px;

    font-weight: bold;

    transition:
        transform .2s,
        background .2s,
        color .2s,
        border-color .2s;
}


.theme-toggle:hover {
    transform: translateY(-2px);
}


body.dark-mode {
    background: #0f1117 !important;

    color: #f1f3f8 !important;
}


body.dark-mode header p,
body.dark-mode .tool-card p,
body.dark-mode .calculator-description,
body.dark-mode .calculator label,
body.dark-mode #timerMessage,
body.dark-mode .session-time,
body.dark-mode footer,
body.dark-mode #authStatusText {
    color: #aeb5c2 !important;
}


body.dark-mode .auth-status,
body.dark-mode .tool-card,
body.dark-mode .calculator,
body.dark-mode .session-card {
    background: #181b24 !important;

    color: #f1f3f8 !important;

    box-shadow:
        0 8px 25px rgba(0,0,0,.35) !important;
}


body.dark-mode .calculator input,
body.dark-mode .calculator select {
    background: #10131a !important;

    color: #f1f3f8 !important;

    border-color: #343947 !important;
}


body.dark-mode .calculator input::placeholder {
    color: #747d8d !important;
}


body.dark-mode .calculator input:focus,
body.dark-mode .calculator select:focus {
    border-color: #8b5cf6 !important;
}


body.dark-mode .calculator button,
body.dark-mode .auth-status button {
    background: #f1f3f8 !important;

    color: #11131a !important;
}


body.dark-mode .auth-switch-button,
body.dark-mode .backButton,
body.dark-mode .remove-subject,
body.dark-mode .remove-session,
body.dark-mode .clearTimetableButton,
body.dark-mode .swap-button {
    background: #292e3a !important;

    color: #f1f3f8 !important;
}


body.dark-mode #marksResult,
body.dark-mode #cgpaResult,
body.dark-mode #converterResult,
body.dark-mode .day-column {
    background: #11141c !important;

    border-color: #303542 !important;

    color: #f1f3f8 !important;
}


body.dark-mode .day-header {
    background: #292e3a !important;
}


body.dark-mode .empty-day {
    color: #727b8b !important;
}


body.dark-mode .fancy-alert-overlay {
    background: rgba(0,0,0,.72) !important;
}


body.dark-mode .fancy-alert-card {
    background: #181b24 !important;

    color: #f1f3f8 !important;
}


body.dark-mode .fancy-alert-card p {
    color: #aeb5c2 !important;
}


body.dark-mode .fancy-alert-close {
    color: #aeb5c2 !important;
}


body.dark-mode .theme-toggle {
    background: #181b24 !important;

    color: #f1f3f8 !important;

    border-color: #343947 !important;
}


body.dark-mode .theme-toggle:hover {
    background: #222733 !important;
}


/* Smooth theme transition */

body,
.auth-status,
.tool-card,
.calculator,
.session-card,
.calculator input,
.calculator select,
.theme-toggle,
.day-column,
#marksResult,
#cgpaResult,
#converterResult {
    transition:
        background-color .25s ease,
        color .25s ease,
        border-color .25s ease,
        box-shadow .25s ease;
}


/* =========================
   AD SLOTS
   ========================= */

.ad-slot {
    width: min(100% - 40px, 728px);

    min-height: 90px;

    margin: 25px auto;

    padding: 12px;

    display: flex;

    align-items: center;

    justify-content: center;

    border: 1px dashed #cfd3dc;

    border-radius: 12px;

    background: #f8f9fc;

    color: #8a909d;

    font-size: 12px;

    letter-spacing: .3px;

    text-align: center;
}


.ad-slot-home {
    margin-top: 10px;
}


.ad-slot-footer {
    margin-top: 10px;

    margin-bottom: 0;
}


body.dark-mode .ad-slot {
    background: #151821;

    border-color: #343947;

    color: #747d8d;
}


@media (max-width: 700px) {

    .ad-slot {
        width: calc(100% - 30px);

        min-height: 70px;
    }
}

/* =========================
   EXAM COUNTDOWN
   ========================= */

.countdown-calculator {
    max-width: 550px;
}

.countdown-result {
    margin-top: 25px;
    padding: 22px 18px;
    background: #f4f6fb;
    border-radius: 16px;
    min-height: 110px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 6px;
    line-height: 1.5;
}

.countdown-exam-name {
    font-size: 20px;
    font-weight: 800;
}

.countdown-time {
    font-size: 32px;
    font-weight: 800;
}

.countdown-date-text {
    color: #666;
    font-size: 14px;
}

.countdown-clear-button {
    background: #eee !important;
    color: #222 !important;
}

body.dark-mode .countdown-result {
    background: #11141c !important;
    color: #f1f3f8 !important;
}

body.dark-mode .countdown-date-text {
    color: #aeb5c2 !important;
}

body.dark-mode .countdown-clear-button {
    background: #292e3a !important;
    color: #f1f3f8 !important;
}

@media (max-width: 700px) {
    .countdown-time {
        font-size: 26px;
    }
}


/* =========================
   TO-DO LIST
   ========================= */

.todo-calculator {
    max-width: 650px;
}

.todo-list {
    margin-top: 25px;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.todo-empty {
    padding: 25px;
    text-align: center;
    background: #f4f6fb;
    border-radius: 16px;
    color: #666;
}

.todo-item {
    padding: 16px;
    border-radius: 16px;
    background: #f4f6fb;
    display: flex;
    align-items: center;
    gap: 14px;
    transition: 0.2s;
}

.todo-item.completed {
    opacity: 0.65;
}

.todo-item.completed .todo-task {
    text-decoration: line-through;
}

.todo-check {
    width: 22px;
    height: 22px;
    cursor: pointer;
    flex-shrink: 0;
}

.todo-content {
    flex: 1;
    min-width: 0;
}

.todo-task {
    font-weight: 800;
    font-size: 17px;
    word-break: break-word;
}

.todo-subject {
    margin-top: 4px;
    font-size: 13px;
    color: #666;
}

.todo-due {
    margin-top: 5px;
    font-size: 13px;
    color: #555;
}

.todo-overdue {
    color: #c62828;
    font-weight: 800;
}

.todo-delete {
    border: none !important;
    background: transparent !important;
    color: #c62828 !important;
    padding: 8px !important;
    font-size: 20px;
    cursor: pointer;
}

body.dark-mode .todo-item,
body.dark-mode .todo-empty {
    background: #11141c !important;
    color: #f1f3f8;
}

body.dark-mode .todo-subject,
body.dark-mode .todo-due {
    color: #aeb5c2;
}

@media (max-width: 700px) {
    .todo-item {
        padding: 14px;
    }

    .todo-task {
        font-size: 16px;
    }
}


/* =========================
   NOTES
   ========================= */

.notes-calculator {
    max-width: 700px;
}

.notes-editor,
.notes-search {
    margin-top: 20px;
}

.notes-editor textarea {
    width: 100%;
    min-height: 180px;
    resize: vertical;
    padding: 14px;
    border: 1px solid #ddd;
    border-radius: 14px;
    font-family: inherit;
    font-size: 15px;
    box-sizing: border-box;
}

.notes-search {
    padding-top: 10px;
}

.notes-list {
    margin-top: 25px;
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.notes-empty {
    padding: 25px;
    text-align: center;
    background: #f4f6fb;
    border-radius: 16px;
    color: #666;
}

.note-card {
    background: #f4f6fb;
    border-radius: 16px;
    padding: 18px;
}

.note-card-title {
    font-size: 19px;
    font-weight: 800;
    word-break: break-word;
}

.note-card-subject {
    margin-top: 4px;
    font-size: 13px;
    color: #666;
}

.note-card-content {
    margin-top: 12px;
    white-space: pre-wrap;
    line-height: 1.6;
    word-break: break-word;
}

.note-card-actions {
    display: flex;
    gap: 8px;
    margin-top: 15px;
}

.note-edit-button,
.note-delete-button {
    flex: 1;
}

.note-delete-button {
    background: #eee !important;
    color: #c62828 !important;
}

.notes-cancel-button {
    background: #eee !important;
    color: #222 !important;
}

body.dark-mode .notes-editor textarea {
    background: #11141c !important;
    color: #f1f3f8 !important;
    border-color: #333846;
}

body.dark-mode .note-card,
body.dark-mode .notes-empty {
    background: #11141c !important;
    color: #f1f3f8;
}

body.dark-mode .note-card-subject {
    color: #aeb5c2;
}

body.dark-mode .note-delete-button,
body.dark-mode .notes-cancel-button {
    background: #292e3a !important;
    color: #f1f3f8 !important;
}

@media (max-width: 700px) {
    .note-card-actions {
        flex-direction: column;
    }
}


/* QUIZ STYLES */

.quiz-calculator {
    max-width: 700px;
}

.quiz-progress {
    margin: 18px 0;
    font-weight: 700;
    text-align: center;
    opacity: 0.8;
}

.quiz-question {
    font-size: 1.25rem;
    font-weight: 700;
    margin: 20px 0;
    line-height: 1.5;
}

.quiz-options {
    display: grid;
    gap: 12px;
    margin-bottom: 18px;
}

.quiz-option {
    width: 100%;
    padding: 14px 16px;
    border: 2px solid #ddd;
    border-radius: 12px;
    background: transparent;
    cursor: pointer;
    text-align: left;
    font-size: 1rem;
    transition: 0.2s ease;
}

.quiz-option:hover {
    transform: translateY(-1px);
}

.quiz-option.correct {
    border-color: #22c55e;
}

.quiz-option.wrong {
    border-color: #ef4444;
}

.quiz-option:disabled {
    cursor: default;
    opacity: 0.95;
}

.quiz-feedback {
    min-height: 28px;
    margin: 10px 0 16px;
    font-weight: 700;
    text-align: center;
}

.quiz-result {
    margin: 20px 0;
    font-size: 1.25rem;
    font-weight: 700;
    text-align: center;
}

.dark-mode .quiz-option {
    border-color: #555;
}

.dark-mode .quiz-option.correct {
    border-color: #22c55e;
}

.dark-mode .quiz-option.wrong {
    border-color: #ef4444;
}

@media (max-width: 600px) {
    .quiz-question {
        font-size: 1.1rem;
    }

    .quiz-option {
        padding: 13px;
    }
}


/* NCERT TEXTBOOK STYLES */

.textbooks-calculator {
    max-width: 850px;
}

.textbook-source-note {
    padding: 14px 16px;
    margin: 16px 0 22px;
    border-radius: 12px;
    border: 1px solid rgba(100, 100, 100, 0.25);
    line-height: 1.5;
}

.textbook-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px;
}

.textbook-card {
    display: flex;
    flex-direction: column;
    gap: 7px;
    padding: 18px;
    border: 1px solid rgba(100, 100, 100, 0.25);
    border-radius: 16px;
    text-decoration: none;
    color: inherit;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.textbook-card:hover {
    transform: translateY(-2px);
}

.textbook-card span {
    font-size: 1.7rem;
}

.textbook-card strong {
    font-size: 1.05rem;
}

.textbook-card small {
    opacity: 0.72;
    line-height: 1.4;
}

.textbook-card b {
    margin-top: 5px;
    font-size: 0.9rem;
}

.official-ncert-button {
    display: block;
    margin: 22px 0 12px;
    padding: 14px 18px;
    border-radius: 12px;
    text-align: center;
    text-decoration: none;
    font-weight: 700;
    border: 1px solid rgba(100, 100, 100, 0.25);
}

@media (max-width: 600px) {
    .textbook-grid {
        grid-template-columns: 1fr;
    }
}


.selected-textbook-class {
    margin: 20px 0 14px;
    padding: 14px 16px;
    border-radius: 12px;
    font-weight: 700;
    border: 1px solid rgba(100, 100, 100, 0.25);
}

#ncertClassSelect {
    width: 100%;
    padding: 13px 14px;
    border-radius: 12px;
    border: 1px solid rgba(100, 100, 100, 0.3);
    font-size: 1rem;
    margin-top: 8px;
    background: inherit;
}


/* PROFESSIONAL AD PLACEHOLDER */

.ad-section {
    width: 100%;
    max-width: 900px;
    margin: 24px auto;
    padding: 0 12px;
    box-sizing: border-box;
}

.ad-label {
    text-align: center;
    font-size: 0.7rem;
    font-weight: 700;
    letter-spacing: 1.5px;
    opacity: 0.55;
    margin-bottom: 7px;
}

.ad-box {
    min-height: 100px;
    width: 100%;
    box-sizing: border-box;
    border: 1px dashed rgba(120, 120, 120, 0.45);
    border-radius: 14px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 6px;
    text-align: center;
    background: rgba(120, 120, 120, 0.04);
}

.ad-icon {
    font-size: 1.4rem;
}

.ad-box strong {
    font-size: 0.9rem;
}

.ad-box small {
    font-size: 0.75rem;
    opacity: 0.6;
}

.dark-mode .ad-box {
    border-color: rgba(180, 180, 180, 0.3);
    background: rgba(255, 255, 255, 0.03);
}

@media (max-width: 600px) {
    .ad-section {
        margin: 18px auto;
        padding: 0 8px;
    }

    .ad-box {
        min-height: 90px;
    }
}
