* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

.quote-day,
.search-section,
.quotes-container,
.menu-btn {
    margin: 0;
    padding-left: 0;
    padding-right: 0;
}

body {
    font-family: 'Poppins', sans-serif;
    background: #0f172a;
    color: white;
    height: 100%;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 8%;
    background: #111827;
    position: sticky;
    top: 0;
    z-index: 100;
}

.logo {
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 1.5rem;
    font-weight: 700;
    flex-shrink: 0;
}

img {
    max-width: 100%;
    height: auto;
}

.logo img {
    width: 50px;
    height: 50px;
    object-fit: contain;
    border-radius: 10px;
}

.logo span {
    white-space: normal;
    line-height: 1;
}

.logo a {
    display: flex;
    align-items: center;
    gap: 12px;
    text-decoration: none;
    color: white;
}

.logo a:visited {
    color: white;
}

.logo a:hover {
    color: #fbbf24;
}

nav {
    display: flex;
    gap: 20px;
    align-items: center;
    margin-left: 20px;
}

nav a {
    text-decoration: none;
    color: white;
    transition: .3s;
}

nav a:hover {
    color: #fbbf24;
}

.main-layout {
    display: grid;
    grid-template-columns: 1fr 0px;
    align-items: start;
    flex: 1;
}

.menu-btn {
    background: none;
    border: none;
    color: white;
    font-size: 28px;
    line-height: 0.2;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
}

.sidebar {
    position: fixed;
    top: 0;
    right: -320px;
    width: 200px;
    height: auto;
    background: #0f1c38;
    padding: 26px 0px 0px 25px;
    transition: 0.3s ease;
    z-index: 999;
}

.sidebar.active {
    right: 0;
}

.sidebar ul {
    list-style: none;
}

.sidebar li {
    margin: 15px 0;
}

.sidebar a {
    color: white;
    text-decoration: none;
}

.sidebar a:hover {
    color: #fbbf24;
}

.search-section {
    padding: 20px 8%;
}

.close-btn {
    position: absolute;
    top: 23px;
    right: 15px;
    background: none;
    border: none;
    color: white;
    font-size: 25px;
    cursor: pointer;
}

.close-btn:hover {
    color: #fbbf24;
}

.search-wrapper {
    position: relative;
}

#searchInput {
    width: 100%;
    padding: 16px 55px 16px 20px;
    background: #414141;
    border: none;
    border-radius: 12px;
    color: #ffffff;
    font-size: 16px;
    outline: none;
}

#searchInput::placeholder {
    color: #9b9b9b;
}

.search-box {
    width: 100%;
    padding: 16px 20px;
    background: #414141;
    border: none;
    border-radius: 12px;
    color: #fff;
    font-size: 16px;
    outline: none;
}

.search-box::placeholder {
    color: #9b9b9b;
}

.clear-search {
    position: absolute;
    right: 25px;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    color: #ff4d4d !important;
    font-size: 20px;
    font-weight: 700;
    cursor: pointer;
    display: none;
    z-index: 10;
}

.clear-search:hover {
    color: #fbbf24;
}

#searchInput {
    width: 100%;
    padding: 16px 55px 16px 20px;
    background: #414141;
    border: none;
    border-radius: 12px;
    color: #ffffff;
    font-size: 16px;
    outline: none;
}

#searchInput::placeholder {
    color: #9b9b9b;
}

#searchInput::-webkit-search-cancel-button {
    -webkit-appearance: none;
    appearance: none;
}

.search-suggestions {
    position: absolute;
    top: 100%;
    left: 0;
    width: 100%;
    background: #1e293b;
    border-radius: 10px;
    margin-top: 5px;
    overflow: hidden;
    display: none;
    z-index: 1000;
}

.suggestion-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 15px;
    cursor: pointer;
}

.suggestion-item:hover {
    background: #334155;
}

.delete-search {
    color: #f87171;
    cursor: pointer;
    font-size: 14px;
    z-index: 10;
}

.suggestion-title {
    color: #fbbf24;
    padding: 10px 15px;
    font-weight: 600;
    border-bottom: 1px solid #334155;
}

.search-text {
    flex: 1;
    cursor: pointer;
     display:block;
    width:100%;
}

.suggestion-item:hover .search-text {
    color: #fbbf24;
}

.no-results {
    display: none;
    text-align: center;
    color: #fbbf24;
    font-size: 22px;
    font-weight: 600;
    margin: 20px 0 40px;
}

.quote-day {
    max-height: 0;
    opacity: 0;
    overflow: hidden;

    margin: 0 8%;
    padding: 0 30px;

    background: #1e293b;
    border-radius: 15px;
    text-align: center;

    transition:
        max-height 0.5s ease,
        opacity 0.5s ease,
        padding 0.5s ease,
        margin 0.5s ease;
}

.quote-day.show {
    max-height: 300px;
    opacity: 1;

    margin: 5px 8%;
    padding: 30px;
}

.quote-day h2 {
    color: #fbbf24;
    margin-bottom: 15px;
}

.quote-day p {
    font-size: 1.2rem;
    line-height: 1.8;
}

.quotes-container {
    padding: 5px 8% 40px;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    justify-content: center;
    gap: 30px;
}

.quote-card {
    background: #1e293b;
    border-radius: 15px;
    overflow: hidden;
    transition: .3s;
    width: 100%;
    max-width: 450px;
}

.quote-card.hidden {
    display: none;
}

.quotes-container.filtered {
    grid-template-columns: repeat(auto-fit, minmax(320px, 450px));
    justify-content: center;
}

.current-category {
    width: 84%;
    margin: 0 auto 20px;
    font-size: 18px;
    font-weight: 600;
    color: #fbbf24;
}

.quote-card:hover {
    transform: translateY(-8px);
}

.quote-card img {
    width: 100%;
    aspect-ratio: 4/5;
    object-fit: cover;
    display: block;
}

.quote-content {
    padding: 8px 22px 14px 22px;
}

.quote-content p {
    line-height: 1.8;
    color: #d1d5db;
}

.hidden {
    display: none;
}



.about-wrapper {
    display: flex;
    justify-content: center;
    padding: 20px 20px;
}

.about {
    padding: 20px 40px 20px 40px;
    background: #1e293b;
    border-radius: 15px;
    color: #ffffff;
}

.about h1 {
    color: #fbbf24;
    margin-bottom: 20px;
    text-align: center;
}

.about p {
    line-height: 1.9;
    margin-bottom: 20px;
    color: #d1d5db;
}

.back-home {
    display: inline-flex;
    align-items: center;
    justify-content: center;

    width: fit-content;

    margin: 20px 0 0 22px;
    padding: 10px 20px;

    background: #fbbf24;
    color: #0f172a;
    text-decoration: none;
    border-radius: 8px;
    font-weight: 600;

    transition: 0.3s;
}

.back-home:hover {
    background: #f59e0b;
    transform: translateY(-2px);
}

.back-home-wrapper {
    padding: 20px;
}

.feedback-form {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.feedback-form textarea,
.feedback-form input {
    width: 100%;
    margin: 0px 300px 0px 0px;
    padding: 15px;
    border: none;
    border-radius: 10px;
    font-size: 16px;
    font-family: 'Poppins', sans-serif;
}

.feedback-form textarea {
    resize: vertical;
}

.feedback-form button {
    padding: 15px;
    border: none;
    border-radius: 10px;
    background: #fbbf24;
    color: #0f172a;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: .3s;
}

.feedback-form button:hover {
    background: #f59e0b;
}

footer {
    background: #111827;
    padding: 0px 20px 20px 20px;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    margin-top: auto;
}

.footer-links {
    margin-bottom: 12px;
}

.footer-links a {
    color: #d1d5db;
    text-decoration: none;
    margin: 0 10px;
    transition: 0.3s;
}

.footer-links a:hover {
    color: #fbbf24;
}

.footer-links span {
    color: #6b7280;
}

footer p {
    color: #9ca3af;
    font-size: 14px;
}

@media (max-width: 600px) {

    body {
        overflow-x: hidden;
    }

    .back-home {
        display: inline-flex;
        align-items: center;
        justify-content: center;

        width: fit-content;

        margin: 20px 0 0 23px;
        padding: 10px 20px;
        font-size: 12px;
        background: #fbbf24;
        color: #0f172a;
        text-decoration: none;
        border-radius: 8px;
        font-weight: 600;

        transition: 0.3s;
    }

    .back-home:hover {
        background: #f59e0b;
        transform: none;
    }

    .back-home-wrapper {
        padding: 20px;
    }

    header {
        flex-direction: row;
        justify-content: space-between;
        padding: 12px 15px;
    }

    .logo {
        font-size: 1.1rem;
    }

    .logo img {
        width: 40px;
        height: 40px;
    }

    .logo span {
        font-size: 0.95rem;
    }

    nav {
        margin-left: 0;
        gap: 12px;
    }

    nav a {
        display: none;
    }

    .menu-btn {
        font-size: 30px;
    }

    .quote-day {
        max-height: 0;
        opacity: 0;
        overflow: hidden;

        margin: 0 8%;
        padding: 0 30px;
    }

    .quote-day.show {
        margin: 10px 15px;
        padding: 20px;
    }

    .quote-day h2 {
        font-size: 1.5rem;
    }

    .quote-day p {
        font-size: 1rem;
        line-height: 1.6;
    }

    .search-section {
        padding: 12px 15px;
    }

    #searchInput {
        padding: 12px;
        font-size: 15px;
    }

    .quotes-container {
        padding: 0 15px 20px;
        grid-template-columns: 1fr;
        gap: 20px;
    }

    .quote-card {
        max-width: 100%;
    }

    .about {
        margin: 15px;
        padding: 25px;
    }

    .about h1 {
        font-size: 1.8rem;
    }

    .about p {
        font-size: 0.95rem;
    }

    .sidebar {
        width: 180px;
        height: auto;
        overflow-y: auto;
        padding: 20px 0px 0px 20px;
    }

    .close-btn {
        position: absolute;
        top: 19px;
        right: 15px;
        background: none;
        border: none;
        color: white;
        font-size: 23px;
    }

    .close-btn:hover {
        color: #fbbf24;
    }

    .about-wrapper {
        display: flex;
        justify-content: center;
        padding: 10px 5px;
    }

    .about {
        padding: 20px;
        background: #1e293b;
        border-radius: 15px;
        color: #ffffff;
    }

    .about h1 {
        color: #fbbf24;
        margin-bottom: 10px;
        text-align: center;
        font-size: 1.6rem;
    }

    .about h2 {
        margin-top: 20px;
        font-size: 1.2rem;
        color: #ffffff;
    }

    .about p {
        line-height: 1.9;
        margin-bottom: 10px;
        color: #d1d5db;
        font-size: 0.95rem;
    }


    footer {
        background: #111827;
        padding: 10px 20px;
        text-align: center;
        padding: 5px 20px 20px 20px;
    }

    .footer-links {
        display: flex;
        flex-direction: row;
        margin-bottom: 15px;
    }

    .footer-links a {
        padding: 0;
        text-decoration: none;
        color: #d1d5db;
        font-size: 15px;
    }

    .footer-links span {
        display: none;
    }
}