/* ========================================
   LittleGrid Official Website Styles
   ======================================== */

/* ----------------------------------------
   1. CSS Variables and Reset Styles
   ---------------------------------------- */

/* CSS Variables */
:root {
  --color-primary: #5B9BD5;
  --color-primary-dark: #4A89C4;
  --color-bg: #FFFFFF;
  --color-bg-alt: #F5F8FC;
  --color-text: #333333;
  --color-text-secondary: #666666;
  --color-border: #E0E0E0;
  --radius-card: 8px;
  --spacing-section: 80px;
  --spacing-section-mobile: 48px;
  --font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}

/* Reset Styles */
*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  font-size: 16px;
  -webkit-text-size-adjust: 100%;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body {
  font-family: var(--font-family);
  font-size: 1rem;
  line-height: 1.6;
  color: var(--color-text);
  background-color: var(--color-bg);
}

a {
  color: inherit;
  text-decoration: none;
}

ul,
ol {
  list-style: none;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

button {
  font-family: inherit;
  font-size: inherit;
  cursor: pointer;
  border: none;
  background: none;
}

/* ----------------------------------------
   2. Common Component Styles
   ---------------------------------------- */

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

.section {
  padding: var(--spacing-section) 0;
}

.section--alt {
  background-color: var(--color-bg-alt);
}

.section__title {
  font-size: 2rem;
  font-weight: 600;
  text-align: center;
  margin-bottom: 48px;
  color: var(--color-text);
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 12px 32px;
  font-size: 1rem;
  font-weight: 500;
  border-radius: var(--radius-card);
  transition: all 0.3s ease;
  cursor: pointer;
}

.btn--primary {
  background-color: var(--color-primary);
  color: #FFFFFF;
}

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

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

.btn--outline:hover {
  background-color: var(--color-primary);
  color: #FFFFFF;
}

/* Cards */
.card {
  background-color: var(--color-bg);
  border-radius: var(--radius-card);
  box-shadow: 0 2px 12px rgba(0, 0, 0, 0.08);
  padding: 24px;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.card:hover {
  transform: translateY(-4px);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.12);
}

/* ----------------------------------------
   3. Header Navigation Styles
   ---------------------------------------- */

.header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  background-color: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--color-border);
}

.header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 64px;
}

.header__logo {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 1.25rem;
  font-weight: 600;
  color: var(--color-text);
}

.header__logo img {
  width: 32px;
  height: 32px;
}

.header__nav {
  display: flex;
  align-items: center;
  gap: 32px;
}

.header__link {
  font-size: 0.9375rem;
  color: var(--color-text-secondary);
  transition: color 0.3s ease;
}

.header__link:hover {
  color: var(--color-primary);
}

.header__menu-btn {
  display: none;
  flex-direction: column;
  gap: 5px;
  padding: 8px;
  cursor: pointer;
}

.header__menu-btn span {
  display: block;
  width: 24px;
  height: 2px;
  background-color: var(--color-text);
  transition: transform 0.3s ease, opacity 0.3s ease;
}

/* ----------------------------------------
   4. Hero Section Styles
   ---------------------------------------- */

.hero {
  min-height: 100vh;
  display: flex;
  align-items: center;
  background: linear-gradient(135deg, #E8F4FD 0%, #FFFFFF 100%);
  padding-top: 64px;
}

.hero__inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  padding: 80px 0;
}

.hero__logo {
  width: 120px;
  height: 120px;
  margin-bottom: 32px;
}

.hero__logo img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.hero__title {
  font-size: 3rem;
  font-weight: 700;
  color: var(--color-text);
  margin-bottom: 16px;
  line-height: 1.2;
}

.hero__subtitle {
  font-size: 1.25rem;
  color: var(--color-text-secondary);
  margin-bottom: 40px;
  max-width: 600px;
}

.hero__actions {
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
  justify-content: center;
}

/* ----------------------------------------
   5. Features Section Styles
   ---------------------------------------- */

.features__grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}

.feature-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  padding: 32px 24px;
  background-color: var(--color-bg);
  border-radius: var(--radius-card);
  box-shadow: 0 2px 12px rgba(0, 0, 0, 0.08);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.feature-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.12);
}

.feature-card__icon {
  width: 64px;
  height: 64px;
  margin-bottom: 20px;
  display: flex;
  align-items: center;
  justify-content: center;
  background-color: var(--color-bg-alt);
  border-radius: 50%;
}

.feature-card__icon img {
  width: 36px;
  height: 36px;
  object-fit: contain;
}

.feature-card__name {
  font-size: 1.125rem;
  font-weight: 600;
  color: var(--color-text);
  margin-bottom: 12px;
}

.feature-card__desc {
  font-size: 0.9375rem;
  color: var(--color-text-secondary);
  line-height: 1.6;
}

/* ----------------------------------------
   6. Download Section Styles
   ---------------------------------------- */

.download {
  text-align: center;
}

.download__qrcode {
  width: 160px;
  height: 160px;
  margin: 0 auto 24px;
  background-color: var(--color-bg-alt);
  border-radius: var(--radius-card);
  display: flex;
  align-items: center;
  justify-content: center;
  border: 2px solid var(--color-border);
}

.download__qrcode img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.download__tip {
  font-size: 0.875rem;
  color: var(--color-text-secondary);
}

/* ----------------------------------------
   7. Changelog Section Styles
   ---------------------------------------- */

.changelog__list {
  max-width: 800px;
  margin: 0 auto;
}

.changelog__item {
  position: relative;
  padding-left: 32px;
  padding-bottom: 32px;
  border-left: 2px solid var(--color-border);
  margin-left: 12px;
}

.changelog__item:last-child {
  border-left-color: transparent;
  padding-bottom: 0;
}

.changelog__item::before {
  content: '';
  position: absolute;
  left: -8px;
  top: 4px;
  width: 14px;
  height: 14px;
  background-color: var(--color-primary);
  border-radius: 50%;
  border: 3px solid var(--color-bg);
}

.changelog__version {
  font-size: 1.125rem;
  font-weight: 600;
  color: var(--color-text);
  margin-bottom: 4px;
}

.changelog__date {
  font-size: 0.875rem;
  color: var(--color-text-secondary);
  margin-bottom: 12px;
}

.changelog__changes {
  font-size: 0.9375rem;
  color: var(--color-text-secondary);
  line-height: 1.8;
}

.changelog__changes li {
  position: relative;
  padding-left: 16px;
  margin-bottom: 4px;
}

.changelog__changes li::before {
  content: '-';
  position: absolute;
  left: 0;
  color: var(--color-text-secondary);
}

/* ----------------------------------------
   8. Feedback Section Styles
   ---------------------------------------- */

.feedback {
  text-align: center;
  padding: 64px 0;
}

.feedback__desc {
  font-size: 1.125rem;
  color: var(--color-text-secondary);
  margin-bottom: 32px;
  max-width: 600px;
  margin-left: auto;
  margin-right: auto;
}

.feedback__actions {
  display: flex;
  gap: 16px;
  justify-content: center;
  flex-wrap: wrap;
}

/* ----------------------------------------
   9. Footer Styles
   ---------------------------------------- */

.footer {
  background-color: var(--color-bg-alt);
  padding: 40px 0;
  border-top: 1px solid var(--color-border);
}

.footer__inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 16px;
}

.footer__copyright {
  font-size: 0.875rem;
  color: var(--color-text-secondary);
}

.footer__links {
  display: flex;
  gap: 24px;
  flex-wrap: wrap;
  justify-content: center;
}

.footer__link {
  font-size: 0.875rem;
  color: var(--color-text-secondary);
  transition: color 0.3s ease;
}

.footer__link:hover {
  color: var(--color-primary);
}

/* ----------------------------------------
   10. Responsive Styles (Mobile)
   ---------------------------------------- */

@media screen and (max-width: 768px) {
  /* Section spacing */
  .section {
    padding: var(--spacing-section-mobile) 0;
  }

  .section__title {
    font-size: 1.5rem;
    margin-bottom: 32px;
  }

  /* Header mobile menu */
  .header__nav {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background-color: var(--color-bg);
    flex-direction: column;
    padding: 24px;
    gap: 16px;
    border-bottom: 1px solid var(--color-border);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
  }

  .header__nav.active {
    display: flex;
  }

  .header__menu-btn {
    display: flex;
  }

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

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

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

  /* Hero section */
  .hero__inner {
    padding: 48px 0;
  }

  .hero__logo {
    width: 80px;
    height: 80px;
    margin-bottom: 24px;
  }

  .hero__title {
    font-size: 2rem;
  }

  .hero__subtitle {
    font-size: 1rem;
    margin-bottom: 32px;
    padding: 0 16px;
  }

  .hero__actions {
    flex-direction: column;
    width: 100%;
    padding: 0 24px;
  }

  .hero__actions .btn {
    width: 100%;
  }

  /* Features grid */
  .features__grid {
    grid-template-columns: 1fr;
    gap: 16px;
  }

  .feature-card {
    padding: 24px 20px;
  }

  .feature-card__icon {
    width: 56px;
    height: 56px;
  }

  .feature-card__icon img {
    width: 28px;
    height: 28px;
  }

  /* Download section */
  .download__qrcode {
    width: 200px;
    height: 200px;
  }

  /* Changelog */
  .changelog__item {
    padding-left: 24px;
    padding-bottom: 24px;
  }

  .changelog__version {
    font-size: 1rem;
  }

  /* Feedback */
  .feedback {
    padding: 48px 0;
  }

  .feedback__desc {
    font-size: 1rem;
    padding: 0 16px;
  }

  .feedback__actions {
    flex-direction: column;
    padding: 0 24px;
  }

  .feedback__actions .btn {
    width: 100%;
  }

  /* Footer */
  .footer {
    padding: 32px 0;
  }

  .footer__links {
    gap: 16px;
  }
}

/* Small mobile screens */
@media screen and (max-width: 480px) {
  .container {
    padding: 0 16px;
  }

  .hero__title {
    font-size: 1.75rem;
  }

  .section__title {
    font-size: 1.25rem;
  }

  .btn {
    padding: 10px 24px;
    font-size: 0.9375rem;
  }
}