* {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: Arial, sans-serif;
  background: #1f1f1f;
  color: #111;
}

.app {
  width: 100%;
  min-height: 100vh;
  background: #1f1f1f;
}

.browserbar {
  display: flex;
  gap: 10px;
  padding: 12px;
  background: #1f1f1f;
}

.browserbar button {
  width: 48px;
  height: 48px;
  border: none;
  border-radius: 14px;
  background: #3a3a3a;
  color: white;
  font-size: 24px;
  cursor: pointer;
}

.tab-wrapper {
  display: flex;
  align-items: center;
  gap: 8px;
  background: #2b2b2b;
  padding: 10px;
}

.tab-list {
  display: flex;
  flex: 1;
  gap: 8px;
  overflow-x: auto;
}

.tab {
  display: flex;
  align-items: center;
  gap: 8px;
  min-width: 120px;
  max-width: 190px;
  padding: 10px 12px;
  border-radius: 14px;
  background: #e9e9e9;
  color: #111;
  font-size: 13px;
  cursor: pointer;
}

.tab.active {
  background: #0b57d0;
  color: white;
}

.tab-title {
  flex: 1;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.close-tab {
  width: 22px;
  height: 22px;
  border: none;
  border-radius: 50%;
  background: rgba(0,0,0,0.18);
  color: inherit;
  cursor: pointer;
}

.add-tab-btn {
  width: 52px;
  height: 52px;
  border: none;
  border-radius: 16px;
  background: #3f63df;
  color: white;
  font-size: 30px;
  cursor: pointer;
}

.content-area {
  width: 100%;
  height: calc(100vh - 132px);
  background: white;
  overflow: hidden;
}

.home-view {
  height: 100%;
  padding: 35px 18px;
  overflow-y: auto;
  text-align: center;
  background: #f5f5f5;
}

.google-logo {
  font-size: 44px;
  font-weight: bold;
  margin: 25px 0 28px;
}

.blue { color: #4285f4; }
.red { color: #ea4335; }
.yellow { color: #fbbc05; }
.green { color: #34a853; }

.search-box {
  display: flex;
  background: white;
  padding: 8px;
  border-radius: 18px;
  box-shadow: 0 3px 12px rgba(0,0,0,0.1);
}

.search-box input {
  flex: 1;
  border: none;
  outline: none;
  padding: 13px;
  font-size: 15px;
  border-radius: 12px;
}

.search-box button {
  border: none;
  border-radius: 12px;
  padding: 12px 15px;
  background: #111;
  color: white;
  font-size: 14px;
}

h3 {
  text-align: left;
  margin-top: 28px;
}

.grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 14px;
}

.card {
  background: white;
  border-radius: 18px;
  padding: 14px 5px;
  font-size: 13px;
  box-shadow: 0 2px 8px rgba(0,0,0,0.08);
  cursor: pointer;
}

.card-icon {
  width: 42px;
  height: 42px;
  background: #eee;
  border-radius: 14px;
  margin: 0 auto 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: bold;
}

.result-view {
  height: 100%;
  overflow-y: auto;
  background: #f5f5f5;
  padding: 15px;
}

.result-item {
  background: white;
  border-radius: 14px;
  padding: 15px;
  margin-bottom: 12px;
  box-shadow: 0 2px 8px rgba(0,0,0,0.08);
  cursor: pointer;
}

.result-title {
  color: #1a0dab;
  font-weight: bold;
  margin-bottom: 5px;
}

.result-url {
  color: green;
  font-size: 12px;
  margin-bottom: 6px;
  word-break: break-all;
}

.badge {
  background: #0b57d0;
  color: white;
  font-size: 11px;
  padding: 3px 7px;
  border-radius: 8px;
  margin-left: 6px;
}

.web-frame {
  width: 100%;
  height: 100%;
  border: none;
  background: white;
}

body.light-theme {
  background: #f5f5f5;
}

body.light-theme .app,
body.light-theme .browserbar {
  background: #f5f5f5;
}

body.light-theme .tab-wrapper {
  background: #e5e5e5;
}

body.light-theme .browserbar button {
  background: #ffffff;
  color: #111;
}

body.light-theme .content-area {
  background: #ffffff;
}

body.light-theme .tab {
  background: #ffffff;
  color: #111;
}

body.light-theme .tab.active {
  background: #0b57d0;
  color: #ffffff;
}