/* ============================================================
   SRG Templates Single Hero Card (Component Styling - 2026 Seamless Edition)
   ============================================================ */
.srg-tpl-hero-wrapper {
    /* ── Full-screen edge-to-edge gradient background for template page ── */
    width: 100%;
    background: linear-gradient(135deg, var(--srg-bg-primary, #ffffff) 0%, var(--srg-context-accent-subtle, rgba(249, 115, 22, 0.08)) 100%);
    border-bottom: 1px solid var(--srg-border-secondary, #e2e8f0);
}

.srg-tpl-hero {
    --tpl-accent:       var(--srg-context-accent, #F97316);
    --tpl-accent-subtle: var(--srg-context-accent-subtle, rgba(249, 115, 22, 0.08));
    --tpl-accent-hover:  var(--srg-context-accent-hover, #ea580c);
    --tpl-gold:         #F59E0B;
    --tpl-gold-light:   #FFFBEB;
    --tpl-ink:          var(--srg-text-primary, #222222);
    --tpl-muted:        var(--srg-text-secondary, #475569);
    --tpl-border:       var(--srg-border-secondary, #e2e8f0);
    --tpl-surface:      var(--srg-bg-secondary, #f8fafc);
    --tpl-radius-img:   14px;
}

/* ── Seamless Hero Container (Constrained on PC to match layout) ── */
.srg-tpl-hero {
    font-family: 'Inter', sans-serif;
    display: flex;
    gap: 40px;
    align-items: center;
    
    /* Borderless and shadowless clean design */
    border: none !important;
    border-radius: 0 !important;
    padding: 48px 0;
    margin-bottom: 0;
    box-shadow: none !important;
}

/* ── Thumbnail Column (Image) ── */
.srg-tpl-hero-img-col {
    flex: 0 0 280px;
}

.srg-tpl-hero-img {
    position: relative; /* Position relative for floating badges */
    width: 100%;
    aspect-ratio: 1 / 1;
    background: #ffffff;
    border: 1px solid var(--tpl-border);
    border-radius: var(--tpl-radius-img);
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 10px 30px -10px rgba(0,0,0,0.06);
}
.srg-tpl-hero-img img { 
    width: 100%; 
    height: 100%; 
    object-fit: cover; 
    display: block; 
}

/* ── Floating Badges on Hero Image ── */
.srg-tpl-hero-badge-floating {
    position: absolute;
    top: 14px;
    left: 14px;
    z-index: 10;
}

/* Price tag style inside Hero Image (Gift Icon unified orange color) */
.srg-tpl-hero-badge-floating .srg-tpl-badge-price {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-size: 12px;
    font-weight: 800;
    padding: 6px 14px;
    border-radius: 30px;
    color: #ffffff;
    background: var(--tpl-accent); /* Creative Orange accent color */
    box-shadow: 0 4px 12px rgba(249, 115, 22, 0.3);
}

.srg-tpl-hero-badge-floating .srg-tpl-badge-price svg {
    stroke: #ffffff;
}

/* ── Content Details Column ── */
.srg-tpl-hero-content { 
    flex: 1; 
    display: flex; 
    flex-direction: column; 
    gap: 16px; 
}

/* ── Badges ── */
.srg-tpl-hero-badges { 
    display: flex; 
    gap: 8px; 
    flex-wrap: wrap; 
    align-items: center; 
}

.srg-tpl-badge {
    display: inline-flex; 
    align-items: center; 
    gap: 6px;
    font-size: 12px; 
    font-weight: 700; 
    padding: 6px 14px; 
    border-radius: 30px;
    text-decoration: none; 
    white-space: nowrap; 
    transition: all .2s ease;
}
.srg-tpl-badge-cat { 
    background: var(--tpl-surface); 
    color: var(--tpl-muted); 
    border: 1px solid var(--tpl-border); 
}
.srg-tpl-badge-cat:hover { 
    background: var(--tpl-accent-subtle); 
    color: var(--tpl-accent); 
    border-color: var(--tpl-accent); 
}
.srg-tpl-badge-format { 
    background: var(--tpl-accent-subtle); 
    color: var(--tpl-accent); 
    border: 1.5px solid var(--tpl-accent); 
}

/* ── Title ── */
.srg-tpl-hero-title {
    font-size: 36px !important; 
    font-weight: 800 !important; 
    color: var(--tpl-ink);
    margin: 0 !important; 
    line-height: 1.2; 
    letter-spacing: -0.8px; 
    border: none !important; 
    padding: 0 !important;
}

/* ── Star Rating ── */
.srg-tpl-hero-rating {
    display: inline-flex; 
    align-items: center; 
    gap: 8px;
}
.srg-tpl-hero-stars-icons { 
    display: flex; 
    align-items: center; 
    gap: 2px; 
}
.srg-tpl-hero-stars-num { 
    font-size: 15px; 
    font-weight: 700; 
    color: var(--tpl-ink); 
}

/* ── Description ── */
.srg-tpl-hero-desc { 
    font-size: 16px; 
    color: var(--tpl-muted); 
    line-height: 1.65; 
    margin: 0; 
}

/* ── Action bar (Seamless & Completely Stripped of box styles) ── */
.srg-tpl-hero-action {
    display: flex; 
    align-items: center; 
    gap: 16px; 
    flex-wrap: wrap;
    
    /* Borderless clean card formatting */
    background: transparent !important; 
    backdrop-filter: none !important;
    border: none !important;
    border-radius: 0 !important; 
    padding: 0 !important; 
    margin-top: 12px;
    box-shadow: none !important;
}

/* Download button */
.srg-tpl-btn-download {
    display: inline-flex; 
    align-items: center; 
    gap: 8px;
    background: var(--tpl-accent); 
    color: #ffffff !important;
    font-weight: 700; 
    font-size: 14px; 
    padding: 12px 24px; 
    border-radius: 8px;
    text-decoration: none !important; 
    transition: all .25s ease;
    box-shadow: 0 4px 14px rgba(249, 115, 22, 0.2); 
    white-space: nowrap;
}
.srg-tpl-btn-download:hover {
    background: var(--tpl-accent-hover);
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(249, 115, 22, 0.3);
}

/* ── Share ── */
.srg-tpl-share { 
    display: flex; 
    align-items: center; 
    gap: 8px; 
    margin-left: auto; 
    flex-shrink: 0; 
}
.srg-tpl-share-label {
    font-size: 12px; 
    font-weight: 700; 
    color: var(--tpl-muted);
    text-transform: uppercase; 
    letter-spacing: .6px; 
    white-space: nowrap;
}
.srg-tpl-share-btn {
    display: inline-flex; 
    align-items: center; 
    justify-content: center;
    width: 36px; 
    height: 36px; 
    border-radius: 8px; 
    border: 1px solid var(--tpl-border);
    background: #ffffff; 
    color: var(--tpl-muted); 
    text-decoration: none !important;
    cursor: pointer; 
    transition: all .2s ease; 
    padding: 0; 
    flex-shrink: 0;
}
.srg-tpl-share-btn:hover { 
    transform: translateY(-2px); 
    color: var(--tpl-accent);
    border-color: var(--tpl-accent);
}
.srg-tpl-share-x:hover    { background: #000000; border-color: #000000; color: #ffffff !important; box-shadow: 0 4px 10px rgba(0,0,0,.15); }
.srg-tpl-share-fb:hover   { background: #1877F2; border-color: #1877F2; color: #ffffff !important; box-shadow: 0 4px 10px rgba(24,119,242,.25); }
.srg-tpl-share-li:hover   { background: #0A66C2; border-color: #0A66C2; color: #ffffff !important; box-shadow: 0 4px 10px rgba(10,102,194,.25); }
.srg-tpl-share-copy:hover { background: var(--tpl-accent-subtle); border-color: var(--tpl-accent); color: var(--tpl-accent); }

/* Clipboard copier integration */
.srg-tpl-share-btn.copied {
    background: var(--tpl-accent-subtle) !important;
    border-color: var(--tpl-accent) !important;
    color: var(--tpl-accent) !important;
}

/* Dark mode compatibility */
html.srg-dark .srg-tpl-hero-wrapper {
    background: linear-gradient(135deg, var(--srg-bg-primary, #0f172a) 0%, rgba(249, 115, 22, 0.05) 100%);
    border-color: var(--srg-neutral-800, #1e293b);
}
html.srg-dark .srg-tpl-hero-img {
    background: var(--srg-neutral-900, #0f172a);
    border-color: var(--srg-neutral-800, #1e293b);
}
html.srg-dark .srg-tpl-badge-cat {
    background: var(--srg-neutral-800, #1e293b);
    color: #ffffff;
}
html.srg-dark .srg-tpl-share-btn {
    background: var(--srg-neutral-800, #1e293b);
    border-color: var(--srg-neutral-700, #334155);
}

/* ── Responsive ── */
@media (max-width: 991px) {
    .srg-tpl-hero { padding: 32px var(--srg-space-4, 16px) 48px var(--srg-space-4, 16px); }
}
@media (max-width: 768px) {
    .srg-tpl-hero-img-col { flex: none; width: 100%; max-width: 240px; margin: 0 auto; }
    .srg-tpl-hero        { flex-direction: column; align-items: stretch; gap: 24px; padding: 24px var(--srg-space-4, 16px) 48px var(--srg-space-4, 16px); }
    .srg-tpl-hero-title  { font-size: 28px !important; text-align: center; }
    .srg-tpl-hero-badges { justify-content: center; }
    .srg-tpl-hero-rating { justify-content: center; }
    .srg-tpl-hero-desc   { text-align: center; }
    .srg-tpl-hero-action { flex-direction: column; align-items: stretch; gap: 12px; padding: 0; }
    .srg-tpl-btn-download { width: 100%; justify-content: center; }
    .srg-tpl-share       { margin-left: 0; justify-content: center; flex-wrap: wrap; }
}