@font-face {
  font-family: 'RodinMaria EB';
  src: url('/FOT-RodinMaria Pro EB.otf') format('opentype');
}

@font-face {
  font-family: 'RodinMaria B';
  src: url('/FOT-RodinMaria Pro B.otf') format('opentype');
}

:root {
  --hue: 0;
  --accent: hsl(var(--hue), 100%, 50%);
  --bg: hsl(var(--hue), 15%, 97%);
  --card-bg: hsl(var(--hue), 15%, 100%);
  --text: hsl(var(--hue), 20%, 15%);
  --text-secondary: hsl(var(--hue), 10%, 45%);
  --separator: hsl(var(--hue), 10%, 90%);
  --glass-blur: 20px;
  --safe-area-inset-bottom: env(safe-area-inset-bottom);
}

body.dark-mode {
  --bg: hsl(var(--hue), 15%, 8%);
  --card-bg: hsl(var(--hue), 15%, 12%);
  --text: hsl(var(--hue), 10%, 95%);
  --text-secondary: hsl(var(--hue), 5%, 65%);
  --separator: hsl(var(--hue), 10%, 20%);
}

* {
  box-sizing: border-box;
  -webkit-tap-highlight-color: transparent;
}

body {
  margin: 0;
  font-family: 'RodinMaria B', -apple-system, sans-serif;
  background-color: var(--bg);
  color: var(--text);
  overflow-x: hidden;
  user-select: none;
}

h1, h2, h3, .app-name {
  font-family: 'RodinMaria EB', sans-serif;
}

#root {
  height: 100vh;
  display: flex;
  flex-direction: column;
}

.main-content {
  flex: 1;
  overflow-y: auto;
}

.view-container {
  padding-bottom: 120px;
  animation: fadeIn 0.3s ease-out;
}

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

/* Tab Bar - Redesigned to 3 Circles */
.tab-bar {
  position: fixed;
  bottom: 30px;
  left: 50%;
  transform: translateX(-50%);
  height: 76px;
  background: rgba(var(--hue), 10%, 10%, 0.05);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-radius: 40px;
  display: flex;
  padding: 10px;
  gap: 18px;
  z-index: 1000;
  border: 1px solid var(--separator);
}

.tab-item-circle {
  width: 56px;
  height: 56px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  background: transparent;
}

.tab-item-circle.active {
  background: var(--accent);
  box-shadow: 0 4px 15px rgba(0,0,0,0.2);
}

.material-symbols-rounded {
  font-variation-settings: 'FILL' 0, 'wght' 400, 'GRAD' 0, 'opsz' 48;
  user-select: none;
}

.v2-tag {
  font-size: 10px;
  background: var(--accent);
  color: white;
  padding: 2px 6px;
  border-radius: 6px;
  margin-left: 8px;
  vertical-align: middle;
  font-family: 'RodinMaria EB';
  display: inline-block;
  line-height: 1;
}

/* Headers */
.chikamichi-header {
  padding: 40px 20px 20px 20px;
}

.chikamichi-header h1 {
  margin: 0;
  font-size: 34px;
}

/* App Cards - Rounder Icons */
.apps-list {
  padding: 0 15px;
}

.app-card {
  background: var(--card-bg);
  margin-bottom: 15px;
  padding: 12px;
  border-radius: 20px;
  display: flex;
  align-items: center;
  border: 1px solid var(--separator);
  cursor: pointer;
  transition: transform 0.2s ease;
}

.app-card:active {
  transform: scale(0.98);
}

.app-icon {
  width: 60px;
  height: 60px;
  border-radius: 14px;
  object-fit: cover;
  background: var(--separator);
}

.app-icon.round {
  border-radius: 50%;
}

.app-info {
  flex: 1;
  margin-left: 12px;
}

.app-name {
  font-size: 17px;
  margin-bottom: 2px;
}

.app-category {
  font-size: 13px;
  color: var(--text-secondary);
}

.install-button {
  background: var(--accent);
  color: white;
  border: none;
  border-radius: 20px;
  padding: 8px 16px;
  font-family: 'RodinMaria EB';
  font-size: 14px;
  display: flex;
  align-items: center;
  gap: 6px;
  box-shadow: 0 4px 10px rgba(0,0,0,0.1);
}

/* Developer Page - Redesigned Centered */
.profile-header.centered {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 40px 20px;
  text-align: center;
}

.profile-pic.xlarge {
  width: 120px;
  height: 120px;
  border-radius: 50%;
  border: 4px solid var(--accent);
  padding: 4px;
  background: var(--card-bg);
}

.profile-handle {
  color: var(--text-secondary);
  margin-top: 5px;
  font-family: 'RodinMaria EB';
}

/* App Details - Redesigned Centered */
.app-details-view {
  background: var(--bg);
}

.details-banner {
  width: 100%;
  height: 200px;
  overflow: hidden;
  margin-bottom: -60px;
}

.details-banner img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.details-hero-centered {
  padding: 20px;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  position: relative;
  z-index: 1;
}

.app-icon-large {
  width: 120px;
  height: 120px;
  border-radius: 50%;
  box-shadow: 0 8px 30px rgba(0,0,0,0.15);
  background: white;
  margin-bottom: 15px;
}

.details-app-name {
  font-size: 28px;
  margin: 10px 0 5px 0;
}

.details-dev-row {
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--accent);
  font-family: 'RodinMaria EB';
  cursor: pointer;
}

.dev-avatar-small {
  width: 24px;
  height: 24px;
  border-radius: 50%;
}

.details-section {
  padding: 20px;
  border-top: 1px solid var(--separator);
  margin: 0 15px;
}

.details-section h3 {
  margin: 0 0 10px 0;
  font-size: 18px;
}

.details-text {
  line-height: 1.6;
  white-space: pre-wrap;
}

/* Forms & Hub */
.hub-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 15px;
  padding: 0 20px;
}

.hub-item {
  background: var(--card-bg);
  border-radius: 20px;
  padding: 24px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  border: 1px solid var(--separator);
  text-align: center;
  box-shadow: 0 4px 12px rgba(0,0,0,0.05);
}



.ios-input-group {
  background: var(--card-bg);
  border-radius: 18px;
  margin: 0 20px 20px 20px;
  overflow: hidden;
  border: 1px solid var(--separator);
}

.ios-input-group input, 
.ios-input-group select, 
.ios-input-group textarea {
  width: 100%;
  border: none;
  padding: 16px 20px;
  font-size: 16px;
  font-family: 'RodinMaria B';
  outline: none;
  background: transparent;
  color: var(--text);
  border-bottom: 0.5px solid var(--separator);
}

.ios-input-group input:last-child,
.ios-input-group textarea:last-child {
  border-bottom: none;
}

.action-btn {
  background: var(--accent);
  color: white;
  border: none;
  padding: 18px;
  border-radius: 18px;
  font-family: 'RodinMaria EB';
  font-size: 17px;
  margin: 0 20px;
  width: calc(100% - 40px);
  cursor: pointer;
  box-shadow: 0 4px 15px rgba(0,0,0,0.1);
}

.action-btn.secondary {
  background: var(--separator);
  color: var(--text);
  box-shadow: none;
}

.action-btn:disabled {
  opacity: 0.5;
}

/* Search Redesign */
.search-container {
  padding: 0 20px 20px 20px;
}

.search-wrapper {
  background: var(--card-bg);
  border-radius: 15px;
  display: flex;
  align-items: center;
  padding: 12px 18px;
  border: 1px solid var(--separator);
}

.search-wrapper input {
  flex: 1;
  background: transparent;
  border: none;
  color: var(--text);
  font-family: 'RodinMaria B';
  font-size: 16px;
  margin-left: 12px;
  outline: none;
}

/* Back Button */
.back-btn {
  background: none;
  border: none;
  color: var(--accent);
  font-family: 'RodinMaria EB';
  font-size: 17px;
  padding: 20px;
  display: flex;
  align-items: center;
  gap: 5px;
  cursor: pointer;
}

.label-title {
  padding: 0 25px 10px 25px;
  font-size: 12px;
  font-family: 'RodinMaria EB';
  color: var(--text-secondary);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.screenshots-scroll {
  display: flex;
  overflow-x: auto;
  gap: 15px;
  padding: 20px;
  scroll-snap-type: x mandatory;
}

.screenshot {
  height: 400px;
  border-radius: 20px;
  border: 1px solid var(--separator);
  scroll-snap-align: center;
}

.hue-slider {
  width: 100%;
  height: 12px;
  -webkit-appearance: none;
  background: linear-gradient(to right, #ff0000 0%, #ffff00 17%, #00ff00 33%, #00ffff 50%, #0000ff 67%, #ff00ff 83%, #ff0000 100%);
  border-radius: 6px;
  outline: none;
  margin: 10px 0;
}

.hue-slider::-webkit-slider-thumb {
  -webkit-appearance: none;
  width: 28px;
  height: 28px;
  background: white;
  border: 3px solid #333;
  border-radius: 50%;
  cursor: pointer;
}

.accent-slider-container {
  padding: 10px 25px 25px 25px;
}