/*
Theme Name:   GeneratePress Child
Theme URI:    https://xclock.app
Description:  Child theme for XClock - Custom digital clock functionality
Author:       XClock Team
Author URI:   https://xclock.app
Template:     generatepress
Version:      2.0.0
License:      GNU General Public License v2 or later
License URI:  http://www.gnu.org/licenses/gpl-2.0.html
Text Domain:  generatepress-child
*/

/* ========================================
   DARK MODE FORCED STYLES
   Matches XClock gradient theme
   ======================================== */

/* Body & Main Background */
body {
    background: linear-gradient(135deg, #2d3748 0%, #1a202c 100%) !important;
    background-attachment: fixed !important;
    color: #f5f7fa !important;
    min-height: 100vh;
}

/* Main content area */
.site,
.site-content,
main,
article,
.entry-content {
    background: transparent !important;
    color: #f5f7fa !important;
}

/* Container backgrounds */
.inside-article,
.site-main > *,
.page .entry-content,
.single .entry-content {
    background: rgba(45, 55, 72, 0.5) !important;
    border-radius: 8px;
    padding: 2rem;
    margin-bottom: 2rem;
}

/* Text colors */
body,
p,
li,
td,
th,
span,
div {
    color: #f5f7fa !important;
}

/* Headings */
h1, h2, h3, h4, h5, h6,
.entry-title,
.site-title {
    color: #ffffff !important;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
}

/* Site Title - Centered, Larger, Bold */
.site-title {
    text-align: center !important;
    font-size: 2rem !important;
    font-weight: bold !important;
}

/* Links */
a {
    color: #60a5fa !important;
    text-decoration: none;
    transition: color 0.3s ease;
}

a:hover,
a:focus {
    color: #93c5fd !important;
    text-decoration: underline;
}

/* Header */
.site-header,
.main-navigation {
    background: rgba(26, 32, 44, 0.95) !important;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

/* Hide Top Navigation Menu (moving to footer) */
.main-navigation {
    display: none !important;
}

.main-navigation a,
.menu-toggle {
    color: #f5f7fa !important;
}

.main-navigation a:hover {
    color: #60a5fa !important;
}

/* ========================================
   FOOTER STYLING - COMPLETE FIX
   ======================================== */

/* Main footer container - Force vertical stacking with perfect centering */
.site-footer {
    background: rgba(26, 32, 44, 0.95) !important;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    color: #ffffff !important;
    display: flex !important;
    flex-direction: column !important;
    justify-content: center !important;
    align-items: center !important;
    text-align: center !important;
}

/* Footer widgets (Links) - Display FIRST (Top) */
.footer-widgets {
    order: 1 !important;
    width: 100% !important;
    padding: 2rem 0 !important;
}

.footer-widgets,
.footer-widgets * {
    color: #ffffff !important;
}

.footer-widgets a {
    color: #ffffff !important;
    text-decoration: none !important;
}

.footer-widgets a:hover {
    color: #60a5fa !important;
    text-decoration: none !important;
}

/* Site info (Copyright) - Display SECOND (Bottom) with proper spacing */
.site-info {
    order: 2 !important;
    background-color: transparent !important;
    background: transparent !important;
    width: 100% !important;
    padding: 1.5rem 0 !important;
    padding-bottom: 20px !important;
}

.site-info,
.site-info *,
.site-info p,
.site-info span,
.site-info a {
    color: #ffffff !important;
}

.site-info a {
    color: #ffffff !important;
    text-decoration: none !important;
}

.site-info a:hover {
    color: #60a5fa !important;
    text-decoration: none !important;
}

/* Remove any underlines from all footer links */
.site-footer a,
.site-footer a:link,
.site-footer a:visited,
.site-footer a:hover,
.site-footer a:active {
    text-decoration: none !important;
}

/* Sidebar (if any) */
.sidebar,
.widget {
    background: rgba(45, 55, 72, 0.5) !important;
    border-radius: 8px;
    padding: 1.5rem;
    margin-bottom: 2rem;
}

.widget-title {
    color: #ffffff !important;
    border-bottom: 2px solid rgba(96, 165, 250, 0.3);
    padding-bottom: 0.5rem;
}

/* Buttons */
button,
.button,
.wp-block-button__link,
input[type="submit"],
input[type="button"] {
    background: #2563eb !important;
    color: #ffffff !important;
    border: none !important;
    border-radius: 8px;
    padding: 0.75rem 1.5rem;
    cursor: pointer;
    transition: all 0.3s ease;
}

button:hover,
.button:hover,
.wp-block-button__link:hover,
input[type="submit"]:hover,
input[type="button"]:hover {
    background: #1d4ed8 !important;
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(37, 99, 235, 0.3);
}

/* Forms */
input[type="text"],
input[type="email"],
input[type="url"],
input[type="password"],
input[type="search"],
input[type="number"],
input[type="tel"],
input[type="date"],
textarea,
select {
    background: rgba(255, 255, 255, 0.1) !important;
    border: 2px solid #4b5563 !important;
    color: #f5f7fa !important;
    border-radius: 8px;
    padding: 0.75rem;
    transition: border-color 0.3s ease;
}

input:focus,
textarea:focus,
select:focus {
    outline: none !important;
    border-color: #60a5fa !important;
    background: rgba(255, 255, 255, 0.15) !important;
}

input::placeholder,
textarea::placeholder {
    color: #9ca3af !important;
}

/* Tables */
table {
    background: rgba(45, 55, 72, 0.5) !important;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

th {
    background: rgba(26, 32, 44, 0.8) !important;
    color: #ffffff !important;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

td {
    border: 1px solid rgba(255, 255, 255, 0.1);
}

/* Blockquotes */
blockquote {
    background: rgba(26, 32, 44, 0.5) !important;
    border-left: 4px solid #60a5fa !important;
    padding: 1rem 1.5rem;
    margin: 1.5rem 0;
    color: #e5e7eb !important;
}

/* Code blocks */
code,
pre {
    background: rgba(26, 32, 44, 0.8) !important;
    color: #93c5fd !important;
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 4px;
}

pre {
    padding: 1rem;
    overflow-x: auto;
}

/* Images - add subtle border */
img {
    border-radius: 8px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.3);
}

/* WordPress blocks */
.wp-block-group,
.wp-block-cover {
    background: rgba(45, 55, 72, 0.5) !important;
    border-radius: 8px;
}

/* ========================================
   HIDE HOME PAGE TITLE
   ======================================== */

/* Hide "Home" title on homepage */
.home .entry-header,
.home .entry-title,
.page-id-3 .entry-header,
.page-id-3 .entry-title {
    display: none !important;
}

/* Alternative: Hide any page title that says "Home" */
.entry-title:contains("Home"),
h1:contains("Home") {
    display: none !important;
}

/* ========================================
   NAVIGATION IMPROVEMENTS
   ======================================== */

/* Mobile menu */
.main-navigation .menu-toggle {
    background: rgba(37, 99, 235, 0.8) !important;
    border: none;
}

/* Dropdown menus */
.main-navigation .sub-menu {
    background: rgba(26, 32, 44, 0.98) !important;
    border: 1px solid rgba(255, 255, 255, 0.1);
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.3);
}

.main-navigation .sub-menu a {
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

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

.nav-links a,
.page-numbers {
    background: rgba(45, 55, 72, 0.8) !important;
    color: #f5f7fa !important;
    border: 1px solid rgba(255, 255, 255, 0.1);
    padding: 0.5rem 1rem;
    border-radius: 4px;
    margin: 0 0.25rem;
}

.nav-links a:hover,
.page-numbers:hover {
    background: rgba(37, 99, 235, 0.8) !important;
}

.page-numbers.current {
    background: #2563eb !important;
    color: #ffffff !important;
}

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

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

.search-form input[type="search"] {
    flex: 1;
}

.search-form button {
    flex-shrink: 0;
}

/* ========================================
   COMMENTS SECTION
   ======================================== */

.comment-list,
.comment-respond {
    background: rgba(45, 55, 72, 0.5) !important;
    border-radius: 8px;
    padding: 1.5rem;
}

.comment {
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    padding: 1rem 0;
}

.comment-author,
.comment-metadata {
    color: #9ca3af !important;
}

.comment-content {
    color: #f5f7fa !important;
}

/* ========================================
   RESPONSIVE ADJUSTMENTS
   ======================================== */

@media (max-width: 768px) {
    .inside-article,
    .site-main > *,
    .page .entry-content,
    .single .entry-content {
        padding: 1rem;
        border-radius: 4px;
    }

    body {
        font-size: 16px;
    }
}

/* ========================================
   SCROLLBAR STYLING (Webkit browsers)
   ======================================== */

::-webkit-scrollbar {
    width: 12px;
}

::-webkit-scrollbar-track {
    background: #1a202c;
}

::-webkit-scrollbar-thumb {
    background: #4b5563;
    border-radius: 6px;
}

::-webkit-scrollbar-thumb:hover {
    background: #60a5fa;
}

/* ========================================
   SELECTION HIGHLIGHT
   ======================================== */

::selection {
    background: rgba(96, 165, 250, 0.3);
    color: #ffffff;
}

::-moz-selection {
    background: rgba(96, 165, 250, 0.3);
    color: #ffffff;
}

/* ========================================
   ACCESSIBILITY
   ======================================== */

/* Focus styles for keyboard navigation */
a:focus,
button:focus,
input:focus,
textarea:focus,
select:focus {
    outline: 2px solid #60a5fa !important;
    outline-offset: 2px;
}

/* Skip to content link */
.skip-link {
    background: #2563eb;
    color: #ffffff;
    padding: 0.5rem 1rem;
    border-radius: 4px;
}

.skip-link:focus {
    outline: 2px solid #ffffff;
}
