/* styles.css - Main stylesheet for Cheese Tarot */

/* Base styles and variables */
:root {
  --primary-color: #f9e8c7; /* Soft cream color */
  --secondary-color: #e6c87d; /* Golden cheese color */
  --accent-color: #d4a24e; /* Aged cheese amber */
  --text-color: #4a4238; /* Dark brown */
  --background-color: #fcf9f2; /* Off-white */
  --card-back-color: #e9c46a; /* Golden yellow */
  --shadow-color: rgba(0, 0, 0, 0.1);
  --border-radius: 12px;
  --transition-speed: 0.3s;
}

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

body {
  font-family: 'Poppins', sans-serif;
  background-color: var(--background-color);
  color: var(--text-color);
  line-height: 1.6;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  background-image: url('../img/background.jpg');
  background-size: cover;
  background-attachment: fixed;
  background-position: center;
}

.container {
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 2rem;
  flex: 1;
  display: flex;
  flex-direction: column;
}

/* Typography */
h1, h2, h3, h4 {
  font-family: 'Playfair Display', serif;
  margin-bottom: 1rem;
}

h1 {
  font-size: 3.5rem;
  text-align: center;
  color: var(--accent-color);
  margin-bottom: 0.5rem;
}

.tagline {
  text-align: center;
  font-style: italic;
  margin-bottom: 2rem;
  font-size: 1.2rem;
}

/* Header */
header {
  margin-bottom: 2rem;
  padding: 2rem 0;
}

/* Main content */
main {
  flex: 1;
}

.intro {
  text-align: center;
  max-width: 800px;
  margin: 0 auto 3rem;
  padding: 2rem;
  background-color: rgba(255, 255, 255, 0.8);
  border-radius: var(--border-radius);
  box-shadow: 0 4px 12px var(--shadow-color);
}

.intro p {
  margin-bottom: 2rem;
  font-size: 1.1rem;
}

/* Buttons */
.btn {
  padding: 0.8rem 1.5rem;
  border: none;
  border-radius: 30px;
  font-family: 'Poppins', sans-serif;
  font-weight: 600;
  font-size: 1rem;
  cursor: pointer;
  transition: all var(--transition-speed) ease;
}

.primary-btn {
  background-color: var(--accent-color);
  color: white;
}

.primary-btn:hover {
  background-color: #c08f3d;
  transform: translateY(-2px);
  box-shadow: 0 4px 8px var(--shadow-color);
}

.secondary-btn {
  background-color: var(--secondary-color);
  color: var(--text-color);
  margin-top: 2rem;
}

.secondary-btn:hover {
  background-color: #d9b96a;
  transform: translateY(-2px);
  box-shadow: 0 4px 8px var(--shadow-color);
}

/* Reading area */
.reading-area {
  margin: 2rem auto;
  padding: 2rem;
  background-color: rgba(255, 255, 255, 0.9);
  border-radius: var(--border-radius);
  box-shadow: 0 6px 18px var(--shadow-color);
  text-align: center;
}

.cards-container {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 2rem;
  margin: 2rem 0;
}

.card-slot {
  width: 220px;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.card {
  width: 100%;
  height: 320px;
  perspective: 1000px;
  margin-bottom: 1rem;
}

.card-inner {
  position: relative;
  width: 100%;
  height: 100%;
  transition: transform 0.8s;
  transform-style: preserve-3d;
  box-shadow: 0 4px 8px var(--shadow-color);
  border-radius: var(--border-radius);
}

.card-back, .card-front {
  position: absolute;
  width: 100%;
  height: 100%;
  backface-visibility: hidden;
  border-radius: var(--border-radius);
  overflow: hidden;
}

.card-back {
  background-color: var(--card-back-color);
  display: flex;
  align-items: center;
  justify-content: center;
}

.card-back-design {
  width: 90%;
  height: 90%;
  border: 2px solid rgba(255, 255, 255, 0.5);
  border-radius: var(--border-radius);
  background-image: repeating-linear-gradient(
    45deg,
    transparent,
    transparent 10px,
    rgba(255, 255, 255, 0.1) 10px,
    rgba(255, 255, 255, 0.1) 20px
  );
}

.card-front {
  background-color: white;
  transform: rotateY(180deg);
  padding: 1rem;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.card-title {
  font-size: 1.1rem;
  margin-bottom: 0.5rem;
  text-align: center;
}

.cheese-name {
  font-size: 1rem;
  color: var(--accent-color);
  margin-bottom: 1rem;
  font-style: italic;
}

.card-image {
  width: 100%;
  height: 150px;
  background-color: var(--primary-color);
  border-radius: var(--border-radius);
  margin-bottom: 1rem;
}

.card-position {
  font-weight: 600;
  margin-bottom: 0.5rem;
  color: var(--accent-color);
}

.card-interpretation {
  font-size: 0.9rem;
  text-align: center;
  height: 120px;
  overflow-y: auto;
  padding: 0.5rem;
  background-color: rgba(255, 255, 255, 0.7);
  border-radius: var(--border-radius);
  margin-top: 0.5rem;
}

/* Footer */
footer {
  text-align: center;
  padding: 2rem 0;
  font-size: 0.9rem;
  color: var(--text-color);
  opacity: 0.8;
}

/* Utility classes */
.hidden {
  display: none;
}

/* Responsive design */
@media (max-width: 768px) {
  .container {
    padding: 1rem;
  }
  
  h1 {
    font-size: 2.5rem;
  }
  
  .cards-container {
    gap: 1rem;
  }
  
  .card-slot {
    width: 180px;
  }
  
  .card {
    height: 260px;
  }
  
  .card-interpretation {
    height: 100px;
  }
}

@media (max-width: 576px) {
  .cards-container {
    flex-direction: column;
    align-items: center;
  }
  
  .card-slot {
    width: 220px;
    margin-bottom: 2rem;
  }
  
  .card {
    height: 320px;
  }
}
