/*
Theme Name: Grain Landing
Theme URI: https://www.grain.co.th/
Author: Grain
Author URI: https://www.grain.co.th/
Description: A modern, conversion-focused landing page WordPress theme with hero sections, features, testimonials, and CTAs. Perfect for product launches, services, and marketing campaigns.
Version: 1.0.0
Requires at least: 6.0
Tested up to: 6.4
Requires PHP: 7.4
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Text Domain: grain-landing
Tags: landing-page, one-page, custom-header, custom-logo, featured-images, full-width-template, editor-style, threaded-comments, translation-ready, marketing, business

This theme, like WordPress, is licensed under the GPL.
*/

/*
===========================================
CSS CUSTOM PROPERTIES (DESIGN SYSTEM)
===========================================
*/

:root {
  /* Colors - Primary */
  --color-primary-rgb: 0, 0, 0;
  --color-primary: rgb(var(--color-primary-rgb));

  --color-secondary-rgb: 255, 255, 255;
  --color-secondary: rgb(var(--color-secondary-rgb));

  /* Colors - Neutral Scale */
  --color-gray-50: rgb(249, 250, 251);
  --color-gray-100: rgb(243, 244, 246);
  --color-gray-200: rgb(229, 231, 235);
  --color-gray-300: rgb(209, 213, 219);
  --color-gray-400: rgb(156, 163, 175);
  --color-gray-500: rgb(107, 114, 128);
  --color-gray-600: rgb(75, 85, 99);
  --color-gray-700: rgb(55, 65, 81);
  --color-gray-800: rgb(31, 41, 55);
  --color-gray-900: rgb(17, 24, 39);

  /* Colors - Brand (Grain Yellow) */
  --color-brand-rgb: 254, 204, 7;
  --color-brand: rgb(var(--color-brand-rgb));
  --color-brand-hover: rgb(212, 170, 0);
  --color-brand-light: rgba(var(--color-brand-rgb), 0.1);

  /* Colors - Accent (Dark Gray) */
  --color-accent-rgb: 31, 41, 55;
  --color-accent: rgb(var(--color-accent-rgb));
  --color-accent-hover: rgb(0, 0, 0);

  /* Colors - Success/Info/Warning */
  --color-success: rgb(16, 185, 129);
  --color-info: rgb(59, 130, 246);
  --color-warning: rgb(245, 158, 11);

  /* Typography */
  --font-family-base: 'Funkis A', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --font-family-heading: 'Funkis A', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;

  /* Font Sizes */
  --font-size-xs: 0.75rem;      /* 12px */
  --font-size-sm: 0.875rem;     /* 14px */
  --font-size-base: 1rem;       /* 16px */
  --font-size-lg: 1.125rem;     /* 18px */
  --font-size-xl: 1.25rem;      /* 20px */
  --font-size-2xl: 1.5rem;      /* 24px */
  --font-size-3xl: 1.875rem;    /* 30px */
  --font-size-4xl: 2.25rem;     /* 36px */
  --font-size-5xl: 3rem;        /* 48px */
  --font-size-6xl: 3.75rem;     /* 60px */
  --font-size-7xl: 4.5rem;      /* 72px */

  /* Line Heights */
  --line-height-tight: 1.25;
  --line-height-normal: 1.5;
  --line-height-relaxed: 1.75;

  /* Spacing Scale */
  --space-xs: 0.25rem;   /* 4px */
  --space-sm: 0.5rem;    /* 8px */
  --space-md: 1rem;      /* 16px */
  --space-lg: 1.5rem;    /* 24px */
  --space-xl: 2rem;      /* 32px */
  --space-2xl: 3rem;     /* 48px */
  --space-3xl: 4rem;     /* 64px */
  --space-4xl: 6rem;     /* 96px */
  --space-5xl: 8rem;     /* 128px */

  /* Container */
  --container-max-width: 1280px;
  --container-padding: var(--space-lg);

  /* Transitions */
  --transition-base: all 0.3s ease;
  --transition-fast: all 0.15s ease;
  --transition-slow: all 0.5s ease;

  /* Backgrounds */
  --color-bg-alt: #f2efea;

  /* Border Radius */
  --radius-sm: 0.25rem;
  --radius-md: 0.5rem;
  --radius-lg: 0;
  --radius-xl: 1.5rem;
  --radius-full: 9999px;

  /* Shadows */
  --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
  --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
  --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
  --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.1);
  --shadow-2xl: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
}

/*
===========================================
RESET & BASE STYLES
===========================================
*/

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

html {
  font-size: 16px;
  scroll-behavior: smooth;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body {
  font-family: var(--font-family-base);
  font-size: var(--font-size-base);
  line-height: var(--line-height-normal);
  color: var(--color-primary);
  background-color: var(--color-secondary);
  overflow-x: hidden;
}

/*
===========================================
TYPOGRAPHY
===========================================
*/

h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-family-heading);
  font-weight: 700;
  line-height: var(--line-height-tight);
  margin-bottom: var(--space-md);
  color: var(--color-primary);
}

h1 { font-size: var(--font-size-6xl); }
h2 { font-size: var(--font-size-5xl); }
h3 { font-size: var(--font-size-4xl); }
h4 { font-size: var(--font-size-3xl); }
h5 { font-size: var(--font-size-2xl); }
h6 { font-size: var(--font-size-xl); }

p {
  margin-bottom: var(--space-md);
  line-height: var(--line-height-relaxed);
}

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

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

/*
===========================================
LAYOUT
===========================================
*/

.container {
  max-width: var(--container-max-width);
  margin: 0 auto;
  padding: 0 var(--container-padding);
}

.container-fluid {
  width: 100%;
  padding: 0 var(--container-padding);
}

section {
  position: relative;
  overflow: hidden;
}

/*
===========================================
RESPONSIVE TYPOGRAPHY
===========================================
*/

@media screen and (max-width: 1024px) {
  :root {
    --font-size-7xl: 3.75rem;   /* 60px */
    --font-size-6xl: 3rem;      /* 48px */
    --font-size-5xl: 2.5rem;    /* 40px */
    --font-size-4xl: 2rem;      /* 32px */
  }
}

@media screen and (max-width: 768px) {
  :root {
    --font-size-7xl: 2.5rem;    /* 40px */
    --font-size-6xl: 2rem;      /* 32px */
    --font-size-5xl: 1.875rem;  /* 30px */
    --font-size-4xl: 1.5rem;    /* 24px */
    --container-padding: var(--space-md);
  }
}

/*
===========================================
UTILITIES
===========================================
*/

.screen-reader-text {
  clip: rect(1px, 1px, 1px, 1px);
  position: absolute !important;
  height: 1px;
  width: 1px;
  overflow: hidden;
}

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

.mb-0 { margin-bottom: 0; }
.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-0 { margin-top: 0; }
.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); }
