/* Metal Works of Ohio - Main Stylesheet */

/* Global Styles */
:root {
  --primary-color: #2c3e50;
  --secondary-color: #e74c3c;
  --accent-color: #f39c12;
  --dark-color: #1a1a1a;
  --light-color: #ecf0f1;
  --metallic-color: #95a5a6;
  --metallic-light: #bdc3c7;
  --transition: all 0.3s ease-in-out;
}

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

body {
  font-family: "Roboto", sans-serif;
  line-height: 1.6;
  color: var(--light-color);
  background-color: var(--dark-color);
  overflow-x: hidden;
}

h1,
h2,
h3,
h4,
h5,
h6 {
  font-family: "Oswald", sans-serif;
  font-weight: 700;
  margin-bottom: 1rem;
  color: var(--light-color);
}

a {
  text-decoration: none;
  color: var(--accent-color);
  transition: var(--transition);
}

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

.container {
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 1rem;
}

.btn {
  display: inline-block;
  padding: 0.8rem 1.5rem;
  background-color: var(--secondary-color);
  color: var(--light-color);
  border: none;
  border-radius: 4px;
  font-weight: 700;
  text-transform: uppercase;
  cursor: pointer;
  transition: var(--transition);
  letter-spacing: 1px;
}

.btn:hover {
  background-color: var(--accent-color);
  transform: translateY(-3px);
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
}

.btn-large {
  padding: 1rem 2rem;
  font-size: 1.1rem;
}

/* Header Styles */
header {
  background-color: var(--primary-color);
  padding: 1rem 0;
  position: sticky;
  top: 0;
  z-index: 100;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
}

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

.logo {
  font-size: 1.8rem;
  font-weight: 900;
  color: var(--light-color);
}

.logo span {
  color: var(--secondary-color);
}

nav ul {
  display: flex;
  list-style: none;
}

nav ul li {
  margin-left: 1.5rem;
}

nav ul li a {
  color: var(--light-color);
  font-weight: 500;
  position: relative;
}

nav ul li a::after {
  content: "";
  position: absolute;
  bottom: -5px;
  left: 0;
  width: 0;
  height: 2px;
  background-color: var(--secondary-color);
  transition: var(--transition);
}

nav ul li a:hover::after {
  width: 100%;
}

/* Hero Section */
.hero {
  height: 80vh;
  background: var(--dark-color);
  display: flex;
  align-items: center;
  position: relative;
  overflow: hidden;
  border-radius: 0 0 30% 30%;
}

.hero-flex-container {
  display: flex;
  justify-content: space-between;
  align-items: center;
  width: 100%;
}

.hero-content {
  max-width: 50%;
}

.hero-image {
  max-width: 30%;
}

.hero-image img,
.contract-img {
  width: 100%;
  border-radius: 8px;
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
}

.icon-placeholder {
  width: 100%;
  height: 100%;
  min-height: 200px;
  background-color: var(--primary-color);
  border-radius: 8px;
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  padding: 2rem;
  text-align: center;
  color: var(--light-color);
  transition: var(--transition);
}

.icon-placeholder:hover {
  transform: translateY(-5px);
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.4);
}

.icon-placeholder i {
  margin-bottom: 1rem;
  color: var(--secondary-color);
}

.icon-placeholder p {
  font-weight: 500;
  margin-top: 0.5rem;
}

.hero h1 {
  font-size: 3.5rem;
  margin-bottom: 1.5rem;
  line-height: 1.2;
  font-weight: 700;
  color: white;
}

.hero p {
  font-size: 1.2rem;
  margin-bottom: 2rem;
  max-width: 600px;
  color: white;
}

@media screen and (max-width: 768px) {
  .hero-flex-container {
    flex-direction: column;
  }

  .hero-content,
  .hero-image {
    max-width: 100%;
    text-align: center;
  }

  .hero-image {
    margin-top: 2rem;
    max-width: 80%;
    margin-left: auto;
    margin-right: auto;
  }

  .hero h1 {
    font-size: 2.8rem;
  }

  .about-content {
    text-align: center;
  }
}

/* Services Section */
.services {
  padding: 5rem 0;
  background-color: var(--primary-color);
}

.section-title {
  text-align: center;
  margin-bottom: 3rem;
}

.section-title h2 {
  font-size: 2.5rem;
  display: inline-block;
  position: relative;
}

.section-title h2::after {
  content: "";
  position: absolute;
  bottom: -10px;
  left: 50%;
  transform: translateX(-50%);
  width: 80px;
  height: 3px;
  background-color: var(--secondary-color);
}

.services-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 2rem;
}

.service-card {
  background-color: var(--dark-color);
  border-radius: 8px;
  overflow: hidden;
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
  transition: var(--transition);
}

.service-card:hover {
  transform: translateY(-10px);
  box-shadow: 0 15px 30px rgba(0, 0, 0, 0.3);
}

.service-img {
  height: 200px;
  overflow: hidden;
}

.service-img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: var(--transition);
}

.service-card:hover .service-img img {
  transform: scale(1.1);
}

.service-content {
  padding: 1.5rem;
}

.service-content h3 {
  font-size: 1.5rem;
  margin-bottom: 1rem;
}

/* About Section */
.about {
  padding: 5rem 0;
  background-color: var(--dark-color);
  overflow: hidden;
  border-radius: 30% 30% 0 0;
}

.about-container {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 3rem;
  align-items: center;
}

.about-img {
  overflow: hidden;
  border-radius: 8px;
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
}

.about-img img {
  width: 100%;
  display: block;
  transition: var(--transition);
}

.about-img .icon-placeholder {
  min-height: 300px;
  background-color: var(--secondary-color);
}

.about-content {
  text-align: right;
}

.about-content h2 {
  font-size: 2.5rem;
  margin-bottom: 1.5rem;
  color: white;
}

.about-content p {
  margin-bottom: 1.5rem;
  color: white;
}

/* Team Section */
.team {
  padding: 5rem 0;
  background-color: var(--primary-color);
}

.team-container {
  text-align: center;
}

.team-img {
  max-width: 100%;
  border-radius: 8px;
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
}

.team-flex-container {
  display: flex;
  align-items: center;
  gap: 3rem;
}

.team-image-container {
  flex: 1;
}

.team-image-container .icon-placeholder {
  min-height: 250px;
  background-color: var(--primary-color);
}

.team-text-container {
  flex: 2;
  text-align: right;
}

@media screen and (max-width: 768px) {
  .team-flex-container {
    flex-direction: column;
  }

  .team-text-container {
    text-align: center;
  }
}

/* CTA Section */
.cta {
  padding: 5rem 0;
  background: var(--primary-color);
  text-align: center;
}

.cta h2 {
  font-size: 2.5rem;
  margin-bottom: 1.5rem;
}

.cta p {
  font-size: 1.2rem;
  max-width: 700px;
  margin: 0 auto 2rem;
}

/* Footer */
footer {
  background-color: var(--dark-color);
  padding: 3rem 0 1rem;
}

.footer-container {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 2rem;
  margin-bottom: 2rem;
}

.footer-col h3 {
  font-size: 1.5rem;
  margin-bottom: 1.5rem;
  position: relative;
}

.footer-col h3::after {
  content: "";
  position: absolute;
  bottom: -8px;
  left: 0;
  width: 50px;
  height: 2px;
  background-color: var(--secondary-color);
}

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

.footer-col ul li {
  margin-bottom: 0.8rem;
}

.footer-col ul li a {
  color: var(--light-color);
}

.footer-col ul li a:hover {
  color: var(--secondary-color);
  padding-left: 5px;
}

.footer-bottom {
  text-align: center;
  padding-top: 2rem;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
}

/* Animations */
@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.animate {
  animation: fadeIn 1s ease-in-out;
}

/* Responsive Design */
@media screen and (max-width: 768px) {
  .hero h1 {
    font-size: 2.5rem;
  }

  .about-container {
    grid-template-columns: 1fr;
  }

  /* Ensure navigation is always visible */
  nav ul {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
  }

  nav ul li {
    margin: 0 0.5rem;
  }
}

/* Spinning Section Holders */
.spinning-holder {
  perspective: 1000px;
  margin: 2rem auto;
  width: 300px;
  height: 300px;
}

.spinning-card {
  width: 100%;
  height: 100%;
  position: relative;
  transform-style: preserve-3d;
  transition: transform 0.8s;
}

.spinning-holder:hover .spinning-card {
  transform: rotateY(180deg);
}

.spinning-front,
.spinning-back {
  position: absolute;
  width: 100%;
  height: 100%;
  backface-visibility: hidden;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  padding: 1.5rem;
  text-align: center;
}

.spinning-front {
  background-color: var(--primary-color);
}

.spinning-back {
  background-color: var(--secondary-color);
  transform: rotateY(180deg);
}

.spinning-icon {
  font-size: 3rem;
  margin-bottom: 1rem;
}

/* Center align text for all pages except home page */
.about-content,
.services-content,
.products-content,
.processing-content,
.contact-content {
  text-align: center;
}

.about-content ul,
.services-content ul,
.products-content ul,
.processing-content ul,
.contact-content ul {
  display: inline-block;
  text-align: left;
}

/* Chatbot */
.chatbot-container {
  position: fixed;
  bottom: 20px;
  right: 20px;
  z-index: 1000;
}

.chatbot-button {
  width: 60px;
  height: 60px;
  border-radius: 50%;
  background-color: var(--secondary-color);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
  transition: var(--transition);
}

.chatbot-button:hover {
  background-color: var(--accent-color);
  transform: scale(1.1);
}

.chatbot-icon {
  color: var(--light-color);
  font-size: 1.5rem;
}

/* Chatbot Interface */
.chatbot-interface {
  position: absolute;
  bottom: 80px;
  right: 0;
  width: 350px;
  height: 450px;
  background-color: var(--light-color);
  border-radius: 10px;
  box-shadow: 0 5px 25px rgba(0, 0, 0, 0.3);
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.chatbot-header {
  background-color: var(--primary-color);
  color: var(--light-color);
  padding: 15px;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.chatbot-header h3 {
  margin: 0;
  font-size: 1.2rem;
}

.close-chatbot {
  background: none;
  border: none;
  color: var(--light-color);
  cursor: pointer;
  font-size: 1.2rem;
}

.chatbot-messages {
  flex: 1;
  padding: 15px;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 10px;
  background-color: #f5f5f5;
}

.bot-message,
.user-message {
  max-width: 80%;
  padding: 10px 15px;
  border-radius: 15px;
  margin-bottom: 5px;
  word-wrap: break-word;
}

.bot-message {
  background-color: var(--primary-color);
  color: var(--light-color);
  align-self: flex-start;
  border-bottom-left-radius: 5px;
}

.user-message {
  background-color: var(--secondary-color);
  color: var(--light-color);
  align-self: flex-end;
  border-bottom-right-radius: 5px;
}

.chatbot-input {
  display: flex;
  padding: 10px;
  background-color: #fff;
  border-top: 1px solid #ddd;
}

.chatbot-input input {
  flex: 1;
  padding: 10px;
  border: 1px solid #ddd;
  border-radius: 20px;
  outline: none;
}

.send-message {
  background-color: var(--secondary-color);
  color: var(--light-color);
  border: none;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  margin-left: 10px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
}

.typing-indicator {
  display: flex;
  align-items: center;
  align-self: flex-start;
  background-color: #e6e6e6;
  padding: 10px 15px;
  border-radius: 15px;
  margin-bottom: 5px;
}

.typing-indicator span {
  height: 8px;
  width: 8px;
  background-color: #999;
  border-radius: 50%;
  display: inline-block;
  margin-right: 5px;
  animation: typing 1s infinite ease-in-out;
}

.typing-indicator span:nth-child(1) {
  animation-delay: 0s;
}

.typing-indicator span:nth-child(2) {
  animation-delay: 0.2s;
}

.typing-indicator span:nth-child(3) {
  animation-delay: 0.4s;
  margin-right: 0;
}

@keyframes typing {
  0% {
    transform: translateY(0px);
  }
  50% {
    transform: translateY(-5px);
  }
  100% {
    transform: translateY(0px);
  }
}
