* {
    box-sizing: border-box
}

:root {
    --bg: #f7f8fa;
    --surface: #fff;
    --soft: #f1f3f6;
    --text: #151922;
    --muted: #6d7480;
    --border: #e3e6eb;
    --primary: #4f46e5;
    --hover: #4338ca;
    --success: #16803c;
    --shadow: 0 8px 28px rgba(20, 27, 45, .055)
}

body.dark {
    --bg: #0d1016;
    --surface: #151922;
    --soft: #1d222c;
    --text: #f2f4f7;
    --muted: #9aa2af;
    --border: #2b313c;
    --primary: #818cf8;
    --hover: #6366f1;
    --success: #4ade80;
    --shadow: 0 12px 35px rgba(0, 0, 0, .25)
}

body {
    margin: 0;
    min-height: 100vh;
    background: var(--bg);
    color: var(--text);
    font-family: "Noto Sans Bengali", Inter, system-ui, -apple-system, "Segoe UI", sans-serif;
    transition: .2s
}


button,
input {
    font: inherit
}

.head {
    height: 68px;
    max-width: 1180px;
    margin: auto;
    padding: 0 22px;
    display: flex;
    align-items: center;
    justify-content: space-between
}

.header {
    position: sticky;
    top: 0
}

header {
    background: var(--surface);
    border-bottom: 1px solid var(--border)
}

.brand {
    display: flex;
    align-items: center;
    gap: 10px;
    font-weight: 750
}

.brandmark {
    width: 34px;
    height: 34px;
    display: grid;
    place-items: center;
    background: var(--primary);
    border-radius: 9px;
    color: #fff
}

.brandmark svg {
    width: 20px;
    height: 20px;
    fill: none;
    stroke: currentColor;
    stroke-width: 1.8;
    stroke-linecap: round;
    stroke-linejoin: round
}

.theme {
    height: 38px;
    padding: 0 12px;
    display: flex;
    gap: 7px;
    align-items: center;
    background: var(--surface);
    color: var(--text);
    border: 1px solid var(--border);
    border-radius: 9px
}

.theme svg {
    width: 17px;
    height: 17px;
    fill: none;
    stroke: currentColor;
    stroke-width: 1.8;
    stroke-linecap: round;
    stroke-linejoin: round
}

body:not(.dark) .moon,
body.dark .sun {
    display: none
}

main {
    max-width: 1180px;
    margin: auto;
    padding: 48px 22px 70px
}

.eyebrow {
    color: var(--primary);
    font-size: 11px;
    font-weight: 800;
    letter-spacing: 1.4px
}

.hero h1 {
    margin: 8px 0 10px;
    font-size: clamp(32px, 5vw, 46px);
    line-height: 1.08;
    letter-spacing: -1.7px
}

.hero p {
    margin: 0;
    color: var(--muted);
    font-size: 15px
}

.hero {
    margin-bottom: 30px
}

.toolbar {
    display: flex;
    gap: 12px;
    align-items: center;
    margin-bottom: 22px
}

.search {
    position: relative;
    flex: 1
}

.search svg {
    position: absolute;
    left: 14px;
    top: 50%;
    width: 18px;
    transform: translateY(-50%);
    fill: none;
    stroke: var(--muted);
    stroke-width: 1.8
}

.search input {
    width: 100%;
    height: 44px;
    padding: 0 14px 0 41px;
    outline: 0;
    color: var(--text);
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 9px
}

.search input:focus {
    border-color: var(--primary)
}

.cats {
    display: flex;
    gap: 7px;
    flex-wrap: wrap
}

.cat {
    height: 38px;
    padding: 0 12px;
    color: var(--muted);
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 8px;
    font-size: 13px
}

.cat.active {
    color: #fff;
    background: var(--primary);
    border-color: var(--primary)
}

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

.card {
    min-height: 300px;
    padding: 18px;
    display: flex;
    flex-direction: column;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 13px;
    box-shadow: var(--shadow)
}

.cardhead {
    display: flex;
    justify-content: space-between;
    gap: 10px;
    margin-bottom: 13px
}

.title {
    margin: 0;
    font-size: 16px;
    line-height: 1.35
}

.tag {
    padding: 5px 8px;
    color: var(--primary);
    background: var(--soft);
    border-radius: 20px;
    font-size: 10px;
    font-weight: 750;
    white-space: nowrap
}

.prompt {
    flex: 1;
    min-height: 155px;
    max-height: 205px;
    overflow: auto;
    margin: 0;
    padding: 13px;
    white-space: pre-wrap;
    color: var(--muted);
    background: var(--soft);
    border-radius: 9px;
    font: 12.5px/1.62 Roboto;
}

.copy {
    height: 40px;
    margin-top: 13px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    color: #fff;
    background: var(--primary);
    border: 0;
    border-radius: 8px;
    font-size: 13px;
    font-weight: 700
}

.copy:hover {
    background: var(--hover)
}

.copy.copied {
    background: var(--success)
}

.copy svg {
    width: 16px;
    height: 16px;
    fill: none;
    stroke: currentColor;
    stroke-width: 1.8;
    stroke-linecap: round;
    stroke-linejoin: round
}

.empty {
    text-align: center;
    padding: 70px 20px;
    color: var(--muted)
}

.empty svg {
    width: 40px;
    height: 40px;
    fill: none;
    stroke: currentColor;
    stroke-width: 1.7
}

.empty h2 {
    font-size: 18px;
    color: var(--text);
    margin: 12px 0 6px
}

.empty p {
    margin: 0;
    font-size: 13px
}

.toast {
    position: fixed;
    left: 50%;
    bottom: 24px;
    padding: 10px 14px;
    color: #fff;
    background: #171a21;
    border-radius: 8px;
    font-size: 13px;
    opacity: 0;
    transform: translate(-50%, 12px);
    transition: .2s;
    pointer-events: none
}

.toast.show {
    opacity: 1;
    transform: translate(-50%, 0)
}

@media (max-width: 900px) {
    .grid {
        grid-template-columns: repeat(2, minmax(0, 1fr))
    }

    .toolbar {
        flex-direction: column;
        align-items: stretch
    }
}

@media (max-width: 600px) {
    .head {
        height: 62px;
        padding: 0 15px
    }

    .brand {
        font-size: 0
    }

    .brandmark {
        font-size: initial
    }

    main {
        padding: 34px 15px 55px
    }

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

    .cats {
        overflow: auto;
        flex-wrap: nowrap
    }

    .cat {
        white-space: nowrap
    }
}
