/*
Theme Name: BitcoinLive24
Theme URI: https://bitcoinlive24.com
Author: BitcoinLive24
Author URI: https://bitcoinlive24.com
Description: Tema ufficiale del blog BitcoinLive24 - Notizie Bitcoin e Crypto in tempo reale
Version: 1.0.0
Requires at least: 6.0
Tested up to: 6.7
Requires PHP: 8.0
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Text Domain: bitcoinlive24
Tags: blog, news, dark-mode, custom-colors, custom-menu, featured-images, threaded-comments, translation-ready
*/

/* ========================================
   BitcoinLive24 Design System
   ======================================== */

:root {
  /* Colors */
  --btc-orange: #F7931A;
  --btc-gold: #FFD700;
  --btc-green: #10B981;
  --btc-blue: #3B82F6;
  --btc-cyan: #06B6D4;

  /* Background */
  --bg-primary: #0a0a0a;
  --bg-secondary: #111111;
  --bg-card: #1a1a1a;
  --bg-card-hover: #222222;

  /* Text */
  --text-primary: #ffffff;
  --text-secondary: #a1a1aa;
  --text-muted: #71717a;

  /* Border */
  --border-color: #27272a;
  --border-hover: rgba(247, 147, 26, 0.5);

  /* Spacing */
  --container-max: 1280px;
  --section-padding: 4rem;
}

/* ========================================
   Reset & Base
   ======================================== */

*, *::before, *::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  padding: 0;
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
  background-color: #000000;
  color: #FFFFFF;
  line-height: 1.6;
  min-height: 100vh;
}

a {
  color: var(--btc-orange);
  text-decoration: none;
  transition: color 0.2s ease;
}

a:hover {
  color: var(--btc-gold);
}

img {
  max-width: 100%;
  height: auto;
}

/* ========================================
   Cyber Grid Background
   ======================================== */

.cyber-grid {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  opacity: 0.3;
  background-image:
    linear-gradient(rgba(247, 147, 26, 0.1) 1px, transparent 1px),
    linear-gradient(90deg, rgba(247, 147, 26, 0.1) 1px, transparent 1px);
  background-size: 50px 50px;
}

/* Matrix Rain Effect */
.matrix-rain {
  position: fixed;
  inset: 0;
  pointer-events: none;
  overflow: hidden;
  z-index: 1;
}

.matrix-line {
  position: absolute;
  top: 0;
  width: 2px;
  height: 100%;
  opacity: 0.4;
  animation: matrix-pulse 3s ease-in-out infinite;
}

.matrix-line:nth-child(1) {
  left: 25%;
  background: linear-gradient(to bottom, transparent, var(--btc-orange), transparent);
}

.matrix-line:nth-child(2) {
  left: 50%;
  background: linear-gradient(to bottom, transparent, var(--btc-gold), transparent);
  animation-delay: 1s;
}

.matrix-line:nth-child(3) {
  left: 75%;
  background: linear-gradient(to bottom, transparent, var(--btc-green), transparent);
  animation-delay: 2s;
}

@keyframes matrix-pulse {
  0%, 100% { opacity: 0.2; transform: scaleY(0.8); }
  50% { opacity: 0.5; transform: scaleY(1); }
}

/* ========================================
   Container
   ======================================== */

.container {
  width: 100%;
  max-width: var(--container-max);
  margin: 0 auto;
  padding: 0 1rem;
}

@media (min-width: 640px) {
  .container {
    padding: 0 1.5rem;
  }
}

@media (min-width: 1024px) {
  .container {
    padding: 0 2rem;
  }
}

/* ========================================
   Header
   ======================================== */

.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(10, 10, 10, 0.9);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border-color);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1rem 0;
}

.site-logo {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--text-primary);
}

.site-logo .btc-icon {
  color: var(--btc-orange);
  font-size: 1.75rem;
}

.site-logo span {
  background: linear-gradient(to right, var(--btc-orange), var(--btc-gold));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* Navigation */
.main-nav ul {
  display: flex;
  align-items: center;
  gap: 2rem;
  list-style: none;
  margin: 0;
  padding: 0;
}

.main-nav a {
  color: var(--text-secondary);
  font-weight: 500;
  transition: color 0.2s;
}

.main-nav a:hover {
  color: var(--btc-orange);
}

.nav-cta {
  background: var(--btc-orange);
  color: #000 !important;
  padding: 0.5rem 1.25rem;
  border-radius: 0.5rem;
  font-weight: 600;
  transition: background 0.2s;
}

.nav-cta:hover {
  background: var(--text-primary);
  color: #000 !important;
}

/* Mobile Menu Toggle */
.menu-toggle {
  display: none;
  background: none;
  border: none;
  color: var(--text-primary);
  font-size: 1.5rem;
  cursor: pointer;
  padding: 0.5rem;
}

@media (max-width: 768px) {
  .menu-toggle {
    display: block;
  }

  .main-nav {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: var(--bg-secondary);
    border-bottom: 1px solid var(--border-color);
    padding: 1rem;
  }

  .main-nav.active {
    display: block;
  }

  .main-nav ul {
    flex-direction: column;
    gap: 1rem;
  }
}

/* ========================================
   Hero Section (Homepage)
   ======================================== */

.hero-section {
  position: relative;
  padding: 4rem 0 6rem;
  background: linear-gradient(to bottom, rgba(0,0,0,0.5), rgba(17, 24, 39, 0.2));
}

.hero-content {
  text-align: center;
  max-width: 800px;
  margin: 0 auto;
}

.hero-badge {
  display: inline-block;
  padding: 0.5rem 1rem;
  background: rgba(247, 147, 26, 0.1);
  border: 1px solid var(--btc-orange);
  border-radius: 9999px;
  color: var(--btc-orange);
  font-size: 0.875rem;
  font-weight: 500;
  margin-bottom: 1.5rem;
}

.hero-title {
  font-size: 2.5rem;
  font-weight: 700;
  line-height: 1.2;
  margin-bottom: 1.5rem;
}

@media (min-width: 768px) {
  .hero-title {
    font-size: 3.5rem;
  }
}

.hero-title .highlight {
  background: linear-gradient(to right, var(--btc-orange), var(--btc-gold));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.hero-description {
  font-size: 1.125rem;
  color: var(--text-secondary);
  margin-bottom: 2rem;
}

/* ========================================
   Article Cards
   ======================================== */

.posts-grid {
  display: grid;
  gap: 1.5rem;
}

@media (min-width: 640px) {
  .posts-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (min-width: 1024px) {
  .posts-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

.article-card {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: 1rem;
  overflow: hidden;
  transition: all 0.3s ease;
}

.article-card:hover {
  border-color: var(--border-hover);
  transform: translateY(-4px);
  box-shadow: 0 20px 40px rgba(247, 147, 26, 0.1);
}

.article-card-image {
  position: relative;
  aspect-ratio: 16/9;
  overflow: hidden;
  background: var(--bg-secondary);
}

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

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

.article-card-image .category-badge {
  position: absolute;
  top: 1rem;
  left: 1rem;
  padding: 0.25rem 0.75rem;
  background: var(--btc-orange);
  color: #000;
  font-size: 0.75rem;
  font-weight: 600;
  border-radius: 9999px;
  text-transform: uppercase;
}

.article-card-content {
  padding: 1.5rem;
}

.article-card-meta {
  display: flex;
  align-items: center;
  gap: 1rem;
  font-size: 0.875rem;
  color: var(--text-muted);
  margin-bottom: 0.75rem;
}

.article-card-title {
  font-size: 1.25rem;
  font-weight: 600;
  margin-bottom: 0.75rem;
  line-height: 1.4;
}

.article-card-title a {
  color: var(--text-primary);
}

.article-card-title a:hover {
  color: var(--btc-orange);
}

.article-card-excerpt {
  color: var(--text-secondary);
  font-size: 0.9375rem;
  line-height: 1.6;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.read-more {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  margin-top: 1rem;
  color: var(--btc-orange);
  font-weight: 500;
  font-size: 0.875rem;
}

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

/* ========================================
   Featured Post
   ======================================== */

.featured-post {
  grid-column: 1 / -1;
  display: grid;
  gap: 2rem;
}

@media (min-width: 768px) {
  .featured-post {
    grid-template-columns: 1.5fr 1fr;
  }
}

.featured-post .article-card-image {
  aspect-ratio: 16/10;
}

.featured-post .article-card-title {
  font-size: 1.75rem;
}

@media (min-width: 768px) {
  .featured-post .article-card-title {
    font-size: 2rem;
  }
}

/* ========================================
   Single Article
   ======================================== */

.single-article {
  padding: 3rem 0;
}

.article-header {
  text-align: center;
  max-width: 800px;
  margin: 0 auto 3rem;
}

.article-category {
  display: inline-block;
  padding: 0.25rem 1rem;
  background: rgba(247, 147, 26, 0.1);
  border: 1px solid var(--btc-orange);
  color: var(--btc-orange);
  font-size: 0.75rem;
  font-weight: 600;
  border-radius: 9999px;
  text-transform: uppercase;
  margin-bottom: 1.5rem;
}

.article-title {
  font-size: 2rem;
  font-weight: 700;
  line-height: 1.3;
  margin-bottom: 1.5rem;
}

@media (min-width: 768px) {
  .article-title {
    font-size: 2.75rem;
  }
}

.article-meta {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 1.5rem;
  color: var(--text-muted);
  font-size: 0.9375rem;
}

.article-meta .author {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.article-meta .author img {
  width: 2.5rem;
  height: 2.5rem;
  border-radius: 50%;
}

.article-featured-image {
  margin-bottom: 3rem;
  border-radius: 1rem;
  overflow: hidden;
}

.article-featured-image img {
  width: 100%;
  height: auto;
}

.article-content {
  max-width: 720px;
  margin: 0 auto;
}

.article-content h2,
.article-content h3,
.article-content h4 {
  color: var(--text-primary);
  margin-top: 2rem;
  margin-bottom: 1rem;
}

.article-content h2 {
  font-size: 1.75rem;
  padding-bottom: 0.5rem;
  border-bottom: 2px solid var(--btc-orange);
}

.article-content h3 {
  font-size: 1.375rem;
}

.article-content p {
  color: var(--text-secondary);
  margin-bottom: 1.5rem;
}

.article-content a {
  color: var(--btc-orange);
  text-decoration: underline;
}

.article-content blockquote {
  border-left: 4px solid var(--btc-orange);
  padding-left: 1.5rem;
  margin: 2rem 0;
  font-style: italic;
  color: var(--text-secondary);
}

.article-content ul,
.article-content ol {
  color: var(--text-secondary);
  padding-left: 1.5rem;
  margin-bottom: 1.5rem;
}

.article-content li {
  margin-bottom: 0.5rem;
}

.article-content pre {
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-radius: 0.5rem;
  padding: 1rem;
  overflow-x: auto;
  margin-bottom: 1.5rem;
}

.article-content code {
  font-family: 'Fira Code', 'Consolas', monospace;
  font-size: 0.875rem;
}

.article-content img {
  border-radius: 0.5rem;
  margin: 1.5rem 0;
}

/* Article Tags */
.article-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-top: 3rem;
  padding-top: 2rem;
  border-top: 1px solid var(--border-color);
}

.article-tags a {
  padding: 0.25rem 0.75rem;
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-radius: 0.25rem;
  color: var(--text-secondary);
  font-size: 0.8125rem;
}

.article-tags a:hover {
  border-color: var(--btc-orange);
  color: var(--btc-orange);
}

/* ========================================
   Sidebar
   ======================================== */

.sidebar {
  display: flex;
  flex-direction: column;
  gap: 2rem;
}

.sidebar-widget {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: 1rem;
  padding: 1.5rem;
}

.sidebar-widget-title {
  font-size: 1.125rem;
  font-weight: 600;
  margin-bottom: 1rem;
  padding-bottom: 0.75rem;
  border-bottom: 2px solid var(--btc-orange);
}

/* ========================================
   Footer
   ======================================== */

.site-footer {
  background: var(--bg-secondary);
  border-top: 1px solid var(--border-color);
  padding: 4rem 0 2rem;
  margin-top: 4rem;
}

.footer-grid {
  display: grid;
  gap: 2rem;
  margin-bottom: 3rem;
}

@media (min-width: 768px) {
  .footer-grid {
    grid-template-columns: 2fr 1fr 1fr 1fr;
  }
}

.footer-brand .site-logo {
  margin-bottom: 1rem;
}

.footer-brand p {
  color: var(--text-muted);
  font-size: 0.9375rem;
}

.footer-links h4 {
  color: var(--text-primary);
  font-size: 1rem;
  font-weight: 600;
  margin-bottom: 1rem;
}

.footer-links ul {
  list-style: none;
  padding: 0;
  margin: 0;
}

.footer-links li {
  margin-bottom: 0.5rem;
}

.footer-links a {
  color: var(--text-muted);
  font-size: 0.9375rem;
}

.footer-links a:hover {
  color: var(--btc-orange);
}

.footer-bottom {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1rem;
  padding-top: 2rem;
  border-top: 1px solid var(--border-color);
  text-align: center;
}

@media (min-width: 768px) {
  .footer-bottom {
    flex-direction: row;
    justify-content: space-between;
  }
}

.footer-bottom p {
  color: var(--text-muted);
  font-size: 0.875rem;
  margin: 0;
}

.social-links {
  display: flex;
  gap: 1rem;
}

.social-links a {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 2.5rem;
  height: 2.5rem;
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: 0.5rem;
  color: var(--text-secondary);
  transition: all 0.2s;
}

.social-links a:hover {
  background: var(--btc-orange);
  border-color: var(--btc-orange);
  color: #000;
}

/* ========================================
   Buttons
   ======================================== */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.75rem 1.5rem;
  font-weight: 600;
  font-size: 0.9375rem;
  border-radius: 0.5rem;
  border: none;
  cursor: pointer;
  transition: all 0.2s;
}

.btn-primary {
  background: var(--btc-orange);
  color: #000;
}

.btn-primary:hover {
  background: var(--text-primary);
}

.btn-outline {
  background: transparent;
  border: 2px solid var(--btc-orange);
  color: var(--btc-orange);
}

.btn-outline:hover {
  background: var(--btc-orange);
  color: #000;
}

/* ========================================
   Pagination
   ======================================== */

.pagination {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  margin-top: 3rem;
}

.pagination a,
.pagination span {
  display: flex;
  align-items: center;
  justify-content: center;
  min-width: 2.5rem;
  height: 2.5rem;
  padding: 0 0.75rem;
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: 0.5rem;
  color: var(--text-secondary);
  font-weight: 500;
}

.pagination a:hover {
  border-color: var(--btc-orange);
  color: var(--btc-orange);
}

.pagination .current {
  background: var(--btc-orange);
  border-color: var(--btc-orange);
  color: #000;
}

/* ========================================
   Search Form
   ======================================== */

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

.search-form input[type="search"] {
  flex: 1;
  padding: 0.75rem 1rem;
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-radius: 0.5rem;
  color: var(--text-primary);
  font-size: 0.9375rem;
}

.search-form input[type="search"]:focus {
  outline: none;
  border-color: var(--btc-orange);
}

.search-form button {
  padding: 0.75rem 1rem;
  background: var(--btc-orange);
  border: none;
  border-radius: 0.5rem;
  color: #000;
  cursor: pointer;
}

/* ========================================
   Comments
   ======================================== */

.comments-area {
  margin-top: 4rem;
  padding-top: 3rem;
  border-top: 1px solid var(--border-color);
}

.comments-title {
  font-size: 1.5rem;
  margin-bottom: 2rem;
}

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

.comment {
  padding: 1.5rem;
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: 1rem;
  margin-bottom: 1rem;
}

.comment-author {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin-bottom: 0.75rem;
}

.comment-author img {
  width: 2.5rem;
  height: 2.5rem;
  border-radius: 50%;
}

.comment-author .fn {
  font-weight: 600;
  color: var(--text-primary);
}

.comment-meta {
  font-size: 0.8125rem;
  color: var(--text-muted);
}

.comment-content {
  color: var(--text-secondary);
}

/* Comment Form */
.comment-respond {
  margin-top: 2rem;
}

.comment-form label {
  display: block;
  margin-bottom: 0.5rem;
  color: var(--text-secondary);
  font-size: 0.9375rem;
}

.comment-form input,
.comment-form textarea {
  width: 100%;
  padding: 0.75rem 1rem;
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-radius: 0.5rem;
  color: var(--text-primary);
  font-size: 0.9375rem;
  margin-bottom: 1rem;
}

.comment-form input:focus,
.comment-form textarea:focus {
  outline: none;
  border-color: var(--btc-orange);
}

.comment-form textarea {
  min-height: 150px;
  resize: vertical;
}

/* ========================================
   404 Page
   ======================================== */

.error-404 {
  text-align: center;
  padding: 6rem 0;
}

.error-404 h1 {
  font-size: 8rem;
  font-weight: 700;
  background: linear-gradient(to right, var(--btc-orange), var(--btc-gold));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  margin-bottom: 1rem;
}

.error-404 h2 {
  font-size: 1.5rem;
  margin-bottom: 1rem;
}

.error-404 p {
  color: var(--text-secondary);
  margin-bottom: 2rem;
}

/* ========================================
   Utilities
   ======================================== */

.text-gradient {
  background: linear-gradient(to right, var(--btc-orange), var(--btc-gold));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.section-divider {
  height: 1px;
  background: linear-gradient(to right, transparent, var(--btc-orange), transparent);
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border-width: 0;
}

/* Layout */
.content-area {
  display: grid;
  gap: 3rem;
}

@media (min-width: 1024px) {
  .content-area.has-sidebar {
    grid-template-columns: 1fr 320px;
  }
}

/* Section Spacing */
.section {
  padding: var(--section-padding) 0;
  position: relative;
  z-index: 10;
}

/* WordPress Specific */
.wp-block-image {
  margin: 1.5rem 0;
}

.aligncenter {
  display: block;
  margin: 0 auto;
}

.alignleft {
  float: left;
  margin-right: 1.5rem;
}

.alignright {
  float: right;
  margin-left: 1.5rem;
}

.wp-caption {
  max-width: 100%;
}

.wp-caption-text {
  font-size: 0.875rem;
  color: var(--text-muted);
  text-align: center;
  margin-top: 0.5rem;
}
