/**
 * Click Medias Custom Styles
 * 
 * Additional styles that extend the main stylesheet
 * Orange Brand Color: #F47920
 * 
 * @package ClickMedias
 */

/* ============================================
   ORANGE ACCENT UTILITIES
   ============================================ */
.text-orange { color: var(--cm-accent, #F47920) !important; }
.bg-orange { background-color: var(--cm-accent, #F47920) !important; }
.border-orange { border-color: var(--cm-accent, #F47920) !important; }

/* Orange gradient text */
.cm-gradient-text {
    background: linear-gradient(135deg, #F47920 0%, #FF9A4D 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* Orange highlight/marker effect */
.cm-highlight {
    background: linear-gradient(transparent 60%, rgba(244, 121, 32, 0.3) 60%);
    padding: 0 4px;
}

/* ============================================
   PAGE TEMPLATES
   ============================================ */
.cm-page {
    padding-top: 100px;
}

.cm-page-header {
    background: linear-gradient(135deg, var(--cm-primary, #1E3A5F) 0%, #2d4a6f 100%);
    padding: 60px 0;
    color: #fff;
    text-align: center;
    position: relative;
    overflow: hidden;
}

.cm-page-header::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, var(--cm-accent, #F47920), var(--cm-secondary, #00D4E4), var(--cm-accent, #F47920));
}

.cm-page-title {
    font-size: clamp(2rem, 4vw, 3rem);
    margin: 0;
}

/* Orange underline for page titles */
.cm-page-title::after {
    content: '';
    display: block;
    width: 80px;
    height: 4px;
    background: var(--cm-accent, #F47920);
    margin: 1rem auto 0;
    border-radius: 2px;
}

.cm-page-content {
    padding: 60px 0;
}

/* Full Width Pages (Portals, Signup) */
.page-template-default .cm-page-content .cm-container {
    max-width: 1400px;
}

/* Portal Pages - Remove default padding */
.cm-client-portal,
.cm-admin-portal,
.cm-agency-portal,
.cm-signup-page {
    margin: -60px 0;
}

.cm-client-portal + .cm-page-content,
.cm-admin-portal + .cm-page-content,
.cm-agency-portal + .cm-page-content {
    padding: 0;
}

/* Single Post/Page Styles */
.cm-single-header {
    padding: 80px 0 40px;
    background: var(--cm-gradient-dark);
    color: var(--cm-white);
}

.cm-single-header h1 {
    font-size: clamp(2rem, 5vw, 3.5rem);
    margin-bottom: 1rem;
}

.cm-single-meta {
    display: flex;
    gap: 1.5rem;
    color: var(--cm-gray-400);
    font-size: 0.9375rem;
}

.cm-single-content {
    padding: 4rem 0;
}

.cm-single-content .cm-container {
    max-width: 800px;
}

/* Contact Page */
.cm-contact-section {
    padding: 80px 0;
}

.cm-contact-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
}

.cm-contact-info h2 {
    margin-bottom: 1.5rem;
}

.cm-contact-info p {
    color: var(--cm-gray-600);
    margin-bottom: 2rem;
}

.cm-contact-details {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.cm-contact-item {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.cm-contact-item svg {
    width: 24px;
    height: 24px;
    color: var(--cm-primary);
}

.cm-contact-form {
    background: var(--cm-white);
    padding: 2rem;
    border-radius: var(--cm-radius-xl);
    box-shadow: var(--cm-shadow-lg);
}

/* Breadcrumbs */
.cm-breadcrumbs {
    padding: 1rem 0;
    font-size: 0.875rem;
}

.cm-breadcrumb-list {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    list-style: none;
    padding: 0;
    margin: 0;
}

.cm-breadcrumb-item {
    display: flex;
    align-items: center;
}

.cm-breadcrumb-item::after {
    content: '/';
    margin-left: 0.5rem;
    color: var(--cm-gray-400);
}

.cm-breadcrumb-item:last-child::after {
    display: none;
}

.cm-breadcrumb-item a {
    color: var(--cm-accent, #F47920);
    text-decoration: none;
}

.cm-breadcrumb-item a:hover {
    text-decoration: underline;
}

.cm-breadcrumb-current {
    color: var(--cm-gray-600);
}

/* Social Share */
.cm-social-share {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 1.5rem 0;
    border-top: 1px solid var(--cm-gray-200);
    margin-top: 2rem;
}

.cm-share-label {
    font-weight: 600;
    color: var(--cm-gray-700);
}

.cm-social-share a {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.5rem 1rem;
    background: var(--cm-gray-100);
    border-radius: var(--cm-radius-md);
    color: var(--cm-gray-700);
    font-size: 0.875rem;
    text-decoration: none;
    transition: all 0.2s ease;
}

.cm-social-share a:hover {
    background: var(--cm-accent, #F47920);
    color: var(--cm-white);
}

/* Archive/Blog Listing */
.cm-archive-header {
    padding: 60px 0 40px;
    background: var(--cm-gray-100);
    text-align: center;
}

.cm-archive-header h1 {
    margin-bottom: 0.5rem;
}

.cm-archive-header p {
    color: var(--cm-gray-600);
}

.cm-posts-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
    gap: 2rem;
    padding: 4rem 0;
}

.cm-post-card {
    background: var(--cm-white);
    border-radius: var(--cm-radius-lg);
    overflow: hidden;
    box-shadow: var(--cm-shadow-sm);
    transition: all 0.3s ease;
}

.cm-post-card:hover {
    box-shadow: var(--cm-shadow-lg);
    transform: translateY(-4px);
}

.cm-post-card-image {
    aspect-ratio: 16/10;
    overflow: hidden;
}

.cm-post-card-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.cm-post-card:hover .cm-post-card-image img {
    transform: scale(1.05);
}

.cm-post-card-content {
    padding: 1.5rem;
}

.cm-post-card-meta {
    display: flex;
    gap: 1rem;
    font-size: 0.8125rem;
    color: var(--cm-gray-500);
    margin-bottom: 0.75rem;
}

.cm-post-card-title {
    font-size: 1.25rem;
    margin-bottom: 0.75rem;
}

.cm-post-card-title a {
    color: var(--cm-dark);
    text-decoration: none;
}

.cm-post-card-title a:hover {
    color: var(--cm-accent, #F47920);
}

.cm-post-card-excerpt {
    color: var(--cm-gray-600);
    font-size: 0.9375rem;
    line-height: 1.6;
    margin-bottom: 1rem;
}

/* 404 Page */
.cm-404 {
    min-height: 70vh;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 4rem 2rem;
}

.cm-404 h1 {
    font-size: 8rem;
    color: var(--cm-accent, #F47920);
    line-height: 1;
    margin-bottom: 1rem;
}

.cm-404 h2 {
    margin-bottom: 1rem;
}

.cm-404 p {
    color: var(--cm-gray-600);
    margin-bottom: 2rem;
}

/* Search Results */
.cm-search-results {
    padding: 4rem 0;
}

.cm-search-form-large {
    max-width: 600px;
    margin: 0 auto 3rem;
}

.cm-search-form-large form {
    display: flex;
    gap: 0.5rem;
}

.cm-search-form-large input[type="search"] {
    flex: 1;
    padding: 1rem 1.5rem;
    border: 2px solid var(--cm-gray-300);
    border-radius: var(--cm-radius-lg);
    font-size: 1rem;
}

.cm-search-form-large input[type="search"]:focus {
    outline: none;
    border-color: var(--cm-accent, #F47920);
}

.cm-search-form-large button {
    padding: 1rem 2rem;
    background: var(--cm-accent, #F47920);
    color: var(--cm-white);
    border: none;
    border-radius: var(--cm-radius-lg);
    cursor: pointer;
    transition: background 0.2s ease;
}

.cm-search-form-large button:hover {
    background: var(--cm-accent-dark, #D86A1A);
}

/* Sidebar */
.cm-sidebar {
    padding-left: 2rem;
}

.cm-widget {
    margin-bottom: 2rem;
    padding: 1.5rem;
    background: var(--cm-gray-50);
    border-radius: var(--cm-radius-lg);
}

.cm-widget-title {
    font-size: 1.125rem;
    margin-bottom: 1rem;
    padding-bottom: 0.75rem;
    border-bottom: 2px solid var(--cm-accent, #F47920);
}

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

.cm-widget li {
    padding: 0.5rem 0;
    border-bottom: 1px solid var(--cm-gray-200);
}

.cm-widget li:last-child {
    border-bottom: none;
}

.cm-widget a {
    color: var(--cm-gray-700);
    text-decoration: none;
}

.cm-widget a:hover {
    color: var(--cm-accent, #F47920);
}

/* Comments */
.cm-comments {
    margin-top: 3rem;
    padding-top: 2rem;
    border-top: 1px solid var(--cm-gray-200);
}

.cm-comments-title {
    margin-bottom: 2rem;
}

.cm-comment-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.cm-comment {
    padding: 1.5rem;
    background: var(--cm-gray-50);
    border-radius: var(--cm-radius-lg);
    margin-bottom: 1rem;
}

.cm-comment-header {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 1rem;
}

.cm-comment-avatar {
    width: 48px;
    height: 48px;
    border-radius: 50%;
}

.cm-comment-author {
    font-weight: 600;
}

.cm-comment-date {
    font-size: 0.8125rem;
    color: var(--cm-gray-500);
}

.cm-comment-content {
    color: var(--cm-gray-700);
}

.cm-comment-reply {
    margin-top: 1rem;
}

.cm-comment-reply a {
    font-size: 0.875rem;
    color: var(--cm-accent, #F47920);
}

/* Responsive */
@media (max-width: 768px) {
    .cm-contact-grid {
        grid-template-columns: 1fr;
    }
    
    .cm-posts-grid {
        grid-template-columns: 1fr;
    }
    
    .cm-sidebar {
        padding-left: 0;
        margin-top: 3rem;
    }
    
    .cm-404 h1 {
        font-size: 5rem;
    }
}

/* ============================================
   ADDITIONAL ORANGE ACCENTS
   ============================================ */

/* Contact page icon color */
.cm-contact-item svg {
    color: var(--cm-accent, #F47920);
}

/* Selection highlight */
::selection {
    background: rgba(244, 121, 32, 0.3);
    color: var(--cm-dark);
}

/* Scrollbar styling with orange */
::-webkit-scrollbar {
    width: 10px;
}

::-webkit-scrollbar-track {
    background: var(--cm-gray-200);
}

::-webkit-scrollbar-thumb {
    background: var(--cm-accent, #F47920);
    border-radius: 5px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--cm-accent-dark, #D86A1A);
}

/* Orange bullets for lists */
.cm-page-content ul:not([class]) li::marker {
    color: var(--cm-accent, #F47920);
}

/* Orange border on focused elements */
.cm-form-input:focus,
input:focus,
textarea:focus,
select:focus {
    border-color: var(--cm-accent, #F47920) !important;
    box-shadow: 0 0 0 3px rgba(244, 121, 32, 0.15) !important;
    outline: none;
}

/* Orange accent on blockquotes */
blockquote {
    border-left: 4px solid var(--cm-accent, #F47920);
    padding-left: 1.5rem;
    margin: 1.5rem 0;
    font-style: italic;
    color: var(--cm-gray-700);
}

/* Orange hover on all generic links in content */
.cm-page-content a:not(.cm-btn):hover,
.cm-single-content a:not(.cm-btn):hover {
    color: var(--cm-accent, #F47920);
}

/* Orange loading spinner */
.cm-loading::after {
    border-color: var(--cm-accent, #F47920) transparent transparent transparent;
}

/* Tag/category badges with orange */
.cm-tag,
.cm-category {
    display: inline-block;
    padding: 0.25rem 0.75rem;
    background: rgba(244, 121, 32, 0.1);
    color: var(--cm-accent, #F47920);
    border-radius: var(--cm-radius-full);
    font-size: 0.8125rem;
    font-weight: 500;
    transition: all 0.2s ease;
}

.cm-tag:hover,
.cm-category:hover {
    background: var(--cm-accent, #F47920);
    color: white;
}

/* Orange notification dot */
.cm-notification-dot {
    width: 8px;
    height: 8px;
    background: var(--cm-accent, #F47920);
    border-radius: 50%;
    display: inline-block;
    animation: pulse-orange 2s infinite;
}

@keyframes pulse-orange {
    0%, 100% { 
        opacity: 1; 
        box-shadow: 0 0 0 0 rgba(244, 121, 32, 0.4);
    }
    50% { 
        opacity: 0.8;
        box-shadow: 0 0 0 8px rgba(244, 121, 32, 0);
    }
}

/* Orange accent line decoration */
.cm-accent-line {
    position: relative;
}

.cm-accent-line::before {
    content: '';
    position: absolute;
    left: 0;
    top: 50%;
    transform: translateY(-50%);
    width: 4px;
    height: 100%;
    background: var(--cm-accent, #F47920);
    border-radius: 2px;
}

/* Read more links */
.cm-read-more {
    color: var(--cm-accent, #F47920);
    font-weight: 600;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    transition: gap 0.2s ease;
}

.cm-read-more:hover {
    gap: 0.75rem;
}

.cm-read-more::after {
    content: '→';
}

/* Table styles with orange header */
.cm-page-content table {
    width: 100%;
    border-collapse: collapse;
    margin: 1.5rem 0;
}

.cm-page-content table th {
    background: var(--cm-accent, #F47920);
    color: white;
    padding: 1rem;
    text-align: left;
    font-weight: 600;
}

.cm-page-content table td {
    padding: 1rem;
    border-bottom: 1px solid var(--cm-gray-200);
}

.cm-page-content table tr:hover td {
    background: rgba(244, 121, 32, 0.05);
}

/* Orange progress bars */
.cm-progress {
    width: 100%;
    height: 8px;
    background: var(--cm-gray-200);
    border-radius: 4px;
    overflow: hidden;
}

.cm-progress-bar {
    height: 100%;
    background: linear-gradient(90deg, var(--cm-accent, #F47920), var(--cm-accent-light, #FF9A4D));
    border-radius: 4px;
    transition: width 0.3s ease;
}

/* Tooltip with orange */
.cm-tooltip {
    position: relative;
}

.cm-tooltip::after {
    content: attr(data-tooltip);
    position: absolute;
    bottom: 100%;
    left: 50%;
    transform: translateX(-50%);
    padding: 0.5rem 1rem;
    background: var(--cm-accent, #F47920);
    color: white;
    font-size: 0.8125rem;
    border-radius: var(--cm-radius-md);
    white-space: nowrap;
    opacity: 0;
    visibility: hidden;
    transition: all 0.2s ease;
}

.cm-tooltip:hover::after {
    opacity: 1;
    visibility: visible;
    bottom: calc(100% + 8px);
}
