/**
 * pages.css - Page-Specific Styles
 *
 * Testimonial cards (redesigned for real Google reviews),
 * contact page layout, gallery grid, blog/post cards,
 * single post content, and pagination.
 *
 * @package LibrandiOutdoorPower
 * @since   1.1.2
 * @updated 1.4.0 - Typography roles updated; post-content links
 *                  now use a high-contrast amber + underline
 *                  treatment so inline links inside long-form
 *                  articles are easy to spot against body copy.
 */


/* ==========================================================
   Testimonial Cards
   ========================================================== */
.testimonial-card {
    background: var(--color-white);
    border: 1px solid var(--color-gray-200);
    border-radius: var(--radius-lg);
    padding: var(--space-6) var(--space-8);
    margin: 0;
    display: flex;
    flex-direction: column;
    gap: var(--space-4);
    transition: box-shadow var(--duration-slow) var(--ease),
                transform  var(--duration-slow) var(--ease);
}
.testimonial-card:hover {
    box-shadow: var(--shadow-card);
    transform: translateY(-2px);
}
.testimonial-card__stars {
    display: flex;
    gap: 2px;
}
.testimonial-card__quote {
    font-size: var(--text-base);
    font-style: normal;
    color: var(--color-gray-700);
    line-height: var(--leading-relaxed);
    flex-grow: 1;
}
.testimonial-card__photo-trigger {
    display: inline-flex;
    align-items: center;
    gap: var(--space-3);
    padding: var(--space-2);
    background: var(--color-gray-50);
    border: 1px solid var(--color-gray-200);
    border-radius: var(--radius-md);
    cursor: pointer;
    transition: border-color var(--duration) var(--ease),
                box-shadow   var(--duration) var(--ease);
}
.testimonial-card__photo-trigger:hover {
    border-color: var(--color-primary-light);
    box-shadow: var(--shadow-sm);
}
.testimonial-card__photo-trigger img {
    width: 64px;
    height: 64px;
    object-fit: cover;
    border-radius: var(--radius);
}
.testimonial-card__photo-label {
    font-family: var(--font-mono);
    font-size: var(--text-sm);
    font-weight: 500;
    color: var(--color-primary);
}
.testimonial-card__attribution {
    display: flex;
    align-items: center;
    gap: var(--space-3);
    padding-top: var(--space-4);
    border-top: 1px solid var(--color-gray-100);
    font-style: normal;
}
.testimonial-card__avatar {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background-color: var(--color-primary);
    color: var(--color-white);
    font-family: var(--font-heading);
    font-size: var(--text-base);
    font-weight: 400;
    flex-shrink: 0;
}
.testimonial-card__cite {
    display: flex;
    flex-direction: column;
}
.testimonial-card__author {
    font-weight: 600;
    color: var(--color-gray-900);
    font-size: var(--text-sm);
}
.testimonial-card__meta {
    font-family: var(--font-mono);
    font-size: var(--text-xs);
    color: var(--color-gray-400);
    margin-top: 1px;
}
.testimonials-source {
    text-align: center;
    font-size: var(--text-sm);
    color: var(--color-gray-400);
    margin-top: var(--space-8);
}


/* ==========================================================
   Contact Page
   ========================================================== */
.contact-grid { display: grid; gap: var(--space-10); }
.contact-form-wrap h2, .contact-info h2 { margin-bottom: var(--space-4); }
.contact-method { margin-bottom: var(--space-6); }
.contact-method h3 { font-size: var(--text-base); font-weight: 400; margin-bottom: var(--space-1); color: var(--color-primary); }
.contact-form-placeholder { padding: var(--space-8); background: var(--color-gray-100); border-radius: var(--radius-lg); text-align: center; }
.map-embed iframe { display: block; width: 100%; }

/* ----- Contact links (Phone, Email) -----
   The default <a> style in base.css has no underline and a muted
   green color, which made these feel like ordinary text. On the
   Contact page the phone number and email address are primary
   CTAs, so they get a proper "I am a link" treatment: amber
   color, underline on the text, small leading icon, and a
   hover affordance that swaps the color and thickens the line. */
.contact-link {
    display: inline-flex;
    align-items: center;
    gap: var(--space-2);
    font-family: var(--font-mono);
    font-size: var(--text-lg);
    font-weight: 600;
    color: var(--color-accent);
    text-decoration: underline;
    text-decoration-thickness: 1.5px;
    text-underline-offset: 4px;
    word-break: break-word;
    transition: color                     var(--duration) var(--ease),
                text-decoration-thickness var(--duration) var(--ease);
}
.contact-link:hover,
.contact-link:focus-visible {
    color: var(--color-accent-hover);
    text-decoration-thickness: 2.5px;
}
.contact-link:focus-visible {
    outline: 2px solid var(--color-accent);
    outline-offset: 3px;
    border-radius: var(--radius);
}
.contact-link__icon {
    flex-shrink: 0;
    color: currentColor;
}


/* ==========================================================
   Gallery Grid
   ========================================================== */
.gallery-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: var(--space-4); }
.gallery-item { margin: 0; }
.gallery-item figcaption { font-size: var(--text-sm); color: var(--color-gray-600); padding-top: var(--space-2); }


/* ==========================================================
   Blog / Post Cards
   IMAGE FIX: object-fit: contain shows the full image inside
   the card frame. No cropping. Background fills empty space.
   ========================================================== */
.post-card {
    background: var(--color-white);
    border: 1px solid var(--color-gray-200);
    border-radius: var(--radius-lg);
    overflow: hidden;
    transition: box-shadow var(--duration-slow) var(--ease),
                transform  var(--duration-slow) var(--ease);
}
.post-card:hover {
    box-shadow: var(--shadow-card);
    transform: translateY(-2px);
}

.post-card__image {
    display: block;
    aspect-ratio: 3 / 2;
    overflow: hidden;
    background-color: var(--color-off-white);
}
.post-card__image img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    object-position: center;
    transition: transform var(--duration-slow) var(--ease);
}
.post-card:hover .post-card__image img {
    transform: scale(1.03);
}

.post-card__body {
    padding: var(--space-6);
}
.post-card__meta {
    display: flex;
    flex-wrap: wrap;
    align-items: baseline;
    gap: 0 var(--space-2);
    font-family: var(--font-mono);
    font-size: var(--text-xs);
    color: var(--color-gray-400);
    text-transform: uppercase;
    letter-spacing: var(--tracking-wide);
    margin-bottom: var(--space-3);
}

/* Category links: accent color, not green */
.post-card__meta a,
.post-card__meta .post-card__category a,
.post-card .post-card__category a {
    color: var(--color-accent) !important;
    font-weight: 600;
    text-decoration: none;
    transition: color var(--duration) var(--ease);
}
.post-card__meta a:hover,
.post-card__meta .post-card__category a:hover,
.post-card .post-card__category a:hover {
    color: var(--color-accent-hover) !important;
}
.post-card__title {
    font-size: var(--text-xl);
    margin-bottom: var(--space-2);
}
.post-card__title a {
    color: var(--color-gray-900);
    transition: color var(--duration) var(--ease);
}
.post-card__title a:hover {
    color: var(--color-primary);
}
.post-card__excerpt {
    font-size: var(--text-sm);
    color: var(--color-gray-600);
}
.post-card__link {
    display: inline-block;
    margin-top: var(--space-3);
    font-family: var(--font-mono);
    font-size: var(--text-sm);
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.02em;
    color: var(--color-accent);
    transition: color var(--duration) var(--ease);
}
.post-card__link:hover {
    color: var(--color-accent-hover);
}


/* ==========================================================
   Single Post Content
   ========================================================== */
.post-featured-image {
    margin-bottom: var(--space-8);
    border-radius: var(--radius-lg);
    overflow: hidden;
}
.post-content {
    font-size: var(--text-lg);
    line-height: var(--leading-relaxed);
}
.post-content h2, .post-content h3 {
    margin-top: var(--space-8);
    margin-bottom: var(--space-4);
}
.post-content ul, .post-content ol {
    margin-left: var(--space-6);
    margin-bottom: var(--space-4);
}

/* ----- Inline links inside post body -----
 * Long-form articles previously used the global <a> color, which
 * is a muted forest green. Against black body text that green
 * reads as "almost the same color" and the links vanish into the
 * paragraph. This rule scopes a high-contrast treatment to post
 * content only: amber fill, persistent underline with a generous
 * offset, and a hover affordance that darkens the amber and
 * thickens the underline. The scope keeps the rest of the site
 * (nav, cards, CTAs) untouched.
 */
.post-content a:not(.btn) {
    color: var(--color-accent);
    font-weight: 600;
    text-decoration: underline;
    text-decoration-color: var(--color-accent);
    text-decoration-thickness: 2px;
    text-underline-offset: 3px;
    transition: color                     var(--duration) var(--ease),
                text-decoration-color     var(--duration) var(--ease),
                text-decoration-thickness var(--duration) var(--ease);
}
.post-content a:not(.btn):hover,
.post-content a:not(.btn):focus-visible {
    color: var(--color-accent-hover);
    text-decoration-color: var(--color-accent-hover);
    text-decoration-thickness: 3px;
}
.post-content a:not(.btn):focus-visible {
    outline: 2px solid var(--color-accent);
    outline-offset: 2px;
    border-radius: 2px;
}

/* Tags: accent color, not green */
.post-tags {
    margin-top: var(--space-8);
    padding-top: var(--space-4);
    border-top: 1px solid var(--color-gray-200);
    font-family: var(--font-mono);
    font-size: var(--text-sm);
    color: var(--color-gray-600);
}
.post-tags a {
    color: var(--color-accent) !important;
    font-weight: 500;
    transition: color var(--duration) var(--ease);
}
.post-tags a:hover { color: var(--color-accent-hover) !important; }
.post-meta {
    font-family: var(--font-mono);
    font-size: var(--text-sm);
}
.post-meta a { color: var(--color-accent) !important; font-weight: 500; }
.post-meta a:hover { color: var(--color-accent-hover) !important; }


/* ----- Post navigation ----- */
.post-navigation {
    display: flex;
    justify-content: space-between;
    gap: var(--space-4);
}
.post-navigation a { font-weight: 500; color: var(--color-primary); }


/* ----- Pagination ----- */
.pagination { margin-top: var(--space-10); text-align: center; }
.pagination .nav-links {
    display: flex;
    justify-content: center;
    gap: var(--space-2);
}
.pagination a,
.pagination span {
    padding: var(--space-2) var(--space-3);
    border-radius: var(--radius);
    font-family: var(--font-mono);
    font-size: var(--text-sm);
    transition: background-color var(--duration) var(--ease),
                color            var(--duration) var(--ease);
}
.pagination .current {
    background-color: var(--color-primary);
    color: var(--color-white);
}
