/* Renovate Quotient - Industrial Construction Theme */

/* Font Imports */
@import url('https://fonts.googleapis.com/css2?family=Roboto+Condensed:wght@300;400;700;900&family=Source+Sans+Pro:wght@300;400;600;700&display=swap');

/* CSS Variables */
:root {
  --construction-orange: #ff6f00;
  --safety-yellow: #ffc107;
  --steel-gray: #455a64;
  --concrete-gray: #78909c;
  --industrial-black: #263238;
  --blueprint-blue: #0277bd;
  --tool-red: #d32f2f;
  --warning-amber: #ff8f00;
  --clean-white: #ffffff;
  --dust-beige: #f5f5dc;
  --metal-silver: #cfd8dc;
  --rust-brown: #8d6e63;
  --construction-gradient: linear-gradient(135deg, #ff6f00 0%, #ffc107 100%);
  --steel-gradient: linear-gradient(45deg, #455a64 0%, #78909c 100%);
  --blueprint-gradient: linear-gradient(180deg, #0277bd 0%, #01579b 100%);
  --industrial-shadow: 0 4px 12px rgba(38, 50, 56, 0.3);
}

/* Global Reset */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: 'Source Sans Pro', sans-serif;
  line-height: 1.6;
  color: var(--industrial-black);
  background: linear-gradient(180deg, var(--dust-beige) 0%, var(--metal-silver) 100%);
  font-weight: 400;
}

/* Typography */
h1, h2, h3, h4, h5, h6 {
  font-family: 'Roboto Condensed', sans-serif;
  color: var(--steel-gray);
  margin-bottom: 1rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1px;
}

h1 { font-size: clamp(2.5rem, 5vw, 4rem); }
h2 { font-size: clamp(2rem, 4vw, 3rem); }
h3 { font-size: clamp(1.5rem, 3vw, 2.5rem); }

/* Container */
.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 1.5rem;
}

/* Header - Industrial Design */
header {
  background: var(--steel-gradient);
  position: relative;
  overflow: hidden;
  box-shadow: var(--industrial-shadow);
  border-bottom: 4px solid var(--construction-orange);
}

header::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><pattern id="grid" width="10" height="10" patternUnits="userSpaceOnUse"><path d="M 10 0 L 0 0 0 10" fill="none" stroke="%23ffffff" stroke-width="0.5" opacity="0.1"/></pattern><rect width="100" height="100" fill="url(%23grid)"/></svg>');
  opacity: 0.3;
}

.header-content {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1.5rem 0;
  position: relative;
  z-index: 2;
}

.logo-link {
  font-family: 'Roboto Condensed', sans-serif;
  font-size: 2rem;
  font-weight: 900;
  color: var(--clean-white);
  text-decoration: none;
  display: flex;
  align-items: center;
  gap: 0.75rem;
  text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.5);
  position: relative;
}

.logo-link::before {
  content: '🔨';
  font-size: 1.75rem;
  animation: hammer 2s ease-in-out infinite;
}

@keyframes hammer {
  0%, 100% { transform: rotate(0deg); }
  25% { transform: rotate(-15deg); }
  75% { transform: rotate(15deg); }
}

/* Navigation - Construction Style */
.main-nav {
  display: flex;
  align-items: center;
}

.nav-links {
  display: flex;
  list-style: none;
  gap: 0;
}

.nav-links a {
  color: var(--clean-white);
  text-decoration: none;
  font-weight: 600;
  padding: 1rem 1.5rem;
  position: relative;
  transition: all 0.3s ease;
  text-transform: uppercase;
  font-size: 0.875rem;
  letter-spacing: 1px;
  border-right: 1px solid rgba(255, 255, 255, 0.2);
}

.nav-links a::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 0;
  height: 4px;
  background: var(--construction-orange);
  transition: width 0.3s ease;
}

.nav-links a:hover,
.nav-links a.active {
  background: rgba(255, 111, 0, 0.1);
  color: var(--safety-yellow);
}

.nav-links a:hover::after,
.nav-links a.active::after {
  width: 100%;
}

/* Mobile Menu */
.menu-toggle {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  flex-direction: column;
  gap: 4px;
}

.bar {
  width: 28px;
  height: 3px;
  background: var(--clean-white);
  transition: all 0.3s ease;
}

/* Featured Post - Construction Site Style */
.featured-post {
  margin: 2rem 0 4rem;
}

.featured-post-content {
  background: var(--clean-white);
  border-radius: 0;
  overflow: hidden;
  box-shadow: var(--industrial-shadow);
  border: 2px solid var(--construction-orange);
  position: relative;
  transition: all 0.3s ease;
}

.featured-post-content::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 6px;
  background: repeating-linear-gradient(
    45deg,
    var(--construction-orange),
    var(--construction-orange) 10px,
    var(--safety-yellow) 10px,
    var(--safety-yellow) 20px
  );
}

.featured-post-content:hover {
  transform: translateY(-3px);
  box-shadow: 0 8px 25px rgba(255, 111, 0, 0.3);
}

.featured-image {
  height: 400px;
  position: relative;
  overflow: hidden;
}

.featured-image::after {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(135deg, transparent 0%, rgba(255, 111, 0, 0.2) 100%);
}

.featured-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: contrast(1.1);
}

.featured-text {
  padding: 2.5rem;
  position: relative;
}

.category-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  background: var(--construction-orange);
  color: white;
  padding: 0.75rem 1.5rem;
  font-weight: 700;
  margin-bottom: 1.5rem;
  text-transform: uppercase;
  letter-spacing: 1px;
  position: relative;
  clip-path: polygon(0 0, calc(100% - 15px) 0, 100% 100%, 0 100%);
}

.category-badge::before {
  content: '⚠️';
  font-size: 1rem;
}

.featured-text h1 {
  color: var(--industrial-black);
  margin-bottom: 1.5rem;
  line-height: 1.2;
  position: relative;
}

.post-meta {
  display: flex;
  gap: 2rem;
  color: var(--concrete-gray);
  font-size: 0.875rem;
  font-weight: 600;
  text-transform: uppercase;
}

.post-meta span {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.post-meta i {
  color: var(--blueprint-blue);
}

/* Section Headers - Blueprint Style */
.section-header {
  text-align: center;
  margin: 4rem 0 3rem;
  position: relative;
}

.section-header h2 {
  color: var(--steel-gray);
  position: relative;
  display: inline-block;
  padding: 0 2rem;
  background: var(--dust-beige);
}

.section-header::before {
  content: '';
  position: absolute;
  top: 50%;
  left: 0;
  right: 0;
  height: 2px;
  background: var(--blueprint-gradient);
  z-index: -1;
}

.section-header::after {
  content: '';
  position: absolute;
  top: calc(50% - 5px);
  left: 50%;
  transform: translateX(-50%);
  width: 10px;
  height: 10px;
  background: var(--construction-orange);
  border-radius: 50%;
}

/* Posts Grid - Construction Grid */
.posts-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 2rem;
  margin-bottom: 4rem;
}

.post-card {
  background: var(--clean-white);
  overflow: hidden;
  box-shadow: var(--industrial-shadow);
  border: 1px solid var(--concrete-gray);
  transition: all 0.3s ease;
  position: relative;
}

.post-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 4px;
  background: var(--construction-gradient);
}

.post-card::after {
  content: '';
  position: absolute;
  top: 10px;
  right: 10px;
  width: 0;
  height: 0;
  border-left: 8px solid transparent;
  border-right: 8px solid transparent;
  border-top: 8px solid var(--tool-red);
  transform: rotate(45deg);
}

.post-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 12px 30px rgba(69, 90, 100, 0.25);
  border-color: var(--construction-orange);
}

.post-image {
  height: 220px;
  position: relative;
  overflow: hidden;
}

.post-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.3s ease;
  filter: contrast(1.1);
}

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

.post-content {
  padding: 1.5rem;
}

.post-content h3 {
  color: var(--industrial-black);
  margin-bottom: 1rem;
  font-size: 1.25rem;
  line-height: 1.3;
  font-weight: 700;
}

.post-content h3:hover {
  color: var(--construction-orange);
}

/* Categories - Tool Grid */
.categories-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 2rem;
  margin-bottom: 4rem;
}

.category-card {
  background: var(--clean-white);
  padding: 2.5rem;
  text-align: center;
  box-shadow: var(--industrial-shadow);
  border: 2px solid var(--concrete-gray);
  transition: all 0.3s ease;
  position: relative;
  overflow: hidden;
}

.category-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(135deg, transparent 0%, rgba(255, 111, 0, 0.05) 100%);
  opacity: 0;
  transition: opacity 0.3s ease;
}

.category-card:hover {
  transform: translateY(-4px);
  border-color: var(--construction-orange);
  box-shadow: 0 12px 30px rgba(255, 111, 0, 0.2);
}

.category-card:hover::before {
  opacity: 1;
}

.category-icon {
  font-size: 3rem;
  color: var(--blueprint-blue);
  margin-bottom: 1.5rem;
  position: relative;
  z-index: 1;
  transition: all 0.3s ease;
}

.category-card:hover .category-icon {
  color: var(--construction-orange);
  transform: scale(1.1) rotate(5deg);
}

.category-card h3 {
  color: var(--industrial-black);
  position: relative;
  z-index: 1;
  font-weight: 700;
}

/* Single Post - Blueprint Style */
.post-article {
  max-width: 900px;
  margin: 2rem auto 4rem;
  background: var(--clean-white);
  overflow: hidden;
  box-shadow: var(--industrial-shadow);
  border: 2px solid var(--construction-orange);
  position: relative;
}

.post-article::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 6px;
  background: repeating-linear-gradient(
    45deg,
    var(--construction-orange),
    var(--construction-orange) 10px,
    var(--safety-yellow) 10px,
    var(--safety-yellow) 20px
  );
}

.post-header {
  padding: 3rem 3rem 2rem;
  background: linear-gradient(135deg, var(--dust-beige) 0%, var(--clean-white) 100%);
  text-align: center;
  border-bottom: 2px solid var(--concrete-gray);
}

.post-category a {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  background: var(--construction-orange);
  color: white;
  padding: 1rem 2rem;
  text-decoration: none;
  font-weight: 700;
  margin-bottom: 2rem;
  transition: all 0.3s ease;
  text-transform: uppercase;
  font-size: 0.875rem;
  letter-spacing: 1px;
  clip-path: polygon(0 0, calc(100% - 15px) 0, 100% 100%, 0 100%);
}

.post-category a::before {
  content: '🔧';
}

.post-category a:hover {
  background: var(--tool-red);
  transform: translateY(-2px);
  box-shadow: 0 5px 15px rgba(211, 47, 47, 0.3);
}

.post-title {
  color: var(--industrial-black);
  margin-bottom: 1.5rem;
  line-height: 1.2;
  font-weight: 900;
}

.post-featured-image {
  height: 400px;
  position: relative;
  overflow: hidden;
}

.post-featured-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.post-content {
  padding: 3rem;
  font-size: 1.125rem;
  line-height: 1.8;
  color: var(--industrial-black);
}

.post-content p {
  margin-bottom: 1.5rem;
}

.post-content h2,
.post-content h3 {
  color: var(--steel-gray);
  margin: 2.5rem 0 1.5rem;
  position: relative;
  padding-left: 2rem;
  font-weight: 700;
}

.post-content h2::before,
.post-content h3::before {
  content: '▶';
  position: absolute;
  left: 0;
  top: 0;
  color: var(--construction-orange);
  font-size: 1.5rem;
}

.post-content ul,
.post-content ol {
  margin: 1.5rem 0;
  padding-left: 2rem;
}

.post-content li {
  margin-bottom: 0.75rem;
  position: relative;
}

.post-content ul li::before {
  content: '▸';
  position: absolute;
  left: -1.5rem;
  color: var(--construction-orange);
  font-weight: bold;
}

/* Override external styles for content paragraphs */
.content-paragraph {
  font-size: 18px !important;
  line-height: 1.7 !important;
  color: var(--industrial-black) !important;
  margin: 20px 0 !important;
  font-weight: 400 !important;
  display: block !important;
}

.content-paragraph:first-of-type {
  font-size: 1.2rem !important;
  color: var(--industrial-black) !important;
}

/* Construction info boxes */
.highlight-box {
  background: var(--safety-yellow) !important;
  color: var(--industrial-black) !important;
  padding: 1.5rem 2rem !important;
  margin: 2rem 0 !important;
  border-left: 5px solid var(--construction-orange) !important;
  position: relative !important;
  border-radius: 0 !important;
}

.highlight-box::before {
  content: '⚠️' !important;
  position: absolute !important;
  top: 1rem !important;
  right: 1.5rem !important;
  font-size: 1.25rem !important;
}

.highlight-box p {
  color: var(--industrial-black) !important;
  font-weight: 600 !important;
}

/* Post Actions - Industrial Theme */
.post-actions {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 2rem 3rem;
  background: var(--metal-silver);
  border-top: 2px solid var(--concrete-gray);
}

.like-button {
  background: var(--blueprint-blue);
  color: white;
  border: none;
  padding: 1rem 2rem;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.3s ease;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  text-transform: uppercase;
  font-size: 0.875rem;
  letter-spacing: 1px;
  clip-path: polygon(0 0, calc(100% - 10px) 0, 100% 100%, 0 100%);
}

.like-button:hover {
  background: var(--construction-orange);
  transform: translateY(-2px);
  box-shadow: 0 5px 15px rgba(255, 111, 0, 0.3);
}

.share-buttons {
  display: flex;
  gap: 1rem;
}

.share-buttons a {
  width: 44px;
  height: 44px;
  background: var(--steel-gray);
  color: white;
  display: flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
  transition: all 0.3s ease;
  font-size: 1.125rem;
  border: 2px solid transparent;
}

.share-buttons a:hover {
  background: var(--construction-orange);
  border-color: var(--safety-yellow);
  transform: translateY(-2px);
}

/* Footer - Industrial Design */
footer {
  background: var(--industrial-black);
  color: var(--clean-white);
  padding: 4rem 0 2rem;
  margin-top: 4rem;
  position: relative;
}

footer::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 4px;
  background: var(--construction-gradient);
}

.footer-content {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr;
  gap: 3rem;
  margin-bottom: 2rem;
}

.footer-logo img {
  height: 50px;
  margin-bottom: 1rem;
}

.footer-logo p {
  color: var(--metal-silver);
  line-height: 1.6;
  font-size: 0.95rem;
}

.footer-links h3,
.footer-social h3 {
  color: var(--construction-orange);
  margin-bottom: 1.5rem;
  font-size: 1.25rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1px;
}

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

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

.footer-links a {
  color: var(--metal-silver);
  text-decoration: none;
  transition: color 0.3s ease;
  font-size: 0.95rem;
}

.footer-links a:hover {
  color: var(--safety-yellow);
}

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

.social-icons a {
  width: 44px;
  height: 44px;
  background: var(--steel-gray);
  color: white;
  display: flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
  transition: all 0.3s ease;
  border: 2px solid transparent;
}

.social-icons a:hover {
  background: var(--construction-orange);
  border-color: var(--safety-yellow);
  transform: translateY(-2px);
}

.footer-bottom {
  text-align: center;
  padding-top: 2rem;
  border-top: 1px solid var(--steel-gray);
  color: var(--metal-silver);
  font-size: 0.875rem;
}

/* Button Styles */
.button {
  display: inline-block;
  background: var(--construction-gradient);
  color: white;
  padding: 1rem 2rem;
  text-decoration: none;
  font-weight: 700;
  transition: all 0.3s ease;
  border: none;
  cursor: pointer;
  text-transform: uppercase;
  font-size: 0.875rem;
  letter-spacing: 1px;
  clip-path: polygon(0 0, calc(100% - 10px) 0, 100% 100%, 0 100%);
}

.button:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 20px rgba(255, 111, 0, 0.3);
  background: var(--tool-red);
}

/* Responsive Design */
@media (max-width: 768px) {
  .menu-toggle {
    display: flex;
  }

  .nav-links {
    position: fixed;
    top: 70px;
    left: -100%;
    width: 100%;
    background: var(--steel-gray);
    flex-direction: column;
    padding: 2rem;
    transition: left 0.3s ease;
    box-shadow: var(--industrial-shadow);
    border-top: 4px solid var(--construction-orange);
  }

  .nav-links.active {
    left: 0;
  }

  .nav-links a {
    padding: 1rem 0;
    border-right: none;
    border-bottom: 1px solid rgba(255, 255, 255, 0.2);
  }

  .posts-grid,
  .categories-grid {
    grid-template-columns: 1fr;
  }

  .footer-content {
    grid-template-columns: 1fr;
    text-align: center;
  }

  .post-content {
    padding: 2rem;
  }

  .post-actions {
    flex-direction: column;
    gap: 1.5rem;
    align-items: stretch;
  }

  .share-buttons {
    justify-content: center;
  }
}

@media (max-width: 480px) {
  .container {
    padding: 0 1rem;
  }

  .featured-text,
  .post-header {
    padding: 1.5rem;
  }

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

/* Loading Animation */
.loading {
  display: inline-block;
  width: 32px;
  height: 32px;
  border: 3px solid var(--metal-silver);
  border-radius: 50%;
  border-top-color: var(--construction-orange);
  animation: spin 1s ease-in-out infinite;
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

/* Construction elements */
.construction-warning {
  background: var(--warning-amber);
  border: 2px solid var(--tool-red);
  padding: 1rem;
  margin: 2rem 0;
  font-weight: 600;
  color: var(--industrial-black);
  position: relative;
}

.construction-warning::before {
  content: '⚠️ NOTICE';
  position: absolute;
  top: -10px;
  left: 1rem;
  background: var(--warning-amber);
  padding: 0 0.5rem;
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1px;
}