
/* PLUSHIE MEADOW — OUR FIRST COLOURS */

body {
    margin: 0;
    background-color: #f6f5eb;
    font-family: Georgia, serif;
    color: #40543e;
}

/* The top of our website */
header {
    background-color: #e5ebdc;
    text-align: center;
    padding: 40px;
}

/* Main heading */
h1 {
    font-size: 42px;
    color: #526d4d;
    margin-bottom: 5px;
}

/* Little subtitle */
header p {
    color: #788b70;
    font-style: italic;
}

/* Main content */
main {
    max-width: 700px;
    margin: 60px auto;
    padding: 35px;
    background-color: #fffef8;
    border-radius: 20px;
    text-align: center;
}

/* Welcome heading */
h2 {
    color: #71866c;
    font-size: 28px;
}

/* Paragraphs */
main p {
    color: #7b8174;
    line-height: 1.8;
}
/* Navigation menu */

nav {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 15px;
    margin-top: 30px;
}

nav a {
    text-decoration: none;
    color: #526d4d;
    background-color: #f6f5eb;
    padding: 12px 22px;
    border-radius: 25px;
    transition: 0.2s;
}

nav a:hover {
    background-color: #cbd9c1;
}
/* HOMEPAGE PREVIEW CARDS */

.home-sections {
    width: 90%;
    max-width: 1100px;
    margin: 50px auto;
    padding: 0;
    display: flex;
    flex-direction: row;
    justify-content: center;
    align-items: stretch;
    gap: 25px;

    /* Remove the original big white container */
    background-color: transparent;
    border-radius: 0;
}

.preview-card {
    flex: 1;
    min-width: 0;
}

/* Individual cards */

.preview-card {
    flex: 1;
    min-width: 0;
    background-color: #fffef8;
    border-radius: 20px;
    padding: 30px 20px;
    text-align: center;
    min-height: 200px;

    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-start;
}

/* Card headings */

.preview-card h2 {
    color: #526d4d;
    font-size: 26px;
    margin-bottom: 5px;
}

/* Card descriptions */

.preview-card p {
    color: #7b8174;
    line-height: 1.7;
}

/* Card links */

.preview-card a {
    display: inline-block;
    margin-top: auto;
    padding: 10px 20px;
    background-color: #e5ebdc;
    color: #526d4d;
    text-decoration: none;
    border-radius: 25px;
    transition: 0.2s;
}

.preview-card a:hover {
    background-color: #cbd9c1;
}

/* Make cards stack on smaller screens */

@media (max-width: 750px) {
    .home-sections {
        grid-template-columns: 1fr;
    }
}
/* PLUSHIE CARD IMAGE */

.card-image {
    width: 100%;
    height: 150px;
    border-radius: 15px;
    display: flex;
    justify-content: center;
    align-items: center;
    margin-bottom: 20px;

    transition: transform 0.3s ease;
}

.card-image:hover {
    transform: scale(1.08);
}

.plushie-image {
    background-color: #e5ebdc;
}

.card-image span {
    font-size: 75px;
}
/* EVENTS CARD IMAGE */

.event-image {
    background-color: #f1e8d9;
}
/* MY COLLECTION CARD IMAGE */

.collection-image {
    background-color: #e8e6d8;
}
/* COLLECTION PROGRESS PREVIEW */

.collection-stats {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 5px;
    margin: 5px 0 12px;
}

.collection-stats strong {
    font-size: 30px;
    color: #526d4d;
}

.collection-stats span {
    font-size: 14px;
    color: #788b70;
}

/* Progress bar background */

.progress-track {
    width: 100%;
    height: 12px;
    background-color: #e8e6d8;
    border-radius: 20px;
    overflow: hidden;
}

/* Actual progress */

.progress-fill {
    width: 24%;
    height: 100%;
    background-color: #71866c;
    border-radius: 20px;
}
/* ACCOUNT BUTTONS */

.account-area {
    display: flex;
    justify-content: flex-end;
    gap: 12px;
    padding: 15px 5%;
    background-color: #e5ebdc;
}

.account-button {
    text-decoration: none;
    padding: 10px 20px;
    border-radius: 25px;
    font-size: 14px;
    transition: background-color 0.2s ease;
}

.login-button {
    color: #526d4d;
    background-color: #fffef8;
}

.login-button:hover {
    background-color: #f6f5eb;
}

.signup-button {
    color: #ffffff;
    background-color: #71866c;
}

.signup-button:hover {
    background-color: #526d4d;
}

/* ACCOUNT PAGES */

.account-page {
    min-height: 100vh;
    background-color: #e5ebdc;
}

.account-back {
    padding: 25px 5%;
}

.account-back a {
    color: #526d4d;
    text-decoration: none;
}

.account-container {
    max-width: 500px;
    margin: 30px auto;
    padding: 20px;
    background-color: transparent;
}

.account-card {
    background-color: #fffef8;
    padding: 40px;
    border-radius: 25px;
    text-align: center;
}

.account-decoration {
    font-size: 45px;
    margin-bottom: 10px;
}

.account-card h1 {
    color: #526d4d;
    font-size: 32px;
}

.account-intro {
    color: #788b70;
    line-height: 1.7;
    margin-bottom: 30px;
}

.account-card form {
    display: flex;
    flex-direction: column;
    text-align: left;
    gap: 10px;
}

.account-card label {
    color: #526d4d;
    font-size: 14px;
    margin-top: 10px;
}

.account-card input {
    padding: 13px;
    border: 1px solid #dce3d5;
    border-radius: 12px;
    background-color: #f6f5eb;
    font-family: Georgia, serif;
    font-size: 14px;
    outline: none;
}

.account-card input:focus {
    border-color: #71866c;
}

.account-card button {
    margin-top: 20px;
    padding: 14px;
    border: none;
    border-radius: 25px;
    background-color: #71866c;
    color: white;
    font-family: Georgia, serif;
    font-size: 16px;
    cursor: pointer;
}

.account-card button:hover {
    background-color: #526d4d;
}

.account-switch {
    margin-top: 25px;
    color: #788b70;
    font-size: 14px;
}

.account-switch a {
    color: #526d4d;
    font-weight: bold;
    text-decoration: none;
}

/* PERSONAL MEADOW PAGE */

.meadow-page {
    background-color: #f6f5eb;
}

/* TOP HEADER */

.meadow-header {
    background-color: #e5ebdc;
    text-align: center;
    padding: 25px;
}

.meadow-header h1 {
    font-size: 32px;
    margin: 0 0 20px;
}

/* MAIN MEADOW AREA */

.personal-meadow {
    max-width: 1100px;
    width: 90%;
    margin: 40px auto;
    padding: 0;
    background-color: transparent;
}

/* MEADOW BANNER */

/* PERSONAL MEADOW BANNER */

.meadow-banner {
    width: 100%;
    height: 400px;
    background-color: #dce8d3;
    background-image: linear-gradient(
        135deg,
        #e5ebdc,
        #cbd9c1
    );
    display: flex;
    align-items: center;
    justify-content: flex-end;
    overflow: hidden;
    border-radius: 0;
}

.meadow-buddy {
    font-size: 85px;
    margin-right: 10%;
}

/* DIVIDER UNDER BANNER */

.meadow-divider {
    width: 100%;
    height: 3px;
    background-color: #71866c;
}


.meadow-banner-text h2 {
    color: #526d4d;
    font-size: 28px;
}

.meadow-banner-text p {
    color: #788b70;
}

.meadow-buddy {
    font-size: 100px;
    padding: 15px;
}

/* PLAYER PROFILE */

.player-profile {
    display: flex;
    flex-direction: column;
    gap: 20px;
    background-color: #fffef8;
    padding: 25px;
    border-radius: 20px;
    margin-top: 0;
}
/* PLAYER INTRODUCTION */

.player-introduction {
    display: flex;
    align-items: center;
    gap: 20px;
}

.player-avatar {
    flex-shrink: 0;
}
.player-avatar {
    width: 100px;
    height: 100px;
    flex-shrink: 0;
    background-color: #e5ebdc;
    border-radius: 25px;
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 55px;
}

.player-information h2 {
    color: #526d4d;
    margin: 0 0 5px;
}

.player-information p {
    color: #788b70;
    margin: 5px 0 15px;
}

.player-details {
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
    color: #71866c;
    font-size: 14px;
}

/* COLLECTION STATISTICS */

.meadow-statistics {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 20px;
    flex-wrap: wrap;
}

.meadow-stat-card {
    background-color: #e5ebdc;
    width: 85px;
    height: 85px;
    border-radius: 50%;
    padding: 5px;
    box-sizing: border-box;

    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 2px;
}

.meadow-stat-card strong {
    font-size: 22px;
    color: #526d4d;
}

.meadow-stat-card span {
    font-size: 11px;
    color: #788b70;
    line-height: 1.2;
}

/* PLUSHIE LIBRARY */

.plushie-dex {
    background-color: #fffef8;
    border-radius: 25px;
    padding: 30px;
    margin-top: 25px;
}

.library-heading {
    text-align: center;
}

.library-heading h2 {
    color: #526d4d;
}

.library-heading p {
    color: #788b70;
}

/* LIBRARY PROGRESS */

.dex-progress {
    margin-top: 30px;
}

.dex-progress-text {
    display: flex;
    justify-content: space-between;
    color: #526d4d;
    margin-bottom: 10px;
}

.dex-progress-track {
    width: 100%;
    height: 12px;
    background-color: #e8e6d8;
    border-radius: 20px;
    overflow: hidden;
}

.dex-progress-fill {
    width: 24%;
    height: 100%;
    background-color: #71866c;
    border-radius: 20px;
}

/* DEX FILTERS */

.dex-filters {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 12px;
    margin: 30px 0;
}

.dex-filters button {
    border: none;
    padding: 10px 20px;
    border-radius: 25px;
    background-color: #e5ebdc;
    color: #526d4d;
    font-family: Georgia, serif;
    cursor: pointer;
}

/* PLUSHIE GRID */

.plushie-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
}

.dex-plushie h3 {
    color: #526d4d;
    font-size: 17px;
}

.missing-plushie .dex-plushie-image {
    opacity: 0.5;
}
/* PLUSHIE LIBRARY CARDS */

.plushie-grid {
    display: grid;
    grid-template-columns: repeat(6, minmax(0, 1fr));
    gap: 10px;
}

.library-card {
    position: relative;
    background-color: #fffef8;
    padding: 8px;
    border-radius: 12px;
    text-align: left;
    border: 1px solid #e5ebdc;
    display: flex;
    flex-direction: row;
    align-items: center;
    gap: 8px;
    min-width: 0;
    min-height: 65px;
    transition: transform 0.2s ease;
}

.library-card:hover {
    transform: translateY(-3px);
}

/* GREEN IMAGE AREA */

.plushie-image {
    background-color: #dce8d3;
    border-radius: 8px;
    width: 48px;
    height: 48px;
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 28px;
}

/* PLUSHIE NAME */

.library-card h3 {
    color: #526d4d;
    font-size: 12px;
    margin: 0;
    padding-right: 12px;
    overflow-wrap: break-word;
}

/* COLLECTED PLUSHIE */

.collected-plushie::after {
    content: "★";
    position: absolute;
    top: -9px;
    right: -5px;
    color: #d4a52f;
    font-size: 27px;
    z-index: 2;
    text-shadow: 1px 2px 3px #b9a77b;
}

/* MISSING PLUSHIE */

.missing-plushie {
    background-color: #f1eadb;
    border-color: #e9dfca;
}

.missing-plushie .plushie-image {
    background-color: #e8dfcd;
}

.missing-plushie h3 {
    color: #93846c;
}
/* SMALLER SCREENS */

@media (max-width: 750px) {

    .meadow-statistics {
        flex-direction: column;
    }
.plushie-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
}
    }

    .meadow-banner {
        flex-direction: column;
        text-align: center;
    }

    .player-profile {
        flex-direction: column;
        text-align: center;
    }

    .player-details {
        justify-content: center;
    }


@media (max-width: 450px) {

    .plushie-grid {
        grid-template-columns: 1fr;
    }

}
/* HOMEPAGE CARD IMAGE */

.preview-card .card-image {
    width: 100%;
    height: 130px;
    background-color: #e5ebdc;
    border-radius: 15px;

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

    font-size: 55px;
    margin-bottom: 15px;
    flex-shrink: 0;
    transition: transform 0.2s ease;
}

.preview-card .card-image:hover {
    transform: scale(1.04);
}

/* ADD PLUSHIE BUTTON */

.library-heading {
    position: relative;
}

.add-plushie-button {
    position: absolute;
    right: 20px;
    bottom: 0;

    background-color: #71866c;
    color: #ffffff;
    border: none;
    border-radius: 25px;

    padding: 12px 20px;
    font-family: Georgia, serif;
    font-size: 14px;

    cursor: pointer;
    transition: background-color 0.2s ease;
}

.add-plushie-button:hover {
    background-color: #526d4d;
}

@media (max-width: 750px) {
    .add-plushie-button {
        position: static;
        display: block;
        margin: 20px auto 0;
    }
}

/* PLUSHIE POPUP */

.plushie-modal {
    display: none;
    position: fixed;
    inset: 0;
    background-color: rgba(40, 55, 37, 0.55);
    z-index: 1000;

    align-items: center;
    justify-content: center;
    padding: 20px;
}

.plushie-modal.open {
    display: flex;
}

.plushie-modal-content {
    position: relative;
    background-color: #fffef8;
    border-radius: 25px;
    padding: 35px;
    width: 100%;
    max-width: 500px;
    max-height: 85vh;
    overflow-y: auto;
    box-sizing: border-box;
    box-shadow: 0 15px 50px rgba(40, 55, 37, 0.2);
}

.plushie-modal-content h2 {
    color: #526d4d;
    text-align: center;
    font-size: 25px;
    margin: 0 30px 10px;
}

.modal-intro {
    text-align: center;
    color: #788b70;
    line-height: 1.6;
    margin-bottom: 25px;
}

.modal-close {
    position: absolute;
    top: 15px;
    right: 20px;
    border: none;
    background: transparent;
    color: #71866c;
    font-size: 30px;
    cursor: pointer;
}

#plushie-form {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

#plushie-form > label {
    color: #526d4d;
    font-size: 14px;
    margin-top: 10px;
}

#plushie-form select,
#plushie-form input[type="text"],
#plushie-form input[type="date"],
#plushie-form textarea {
    width: 100%;
    box-sizing: border-box;
    padding: 12px;
    border: 1px solid #dce3d5;
    border-radius: 12px;
    background-color: #f6f5eb;
    color: #40543e;
    font-family: Georgia, serif;
    font-size: 14px;
}

.plushie-radio-options {
    display: flex;
    flex-direction: column;
    gap: 12px;
    padding: 10px;
    background-color: #f6f5eb;
    border-radius: 12px;
}

.plushie-radio-options label {
    display: flex;
    align-items: center;
    gap: 8px;
    color: #526d4d;
    font-size: 14px;
    cursor: pointer;
}

.save-plushie-button {
    margin-top: 15px;
    padding: 14px;
    background-color: #71866c;
    color: white;
    border: none;
    border-radius: 25px;
    font-family: Georgia, serif;
    font-size: 15px;
    cursor: pointer;
}

.save-plushie-button:hover {
    background-color: #526d4d;
}

/* PLUSHIE DUPLICATE COUNTER */

.library-card .plushie-count {
    position: absolute;
    bottom: 5px;
    right: 8px;

    color: #526d4d;
    font-family: Georgia, serif;
    font-size: 13px;
    font-weight: bold;
}

.library-card .plushie-count[hidden] {
    display: none;
}

/* MAKE CARDS FEEL CLICKABLE */

.library-card {
    cursor: pointer;
}

/* PLUSHIE COLLECTION JOURNAL */

#plushie-history[hidden],
#back-to-history[hidden],
#plushie-form[hidden] {
    display: none;
}

.history-plushie-heading {
    display: flex;
    align-items: center;
    gap: 15px;
    background-color: #e5ebdc;
    padding: 15px;
    border-radius: 15px;
    margin-bottom: 20px;
}

.history-plushie-image {
    width: 65px;
    height: 65px;
    flex-shrink: 0;
    background-color: #fffef8;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 35px;
}

.history-plushie-heading h3 {
    margin: 0 0 5px;
    color: #526d4d;
}

#plushie-history-count {
    margin: 0;
    color: #788b70;
    font-size: 13px;
}

.history-section-title {
    text-align: center;
    color: #526d4d;
    margin-bottom: 15px;
}

#plushie-history-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin-bottom: 20px;
}

.plushie-history-entry {
    background-color: #f6f5eb;
    border-radius: 15px;
    padding: 16px;
    color: #526d4d;
}

.history-entry-top {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 10px;
    margin-bottom: 10px;
}

.history-entry-top h4 {
    margin: 0;
}

.history-status {
    background-color: #dce8d3;
    border-radius: 20px;
    padding: 5px 10px;
    font-size: 12px;
    white-space: nowrap;
}

.history-status.gifted {
    background-color: #e8dfcd;
    color: #93846c;
}

.plushie-history-entry p {
    margin: 7px 0;
    font-size: 14px;
    line-height: 1.5;
    overflow-wrap: anywhere;
}

.history-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 15px;
}

.history-actions button,
.history-confirmation button {
    border: none;
    border-radius: 20px;
    padding: 9px 13px;
    font-family: Georgia, serif;
    font-size: 12px;
    cursor: pointer;
}

.history-gift-button,
.history-return-button {
    background-color: #e5ebdc;
    color: #526d4d;
}

.history-delete-button {
    background-color: #f0dfda;
    color: #94594e;
}

.history-confirmation {
    margin-top: 12px;
    padding: 12px;
    border: 1px solid #e3c9c0;
    border-radius: 12px;
}

.history-confirmation p {
    margin: 0 0 10px;
}

.history-confirmation button {
    margin-right: 8px;
}

.history-confirm-delete {
    background-color: #94594e;
    color: white;
}

.history-cancel-delete {
    background-color: #e5ebdc;
    color: #526d4d;
}

.history-empty {
    text-align: center;
    color: #788b70;
    padding: 20px;
}

#add-another-plushie,
#back-to-history {
    padding: 12px 18px;
    border: none;
    border-radius: 25px;
    font-family: Georgia, serif;
    cursor: pointer;
}

#add-another-plushie {
    width: 100%;
    background-color: #71866c;
    color: white;
}

#back-to-history {
    background-color: #e5ebdc;
    color: #526d4d;
    margin-bottom: 15px;
}

/* CONDITIONAL PLUSHIE QUESTIONS */

.plushie-extra-question {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin-top: 10px;
}

.plushie-extra-question label {
    color: #526d4d;
    font-size: 14px;
}

#plushie-form .plushie-extra-question input {
    width: 100%;
    box-sizing: border-box;
    padding: 12px;
    border: 1px solid #dce3d5;
    border-radius: 12px;
    background-color: #f6f5eb;
    color: #40543e;
    font-family: Georgia, serif;
    font-size: 14px;
}

.plushie-extra-question[hidden] {
    display: none;
}
/* EDIT PLUSHIE BUTTON */

.history-edit-button {
    background-color: #dce8d3;
    color: #526d4d;
}

.history-edit-button:hover {
    background-color: #cbd9c1;
}
/* WANTED PLUSHIE HEARTS */

.library-card {
    position: relative;
}

.wanted-heart {
    position: absolute;
    top: 5px;
    right: 6px;
    border: none;
    background: transparent;
    color: #a9a69b;
    font-size: 23px;
    line-height: 1;
    cursor: pointer;
    padding: 5px;
    transition: color 0.2s ease, transform 0.2s ease;
}

.wanted-heart:hover {
    color: #d78da2;
    transform: scale(1.15);
}

.wanted-heart.is-wanted {
    color: #d78da2;
}

.wanted-heart[hidden] {
    display: none;
}
/* REAL PLUSHIE IMAGES */

.plushie-image img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    display: block;
}
/* PLUSHIE JOURNAL IMAGES */

.history-plushie-image img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    display: block;
}

/* LIBRARY TOOLBAR */


.library-toolbar {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 24px;
    flex-wrap: wrap;
    margin: 24px 0;
}

.library-search {
    flex: 0 1 320px;
    width: 100%;
    max-width: 320px;
    min-width: 190px;
}

.library-search input {
    width: 100%;
    padding: 12px 16px;
    border: 1px solid #dce3d5;
    border-radius: 12px;
    background: #fffdf7;
    color: #526d4d;
    font-family: Georgia, serif;
    font-size: 14px;
}

.library-search input:focus {
    outline: 2px solid #a9bea0;
    outline-offset: 2px;
}

.library-toolbar .dex-filters {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

/* PLUSHIE CATEGORY SECTIONS */

.plushie-category {
    margin: 30px 0 42px;
}

.plushie-category[hidden] {
    display: none;
}

.plushie-category-heading {
    display: flex;
    align-items: center;
    gap: 20px;
    margin-bottom: 20px;
}

.plushie-category-heading h3 {
    color: #526d4d;
    font-family: Georgia, serif;
    font-size: 21px;
    white-space: nowrap;
    margin: 0;
}

.plushie-category-line {
    height: 1px;
    background: #d7ddcd;
    flex: 1;
}

@media (max-width: 650px) {
    .library-toolbar {
        align-items: stretch;
        flex-direction: column;
    }

    .library-toolbar .dex-filters {
        justify-content: flex-start;
    }

    .plushie-category-heading h3 {
        font-size: 18px;
    }
}

/* KEEP THE MEADOW CONTENT CENTRED */

.player-profile {
    width: calc(100% - 48px);
    max-width: 900px;
    margin-left: auto;
    margin-right: auto;
    box-sizing: border-box;
}

.plushie-library {
    width: calc(100% - 48px);
    max-width: 1400px;
    margin-left: auto;
    margin-right: auto;
    box-sizing: border-box;
}
/* EXTRA BREATHING ROOM ON SMALL SCREENS */

@media (max-width: 650px) {
    .player-profile,
    .plushie-library {
        width: calc(100% - 32px);
    }
}

/* PUBLIC PLUSHIE LIBRARY */

.public-library-page {
    background: #f7f6ed;
}

.public-library-container {
    width: calc(100% - 48px);
    max-width: 1400px;
    margin: 40px auto 80px;
    box-sizing: border-box;
}

.public-library-intro {
    text-align: center;
    margin-bottom: 42px;
}

.public-library-intro h2 {
    color: #526d4d;
    font-size: 32px;
    margin-bottom: 12px;
}

.public-library-intro p {
    color: #7b856e;
    max-width: 650px;
    margin: 0 auto 24px;
    line-height: 1.7;
}

.public-library-total {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: #e5eadc;
    color: #526d4d;
    padding: 12px 24px;
    border-radius: 30px;
}

.public-library-toolbar {
    display: flex;
    justify-content: center;
    align-items: center;
    flex-wrap: wrap;
    gap: 14px;
    margin-bottom: 36px;
}

.public-library-toolbar input,
.public-library-toolbar select {
    background: #fffdf7;
    border: 1px solid #dce3d5;
    border-radius: 12px;
    padding: 12px 16px;
    font-family: Georgia, serif;
    font-size: 14px;
    color: #526d4d;
}

.public-library-toolbar input {
    width: 300px;
    max-width: 100%;
}

.public-plushie-category {
    margin-bottom: 42px;
}

.public-plushie-cards {
    display: grid;
    grid-template-columns: repeat(6, minmax(0, 1fr));
    gap: 10px;
    margin-top: 20px;
}

.public-plushie-card {
    display: flex;
    align-items: center;
    gap: 8px;
    min-width: 0;
    min-height: 76px;
    padding: 10px;
    box-sizing: border-box;
    background: #fffdf8;
    border: 1px solid #dce7d4;
    border-radius: 12px;
    color: #526d4d;
    font-family: Georgia, serif;
    font-size: 13px;
    font-weight: bold;
    cursor: default;
}

.public-plushie-card img {
    width: 46px;
    height: 46px;
    object-fit: contain;
    flex-shrink: 0;
    border-radius: 8px;
    background: #e5eadc;
}

.public-plushie-card span {
    overflow-wrap: anywhere;
}

.public-plushie-card[hidden],
.public-plushie-category[hidden],
#public-no-results[hidden] {
    display: none;
}

#public-no-results {
    text-align: center;
    color: #7b856e;
    margin: 40px 0;
}

@media (max-width: 1100px) {
    .public-plushie-cards {
        grid-template-columns: repeat(4, minmax(0, 1fr));
    }
}

@media (max-width: 750px) {
    .public-plushie-cards {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 480px) {
    .public-library-container {
        width: calc(100% - 32px);
    }

    .public-plushie-cards {
        grid-template-columns: 1fr;
    }
}

/* HOMEPAGE FEATURE CARDS */

.home-feature-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 28px;
    max-width: 1100px;
    width: calc(100% - 48px);
    margin: 48px auto 80px;
}

.home-feature-card {
    background: #fffdf8;
    border-radius: 22px;
    padding: 24px;
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
    box-sizing: border-box;
}

.home-feature-images {
    width: 100%;
    min-height: 160px;
    background: #e5eadc;
    border-radius: 16px;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 10px;
    padding: 16px;
    box-sizing: border-box;
}

.home-feature-images img {
    width: 29%;
    max-width: 125px;
    height: 125px;
    object-fit: contain;
    transition: transform 0.2s ease;
}

.home-feature-images img:hover {
    transform: translateY(-5px);
}

.home-feature-card h2 {
    color: #526d4d;
    font-size: 25px;
    margin: 26px 0 12px;
}

.home-feature-stat {
    display: flex;
    flex-direction: column;
    gap: 5px;
    color: #526d4d;
}

.home-feature-stat strong {
    font-size: 24px;
}

.home-feature-stat span {
    font-size: 14px;
}

.home-feature-card p {
    color: #7b856e;
    line-height: 1.7;
    max-width: 350px;
    margin: 22px auto;
}

.home-feature-button {
    display: inline-block;
    margin-top: auto;
    padding: 12px 24px;
    background: #e5eadc;
    color: #526d4d;
    border-radius: 30px;
    text-decoration: none;
    font-family: Georgia, serif;
}

.home-feature-button:hover {
    background: #d3dfca;
}

@media (max-width: 700px) {
    .home-feature-grid {
        grid-template-columns: 1fr;
    }

    .home-feature-images img {
        height: 95px;
    }
}

/* EDIT MY MEADOW BUTTON */

.edit-meadow-button {
    margin: 12px 0;
    padding: 9px 18px;
    background: #e5eadc;
    color: #526d4d;
    border: 1px solid #d3dfca;
    border-radius: 24px;
    font-family: Georgia, serif;
    cursor: pointer;
}

.edit-meadow-button:hover {
    background: #d3dfca;
}

/* MEADOW SETUP POPUP */

.meadow-setup-overlay {
    position: fixed;
    inset: 0;
    z-index: 9999;
    background: rgba(37, 54, 36, 0.55);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    box-sizing: border-box;
}

.meadow-setup-overlay[hidden],
.meadow-setup-step[hidden],
.meadow-setup-actions button[hidden] {
    display: none !important;
}

body.meadow-setup-open {
    overflow: hidden;
}

.meadow-setup-panel {
    position: relative;
    width: 100%;
    max-width: 580px;
    max-height: 90vh;
    overflow-y: auto;
    background: #fffdf8;
    border-radius: 24px;
    padding: 36px;
    box-sizing: border-box;
    box-shadow: 0 15px 50px rgba(0, 0, 0, 0.18);
    color: #526d4d;
}

.meadow-setup-panel h2 {
    margin: 8px 0 26px;
    color: #526d4d;
    font-size: 27px;
}

.meadow-setup-panel h3 {
    font-size: 19px;
}

.meadow-setup-progress {
    color: #8a9b80;
    font-size: 13px;
}

.meadow-setup-close {
    position: absolute;
    top: 16px;
    right: 20px;
    background: transparent;
    border: none;
    color: #526d4d;
    font-size: 28px;
    cursor: pointer;
}

.meadow-setup-step label {
    display: block;
    margin: 18px 0 8px;
    font-weight: bold;
}

.meadow-setup-step input:not([type="file"]),
.meadow-setup-step select,
.meadow-setup-step textarea {
    width: 100%;
    box-sizing: border-box;
    padding: 12px;
    background: white;
    border: 1px solid #dce3d5;
    border-radius: 12px;
    color: #526d4d;
    font-family: Georgia, serif;
    font-size: 15px;
}

.meadow-choice-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
    margin: 20px 0;
}

.meadow-choice {
    background: #f7f6ed;
    border: 2px solid transparent;
    border-radius: 14px;
    padding: 12px;
    cursor: pointer;
    color: #526d4d;
    font-family: Georgia, serif;
}

.meadow-choice.selected {
    border-color: #79986e;
    background: #e5eadc;
}

.meadow-choice img {
    display: block;
    width: 100%;
    height: 95px;
    object-fit: contain;
    margin-bottom: 8px;
}

.meadow-banner-swatch {
    height: 90px;
    border-radius: 10px;
    margin-bottom: 8px;
}

.meadow-choice span {
    display: block;
    font-size: 13px;
}

.meadow-setup-step input[type="file"] {
    max-width: 100%;
    font-size: 13px;
}

.meadow-setup-actions {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    margin-top: 30px;
}

.meadow-setup-actions button {
    background: #e5eadc;
    border: none;
    border-radius: 24px;
    padding: 12px 20px;
    color: #526d4d;
    font-family: Georgia, serif;
    cursor: pointer;
}

.meadow-setup-actions button:hover {
    background: #d3dfca;
}

/* SAVED PROFILE AVATAR */

.player-avatar .meadow-profile-avatar-image {
    width: 100%;
    height: 100%;
    object-fit: contain;
    border-radius: inherit;
}

@media (max-width: 600px) {
    .meadow-setup-panel {
        padding: 26px 20px;
    }

    .meadow-choice-grid {
        gap: 8px;
    }
}

/* PERSONAL MEADOW PROFILE POLISH */

.player-profile {
    position: relative;
    padding-top: 32px;
}

/* EDIT BUTTON IN TOP-RIGHT CORNER */

.player-profile > .edit-meadow-button {
    position: absolute;
    top: 20px;
    right: 24px;
    margin: 0;
    padding: 10px 18px;
    border-radius: 24px;
    background: #e5eadc;
    border: 1px solid #d3dfca;
    color: #526d4d;
    font-family: Georgia, serif;
    font-size: 13px;
    cursor: pointer;
    z-index: 2;
}

.player-profile > .edit-meadow-button:hover {
    background: #d3dfca;
}

/* KEEP PROFILE INFORMATION TOGETHER */

.player-information {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 8px;
    padding-right: 175px;
}

.player-information h2 {
    margin: 0;
}

.player-information > p {
    margin: 0;
    line-height: 1.6;
}

.player-details {
    display: flex;
    flex-wrap: wrap;
    gap: 8px 20px;
    margin-top: 4px;
}

/* SMALL SCREENS */

@media (max-width: 650px) {
    .player-profile > .edit-meadow-button {
        position: static;
        display: block;
        margin: 0 0 20px auto;
    }

    .player-information {
        padding-right: 0;
    }
}

/* PALIA VILLAGER AVATAR GALLERY */

#setup-avatar-options {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    max-height: 350px;
    overflow-y: auto;
    gap: 12px;
    padding: 8px;
}

#setup-avatar-options .meadow-choice {
    padding: 10px 6px;
    border-radius: 14px;
}

#setup-avatar-options .meadow-choice img {
    width: 100%;
    height: 75px;
    object-fit: contain;
    margin-bottom: 6px;
}

#setup-avatar-options .meadow-choice span {
    font-size: 12px;
}

@media (max-width: 480px) {
    #setup-avatar-options {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }
}

/* PALIA LANDSCAPE BANNER GALLERY */

#setup-banner-options {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    max-height: 360px;
    overflow-y: auto;
    gap: 12px;
    padding: 8px;
}

#setup-banner-options .meadow-choice {
    padding: 8px;
}

#setup-banner-options .meadow-banner-preview {
    width: 100%;
    height: 110px;
    object-fit: cover;
    border-radius: 10px;
    margin-bottom: 8px;
}

#setup-banner-options .meadow-choice span {
    font-size: 12px;
}

@media (max-width: 480px) {
    #setup-banner-options {
        grid-template-columns: 1fr;
    }
}
/* TWITCH ACCOUNT DISPLAY */

.account-area {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 12px;
}

.account-username {
    color: #647d63;
    font-weight: 600;
    font-size: 14px;
}

.account-area button {
    cursor: pointer;
}
/* HIDE PERSONAL MEADOW WHILE CHECKING LOGIN */

body.meadow-page.auth-checking {
    visibility: hidden;
}
/* GIFTED PLUSHIE HISTORY MARKER */

.plushie-history-marker {
    position: absolute;
   bottom: 5px;
right: 5px;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 30px;
    height: 30px;
    background: #fff5e8;
    border: 1px solid #e8d5bc;
    border-radius: 50%;
    font-size: 15px;
    box-shadow: 0 2px 6px rgba(80, 60, 40, 0.1);
    pointer-events: none;
    z-index: 2;
}

.plushie-history-marker[hidden] {
    display: none;
}
/* KEEP THE GIFT MARKER INSIDE ITS PLUSHIE CARD */

.plushie-grid .library-card {
    position: relative;
}
/* FAVOURITE PLUSHIE ON MEADOW PROFILE */

.player-details {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 18px;
}

.meadow-favourite {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    vertical-align: middle;
}

.meadow-favourite-image {
    width: 22px;
    height: 22px;
    object-fit: contain;
    flex-shrink: 0;

    position: relative;
    z-index: 1;

    transition: transform 0.25s ease;
    transform-origin: center;
    cursor: pointer;
}

.meadow-favourite-image:hover {
    transform: scale(3);
    z-index: 10;
}
/* WATERCOLOUR STORYBOOK LIBRARY ICON */

.library-title {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
}

.library-title-icon {
    width: 36px;
    height: 36px;
    object-fit: contain;
    flex-shrink: 0;
}
/* MY PLUSHIE LIBRARY - WATERCOLOUR BACKGROUND */

.library-storybook-card {
    position: relative;
    isolation: isolate;

    width: fit-content;
    max-width: 100%;
    box-sizing: border-box;
    margin: 0 auto;

    padding: 65px 65px;

    background: transparent;
    border: none;
    border-radius: 0;

    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
}

/* Watercolour illustration behind the text */

.library-storybook-card::before {
    content: "";
    position: absolute;
    inset: 0;
    z-index: -1;

    background-image: url("images/icons/plushie-meadow-storybook.png");
    background-repeat: no-repeat;
    background-position: center 55%;
    background-size: 70% auto;

    opacity: 0.35;
    pointer-events: none;
}

.library-storybook-card .library-title {
    display: block;
    margin: 0;
    position: relative;
}

.library-storybook-card p {
    margin: 8px 0 0;
    position: relative;
}
/* CENTRE USER PROFILE OVER THE MEADOW BANNER */

.player-profile {
    position: relative;
    z-index: 2;
    margin-top: -300px;
    margin-bottom: 200px;
    padding-top: 12px;
    padding-bottom: 12px;
}
/* PLAYER PROFILE - SIDE BY SIDE LAYOUT */

.player-profile-layout {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
}

.player-profile-layout .player-introduction {
    display: flex;
    align-items: center;
    flex: 1;
    min-width: 0;
    gap: 15px;
}

.player-profile-layout .player-information {
    flex: 1;
    min-width: 0;
    text-align: left;
}

.player-profile-layout .player-information h2 {
    text-align: left;
}

.player-profile-layout .player-information p {
    text-align: center;
}
.player-profile-layout .player-information h2 {
    white-space: nowrap;
}

.player-profile-layout .player-details {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 6px;
}

.player-profile-layout .player-details span {
    display: flex;
    align-items: center;
    justify-content: flex-start;
    gap: 5px;
    text-align: left;
    margin: 0;
    width: 100%;
}
/* ALIGN PROFILE DETAIL ICONS */

.player-profile-layout .player-details .detail-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 24px;
    flex: 0 0 24px;
}
.player-profile-right {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;
    flex-shrink: 0;
}

.player-profile-right .meadow-statistics {
    display: flex;
    justify-content: center;
    gap: 10px;
}

/* KEEP THE PROFILE RESPONSIVE */

@media (max-width: 700px) {
    .player-profile-layout {
        flex-direction: column;
    }
}
/* MEADOW HEADER SUBTITLE */

.meadow-header-subtitle {
    font-size: 15px;
    font-weight: 500;
    color: #789477;
    margin: 4px 0 0;
    letter-spacing: 1px;
}