/**
 * two-rings Corporate Website
 * Main Stylesheet
 * Design: Modern × Minimal × Professional
 */

/* ============================================
   1. CSS Reset & Defaults
   ============================================ */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  font-size: 16px;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
  line-height: 1.6;
  color: #333333;
  background-color: #ffffff;
  overflow-x: hidden;
}

/* ============================================
   2. Typography
   ============================================ */
h1 {
  font-size: 48px;
  font-weight: 700;
  line-height: 1.2;
  margin-bottom: 24px;
}

h2 {
  font-size: 36px;
  font-weight: 600;
  line-height: 1.3;
  margin-bottom: 24px;
}

h3 {
  font-size: 24px;
  font-weight: 600;
  line-height: 1.4;
  margin-bottom: 16px;
}

p {
  font-size: 16px;
  font-weight: 400;
  line-height: 1.6;
  margin-bottom: 16px;
}

a {
  color: #0066CC;
  text-decoration: none;
  transition: color 0.3s ease, opacity 0.3s ease;
}

a:hover {
  color: #003366;
}

/* ============================================
   3. Color System
   ============================================ */
:root {
  --color-primary-light: #0066CC;
  --color-primary-dark: #003366;
  --color-accent: #00CC66;
  --color-white: #ffffff;
  --color-light-gray: #F5F5F5;
  --color-medium-gray: #CCCCCC;
  --color-dark-gray: #333333;
  --color-border: #E0E0E0;
  
  /* Spacing */
  --space-xs: 8px;
  --space-sm: 16px;
  --space-md: 24px;
  --space-lg: 32px;
  --space-xl: 48px;
  --space-2xl: 64px;
  
  /* Shadow */
  --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.1);
  --shadow-md: 0 4px 16px rgba(0, 102, 204, 0.2);
  --shadow-lg: 0 8px 32px rgba(0, 0, 0, 0.15);
}

/* ============================================
   4. Header & Navigation
   ============================================ */
header {
  position: sticky;
  top: 0;
  z-index: 100;
  height: 60px;
  background-color: var(--color-white);
  border-bottom: 1px solid var(--color-border);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 var(--space-lg);
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
}

.logo {
  font-size: 20px;
  font-weight: 700;
  color: var(--color-primary-dark);
  display: flex;
  align-items: center;
  gap: var(--space-sm);
}

.logo-text {
  letter-spacing: 0.5px;
}

nav {
  display: flex;
  align-items: center;
  gap: var(--space-lg);
}

nav a {
  font-size: 14px;
  font-weight: 500;
  color: var(--color-dark-gray);
  position: relative;
  transition: color 0.3s ease;
}

nav a::after {
  content: '';
  position: absolute;
  bottom: -4px;
  left: 0;
  width: 0;
  height: 2px;
  background-color: var(--color-accent);
  transition: width 0.3s ease;
}

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

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

.nav-cta {
  background-color: var(--color-accent);
  color: var(--color-white) !important;
  padding: 10px 24px;
  border-radius: 4px;
  font-weight: 600;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.nav-cta::after {
  display: none;
}

.nav-cta:hover {
  color: var(--color-white) !important;
  box-shadow: var(--shadow-md);
  transform: translateY(-2px);
}

.hamburger {
  display: none;
  width: 24px;
  height: 24px;
  flex-direction: column;
  justify-content: space-around;
  cursor: pointer;
  z-index: 200;
}

.hamburger span {
  width: 100%;
  height: 2px;
  background-color: var(--color-dark-gray);
  transition: all 0.3s ease;
  border-radius: 1px;
}

.hamburger.active span:nth-child(1) {
  transform: rotate(45deg) translate(8px, 8px);
}

.hamburger.active span:nth-child(2) {
  opacity: 0;
}

.hamburger.active span:nth-child(3) {
  transform: rotate(-45deg) translate(8px, -8px);
}

/* ============================================
   5. Buttons
   ============================================ */
.btn {
  display: inline-block;
  padding: 12px 32px;
  border-radius: 4px;
  font-weight: 600;
  font-size: 16px;
  cursor: pointer;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  border: none;
  text-align: center;
  text-decoration: none;
  white-space: nowrap;
}

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

.btn-primary:hover {
  box-shadow: var(--shadow-md);
  transform: translateY(-2px);
}

.btn-secondary {
  background-color: transparent;
  color: var(--color-primary-light);
  border: 2px solid var(--color-primary-light);
}

.btn-secondary:hover {
  background-color: rgba(0, 102, 204, 0.05);
}

.btn-large {
  padding: 16px 48px;
  font-size: 18px;
}

.btn-block {
  display: block;
  width: 100%;
}

/* ============================================
   6. Container & Layout
   ============================================ */
.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 var(--space-lg);
}

.section {
  padding: var(--space-2xl) 0;
}

.section-light {
  background-color: var(--color-light-gray);
}

.section-dark {
  background-color: var(--color-primary-dark);
  color: var(--color-white);
}

.section-dark a {
  color: var(--color-accent);
}

/* Grid System */
.grid {
  display: grid;
  gap: var(--space-lg);
}

.grid-2 {
  grid-template-columns: repeat(2, 1fr);
}

.grid-3 {
  grid-template-columns: repeat(3, 1fr);
}

.grid-cols-1-2 {
  grid-template-columns: 1fr 1fr;
  align-items: center;
}

/* Flex utilities */
.flex {
  display: flex;
}

.flex-center {
  display: flex;
  align-items: center;
  justify-content: center;
}

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

.flex-col {
  flex-direction: column;
}

.gap-sm { gap: var(--space-sm); }
.gap-md { gap: var(--space-md); }
.gap-lg { gap: var(--space-lg); }

/* ============================================
   7. Hero Section
   ============================================ */
.hero {
  position: relative;
  height: 600px;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  color: var(--color-white);
  overflow: hidden;
}

.hero::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(135deg, #0066CC 0%, #003366 100%);
  z-index: -2;
}

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

.hero-content {
  position: relative;
  z-index: 1;
  max-width: 800px;
  padding: 0 var(--space-lg);
}

.hero h1 {
  color: var(--color-white);
  margin-bottom: 24px;
  animation: fadeInUp 0.8s ease-out;
}

.hero p {
  font-size: 18px;
  color: rgba(255, 255, 255, 0.9);
  margin-bottom: 32px;
  animation: fadeInUp 0.8s ease-out 0.2s both;
}

.hero .btn {
  animation: fadeInUp 0.8s ease-out 0.4s both;
}

@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* ============================================
   8. Cards
   ============================================ */
.card {
  background-color: var(--color-white);
  border-radius: 8px;
  padding: var(--space-lg);
  box-shadow: var(--shadow-sm);
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  height: 100%;
}

.card:hover {
  box-shadow: var(--shadow-md);
  transform: translateY(-4px);
}

.card-icon {
  width: 48px;
  height: 48px;
  margin-bottom: var(--space-md);
  color: var(--color-primary-light);
  font-size: 32px;
}

.card-title {
  font-size: 20px;
  font-weight: 600;
  margin-bottom: 12px;
  color: var(--color-dark-gray);
}

.card-text {
  font-size: 14px;
  color: #666666;
  line-height: 1.6;
}

.product-image {
  border-radius: 8px;
  height: 250px;
  margin-bottom: var(--space-lg);
  overflow: hidden;
  background-color: #f5f5f5;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 1px solid #ddd;
}

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

/* ============================================
   9. Footer
   ============================================ */
footer {
  background-color: var(--color-primary-dark);
  color: var(--color-white);
  padding: var(--space-xl) 0 var(--space-md) 0;
  text-align: center;
}

.footer-menu {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: var(--space-md);
  margin-bottom: var(--space-lg);
}

.footer-menu a {
  color: rgba(255, 255, 255, 0.8);
  font-size: 14px;
  transition: opacity 0.3s ease;
}

.footer-menu a:hover {
  color: var(--color-accent);
  opacity: 1;
}

.footer-copyright {
  font-size: 12px;
  color: rgba(255, 255, 255, 0.6);
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  padding-top: var(--space-md);
}

/* ============================================
   10. Forms
   ============================================ */
.form-group {
  margin-bottom: var(--space-lg);
}

.form-label {
  display: block;
  margin-bottom: var(--space-sm);
  font-weight: 600;
  font-size: 14px;
  color: var(--color-dark-gray);
}

.form-input,
.form-select,
.form-textarea {
  width: 100%;
  padding: 12px 0;
  font-size: 16px;
  border: none;
  border-bottom: 1px solid var(--color-border);
  font-family: inherit;
  transition: all 0.3s ease;
  background-color: transparent;
}

.form-input:focus,
.form-select:focus,
.form-textarea:focus {
  outline: none;
  border-bottom-color: var(--color-primary-light);
  box-shadow: 0 2px 0 var(--color-primary-light);
}

.form-textarea {
  resize: vertical;
  min-height: 120px;
  padding: 12px;
  border: 1px solid var(--color-border);
  border-radius: 4px;
  background-color: var(--color-white);
}

.form-textarea:focus {
  border-color: var(--color-primary-light);
  box-shadow: 0 0 0 3px rgba(0, 102, 204, 0.1);
}

.form-checkbox {
  display: flex;
  align-items: center;
  gap: var(--space-sm);
  margin-bottom: var(--space-md);
}

.form-checkbox input {
  width: 18px;
  height: 18px;
  cursor: pointer;
}

.form-checkbox label {
  cursor: pointer;
  font-size: 14px;
}

.form-error {
  color: #cc0000;
  font-size: 12px;
  margin-top: 4px;
  display: none;
}

.form-input.error,
.form-select.error {
  border-bottom-color: #cc0000;
}

.form-input.error ~ .form-error,
.form-select.error ~ .form-error {
  display: block;
}

/* ============================================
   11. Utility Classes
   ============================================ */
.text-center {
  text-align: center;
}

.text-left {
  text-align: left;
}

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

.text-white {
  color: var(--color-white);
}

.text-gray {
  color: #666666;
}

.text-small {
  font-size: 14px;
}

.text-muted {
  opacity: 0.7;
}

.mb-sm { margin-bottom: var(--space-sm); }
.mb-md { margin-bottom: var(--space-md); }
.mb-lg { margin-bottom: var(--space-lg); }
.mb-xl { margin-bottom: var(--space-xl); }

.mt-sm { margin-top: var(--space-sm); }
.mt-md { margin-top: var(--space-md); }
.mt-lg { margin-top: var(--space-lg); }
.mt-xl { margin-top: var(--space-xl); }

.py-sm { padding-top: var(--space-sm); padding-bottom: var(--space-sm); }
.py-md { padding-top: var(--space-md); padding-bottom: var(--space-md); }
.py-lg { padding-top: var(--space-lg); padding-bottom: var(--space-lg); }
.py-xl { padding-top: var(--space-xl); padding-bottom: var(--space-xl); }

.hidden {
  display: none;
}

.visible {
  visibility: visible;
}

.invisible {
  visibility: hidden;
}

.opacity-0 {
  opacity: 0;
}

.opacity-50 {
  opacity: 0.5;
}

/* ============================================
   12. Animations
   ============================================ */
@keyframes slideInLeft {
  from {
    opacity: 0;
    transform: translateX(-30px);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

@keyframes slideInRight {
  from {
    opacity: 0;
    transform: translateX(30px);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

@keyframes scaleIn {
  from {
    opacity: 0;
    transform: scale(0.95);
  }
  to {
    opacity: 1;
    transform: scale(1);
  }
}

.animate-fade-in {
  animation: fadeInUp 0.8s ease-out;
}

.animate-slide-in-left {
  animation: slideInLeft 0.6s ease-out;
}

.animate-slide-in-right {
  animation: slideInRight 0.6s ease-out;
}

.animate-scale-in {
  animation: scaleIn 0.6s ease-out;
}

/* ============================================
   13. Responsive Design
   ============================================ */
@media (max-width: 1024px) {
  .container {
    padding: 0 var(--space-md);
  }
  
  h1 {
    font-size: 40px;
  }
  
  h2 {
    font-size: 32px;
  }
  
  h3 {
    font-size: 22px;
  }
  
  .grid-2,
  .grid-3 {
    grid-template-columns: 1fr;
  }
  
  .grid-cols-1-2 {
    grid-template-columns: 1fr;
    gap: var(--space-lg);
  }
}

@media (max-width: 768px) {
  .hamburger {
    display: flex;
  }
  
  nav {
    position: fixed;
    left: 0;
    top: 60px;
    width: 100%;
    height: calc(100vh - 60px);
    background-color: var(--color-white);
    flex-direction: column;
    padding: var(--space-lg);
    gap: var(--space-sm);
    transform: translateX(-100%);
    transition: transform 0.3s ease;
    z-index: 150;
  }
  
  nav.active {
    transform: translateX(0);
  }
  
  nav a {
    padding: var(--space-md) 0;
    border-bottom: 1px solid var(--color-border);
  }
  
  .section {
    padding: var(--space-xl) 0;
  }
  
  h1 {
    font-size: 32px;
    margin-bottom: 16px;
  }
  
  h2 {
    font-size: 28px;
  }
  
  h3 {
    font-size: 20px;
  }
  
  p {
    font-size: 15px;
  }
  
  .hero {
    height: 400px;
  }
  
  .btn {
    padding: 12px 24px;
    font-size: 15px;
  }
  
  .btn-large {
    padding: 14px 32px;
    font-size: 16px;
  }
}

@media (max-width: 480px) {
  header {
    padding: 0 var(--space-md);
  }
  
  .container {
    padding: 0 var(--space-md);
  }
  
  h1 {
    font-size: 28px;
  }
  
  h2 {
    font-size: 24px;
  }
  
  h3 {
    font-size: 18px;
  }
  
  p {
    font-size: 14px;
  }
  
  .section {
    padding: var(--space-lg) 0;
  }
  
  .hero {
    height: 300px;
  }
  
  .hero h1 {
    font-size: 24px;
  }
  
  .hero p {
    font-size: 16px;
  }
  
  .card {
    padding: var(--space-md);
  }
  
  .grid {
    gap: var(--space-md);
  }
}
