@font-face {
    font-family: 'MyFont';
    src: url('5.ttf') format('truetype');
    font-weight: normal;
    font-style: normal;
}

@font-face {
    font-family: 'BodyFont';
    src: url('2.ttf') format('truetype');
    font-weight: normal;
    font-style: normal;
}

:root {
    --main-color: #b5e6ff;
    --second-color: #456C80;
    --color3: #FF670A;
    --color4: #FAAF0C;
    --color5: #806D45;
    --bg-color: rgb(0, 0, 0, 0.8);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    outline: none;
    border: none;
    text-decoration: none;
    font-family: 'BodyFont', sans-serif;
}

.header {
    display: flex;
    position: fixed;
    align-items: center;
    width: 100%;
    padding: 0 7%;
    justify-content: center;
    z-index: 1000;
}

.headerside {
    flex-grow: 0;
}

.nav-links {
    flex-grow: 1;
    background: transparent;
    backdrop-filter: blur(5px);
    transition: background 0.3s;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 5vw 0 5vw;
    padding: 0 50px 0 50px;
    height: 5vh;
    gap: 5vw;
    border-radius: 50px 50px 50px 50px;
}

.nav-links a {
    text-decoration: none;
    font-family: 'MyFont', sans-serif;
    color: var(--main-color);
    font-size: 18px;
    transition: color 0.3s ease;
}

.nav-links a:hover {
    color: var(--second-color);
}

h1 {
    font-family: 'BodyFont', sans-serif;
    font-size: 50px;
}

.main {
    position: relative;
    top: 0;
    left: 0;
    width: 100%;
    text-align: center;
    min-height: 110vh;
    background-image: url('homebd.jpg');
    background-size: cover;
    background-color: var(--bg-color);
    background-blend-mode: darken;
    border-radius: 0 0 20px 20px;
}

.headerarea {
    position: flex;
    min-height: 15vh;
}

.body {
    z-index: 999;
    display: flex;
    width: 100%;
    padding: 10vh 0vh;
    justify-content: center;
    font-family: 'BodyFont', sans-serif;
    color: var(--main-color);
    text-align: center;
}

.input {
    z-index: 998;
    position: absolute;
    display: flex;
    justify-content: center;
    width: 100%;
    min-height: 9vh;
}

.content {
    z-index: 997;
    display: relative;
    position: absolute;
    top: 30vh;
    justify-content: center;
    width: 100%;
    min-height: 70vh;
    opacity: 0;
    color: var(--main-color);
}

.container {
    display: flex;
    margin: 5vh 5vw;
    max-height: 50vh;
}

.sidebar {
    width: 200px;
    background: linear-gradient(to bottom, #b86e00, #8b1c13);
    display: flex;
    flex-direction: column;
    overflow-y: auto;
    transition: width 0.3s ease;
}

.sidebar::-webkit-scrollbar {
    width: 10px;
    margin-top: 20px;
    margin-bottom: 20px;
}

/* Track */
.sidebar::-webkit-scrollbar-track {
    box-shadow: inset 0 0 5px var(--color5);
    padding-top: 10px;
    border-radius: 10px;
}

/* Handle */
.sidebar::-webkit-scrollbar-thumb {
    padding-top: 10px;
    background: var(--second-color);
    border-radius: 10px;
}

.ingredients {
    padding: 10px;
    border-radius: 15px;
}

.ingredient {
    background-color: rgba(0, 0, 0, 0.2);
    margin-bottom: 8px;
    padding: 12px;
    border-radius: 8px;
    cursor: pointer;
    text-align: center;
    transition: all 0.3s ease;
    color: var(--main-color);
    font-weight: bold;
}

.ingredient:hover {
    background-color: rgba(255, 255, 255, 0.2);
}

.ingredient.active {
    background-color: rgba(255, 255, 255, 0.3);
    color: #fff;
}

.ingredient-bar {
    width: 100%;
    height: 6px;
    background: white;
    border-radius: 5px;
    overflow: hidden;
    margin-top: 5px;
}

.ingredient-bar .fill {
    height: 100%;
    background: #3498db;
    width: 0;
    transition: width 0.3s ease;
}

.result-box {
    display: flex;
    flex-direction: column;
    align-items: center;
}

.image-box {
    height: 30vh;
    justify-content: top;
}

.image-box img {
    align-self: start;
    height: 100%;
}

.detailboxarea {
    display: flex;
    flex: auto;
    position: relative;
    background-color: #45120572;
    border-radius: 0 15px 15px 0;
}

.detail-box {
    display: flex;
    position: relative;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    background-color: #e6522d5b;
    width: 100%;
    visibility: hidden;
    overflow: hidden;
}

.ingredient-item {
    position: relative;
    left: 100%;
}

.ingredient-detail {
    display: flex;
    font-size: 18px;
    padding: 40px;
    height: 60%;
    align-items: center;
    justify-content: center;
    color: white;
}

.slider-container {
    display: flex;
    flex-direction: column;
    justify-content: center;
    width: 80%;
    height: 100px;
}


.detail-box h2 {
    font-size: 32px;
    margin-bottom: 20px;
    letter-spacing: 2px;
}

.detail-box p {
    font-size: 18px;
    line-height: 1.6;
}

.pricing {
    display: flex;
    flex-direction: row;
    align-items: center;
    justify-content: space-around;
    margin-top: 10px;
    width: 25vw;
    height: 100%;
}

.pricing-box {
    color: white;
    transition: all 0.3s ease-in-out;
}

.signup-btn {
    padding: 10px 20px;
    background: var(--second-color);
    color: white;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    transition: background 0.1s ease;
}

.signup-btn:hover {
    background: var(--main-color);
}

.body2 {
    font-family: 'BodyFont', sans-serif;
    display: flex;
    justify-content: center;
    color: white;
    text-align: center;
    transition: all 1s ease;
    opacity: 1;
    transform: scale(1);
    height: auto;
}

.ai-input {
    display: flex;
    position: absolute;
    width: 60%;
    font-size: 18px;
    border: 2px solid var(--main-color);
    background-color: var(--bg-color);
    color: var(--main-color);
    border-radius: 30px;
    outline: none;
    resize: none;
}

.ai-input::placeholder {
    color: var(--main-color);
}

.ai-logo {
    position: relative;
    left: 15px;
    top: 50%;
    width: 40px;
    height: 40px;
    z-index: 9999;
}

.inputtext {
    position: relative;
    min-height: 8vh;
    resize: none;
    color: var(--main-color);
    width: 100%;
    padding: 0 15px;
    top: 50%;
    font-size: 20px;
    background: transparent;
    z-index: 9999;
}

.error-msg {
    color: red;
    font-size: 0.9em;
    margin-bottom: 10px;
}

.generate-btn {
    position: flex;
    margin: 2px;
    padding-right: 1vw;
    padding-left: 1vw;
    font-size: 16px;
    top: 50%;
    color: var(--bg-color);
    border: 2px solid var(--main-color);
    background-color: var(--color3);
    border-radius: 30px;
    cursor: pointer;
}

.generate-btn:hover {
    background: var(--second-color);
    transition: background 0.1s;
}

.buy-btn {
    padding: 10px 20px;
    background: rgba(203, 95, 12, 0.6);
    color: white;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    font-size: medium;
    font-family: 'MyFont', sans-serif;
    font-weight: bold;
    transition: background 0.3s ease;
}

.buy-btn:hover {
    background: rgb(41, 102, 121);
}

.body.shrink {
    transition: all 2s ease;
    transform: translateY(-20vh) scaleY(0);
    opacity: 0;
    overflow: hidden;
}

.content.fade-in {
    opacity: 1;
    transition: opacity 2s ease-in-out;
}

.input.rise {
    transition: all 2s ease;
    transform: translateY(-39vh);
}

.promote {
    display: flex;
    position: relative;
    top: 0;
    left: 0;
    width: 100%;
    height: 100vh;
    background-color: wheat;
    opacity: 0.8;
    border-radius: 20px;
}

.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    height: 100vh;
    width: 100vw;
    background-color: rgba(0, 0, 0, 0.4);
    backdrop-filter: blur(5px);
    display: none;
    justify-content: center;
    align-items: center;
    z-index: 1001;
}

.modal-overlay.active {
    display: flex;
}

/* Modal box */
.modal-box {
    width: 970px;
    height: 600px;
    background: #fff;
    display: flex;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
}

.modal-section {
    width: 50%;
    padding: 40px 20px;
    box-sizing: border-box;
}

.modal-section h2 {
    margin-bottom: 20px;
    font-size: 24px;
    text-align: center;
}

.modal-section input {
    width: 100%;
    padding: 12px;
    margin: 10px 0;
    border-radius: 6px;
    border: 1px solid #ccc;
    font-size: 16px;
}