/* ============================================
   SORA JAPAN – Engineering Jobs Styles
   ============================================ */

@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700&display=swap');
@import url('https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.4.0/css/all.min.css');

:root {
  --color-primary: #0EA5E9;
  --color-cta: #F97316;
  --color-bg: #F0F9FF;
  --color-bg-white: #FFFFFF;
  --color-text: #0C4A6E;
  --color-text-light: #475569;
  --color-border: #E2E8F0;
  --shadow-md: 0 4px 6px -1px rgba(0,0,0,0.07), 0 2px 4px -2px rgba(0,0,0,0.05);
  --shadow-lg: 0 10px 25px -3px rgba(0,0,0,0.08), 0 4px 6px -4px rgba(0,0,0,0.04);
  --radius-md: 12px;
  --transition: 250ms ease;
}

body {
  font-family: 'Inter', sans-serif;
  background-color: var(--color-bg);
  color: var(--color-text);
  margin: 0;
  padding: 0;
  line-height: 1.6;
}

.header {
  background: var(--color-bg-white);
  padding: 15px 20px;
  box-shadow: var(--shadow-md);
  display: flex;
  align-items: center;
  justify-content: space-between;
  position: sticky;
  top: 0;
  z-index: 100;
}

.header .logo img {
  height: 50px;
}

.header a {
  text-decoration: none;
  color: var(--color-text);
  font-weight: 500;
}

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

.page-title {
  text-align: center;
  margin: 40px 20px 20px;
  font-size: 28px;
  color: var(--color-text);
}

.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 20px;
}

/* --- Filter Bar --- */
.filter-bar {
  display: flex;
  gap: 15px;
  margin-bottom: 30px;
  background: var(--color-bg-white);
  padding: 15px 20px;
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-md);
  align-items: center;
  flex-wrap: wrap;
}

.filter-bar select {
  padding: 10px 15px;
  border: 1px solid var(--color-border);
  border-radius: 8px;
  font-family: 'Inter', sans-serif;
  outline: none;
  min-width: 150px;
}

/* --- Card Grid --- */
.card-container {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 25px;
}

/* --- Job Card --- */
.job-card {
  background: var(--color-bg-white);
  border-radius: var(--radius-md);
  overflow: hidden;
  box-shadow: var(--shadow-md);
  transition: transform var(--transition), box-shadow var(--transition);
  display: flex;
  flex-direction: column;
}

.job-card:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-lg);
}

.job-card-image {
  height: 160px;
  background-size: cover;
  background-position: center;
  position: relative;
}

.job-card-badge {
  position: absolute;
  top: 15px;
  left: 15px;
  background: var(--color-primary);
  color: white;
  padding: 5px 12px;
  border-radius: 20px;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.5px;
}

.job-card-content {
  padding: 20px;
  display: flex;
  flex-direction: column;
  flex-grow: 1;
}

.job-title {
  font-size: 18px;
  margin: 0 0 10px 0;
  font-weight: 700;
  line-height: 1.4;
  color: #000;
}

.job-company {
  font-size: 14px;
  color: var(--color-text-light);
  margin-bottom: 20px;
  display: flex;
  align-items: center;
  gap: 8px;
}

.job-details-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  margin-bottom: 20px;
  flex-grow: 1;
}

.job-detail-item {
  display: flex;
  flex-direction: column;
  font-size: 13px;
}

.detail-label {
  color: var(--color-text-light);
  display: flex;
  align-items: center;
  gap: 6px;
  margin-bottom: 3px;
}

.detail-value {
  font-weight: 500;
  color: var(--color-text);
}

.detail-value.highlight {
  color: var(--color-cta);
  font-size: 15px;
  font-weight: 700;
}

.btn {
  display: inline-block;
  text-align: center;
  padding: 12px 20px;
  border-radius: 8px;
  font-weight: 600;
  cursor: pointer;
  border: none;
  transition: var(--transition);
  font-family: inherit;
  text-decoration: none;
}

.job-btn {
  background: var(--color-bg);
  color: var(--color-primary);
  width: 100%;
  border: 1px solid var(--color-primary);
}

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

.btn-call-now {
  background: var(--color-cta);
  color: white;
  padding: 12px 24px;
  border-radius: 30px;
}

.btn-call-now:hover {
  background: #ea580c;
}

/* --- Modal --- */
.modal {
  display: none;
  position: fixed;
  z-index: 1000;
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
  overflow: auto;
  background-color: rgba(0,0,0,0.5);
  backdrop-filter: blur(4px);
  align-items: center;
  justify-content: center;
}

.modal-content {
  background-color: #fefefe;
  padding: 30px;
  border-radius: var(--radius-md);
  width: 90%;
  max-width: 600px;
  position: relative;
  box-shadow: var(--shadow-lg);
  max-height: 90vh;
  overflow-y: auto;
}

.close-btn {
  position: absolute;
  top: 15px;
  right: 20px;
  color: #aaa;
  font-size: 28px;
  font-weight: bold;
  cursor: pointer;
}

.close-btn:hover,
.close-btn:focus {
  color: black;
  text-decoration: none;
  cursor: pointer;
}

.modal-content h2 {
  margin-top: 0;
  margin-bottom: 15px;
  font-size: 22px;
  padding-right: 30px;
}

.modal-content h3 {
  margin-top: 20px;
  margin-bottom: 10px;
  font-size: 16px;
  color: var(--color-primary);
}

.modal-content p {
  margin-bottom: 8px;
  font-size: 14px;
}

.highlight {
  color: var(--color-cta);
  font-weight: bold;
}

.loading, .error, .no-data {
  text-align: center;
  padding: 50px;
  font-size: 18px;
  color: var(--color-text-light);
  grid-column: 1 / -1;
}

.error {
  color: #ef4444;
}

/* Top Nav Links */
.job-nav {
  display: flex;
  justify-content: center;
  gap: 15px;
  margin-bottom: 30px;
  flex-wrap: wrap;
}

.job-nav a {
  padding: 10px 20px;
  border-radius: 20px;
  background: white;
  color: var(--color-text);
  text-decoration: none;
  font-weight: 500;
  box-shadow: var(--shadow-sm);
  transition: all var(--transition);
}

.job-nav a:hover, .job-nav a.active {
  background: var(--color-primary);
  color: white;
}

/* ── Skeleton Loading ── */
.skeleton-card {
  pointer-events: none;
}
.skeleton-img {
  width: 100%;
  height: 200px;
  background: #e5e7eb;
  border-radius: 12px 12px 0 0;
}
.skeleton-body {
  padding: 20px;
}
.skeleton-line {
  background: #e5e7eb;
  border-radius: 4px;
  margin-bottom: 8px;
}
.skeleton-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin-top: 12px;
}
.skeleton-pulse {
  animation: skeletonPulse 1.5s ease-in-out infinite;
}
@keyframes skeletonPulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.4; }
}
