/* =========================================
   Power Modding - Package Detail Page (Ultra Wide)
   ========================================= */

/* 1. Page Wrapper & Navbar Fix */
.pm-package-page {
    /* Large padding top prevents navbar from squashing content */
    padding-top: 20px; 
    padding-bottom: 100px;
    background-color: var(--bg-dark);
    min-height: 100vh;
}

/* 2. Ultra-Wide Container */
.pm-container-wide {
    max-width: 1600px !important; /* Forces wider layout */
    margin: 0 auto;
    padding: 0 40px;
    width: 95%; 
}

/* 3. Grid Layout */
.pm-package-grid {
    display: grid;
    /* 1fr takes remaining space, 420px fixed width for sidebar */
    grid-template-columns: 1fr 420px; 
    gap: 60px; /* Large gap for premium feel */
    align-items: start;
}

/* --- Breadcrumbs --- */
.pm-breadcrumbs {
    margin-bottom: 40px;
    color: var(--text-muted);
    font-size: 0.95rem;
    display: flex; 
    align-items: center; 
    gap: 10px;
}
.pm-breadcrumbs a { color: var(--text-muted); transition: 0.2s; }
.pm-breadcrumbs a:hover { color: #fff; }
.pm-sep { font-size: 0.7rem; color: #444; }
.pm-current { color: #fff; font-weight: 700; text-transform: uppercase; letter-spacing: 0.5px; }

/* --- Left Column: Media Section --- */
.pm-media-wrapper {
    position: relative;
    border-radius: 16px;
    overflow: hidden;
    border: 1px solid rgba(255,255,255,0.08);
    box-shadow: 0 20px 60px rgba(0,0,0,0.5);
    margin-bottom: 50px;
    background: #000;
}

.pm-hero-image {
    width: 100%;
    height: auto;
    display: block;
    max-height: 600px; /* Prevents extremely tall images */
    object-fit: cover;
}

.pm-sale-sticker {
    position: absolute; top: 20px; left: 20px;
    background: var(--primary-red); color: white;
    padding: 10px 15px; border-radius: 8px;
    display: flex; flex-direction: column; align-items: center;
    box-shadow: 0 5px 15px rgba(255, 59, 59, 0.4);
    font-weight: 800; line-height: 1;
}
.pm-sale-sticker .percent { font-size: 1.4rem; }
.pm-sale-sticker .label { font-size: 0.75rem; opacity: 0.9; }

/* --- Left Column: Description Box --- */
.pm-description-box {
    background: #0f0f0f;
    border: 1px solid rgba(255,255,255,0.05);
    border-radius: 16px;
    overflow: hidden;
}

.pm-desc-header {
    background: rgba(255,255,255,0.02);
    padding: 25px 40px;
    border-bottom: 1px solid rgba(255,255,255,0.05);
}
.pm-desc-header h2 { 
    margin: 0; font-size: 1.3rem; color: #fff; 
    display: flex; align-items: center; gap: 12px; 
}
.pm-desc-header h2 i { color: var(--primary-red); }

/* --- THE RAW TEXT ENGINE (Formatting Description) --- */
.pm-raw-text {
    padding: 50px; /* Spacious reading area */
    color: #d1d5db; 
    font-size: 1.05rem;
    line-height: 1.8;
}

/* Headings */
.pm-raw-text h1, .pm-raw-text h2 {
    color: #fff;
    font-weight: 800;
    margin-top: 40px; margin-bottom: 20px;
    padding-bottom: 15px; border-bottom: 2px solid var(--primary-red);
    display: inline-block;
}
.pm-raw-text h3 { color: #fff; font-weight: 700; margin-top: 30px; font-size: 1.2rem; }

/* Text Elements */
.pm-raw-text p { margin-bottom: 20px; }
.pm-raw-text strong { color: #fff; font-weight: 700; }
.pm-raw-text a { color: var(--primary-red); text-decoration: underline; }

/* Custom Lists */
.pm-raw-text ul { padding-left: 20px; margin-bottom: 30px; list-style: none; }
.pm-raw-text ul li {
    position: relative;
    padding-left: 25px;
    margin-bottom: 12px;
}
.pm-raw-text ul li::before {
    content: "➤"; /* Custom arrow bullet */
    position: absolute; left: 0; top: 2px;
    color: var(--primary-red); font-size: 0.8rem;
}

/* Images inside description */
.pm-raw-text img {
    max-width: 100%;
    border-radius: 8px;
    border: 1px solid rgba(255,255,255,0.1);
    margin: 30px 0;
    box-shadow: 0 10px 30px rgba(0,0,0,0.3);
}

/* Code Blocks */
.pm-raw-text pre, .pm-raw-text code {
    background: #1a1a1a;
    color: #fbbf24;
    font-family: 'JetBrains Mono', monospace;
    padding: 4px 8px;
    border-radius: 4px;
    font-size: 0.9em;
}
.pm-raw-text pre { 
    padding: 20px; 
    border-left: 3px solid var(--primary-red); 
    overflow-x: auto; 
    margin-bottom: 30px;
}

/* --- Right Column: Sticky Sidebar --- */
.pm-sticky-card {
    background: #0f0f0f;
    border: 1px solid rgba(255,255,255,0.1);
    border-radius: 16px;
    padding: 35px;
    position: sticky;
    top: 140px; /* Sticks below header */
    box-shadow: 0 10px 40px rgba(0,0,0,0.3);
}

.pm-pkg-title { 
    font-size: 2.2rem; line-height: 1.1; 
    margin: 0 0 15px 0; color: #fff; font-weight: 800; 
}

.pm-pkg-badges { display: flex; gap: 10px; margin-bottom: 30px; flex-wrap: wrap; }
.pm-badge-pill {
    background: rgba(255,255,255,0.05); border: 1px solid rgba(255,255,255,0.1);
    padding: 6px 12px; border-radius: 50px; font-size: 0.8rem; color: #aaa; 
    display: flex; align-items: center; gap: 6px;
}

/* Price Section */
.pm-price-container { 
    margin-bottom: 35px; padding-bottom: 25px; 
    border-bottom: 1px solid rgba(255,255,255,0.1); 
}
.pm-price-final { font-size: 2.5rem; font-weight: 800; color: #fff; letter-spacing: -1px; }
.text-red { color: var(--primary-red); }
.pm-price-original { text-decoration: line-through; color: #666; font-size: 1.2rem; margin-right: 10px; }
.pm-sale-timer { color: #fbbf24; font-size: 0.85rem; font-weight: 600; margin-top: 8px; }

/* Buttons */
.pm-actions-stack { display: flex; flex-direction: column; gap: 12px; }

.pm-btn-main {
    width: 100%;
    padding: 20px;
    background: #fff;
    color: #000;
    font-weight: 800;
    font-size: 1.1rem;
    text-transform: uppercase;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    display: flex; justify-content: space-between; align-items: center; 
    padding-left: 30px; padding-right: 30px;
    transition: all 0.2s ease;
}
.pm-btn-main:hover { background: var(--primary-red); color: white; transform: scale(1.02); }

.pm-btn-main.disabled { 
    background: #222; color: #666; 
    cursor: not-allowed; border: 1px solid #333; 
    transform: none !important;
}

.pm-btn-gift {
    width: 100%; padding: 12px; text-align: center;
    background: transparent; border: 1px solid rgba(255,255,255,0.2);
    color: #aaa; border-radius: 8px; font-weight: 600; 
    text-decoration: none; font-size: 0.9rem; transition: 0.2s;
}
.pm-btn-gift:hover { border-color: #fff; color: #fff; }

.pm-btn-sub { 
    display: block; text-align: center; color: var(--primary-red); 
    margin-top: 5px; text-decoration: underline; cursor: pointer; 
}

/* Secure Icons */
.pm-secure-box { margin-top: 30px; text-align: center; opacity: 0.5; }
.pm-secure-box .item { display: inline-block; font-size: 24px; margin: 0 5px; color: #fff; }
.pm-secure-box .text { display: block; font-size: 11px; margin-top: 5px; text-transform: uppercase; letter-spacing: 1px; }

/* Responsive Adjustments */
@media (max-width: 1100px) {
    .pm-package-grid { grid-template-columns: 1fr; } /* Stack vertically */
    .pm-sticky-card { position: relative; top: 0; margin-bottom: 40px; }
    .pm-container-wide { padding: 0 24px; }
    .pm-package-page { padding-top: 100px; }
}

/* Update this existing class */
.pm-package-grid {
    display: grid;
    grid-template-columns: 1fr 420px; 
    gap: 60px; 
    align-items: start;
    margin-bottom: 40px; /* Adds space before the description starts */
}

/* Update Description Box to be full width */
.pm-description-box {
    background: #0f0f0f;
    border: 1px solid rgba(255,255,255,0.05);
    border-radius: 16px;
    overflow: hidden;
    width: 100%; /* Ensures full width */
    clear: both; /* Safety to ensure it sits below floats if any */
}

/* The rest remains the same... */
.pm-media-wrapper {
    /* Remove margin-bottom from here if you want tighter spacing, 
       otherwise keep it for responsive stacking */
    margin-bottom: 0; 
}

/* Gift Wrapper */
.pm-gift-wrapper {
    width: 100%;
    margin-top: 10px;
}

/* The Toggle Button (Active State) */
.pm-btn-gift.active {
    background: rgba(255, 255, 255, 0.1);
    color: #fff;
    border-color: #fff;
}

/* The Hidden Area Container */
.pm-gift-input-container {
    margin-top: 10px;
    animation: slideDown 0.3s ease-out;
}

@keyframes slideDown {
    from { opacity: 0; transform: translateY(-10px); }
    to { opacity: 1; transform: translateY(0); }
}

/* The Input Box Layout */
.pm-gift-box {
    display: flex;
    gap: 8px;
    background: #1a1a1a;
    padding: 8px;
    border: 1px solid rgba(255,255,255,0.1);
    border-radius: 8px;
}

/* The Text Input */
.pm-gift-input {
    flex-grow: 1;
    background: transparent;
    border: none;
    color: #fff;
    padding: 8px 12px;
    font-size: 0.9rem;
    outline: none;
}
.pm-gift-input::placeholder {
    color: #666;
}

/* The Confirm Button */
.pm-gift-confirm-btn {
    background: var(--primary-red);
    color: #fff;
    border: none;
    padding: 8px 15px;
    border-radius: 6px;
    cursor: pointer;
    font-weight: 700;
    font-size: 0.85rem;
    transition: 0.2s;
    white-space: nowrap;
}
.pm-gift-confirm-btn:hover {
    background: #fff;
    color: #000;
}