/* ============================================
   apinand.com — modernized 2026
   Mobile-first, responsive
   ============================================ */

/* Reset */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  padding: 0;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, "Noto Sans Thai", sans-serif;
  font-size: 16px;
  line-height: 1.55;
  color: #50565c;
  background-color: #f2f2f2;
  -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; height: auto; display: block; }
a { color: #2eaceb; text-decoration: none; }
a:hover { text-decoration: underline; }

/* ============================================
   HEADER / NAV
   ============================================ */
.site-header {
  background-color: #c4f0f8;
  position: sticky;
  top: 0;
  z-index: 50;
  width: 100%;
}

.site-header .wrapper {
  max-width: 960px;
  margin: 0 auto;
  padding: 14px 20px 0;
  position: relative;
}

.nav {
  background: #2eaceb;
  border-radius: 12px 12px 0 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 8px 0 0;
  min-height: 56px;
  flex-wrap: wrap;
}

.menu {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  align-items: center;
  flex-wrap: wrap;
}

.menu li { display: block; }

.menu li a {
  display: block;
  color: #fff;
  font-family: "Oswald", "Helvetica Neue", Arial, sans-serif;
  text-transform: uppercase;
  font-size: 16px;
  letter-spacing: 0.3px;
  padding: 0 14px;
  height: 56px;
  line-height: 56px;
  text-shadow: 1px 1px #105775;
  transition: background-color .15s ease;
}

.menu li a:hover {
  background-color: #97e2f1;
  color: #2eaceb;
  text-shadow: 1px 1px #fff;
  text-decoration: none;
}

.menu li.home a {
  background: url('images/home.png') no-repeat center center;
  background-size: 22px 22px;
  width: 48px;
  text-indent: -9999px;
  overflow: hidden;
}

.menu li.current a {
  background-color: #97e2f1;
  color: #2eaceb;
  text-shadow: 1px 1px #fff;
}

.linkedin-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: #fff;
  color: #2eaceb;
  border-radius: 6px;
  padding: 6px 12px;
  font-size: 13px;
  font-weight: 600;
  margin: 8px;
  white-space: nowrap;
}

.linkedin-btn:hover {
  background: #f0f9fd;
  text-decoration: none;
}

/* ============================================
   MAIN
   ============================================ */
.main {
  max-width: 960px;
  margin: 20px auto;
  padding: 0 20px;
}

.container {
  background-color: #fff;
  box-shadow: 0 3px 20px #c8c8c8;
  border-radius: 0 0 8px 8px;
  padding: 20px;
  position: relative;
  overflow: hidden;
}

/* ============================================
   HOME PAGE
   ============================================ */
.fp-content { max-width: 100%; }

@media (min-width: 768px) {
  .fp-content { max-width: 60%; }
}

h1.h, h2.h-section {
  font-family: "Oswald", "Helvetica Neue", Arial, sans-serif;
  color: #383e44;
  font-weight: normal;
  text-shadow: 1px 1px #fff;
  text-transform: uppercase;
  background: url('images/bgh.png') repeat-y;
  margin: -20px 0 16px -20px;
  padding: 0 20px;
  line-height: 60px;
  font-size: 24px;
  letter-spacing: 0.5px;
}

@media (min-width: 768px) {
  h1.h, h2.h-section { font-size: 26px; line-height: 66px; }
}

.fp-content p { margin: 0 0 12px; }
.fp-content p.ind { text-indent: 30px; }

.awards-content {
  margin-top: 24px;
  font-size: 14px;
}

.awards-content .h {
  width: 225px;
  height: 58px;
  background: url('images/awards.png') no-repeat;
  background-size: contain;
  position: relative;
  margin-bottom: 0;
}

.awards-content .h h2 {
  font-family: "Oswald", "Helvetica Neue", Arial, sans-serif;
  color: #fff;
  text-shadow: 1px 1px #105775;
  font-weight: normal;
  text-transform: uppercase;
  position: absolute;
  left: 60px;
  bottom: 14px;
  margin: 0;
  font-size: 19px;
}
.awards-content .h h2 a { color: #fff; }
.awards-content .h h2 a:hover { opacity: .85; text-decoration: none; }

.content-wrapper {
  border: 1px solid #d9d2d2;
  padding: 16px 14px 16px 30px;
  border-radius: 0 0 4px 4px;
}

.content-wrapper ul {
  margin: 0;
  padding: 0;
  list-style: none;
}

.content-wrapper li {
  border-bottom: 1px solid #ececec;
  margin-bottom: 8px;
  padding-bottom: 8px;
  position: relative;
  padding-left: 14px;
}

.content-wrapper li:last-child {
  border-bottom: 0;
  margin-bottom: 0;
}

.content-wrapper li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 9px;
  width: 8px;
  height: 8px;
  background: url('images/bullet.gif') no-repeat center / contain;
}

.content-wrapper li span {
  font-weight: 700;
  display: block;
  margin-bottom: 2px;
}

.btm {
  text-align: right;
  display: block;
  padding: 16px 4px 4px;
  font-size: 14px;
}

.btm a { color: #50565c; }

/* Trophy hero image — desktop only (hidden on mobile) */
.award-fp-img {
  display: none;
}

@media (min-width: 900px) {
  .award-fp-img {
    display: block;
    background: url('images/fp-award-img.png') no-repeat center center;
    background-size: contain;
    width: 320px;
    height: 540px;
    position: absolute;
    bottom: 0;
    right: 0;
    pointer-events: none;
  }
}

/* ============================================
   AWARDS PAGE
   ============================================ */
.awards-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 20px;
  margin-top: 8px;
}

@media (min-width: 700px) {
  .awards-grid { grid-template-columns: 1fr 1fr; gap: 24px; }
}

.bx {
  border: 1px solid #c8c8c8;
  border-radius: 6px;
  padding: 18px;
  background: #fff;
  display: flex;
  flex-direction: column;
}

.bx p { margin: 0 0 10px; color: #000; }
.bx p img { margin: 0 auto; }
.bx p.win {
  font-weight: 700;
  text-transform: uppercase;
  margin-top: 4px;
  color: #2eaceb;
  font-size: 13px;
  letter-spacing: 0.5px;
}
.bx p.d { text-align: center; margin-top: auto; }
.bx p.d img { margin: 12px auto 0; max-height: 100px; width: auto; }
.bx ul { margin: 0 0 12px; padding: 0; list-style: none; }
.bx li { margin-bottom: 8px; padding-left: 12px; position: relative; }
.bx li::before {
  content: "•";
  position: absolute;
  left: 0;
  top: 0;
  color: #2eaceb;
}

.home-aw {
  margin-top: 24px;
  text-align: right;
  font-size: 14px;
}
.home-aw p { margin: 0; }
.home-aw a { color: #747170; }

/* ============================================
   PRESS PAGE
   ============================================ */
.itp-images {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
  gap: 12px;
  margin: 16px 0 32px;
}

.itp-images a {
  display: block;
  border: 1px solid #838383;
  border-radius: 4px;
  overflow: hidden;
  aspect-ratio: 1;
  background: #f5f5f5;
}

.itp-images img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: opacity .2s ease;
}

.itp-images a:hover img { opacity: .8; }

.itp-videos {
  display: grid;
  grid-template-columns: 1fr;
  gap: 24px;
  margin: 24px 0;
}

.video-wrap {
  position: relative;
  width: 100%;
  padding-bottom: 56.25%; /* 16:9 */
  height: 0;
  border: 1px solid #838383;
  border-radius: 6px;
  overflow: hidden;
}

.video-wrap iframe {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  border: 0;
}

.video-caption {
  text-align: right;
  color: #000;
  margin: 8px 0 0;
  font-size: 14px;
}

.itp-sources {
  color: #747170;
  font-size: 13px;
  line-height: 1.7;
  border-top: 1px solid #ececec;
  padding-top: 16px;
  margin-top: 32px;
}

.itp-sources a { color: #747170; text-decoration: underline; }

/* ============================================
   FOOTER
   ============================================ */
.site-footer {
  background-color: #c4f0f8;
  margin-top: 24px;
  padding: 0;
}

.site-footer .wrapper {
  max-width: 960px;
  margin: 0 auto;
  padding: 0 20px;
}

.site-footer .inner {
  background-color: #2eaceb;
  color: #fff;
  font-size: 12px;
  text-align: center;
  line-height: 40px;
  border-radius: 6px 6px 0 0;
}

.site-footer a { color: #fff; }

/* ============================================
   LIGHTBOX (CSS-only via :target)
   ============================================ */
.lightbox {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,.85);
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  visibility: hidden;
  transition: opacity .2s ease;
  z-index: 100;
  padding: 20px;
}

.lightbox:target {
  opacity: 1;
  visibility: visible;
}

.lightbox img {
  max-width: 95%;
  max-height: 95vh;
  object-fit: contain;
  border-radius: 4px;
}

.lightbox .lb-close {
  position: absolute;
  top: 20px;
  right: 20px;
  width: 40px;
  height: 40px;
  background: rgba(255,255,255,.95);
  color: #000;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 24px;
  text-decoration: none;
  font-weight: 700;
  line-height: 1;
}

.lightbox .lb-close:hover { background: #fff; text-decoration: none; }

/* ============================================
   UTIL
   ============================================ */
sup { font-size: 0.7em; }
.clear { clear: both; }
