/*
 * Styles for the RoadIrish Apparel web store.
 *
 * The design takes inspiration from the bold, patriotic aesthetic of brands like
 * Grunt Style: dark backgrounds, high contrast typography and pops of red,
 * white and blue. Layouts are responsive, using flexbox and CSS grid to
 * organize navigation, hero content and product listings.
 */

/* CSS Reset and variables */
:root {
  --color-background: #1a1a1a;
  --color-primary: #d32f2f; /* deep red accent */
  --color-secondary: #0d47a1; /* navy blue accent */
  --color-light: #ffffff;
  --color-muted: #cccccc;
  --font-family-base: 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
}

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

body {
  font-family: var(--font-family-base);
  line-height: 1.6;
  background-color: var(--color-background);
  color: var(--color-light);
}

a {
  color: var(--color-light);
  text-decoration: none;
  transition: color 0.3s ease;
}

a:hover {
  color: var(--color-primary);
}

.container {
  width: 90%;
  max-width: 1200px;
  margin: 0 auto;
}

/* Header */
.site-header {
  background-color: var(--color-background);
  padding: 1rem 0;
  border-bottom: 2px solid var(--color-primary);
  position: sticky;
  top: 0;
  z-index: 1000;
}

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

.logo a {
  font-size: 1.8rem;
  font-weight: 700;
  color: var(--color-primary);
}

nav .nav-list {
  list-style: none;
  display: flex;
  gap: 1.5rem;
}

nav .nav-list li {
  font-size: 1rem;
  font-weight: 500;
}

.cart-link a {
  font-weight: 500;
  background-color: var(--color-primary);
  padding: 0.5rem 1rem;
  border-radius: 4px;
  transition: background-color 0.3s ease;
}

.cart-link a:hover {
  background-color: var(--color-secondary);
}

/* Hero section */
.hero {
  position: relative;
  width: 100%;
  height: 60vh;
  overflow: hidden;
}

.hero-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.hero-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.5);
  pointer-events: none;
}

.hero-content {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  text-align: center;
  max-width: 80%;
}

.hero-content h1 {
  font-size: 3rem;
  margin-bottom: 0.5rem;
  color: var(--color-light);
  letter-spacing: 2px;
  text-transform: uppercase;
}

.hero-content p {
  font-size: 1.2rem;
  margin-bottom: 1.5rem;
  color: var(--color-muted);
}

.btn-primary {
  background-color: var(--color-primary);
  color: var(--color-light);
  padding: 0.75rem 1.5rem;
  border: none;
  border-radius: 4px;
  font-size: 1rem;
  cursor: pointer;
  transition: background-color 0.3s ease;
}

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

/* Collections & products */
.content {
  padding: 2rem 0;
}

.collection h2 {
  font-size: 2rem;
  margin: 2rem 0 1rem;
  border-bottom: 2px solid var(--color-primary);
  display: inline-block;
}

.product-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 1.5rem;
}

.product-card {
  background-color: #2b2b2b;
  padding: 1rem;
  border-radius: 6px;
  text-align: center;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  border: 1px solid rgba(255, 255, 255, 0.05);
}

.product-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 8px 15px rgba(0, 0, 0, 0.3);
}

.product-img {
  width: 100%;
  height: 200px;
  object-fit: contain;
  margin-bottom: 1rem;
  filter: drop-shadow(0 0 3px rgba(0,0,0,0.5));
}

.product-title {
  font-size: 1.1rem;
  margin-bottom: 0.5rem;
  color: var(--color-light);
}

.price {
  color: var(--color-primary);
  font-weight: 700;
  margin-bottom: 1rem;
}

.add-to-cart {
  background-color: var(--color-primary);
  color: var(--color-light);
  border: none;
  padding: 0.5rem 1rem;
  border-radius: 4px;
  cursor: pointer;
  transition: background-color 0.3s ease;
}

.add-to-cart:hover {
  background-color: var(--color-secondary);
}

/* Footer */
.site-footer {
  background-color: #111;
  padding: 1rem 0;
  text-align: center;
  border-top: 2px solid var(--color-primary);
}

.site-footer p {
  color: var(--color-muted);
  font-size: 0.9rem;
}

/* Contact page styles */
.contact-wrapper {
  display: flex;
  flex-wrap: wrap;
  gap: 2rem;
  margin-top: 1.5rem;
}

.contact-form {
  flex: 1 1 300px;
}

.contact-info {
  flex: 1 1 250px;
  margin-top: 1rem;
}

.form-group {
  display: flex;
  flex-direction: column;
  margin-bottom: 1rem;
  color: var(--color-light);
}

.form-group label {
  margin-bottom: 0.3rem;
  font-weight: 500;
}

.form-group input,
.form-group textarea {
  padding: 0.5rem;
  border: 1px solid #444;
  border-radius: 4px;
  background-color: #333;
  color: var(--color-light);
  font-size: 1rem;
}

.form-group input:focus,
.form-group textarea:focus {
  outline: none;
  border-color: var(--color-primary);
}

.contact-info p {
  margin-bottom: 0.5rem;
  color: var(--color-muted);
}

/* Modal styles */
.modal {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.8);
  display: flex;
  align-items: center;
  justify-content: center;
  overflow-y: auto;
}

.modal.hidden {
  display: none;
}

.modal-content {
  background-color: #2b2b2b;
  padding: 2rem;
  border-radius: 6px;
  width: 90%;
  max-width: 600px;
  color: var(--color-light);
  position: relative;
}

.close-modal {
  position: absolute;
  top: 10px;
  right: 10px;
  font-size: 1.5rem;
  cursor: pointer;
  color: var(--color-muted);
}

/* Responsive text scaling */
@media (max-width: 768px) {
  .hero-content h1 {
    font-size: 2rem;
  }
  .hero-content p {
    font-size: 1rem;
  }
}