/* =========================================================
   AMCAS Character Counter
   File: amcas-character-counter.css
   ========================================================= */


/* =========================================================
   RESET / BASE
   ========================================================= */

*,
*::before,
*::after {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    background-color: #f3f4f6;
    color: #202124;
    font-family: "Poppins", Arial, sans-serif;
    font-size: 17px;
    line-height: 1.65;
}

main {
    display: block;
}

p {
    margin-top: 0;
    margin-bottom: 1.15rem;
}

a {
    color: inherit;
}

button,
textarea,
select {
    font-family: inherit;
}

button {
    -webkit-tap-highlight-color: transparent;
}

code {
    font-family:
        "SFMono-Regular",
        Consolas,
        "Liberation Mono",
        Menlo,
        monospace;
}


/* =========================================================
   ACCESSIBILITY
   ========================================================= */

.visually-hidden {
    position: absolute !important;
    width: 1px !important;
    height: 1px !important;
    padding: 0 !important;
    margin: -1px !important;
    overflow: hidden !important;
    clip: rect(0, 0, 0, 0) !important;
    clip-path: inset(50%) !important;
    white-space: nowrap !important;
    border: 0 !important;
}

[hidden] {
    display: none !important;
}


/* =========================================================
   MAIN PAGE
   ========================================================= */

.amcas-section {
    width: 100%;
    padding-top: 110px;
    padding-right: 20px;
    padding-bottom: 70px;
    padding-left: 20px;
}

.amcas-container {
    width: 100%;
    max-width: 1020px;
    margin: 0 auto;
}


/* =========================================================
   PAGE HEADING
   ========================================================= */

.amcas-heading {
    width: 100%;
    max-width: 850px;
    margin: 0 auto 26px;
    text-align: center;
}

.amcas-heading h1 {
    margin: 0 0 10px;
    color: #202124;
    font-size: 38px;
    font-weight: 700;
    line-height: 1.2;
    letter-spacing: -0.5px;
}

.amcas-intro {
    max-width: 800px;
    margin: 0 auto;
    color: #5c616a;
    font-size: 18px;
    line-height: 1.6;
}


/* =========================================================
   COUNTER WRAPPER
   ========================================================= */

.counter-wrapper {
    width: 100%;
    margin: 0 auto 40px;
    padding: 24px;
    background-color: #ffffff;
    border: 1px solid #dfe2e6;
    border-radius: 14px;
    box-shadow:
        0 3px 6px rgba(0, 0, 0, 0.025),
        0 8px 22px rgba(0, 0, 0, 0.045);
}


/* =========================================================
   AMCAS SECTION SELECTOR
   ========================================================= */

.amcas-section-selector {
    width: 100%;
    margin-bottom: 16px;
}

.amcas-section-label {
    display: block;
    margin-bottom: 7px;
    color: #3e434b;
    font-size: 14px;
    font-weight: 650;
    line-height: 1.4;
}

.amcas-section-select {
    display: block;
    width: 100%;
    min-height: 50px;
    margin: 0;
    padding: 11px 44px 11px 14px;

    background-color: #ffffff;
    color: #252a31;

    border: 1px solid #c8ccd2;
    border-radius: 8px;
    outline: none;

    font-size: 16px;
    font-weight: 500;
    line-height: 1.45;

    cursor: pointer;

    appearance: none;
    -webkit-appearance: none;
    -moz-appearance: none;

    background-image:
        linear-gradient(45deg, transparent 50%, #656b74 50%),
        linear-gradient(135deg, #656b74 50%, transparent 50%);

    background-position:
        calc(100% - 20px) 21px,
        calc(100% - 14px) 21px;

    background-size:
        6px 6px,
        6px 6px;

    background-repeat: no-repeat;

    transition:
        border-color 0.2s ease,
        box-shadow 0.2s ease,
        background-color 0.2s ease;
}

.amcas-section-select:hover {
    border-color: #9da3ac;
}

.amcas-section-select:focus {
    border-color: #4f5968;
    box-shadow: 0 0 0 3px rgba(79, 89, 104, 0.12);
}

.amcas-section-select:focus-visible {
    outline: none;
}


/* =========================================================
   CHARACTER METRICS
   ========================================================= */

.counter-metrics {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
    margin-bottom: 16px;
}

.counter-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;

    min-width: 0;
    min-height: 94px;

    padding: 13px 16px;

    background-color: #f7f8fa;

    border: 1px solid #dfe2e6;
    border-radius: 10px;

    text-align: center;

    transition:
        background-color 0.2s ease,
        border-color 0.2s ease,
        box-shadow 0.2s ease;
}

.counter-label {
    display: block;
    margin-bottom: 2px;

    color: #5f6570;

    font-size: 14px;
    font-weight: 600;
    line-height: 1.4;
    letter-spacing: 0.35px;
    text-transform: uppercase;
}

.counter-number {
    color: #202124;

    font-size: 36px;
    font-weight: 700;
    line-height: 1.3;

    overflow-wrap: anywhere;
}

.counter-limit {
    color: #777d86;
    font-size: 19px;
    font-weight: 500;
}

#typed,
#remaining,
#currentLimit {
    transition: color 0.2s ease;
}


/* =========================================================
   OVER CHARACTER LIMIT
   ========================================================= */

.counter-card.over-limit {
    background-color: #fff3f3;
    border-color: #d93025;
}

.counter-card.over-limit .counter-number,
.counter-card.over-limit #typed,
.counter-card.over-limit #remaining {
    color: #c5221f;
}


/* =========================================================
   TEXTAREA
   ========================================================= */

.textarea-wrapper {
    width: 100%;
}

#userWord {
    display: block;

    width: 100%;
    height: 370px;
    min-height: 170px;

    margin: 0;
    padding: 17px 18px;

    resize: vertical;
    overflow-y: auto;

    background-color: #ffffff;
    color: #202124;

    border: 2px solid #c8ccd2;
    border-radius: 10px;
    outline: none;

    font-family: "Poppins", Arial, sans-serif;
    font-size: 17px;
    font-weight: 400;
    line-height: 1.6;

    caret-color: #202124;

    transition:
        border-color 0.2s ease,
        box-shadow 0.2s ease;
}

#userWord::placeholder {
    color: #8b9098;
    opacity: 1;
}

#userWord:hover {
    border-color: #9da3ac;
}

#userWord:focus {
    border-color: #4f5968;
    box-shadow: 0 0 0 3px rgba(79, 89, 104, 0.12);
}

#userWord[aria-invalid="true"] {
    border-color: #d93025;
}


/* =========================================================
   COPY / CLEAR / UNDO BUTTONS
   ========================================================= */

.counter-actions {
    display: flex;
    align-items: center;
    justify-content: flex-end;

    gap: 9px;

    margin-top: 10px;
    margin-bottom: 0;
}

.copyButton,
.clearButton {
    min-width: 105px;

    padding: 9px 16px;

    border: 0;
    border-radius: 7px;

    color: #ffffff;

    font-size: 14px;
    font-weight: 600;
    line-height: 1.4;

    cursor: pointer;

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

.copyButton {
    background-color: #287a39;
}

.copyButton:hover {
    background-color: #216a31;
    box-shadow: 0 3px 8px rgba(0, 0, 0, 0.12);
}

.clearButton {
    background-color: #c6403b;
}

.clearButton:hover {
    background-color: #ae342f;
    box-shadow: 0 3px 8px rgba(0, 0, 0, 0.12);
}

.copyButton:active,
.clearButton:active {
    transform: translateY(1px);
}

.copyButton:focus-visible,
.clearButton:focus-visible {
    outline: 3px solid rgba(41, 89, 155, 0.25);
    outline-offset: 2px;
}

#copyButton,
#clearUndoButton {
    min-width: 105px;
}


/* =========================================================
   COPY BUTTON STATES
   ========================================================= */

#copyButton.copied {
    background-color: #1f6f30;
}

#copyButton.no-text {
    background-color: #6c727b;
}

#copyButton.copied:hover {
    background-color: #1f6f30;
}

#copyButton.no-text:hover {
    background-color: #6c727b;
}


/* =========================================================
   UNDO STATE
   ========================================================= */

#clearUndoButton.undo-active {
    background-color: #5d6470;
}

#clearUndoButton.undo-active:hover {
    background-color: #4f5660;
}


/* =========================================================
   AMCAS COMPATIBILITY ALERT
   ========================================================= */

/*
   This alert is positioned after the Copy / Clear buttons
   in the HTML.

   That means the button position does not change when
   the alert appears or disappears.
*/

.amcas-compatibility-alert {
    width: 100%;

    margin-top: 16px;
    padding: 16px 17px;

    background-color: #fff9e8;

    border: 1px solid #e8d18b;
    border-left: 5px solid #c18b12;
    border-radius: 8px;

    color: #514a3b;

    box-shadow:
        0 2px 5px rgba(0, 0, 0, 0.025);

    overflow-wrap: anywhere;
}


/* =========================================================
   COMPATIBILITY ALERT HEADER
   ========================================================= */

.amcas-compatibility-header {
    display: flex;
    align-items: flex-start;
    gap: 12px;
}

.amcas-compatibility-icon {
    display: flex;
    flex: 0 0 auto;

    align-items: center;
    justify-content: center;

    width: 28px;
    height: 28px;

    margin-top: 1px;

    background-color: #c18b12;
    color: #ffffff;

    border-radius: 50%;

    font-size: 17px;
    font-weight: 700;
    line-height: 1;
}

.amcas-compatibility-header-text {
    min-width: 0;
    flex: 1;
}

.amcas-compatibility-title {
    display: block;

    margin: 0 0 4px;

    color: #443c2d;

    font-size: 16px;
    font-weight: 700;
    line-height: 1.4;
}

.amcas-compatibility-message {
    margin: 0;

    color: #5e5648;

    font-size: 14px;
    line-height: 1.55;
}


/* =========================================================
   ALERT STATE:
   CONFIRMED AMCAS PROBLEM
   ========================================================= */

/*
   Confirmed removed / trimmed characters are RED.
*/

.amcas-compatibility-alert.has-removed {
    background-color: #fff5f4;

    border-color: #e6b5b1;
    border-left-color: #c43b33;
}

.amcas-compatibility-alert.has-removed
.amcas-compatibility-icon {
    background-color: #c43b33;
}

.amcas-compatibility-alert.has-removed
.amcas-compatibility-title {
    color: #922c26;
}

.amcas-compatibility-alert.has-removed
.amcas-compatibility-message {
    color: #654541;
}


/* =========================================================
   ALERT STATE:
   EXPLICITLY REJECTED
   ========================================================= */

/*
   Rejected by AMCAS is also red, but slightly stronger.
*/

.amcas-compatibility-alert.has-rejected {
    background-color: #fff0ef;

    border-color: #dc9994;
    border-left-color: #b3261e;
}

.amcas-compatibility-alert.has-rejected
.amcas-compatibility-icon {
    background-color: #b3261e;
}

.amcas-compatibility-alert.has-rejected
.amcas-compatibility-title {
    color: #7e211c;
}

.amcas-compatibility-alert.has-rejected
.amcas-compatibility-message {
    color: #603532;
}


/* =========================================================
   ALERT STATE:
   QUESTIONABLE / NOT CONFIRMED
   ========================================================= */

/*
   Questionable-only warnings are YELLOW.

   If the alert also contains a confirmed problem,
   the red state takes priority.
*/

.amcas-compatibility-alert.has-questionable:not(.has-removed):not(.has-rejected) {
    background-color: #fff9e8;

    border-color: #e8d18b;
    border-left-color: #c18b12;
}

.amcas-compatibility-alert.has-questionable:not(.has-removed):not(.has-rejected)
.amcas-compatibility-icon {
    background-color: #c18b12;
}

.amcas-compatibility-alert.has-questionable:not(.has-removed):not(.has-rejected)
.amcas-compatibility-title {
    color: #76540a;
}

.amcas-compatibility-alert.has-questionable:not(.has-removed):not(.has-rejected)
.amcas-compatibility-message {
    color: #665a3d;
}


/* =========================================================
   COMPATIBILITY DETAILS
   ========================================================= */

.amcas-compatibility-details {
    margin-top: 14px;
}

.amcas-compatibility-group {
    margin-top: 11px;
    padding: 12px 13px;

    background-color: #ffffff;

    border: 1px solid #e2e3e6;
    border-radius: 7px;
}

.amcas-compatibility-group:first-child {
    margin-top: 0;
}

.amcas-compatibility-group-heading {
    display: flex;
    align-items: center;
    justify-content: space-between;

    gap: 12px;

    margin-bottom: 5px;
}

.amcas-compatibility-group-heading strong {
    color: #34383e;

    font-size: 14px;
    font-weight: 700;
    line-height: 1.4;
}

.amcas-compatibility-count {
    flex: 0 0 auto;

    padding: 2px 8px;

    background-color: #eef0f2;
    color: #50565e;

    border-radius: 999px;

    font-size: 12px;
    font-weight: 650;
    line-height: 1.5;
}

.amcas-compatibility-group-description {
    margin: 0 0 9px;

    color: #666b73;

    font-size: 13px;
    line-height: 1.5;
}


/* =========================================================
   CONFIRMED PROBLEM GROUP
   ========================================================= */

/*
   Confirmed removed / trimmed characters = RED.
*/

.amcas-removed-group {
    background-color: #fff4f3;
    border-color: #e5b0ac;
}

.amcas-removed-group
.amcas-compatibility-group-heading strong {
    color: #9b3029;
}

.amcas-removed-group
.amcas-compatibility-count {
    background-color: #f3cfcc;
    color: #852820;
}

.amcas-removed-group
.amcas-compatibility-group-description {
    color: #684744;
}


/* =========================================================
   REJECTED GROUP
   ========================================================= */

/*
   Explicit AMCAS validation error = stronger RED.
*/

.amcas-rejected-group {
    background-color: #fff0ef;
    border-color: #dc9994;
}

.amcas-rejected-group
.amcas-compatibility-group-heading strong {
    color: #84251f;
}

.amcas-rejected-group
.amcas-compatibility-count {
    background-color: #efc1bd;
    color: #741e19;
}

.amcas-rejected-group
.amcas-compatibility-group-description {
    color: #603e3b;
}


/* =========================================================
   QUESTIONABLE / UNCONFIRMED GROUP
   ========================================================= */

/*
   Not confirmed = YELLOW.
*/

.amcas-questionable-group {
    background-color: #fff9e8;
    border-color: #e8d18b;
}

.amcas-questionable-group
.amcas-compatibility-group-heading strong {
    color: #785809;
}

.amcas-questionable-group
.amcas-compatibility-count {
    background-color: #f4e4af;
    color: #684b07;
}

.amcas-questionable-group
.amcas-compatibility-group-description {
    color: #665c42;
}


/* =========================================================
   CHARACTER LIST
   ========================================================= */

.amcas-character-list {
    display: flex;
    flex-wrap: wrap;

    gap: 7px;
}

.amcas-character-item {
    display: inline-flex;
    align-items: center;

    max-width: 100%;

    padding: 5px 8px;

    background-color: #ffffff;
    color: #30343a;

    border: 1px solid #d9dce0;
    border-radius: 5px;

    font-family:
        "SFMono-Regular",
        Consolas,
        "Liberation Mono",
        Menlo,
        monospace;

    font-size: 13px;
    font-weight: 600;
    line-height: 1.4;

    overflow-wrap: anywhere;
    word-break: break-word;
}


/* Confirmed problem character */

.amcas-removed-group
.amcas-character-item {
    background-color: #ffffff;
    border-color: #dfa39e;
}


/* Explicitly rejected character */

.amcas-rejected-group
.amcas-character-item {
    background-color: #ffffff;
    border-color: #d88e88;
}


/* Questionable character */

.amcas-questionable-group
.amcas-character-item {
    background-color: #ffffff;
    border-color: #dfca84;
}


/* =========================================================
   INVISIBLE / NAMED CHARACTER DISPLAY
   ========================================================= */

.amcas-character-item.invisible-character {
    font-family: "Poppins", Arial, sans-serif;
    font-size: 12px;
    font-weight: 600;
}

.amcas-character-code {
    margin-left: 5px;

    color: #747a82;

    font-family:
        "SFMono-Regular",
        Consolas,
        "Liberation Mono",
        Menlo,
        monospace;

    font-size: 11px;
    font-weight: 500;
}


/* =========================================================
   COMPATIBILITY NOTE
   ========================================================= */

.amcas-compatibility-note {
    margin: 14px 0 0;
    padding-top: 12px;

    color: #615b50;

    border-top: 1px solid rgba(120, 100, 70, 0.18);

    font-size: 13px;
    line-height: 1.55;
}


/* =========================================================
   INFORMATIONAL CONTENT
   ========================================================= */

.amcas-content {
    width: 100%;

    padding: 34px 38px;

    background-color: #ffffff;

    border: 1px solid #dfe2e6;
    border-radius: 14px;

    box-shadow:
        0 3px 14px rgba(0, 0, 0, 0.04);
}


/* =========================================================
   CONTENT SECTIONS
   ========================================================= */

.content-section {
    margin: 0 0 30px;
    padding: 0 0 30px;

    border-bottom: 1px solid #e7e9ec;
}

.content-section:last-of-type {
    margin-bottom: 0;
}

.content-section h2 {
    margin: 0 0 14px;

    color: #282c33;

    font-size: 25px;
    font-weight: 650;
    line-height: 1.35;
    letter-spacing: -0.2px;
}

.content-section h3 {
    margin: 22px 0 8px;

    color: #333840;

    font-size: 19px;
    font-weight: 650;
    line-height: 1.4;
}

.content-section p {
    color: #474d56;
}


/* =========================================================
   INLINE CHARACTER EXAMPLES
   ========================================================= */

.content-section code {
    padding: 1px 5px;

    background-color: #f2f3f5;
    color: #30353c;

    border: 1px solid #e1e3e6;
    border-radius: 4px;

    font-family:
        "SFMono-Regular",
        Consolas,
        "Liberation Mono",
        Menlo,
        monospace;

    font-size: 0.92em;
    line-height: 1.45;

    overflow-wrap: anywhere;
}


/* =========================================================
   AMCAS GUIDELINE LISTS
   ========================================================= */

.amcas-guidelines {
    margin: 15px 0 20px;
    padding-left: 27px;

    list-style-type: disc;
}

.amcas-guidelines li {
    display: list-item;

    margin-bottom: 9px;
    padding-left: 2px;

    color: #474d56;

    list-style-type: disc;
}

.amcas-guidelines li:last-child {
    margin-bottom: 0;
}

.amcas-guidelines li::marker {
    color: #555c66;
}


/* =========================================================
   GUIDELINE NOTE
   ========================================================= */

.guideline-note {
    margin-top: 18px;
    margin-bottom: 17px;

    padding: 13px 15px;

    background-color: #f6f7f8;
    color: #51565f;

    border-left: 4px solid #7a818b;
    border-radius: 4px;
}


/* =========================================================
   OFFICIAL AAMC LINKS
   ========================================================= */

.official-source-link {
    display: inline;

    color: #155cb6;

    text-decoration: underline;
    text-decoration-thickness: 1px;
    text-underline-offset: 2px;

    transition:
        color 0.15s ease;
}

.official-source-link:hover {
    color: #0d458d;
}

.official-source-link:focus-visible {
    outline: 2px solid #4b79b5;
    outline-offset: 3px;

    border-radius: 2px;
}


/* =========================================================
   AMCAS CHARACTER LIMIT TABLE
   ========================================================= */

.amcas-limit-table-wrapper {
    width: 100%;

    margin: 18px 0 22px;

    overflow-x: auto;

    background-color: #ffffff;

    border: 1px solid #dfe2e6;
    border-radius: 9px;
}

.amcas-limit-table {
    width: 100%;
    min-width: 580px;

    border-collapse: collapse;
    border-spacing: 0;

    color: #41464e;

    font-size: 15px;
    line-height: 1.5;
}

.amcas-limit-table thead {
    background-color: #f4f5f7;
}

.amcas-limit-table th {
    padding: 13px 16px;

    color: #353a42;

    font-size: 14px;
    font-weight: 650;

    text-align: left;
    vertical-align: middle;

    border-bottom: 1px solid #d8dce1;
}

.amcas-limit-table td {
    padding: 13px 16px;

    text-align: left;
    vertical-align: top;

    border-bottom: 1px solid #e6e8eb;
}

.amcas-limit-table tbody tr:last-child td {
    border-bottom: 0;
}

.amcas-limit-table tbody tr:nth-child(even) {
    background-color: #fafbfc;
}

.amcas-limit-table th:last-child,
.amcas-limit-table td:last-child {
    width: 175px;

    text-align: center;

    white-space: nowrap;
}

.amcas-limit-table td strong {
    color: #30353c;
    font-weight: 650;
}


/* =========================================================
   HOW-TO LIST
   ========================================================= */

.how-to-list {
    margin: 15px 0 0;
    padding-left: 27px;
}

.how-to-list li {
    margin-bottom: 10px;
    padding-left: 3px;

    color: #474d56;
}

.how-to-list li:last-child {
    margin-bottom: 0;
}


/* =========================================================
   FAQ
   ========================================================= */

.faq-section {
    border-bottom: 0;
}

.faq-item {
    padding: 19px 0;

    border-bottom: 1px solid #e9eaec;
}

.faq-item:first-of-type {
    padding-top: 5px;
}

.faq-item:last-child {
    padding-bottom: 0;
    border-bottom: 0;
}

.faq-item h3 {
    margin: 0 0 8px;

    color: #30343b;

    font-size: 18px;
    font-weight: 650;
    line-height: 1.45;
}

.faq-item p:last-child {
    margin-bottom: 0;
}


/* =========================================================
   PRIVACY / DISCLOSURES
   ========================================================= */

.amcas-disclosures {
    width: 100%;

    padding: 20px 22px;

    background-color: #f6f7f8;

    border: 1px solid #dfe2e6;
    border-radius: 9px;
}

.amcas-disclosures p {
    margin: 0 0 10px;

    color: #5f646d;

    font-size: 13px;
    line-height: 1.6;
}

.amcas-disclosures p:last-child {
    margin-bottom: 0;
}


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

#search-icon,
#search-form-container,
#theme-toggle-btn {
    display: none !important;
}

#menu-toggle-icon {
    border: 0;
    cursor: pointer;
}


/* =========================================================
   LARGE DESKTOP
   ========================================================= */

@media only screen and (min-width: 1400px) {

    .amcas-container {
        max-width: 1040px;
    }

    #userWord {
        height: 390px;
        min-height: 170px;
    }

}


/* =========================================================
   TABLET / SMALL DESKTOP
   ========================================================= */

@media only screen and (max-width: 1024px) {

    .amcas-section {
        padding-right: 18px;
        padding-left: 18px;
    }

    .amcas-container {
        max-width: 900px;
    }

    .amcas-content {
        padding: 30px 31px;
    }

}


/* =========================================================
   TABLET
   ========================================================= */

@media only screen and (max-width: 768px) {

    body {
        font-size: 16px;
    }

    .amcas-section {
        padding-top: 98px;
        padding-bottom: 50px;
    }

    .amcas-heading {
        margin-bottom: 21px;
    }

    .amcas-heading h1 {
        font-size: 31px;
    }

    .amcas-intro {
        max-width: 680px;
        font-size: 16px;
    }

    .counter-wrapper {
        margin-bottom: 30px;
        padding: 18px;
    }

    .amcas-section-label {
        font-size: 13px;
    }

    .amcas-section-select {
        min-height: 48px;

        padding-top: 10px;
        padding-bottom: 10px;

        font-size: 15px;

        background-position:
            calc(100% - 20px) 20px,
            calc(100% - 14px) 20px;
    }

    .counter-card {
        min-height: 86px;
        padding: 11px 12px;
    }

    .counter-label {
        font-size: 13px;
    }

    .counter-number {
        font-size: 31px;
    }

    .counter-limit {
        font-size: 17px;
    }

    #userWord {
        height: 330px;
        min-height: 160px;

        padding: 15px;

        font-size: 16px;
    }

    .counter-actions {
        margin-top: 9px;
    }

    .amcas-compatibility-alert {
        margin-top: 15px;
        padding: 15px;
    }

    .amcas-content {
        padding: 27px 24px;
    }

    .content-section {
        margin-bottom: 26px;
        padding-bottom: 26px;
    }

    .content-section h2 {
        font-size: 23px;
    }

    .content-section h3 {
        font-size: 18px;
    }

}


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

@media only screen and (max-width: 600px) {

    .amcas-section {
        padding-top: 88px;
        padding-right: 12px;
        padding-bottom: 40px;
        padding-left: 12px;
    }

    .amcas-heading {
        margin-bottom: 18px;
    }

    .amcas-heading h1 {
        margin-bottom: 8px;

        font-size: 28px;
        line-height: 1.25;
    }

    .amcas-intro {
        font-size: 15px;
        line-height: 1.55;
    }

    .counter-wrapper {
        padding: 14px;

        border-radius: 11px;
    }

    .amcas-section-selector {
        margin-bottom: 12px;
    }

    .amcas-section-label {
        margin-bottom: 6px;

        font-size: 13px;
    }

    .amcas-section-select {
        min-height: 46px;

        padding: 10px 40px 10px 12px;

        font-size: 14px;
        line-height: 1.4;

        background-position:
            calc(100% - 18px) 19px,
            calc(100% - 12px) 19px;
    }

    .counter-metrics {
        gap: 8px;
        margin-bottom: 12px;
    }

    .counter-card {
        min-height: 78px;

        padding: 9px 7px;

        border-radius: 8px;
    }

    .counter-label {
        font-size: 12px;
        letter-spacing: 0.2px;
    }

    .counter-number {
        font-size: 27px;
    }

    .counter-limit {
        font-size: 14px;
    }

    #userWord {
        height: 290px;
        min-height: 145px;

        padding: 13px;

        border-radius: 8px;

        font-size: 16px;
        line-height: 1.55;
    }


    /* -----------------------------------------------------
       Buttons
       ----------------------------------------------------- */

    .counter-actions {
        gap: 8px;
        margin-top: 8px;
    }

    .copyButton,
    .clearButton {
        min-width: 95px;

        padding: 9px 14px;

        font-size: 13px;
    }


    /* -----------------------------------------------------
       Compatibility warning
       ----------------------------------------------------- */

    .amcas-compatibility-alert {
        margin-top: 13px;

        padding: 13px 12px;

        border-left-width: 4px;
        border-radius: 7px;
    }

    .amcas-compatibility-header {
        gap: 9px;
    }

    .amcas-compatibility-icon {
        width: 25px;
        height: 25px;

        font-size: 15px;
    }

    .amcas-compatibility-title {
        font-size: 14px;
    }

    .amcas-compatibility-message {
        font-size: 13px;
    }

    .amcas-compatibility-details {
        margin-top: 12px;
    }

    .amcas-compatibility-group {
        padding: 11px;
    }

    .amcas-compatibility-group-heading {
        align-items: flex-start;
        gap: 8px;
    }

    .amcas-compatibility-group-heading strong {
        font-size: 13px;
    }

    .amcas-compatibility-count {
        padding: 2px 7px;
        font-size: 11px;
    }

    .amcas-compatibility-group-description {
        font-size: 12px;
    }

    .amcas-character-list {
        gap: 6px;
    }

    .amcas-character-item {
        padding: 4px 7px;
        font-size: 12px;
    }

    .amcas-character-item.invisible-character {
        font-size: 11px;
    }

    .amcas-character-code {
        font-size: 10px;
    }

    .amcas-compatibility-note {
        margin-top: 12px;
        padding-top: 10px;

        font-size: 12px;
    }


    /* -----------------------------------------------------
       Content
       ----------------------------------------------------- */

    .amcas-content {
        padding: 23px 17px;
        border-radius: 11px;
    }

    .content-section {
        margin-bottom: 24px;
        padding-bottom: 24px;
    }

    .content-section h2 {
        margin-bottom: 12px;
        font-size: 21px;
    }

    .content-section h3,
    .faq-item h3 {
        font-size: 17px;
    }

    .amcas-guidelines,
    .how-to-list {
        padding-left: 24px;
    }

    .guideline-note {
        padding: 12px 13px;
    }

    .amcas-limit-table-wrapper {
        margin-top: 16px;
        margin-bottom: 20px;

        border-radius: 7px;
    }

    .amcas-limit-table {
        min-width: 520px;
        font-size: 14px;
    }

    .amcas-limit-table th,
    .amcas-limit-table td {
        padding: 11px 12px;
    }

    .amcas-limit-table th:last-child,
    .amcas-limit-table td:last-child {
        width: 145px;
    }

    .amcas-disclosures {
        padding: 17px;
    }

}


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

@media only screen and (max-width: 400px) {

    .amcas-section {
        padding-right: 9px;
        padding-left: 9px;
    }

    .amcas-heading h1 {
        font-size: 25px;
    }

    .counter-wrapper {
        padding: 11px;
    }

    .amcas-section-select {
        min-height: 44px;

        padding-left: 10px;
        padding-right: 36px;

        font-size: 13px;

        background-position:
            calc(100% - 17px) 18px,
            calc(100% - 11px) 18px;
    }

    .counter-card {
        min-height: 73px;
    }

    .counter-label {
        font-size: 11px;
    }

    .counter-number {
        font-size: 24px;
    }

    .counter-limit {
        font-size: 13px;
    }

    #userWord {
        height: 270px;
        min-height: 130px;
    }


    /* -----------------------------------------------------
       Buttons
       ----------------------------------------------------- */

    .counter-actions {
        width: 100%;
        justify-content: flex-end;
    }

    .copyButton,
    .clearButton {
        min-width: 90px;
        padding: 8px 12px;
    }


    /* -----------------------------------------------------
       Compatibility warning
       ----------------------------------------------------- */

    .amcas-compatibility-alert {
        margin-top: 12px;
        padding: 11px 10px;
    }

    .amcas-compatibility-header {
        gap: 8px;
    }

    .amcas-compatibility-icon {
        width: 23px;
        height: 23px;

        font-size: 14px;
    }

    .amcas-compatibility-group-heading {
        display: block;
    }

    .amcas-compatibility-count {
        display: inline-block;
        margin-top: 5px;
    }

    .amcas-character-item {
        max-width: 100%;
    }


    /* -----------------------------------------------------
       Content
       ----------------------------------------------------- */

    .amcas-content {
        padding: 20px 14px;
    }

    .content-section h2 {
        font-size: 20px;
    }

    .amcas-limit-table {
        min-width: 500px;
    }

}


/* =========================================================
   REDUCED MOTION
   ========================================================= */

@media (prefers-reduced-motion: reduce) {

    html {
        scroll-behavior: auto;
    }

    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }

}