/* =============================================================================
   GLOBAL RESET
============================================================================= */

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


/* =============================================================================
   BODY
============================================================================= */

body.single-post.has-custom-prompt-layout {
    background: #eef3f9;
}


/* =============================================================================
   MAIN CONTAINER
============================================================================= */

body.single-post.has-custom-prompt-layout .wp-block-group {
    max-width: 1280px;
    margin: 0 auto;
    padding-top: 36px;
    padding-bottom: 60px;
    gap: 30px;
    align-items: flex-start;
}


/* =============================================================================
   MAIN POST CARD
============================================================================= */

body.single-post.has-custom-prompt-layout article.post {
    background: #ffffff;
    padding: 28px;
    border-radius: 24px;
    border: 1px solid #e9eef5;
    box-shadow: 0 16px 42px rgba(15, 23, 42, 0.07);
}


/* =============================================================================
   POST HEADER
============================================================================= */

body.single-post.has-custom-prompt-layout .entry-header {
    margin-bottom: 18px;
}

body.single-post.has-custom-prompt-layout .entry-title {
    margin-bottom: 12px;
    font-size: 42px;
    line-height: 1.15;
    font-weight: 800;
    letter-spacing: -0.6px;
    color: #0f172a;
}

body.single-post.has-custom-prompt-layout .entry-meta,
body.single-post.has-custom-prompt-layout .entry-meta a {
    font-size: 14px;
    font-weight: 600;
    color: #64748b;
}


/* =============================================================================
   FEATURED IMAGE — Injected after title via functions.php
============================================================================= */

body.single-post.has-custom-prompt-layout .post-featured-image-after-title {
    width: 100%;
    margin: 0 0 26px 0;
    overflow: hidden;
    border-radius: 20px;
    box-shadow: 0 12px 36px rgba(15, 23, 42, 0.10);
    display: block;
    line-height: 0;
}

body.single-post.has-custom-prompt-layout .post-featured-image-after-title img {
    width: 100%;
    height: auto;
    max-height: 550px;
    object-fit: cover;
    object-position: center;
    display: block;
    border-radius: 20px;
}


/* =============================================================================
   POST CONTENT
============================================================================= */

body.single-post.has-custom-prompt-layout .entry-content {
    margin-top: 0;
}

body.single-post.has-custom-prompt-layout .entry-content p {
    margin-bottom: 16px;
    font-size: 16px;
    line-height: 1.8;
    color: #334155;
}


/* =============================================================================
   PROMPT ITEM CARD
   - Each [prompt_item] shortcode renders as one of these cards
   - Single clean container, no nested boxes
============================================================================= */

body.single-post.has-custom-prompt-layout .prompt-item-card {
    margin: 22px 0 30px;
    padding: 20px;
    background: #ffffff;
    border: 1px solid #e7edf5;
    border-radius: 20px;
    box-shadow: 0 10px 28px rgba(15, 23, 42, 0.05);
}

body.single-post.has-custom-prompt-layout .prompt-item-header {
    margin-bottom: 14px;
}

body.single-post.has-custom-prompt-layout .prompt-item-badge,
body.single-post.has-custom-prompt-layout .prompt-box-badge {
    display: inline-block;
    padding: 7px 12px;
    margin-bottom: 10px;
    border-radius: 999px;
    background: #eef2ff;
    color: #4f46e5;
    font-size: 12px;
    font-weight: 700;
    line-height: 1;
}

body.single-post.has-custom-prompt-layout .prompt-item-title {
    margin: 0 0 16px 0;
    font-size: clamp(16px, 2.5vw, 22px) !important;
    line-height: 1.25;
    font-weight: 600;
    color: #0f172a;
}


/* =============================================================================
   PROMPT IMAGE — Horizontal collage style
   Wide, short height, fully visible, no cropping
============================================================================= */

body.single-post.has-custom-prompt-layout .prompt-item-image-wrap {
    width: 100%;
	max-height:400px;
    margin: 0 0 18px 0;
    overflow: hidden;
    border-radius: 20px !important;
    display: flex;
    justify-content: center;
    align-items: center;
/*     background: #f1f5f9; */
    position: relative;
}

body.single-post.has-custom-prompt-layout .prompt-item-image {
    width: auto;
/*     height: 100%; */
	max-height:400px;
    object-fit: contain;
    object-position: center;
    display: block;
    border-radius: 20px !important;
    min-width: 0;
	border-radius:20px !important;
	
}


/* =============================================================================
   LEGACY PROMPT BOX — [prompt_box] shortcode
   Kept for backward compatibility with older posts
============================================================================= */

body.single-post.has-custom-prompt-layout .prompt-text-box {
    margin-bottom: 14px;
    padding: 14px 16px;

    background: #f8fafc;
/*     background: #2145e6; */

    border: 1px solid #dbe7f3;
    border-radius: 14px;
}

body.single-post.has-custom-prompt-layout .prompt-text {
    color: #1e293b;
/*     color: #ffffff; */

    font-family: Arial, sans-serif;
    font-size: 15px;
    line-height: 1.75;

    white-space: pre-wrap;
    word-break: break-word;
    text-align: left;

    margin: 0;
    padding: 0;

    /* Collapsed state — shows 3 lines */
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* Expanded state — toggled by View Full Prompt button */
body.single-post.has-custom-prompt-layout .prompt-text:not(.collapsed) {
    display: block;
    overflow: visible;
    -webkit-line-clamp: unset;
}

/* Legacy expanded class (used by prompt_box shortcode) */
body.single-post.has-custom-prompt-layout .prompt-text.expanded {
    max-height: 3000px;
    display: block;
    overflow: visible;
}

/* =============================================================================
   PROMPT TEXT BOX
   - Light background box that holds the prompt text
   - Collapsed by default (3 lines), expands on View Full Prompt click
============================================================================= */

body.single-post.has-custom-prompt-layout .prompt-text-box {
    margin-bottom: 14px;
    padding: 14px 16px;
    background: #f8fafc;
/* 	background: #2145e6; */
    border: 1px solid #dbe7f3;
    border-radius: 14px;
}

body.single-post.has-custom-prompt-layout .prompt-text {
    color: #1e293b;
/* 	color: #ffff; */
    font-family: Arial, sans-serif;
    font-size: 15px;
    line-height: 1.75;
    white-space: pre-wrap;
    word-break: break-word;
    text-align: left;
    margin: 0;
    padding: 0;
    /* Collapsed state — shows 3 lines */
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* Expanded state — toggled by View Full Prompt button */
body.single-post.has-custom-prompt-layout .prompt-text:not(.collapsed) {
    display: block;
    overflow: visible;
    -webkit-line-clamp: unset;
}

/* Legacy expanded class (used by prompt_box shortcode) */
body.single-post.has-custom-prompt-layout .prompt-text.expanded {
    max-height: 3000px;
    display: block;
    overflow: visible;
}


/* =============================================================================
   BUTTONS — Base Styles
============================================================================= */

body.single-post.has-custom-prompt-layout .prompt-btn-row {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 16px;
}

body.single-post.has-custom-prompt-layout .prompt-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 5px;
    min-width: 125px;
    padding: 12px 18px;
    border: none;
    border-radius: 12px;
    cursor: pointer;
    text-decoration: none;
    font-size: 13px;
    font-weight: 700;
    transition: all 0.2s ease;
}


/* =============================================================================
   BUTTONS — View Prompt + Copy Prompt
============================================================================= */

body.single-post.has-custom-prompt-layout .view-prompt-btn,
body.single-post.has-custom-prompt-layout .copy-btn {
    background: #f1f5f9;
    border: 1px solid #dde6f0;
    color: #0f172a;
}

body.single-post.has-custom-prompt-layout .view-prompt-btn:hover,
body.single-post.has-custom-prompt-layout .copy-btn:hover {
    background: #e2e8f0;
    transform: translateY(-1px);
}


/* =============================================================================
   BUTTONS — Share (copies post URL to clipboard)
============================================================================= */

body.single-post.has-custom-prompt-layout .share-btn {
    background: #f1f5f9;
    border: 1px solid #dde6f0;
    color: #0f172a;
}

body.single-post.has-custom-prompt-layout .share-btn:hover {
    background: #e2e8f0;
    transform: translateY(-1px);
}


/* =============================================================================
   BUTTONS — Like (heart toggle with localStorage counter)
   Default: outline heart (🤍), red border, white bg
   Liked:   filled heart (❤️), pink bg — toggled via JS adding .liked class
============================================================================= */

body.single-post.has-custom-prompt-layout .like-btn {
    background: #ffffff;
    border: 1.5px solid #e11d48;
    color: #e11d48;
    min-width: 80px;
}

body.single-post.has-custom-prompt-layout .like-btn:hover {
    background: #fff0f3;
    transform: translateY(-1px);
}

body.single-post.has-custom-prompt-layout .like-btn.liked {
    background: #ffe4e6;
    border-color: #e11d48;
}

body.single-post.has-custom-prompt-layout .like-icon {
    font-size: 1rem;
    line-height: 1;
}

body.single-post.has-custom-prompt-layout .like-count {
    font-size: 13px;
    font-weight: 700;
    color: #e11d48;
}


/* =============================================================================
   BUTTONS — Legacy (Gemini, ChatGPT, WhatsApp)
   Kept for older posts using [prompt_box] shortcode
============================================================================= */

body.single-post.has-custom-prompt-layout .gemini-btn {
    background: linear-gradient(135deg, #6366f1, #3b82f6);
    color: #ffffff;
}

body.single-post.has-custom-prompt-layout .chatgpt-btn {
    background: #10a37f;
    color: #ffffff;
}

body.single-post.has-custom-prompt-layout .whatsapp-btn {
    background: #25d366;
    color: #ffffff;
}

body.single-post.has-custom-prompt-layout .gemini-btn:hover,
body.single-post.has-custom-prompt-layout .chatgpt-btn:hover,
body.single-post.has-custom-prompt-layout .whatsapp-btn:hover {
    color: #ffffff;
    transform: translateY(-1px);
}


/* =============================================================================
   POST NAVIGATION
============================================================================= */

body.single-post.has-custom-prompt-layout .post-navigation,
body.single-post.has-custom-prompt-layout nav.navigation.post-navigation {
    margin-top: 28px;
    padding-top: 18px;
    border-top: 1px solid #e8edf5;
}

body.single-post.has-custom-prompt-layout .nav-links a {
    color: #4f46e5;
    font-weight: 600;
    text-decoration: none;
}


/* =============================================================================
   SIDEBAR WIDGETS
============================================================================= */

.widget-area .widget {
    margin-bottom: 22px;
    padding: 22px;
    background: #ffffff;
    border: 1px solid #e9eef5;
    border-radius: 20px;
    box-shadow: 0 12px 28px rgba(15, 23, 42, 0.05);
}

.widget-title {
    margin-bottom: 16px;
    font-size: 24px;
    line-height: 1.2;
    font-weight: 800;
    color: #0f172a;
}

.widget-area ul {
    margin: 0;
    padding: 0;
    list-style: none;
}

.widget-area ul li {
    margin-bottom: 10px;
    line-height: 1.6;
}

.widget-area a {
    color: #4f46e5;
    text-decoration: none;
    font-weight: 500;
    transition: 0.2s ease;
}

.widget-area a:hover {
    color: #312e81;
}


/* =============================================================================
   SEARCH FORM
============================================================================= */

.search-form {
    display: flex;
    align-items: center;
    gap: 10px;
}

.search-field {
    width: 100%;
    height: 44px;
    padding: 0 14px;
    border: 1px solid #dbe3ee;
    border-radius: 12px;
    background: #fff;
    outline: none;
}

.search-submit {
    height: 44px;
    padding: 0 16px;
    border: none;
    border-radius: 12px;
    background: #4f46e5;
    color: #ffffff;
    font-weight: 700;
    cursor: pointer;
}

.search-field:focus {
    border-color: #6366f1;
    box-shadow: 0 0 0 4px rgba(99, 102, 241, 0.08);
}


/* =============================================================================
   HIDE COMMENTS SITE-WIDE
============================================================================= */

.comments-area,
#comments,
.comment-respond,
.comments-title,
.comment-list,
.comment-form,
.comment-form-comment {
    display: none !important;
}


/* =============================================================================
   FEATURED IMAGE — Legacy (kept for compatibility)
============================================================================= */

.single-featured-image {
    width: 100%;
    margin-bottom: 26px;
    overflow: hidden;
    border-radius: 22px;
    box-shadow: 0 18px 45px rgba(15, 23, 42, 0.12);
}

.featured-responsive-image {
    width: 100%;
    height: auto;
    max-height: 72vh;
    object-fit: cover;
    display: block;
}


/* =============================================================================
   HOME GRID — Section Wrapper
============================================================================= */

.gemini-prompts-section {
    padding: 40px 0 60px;
}

.gemini-prompts-container {
    max-width: 1280px;
    margin: 0 auto;
    padding: 0 20px;
}

.gemini-prompts-header {
    text-align: center;
    margin-bottom: 36px;
}

.gemini-prompts-badge {
    display: inline-block;
    padding: 6px 14px;
    border-radius: 999px;
    background: #eef2ff;
    color: #4f46e5;
    font-size: 12px;
    font-weight: 700;
    margin-bottom: 12px;
}

.gemini-prompts-header h2 {
    font-size: 36px;
    font-weight: 800;
    color: #0f172a;
    margin: 0 0 10px;
}

.gemini-prompts-header p {
    font-size: 16px;
    color: #64748b;
    margin: 0;
}


/* =============================================================================
   HOME GRID — 3 Column Card Grid
============================================================================= */

.gemini-prompts-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
}

.gemini-prompt-card {
    background: #ffffff;
    border-radius: 18px;
    border: 1px solid #e9eef5;
    box-shadow: 0 8px 24px rgba(15, 23, 42, 0.06);
    overflow: hidden;
    transition: transform 0.22s ease, box-shadow 0.22s ease;
    display: flex;
    flex-direction: column;
}

.gemini-prompt-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 18px 40px rgba(15, 23, 42, 0.12);
}

.gemini-prompt-card > a {
    display: flex;
    flex-direction: column;
    height: 100%;
    text-decoration: none;
    color: inherit;
}

/* Card thumbnail — wide, short (collage/banner style) */
.gemini-prompt-card .post-thumb {
    width: 100%;
    height: 320px;
    flex-shrink: 0;
    overflow: hidden;
    background: #f1f5f9;
    display: flex;
    align-items: center;
    justify-content: center;
}

.gemini-prompt-card .post-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
    display: block;
    transition: transform 0.4s ease;
}

.gemini-prompt-card:hover .post-thumb img {
    transform: scale(1.04);
}

/* Card text content — below image, not overlaid */
.gemini-prompt-overlay-content {
    padding: 16px 18px 20px;
    display: flex;
    flex-direction: column;
    gap: 6px;
    flex: 1;
    position: static;
    background: #ffffff;
}

.prompt-card-cat {
    display: inline-block;
    font-size: 11px;
    font-weight: 700;
    color: #4f46e5;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    background: #eef2ff;
    padding: 3px 10px;
    border-radius: 999px;
    width: fit-content;
}

.gemini-prompt-overlay-content h3 {
    margin: 0;
    font-size: 15px;
    font-weight: 700;
    color: #0f172a;
    line-height: 1.4;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.prompt-card-meta {
    font-size: 12px;
    color: #94a3b8;
    font-weight: 500;
    margin-top: auto;
    padding-top: 8px;
}


/* =============================================================================
   PAGINATION
============================================================================= */

.gemini-pagination {
    margin-top: 40px;
    display: flex;
    justify-content: center;
}

.gemini-pagination .page-numbers {
    display: inline-flex;
    list-style: none;
    margin: 0;
    padding: 0;
    gap: 8px;
    flex-wrap: wrap;
    justify-content: center;
}

.gemini-pagination .page-numbers li a,
.gemini-pagination .page-numbers li span {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    border-radius: 10px;
    font-weight: 700;
    font-size: 14px;
    text-decoration: none;
    color: #4f46e5;
    background: #ffffff;
    border: 1px solid #e2e8f0;
    transition: all 0.2s;
}

.gemini-pagination .page-numbers li span.current,
.gemini-pagination .page-numbers li a:hover {
    background: #4f46e5;
    color: #ffffff;
    border-color: #4f46e5;
}


/* =============================================================================
   RESPONSIVE — Tablet 1100px
============================================================================= */

@media (max-width: 1100px) {

    body.single-post.has-custom-prompt-layout .entry-title {
        font-size: 36px;
    }

    .gemini-prompts-grid {
        grid-template-columns: repeat(3, 1fr);
        gap: 18px;
    }

    .gemini-prompt-card .post-thumb {
        height: 350px;
    }
}


/* =============================================================================
   RESPONSIVE — Tablet 921px
============================================================================= */

@media (max-width: 921px) {

    body.single-post.has-custom-prompt-layout .wp-block-group {
        padding-top: 24px;
        padding-bottom: 36px;
        gap: 24px;
    }

    body.single-post.has-custom-prompt-layout article.post {
        padding: 22px;
        border-radius: 18px;
    }

    body.single-post.has-custom-prompt-layout .entry-title {
        font-size: 30px;
    }

    body.single-post.has-custom-prompt-layout .prompt-item-title {
        font-size: 24px;
    }

    body.single-post.has-custom-prompt-layout .prompt-item-image-wrap {
        width: 100%;
        max-width: 100%;
        margin-left: auto;
        margin-right: auto;
        display: flex;
        justify-content: center;
        align-items: center;
    }

    body.single-post.has-custom-prompt-layout .prompt-item-image {
        width: 100%;
        max-width: 100%;
        height: 100%;
        object-fit: contain;
        object-position: center;
        display: block;
        margin: 0 auto;
    }

    .widget-title {
        font-size: 22px;
    }

    .gemini-prompts-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}


/* =============================================================================
   RESPONSIVE — Mobile 767px
============================================================================= */

@media (max-width: 767px) {

    body.single-post.has-custom-prompt-layout .entry-title {
        font-size: 26px;
    }

    body.single-post.has-custom-prompt-layout .prompt-item-card {
        padding: 16px;
    }

    body.single-post.has-custom-prompt-layout .prompt-item-title {
        font-size: 21px;
    }

    body.single-post.has-custom-prompt-layout .prompt-container {
        padding: 16px;
        border-radius: 16px;
    }

    body.single-post.has-custom-prompt-layout .prompt-box-title {
        font-size: 18px;
    }

    body.single-post.has-custom-prompt-layout .prompt-text {
        font-size: 14px;
        line-height: 1.8;
    }

    /* Stack buttons vertically on mobile */
    body.single-post.has-custom-prompt-layout .prompt-btn-row {
        flex-direction: column;
    }

    body.single-post.has-custom-prompt-layout .prompt-btn {
        width: 100%;
    }

    body.single-post.has-custom-prompt-layout .prompt-item-image-wrap {
        width: 100%;
        max-width: 100%;
        margin-left: auto;
        margin-right: auto;
        display: flex;
        justify-content: center;
        align-items: center;
    }

    body.single-post.has-custom-prompt-layout .prompt-item-image {
        width: 100%;
        max-width: 100%;
        height: 100%;
        object-fit: contain;
        object-position: center;
        display: block;
        margin: 0 auto;
    }

    .widget-title {
        font-size: 22px;
    }

    .gemini-prompts-grid {
        grid-template-columns: 1fr;
    }

    .gemini-prompt-card .post-thumb {
        height: 300px;
    }

    .gemini-prompts-header h2 {
        font-size: 26px;
    }
}

