/* iPhone 12-style device frame – scoped for IphoneComponent */

.iphone-component .iphoneMock {
  display: flex;
  flex-direction: row;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  width: 100%;
  min-height: 320px;
}

.iphone-component .iphoneMock .container {
  display: flex;
  flex-direction: row;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  margin: 0 auto;
  overflow: hidden;
}

.iphone-component .iphoneMock .container .iphone {
  width: 320px;
  height: 640px;
  border-radius: 45px;
  position: relative;
  user-select: none;
}

.iphone-component .iphoneMock .container .iphone:before,
.iphone-component .iphoneMock .container .iphone:after {
  content: "";
  position: absolute;
  background-color: rgba(255, 255, 255, 0.1);
  width: 6px;
  height: 7px;
  z-index: 1;
}
.iphone-component .iphoneMock .container .iphone:before {
  top: 1px;
  right: 70px;
}
.iphone-component .iphoneMock .container .iphone:after {
  bottom: -1px;
  left: 70px;
}

.iphone-component .iphoneMock .container .iphone .borderColor {
  display: flex;
  flex-direction: row;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  height: 100%;
  width: 100%;
  background-color: #152839;
  border: 1px solid rgba(255, 255, 255, 0.6);
  box-shadow: inset 0 0 3px 1px #fff;
  border-radius: 45px;
  position: relative;
}

.iphone-component .iphoneMock .container .iphone .borderColor:before,
.iphone-component .iphoneMock .container .iphone .borderColor:after {
  content: "";
  position: absolute;
  top: 65px;
  background-color: rgba(255, 255, 255, 0.1);
  width: 7px;
  height: 6px;
  z-index: 1;
}
.iphone-component .iphoneMock .container .iphone .borderColor:before { left: 0; }
.iphone-component .iphoneMock .container .iphone .borderColor:after { right: 0; }

.iphone-component .iphoneMock .container .iphone .borderColor .buttons > * {
  position: absolute;
  left: -3px;
  width: 3px;
  background: linear-gradient(90deg, transparent, #152839);
  border-radius: 20px 10px 10px 20px;
}
.iphone-component .iphoneMock .container .iphone .borderColor .buttons .touchID {
  top: 160px;
  right: -3px;
  left: auto;
  height: 80px;
  background: linear-gradient(90deg, #152839, transparent);
  border-radius: 10px 20px 20px 10px;
}
.iphone-component .iphoneMock .container .iphone .borderColor .buttons .switch {
  top: 100px;
  height: 25px;
}
.iphone-component .iphoneMock .container .iphone .borderColor .buttons .vol {
  top: 150px;
  height: 45px;
}
.iphone-component .iphoneMock .container .iphone .borderColor .buttons .vol.down {
  top: 210px;
}

.iphone-component .iphoneMock .container .iphone .borderColor .backSide {
  display: flex;
  flex-direction: row;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  position: absolute;
  width: calc(100% - 12px);
  height: calc(100% - 12px);
  border-radius: 40px;
  background-color: #152839;
  transform: rotateY(180deg);
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  overflow: hidden;
  z-index: 1;
}
.iphone-component .iphoneMock .container .iphone .borderColor .backSide .cameras {
  display: flex;
  flex-direction: column;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  position: absolute;
  top: 20px;
  left: 20px;
  width: 120px;
  height: 120px;
  padding: 10px;
  border-radius: 25px;
  box-sizing: border-box;
  background: linear-gradient(45deg, rgba(0, 0, 0, 0.3), transparent);
  box-shadow: 1px 1px 10px 0 rgba(0, 0, 0, 0.4);
}
.iphone-component .iphoneMock .container .iphone .borderColor .backSide .cameras .cam {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 42px;
  height: 42px;
  border-radius: 50%;
  position: relative;
}
.iphone-component .iphoneMock .container .iphone .borderColor .backSide .cameras .cam:before {
  content: "";
  position: absolute;
  width: calc(100% + 10px);
  height: calc(100% + 10px);
  border-radius: 50%;
  box-shadow: -2px 2px 8px 0 #000;
  background: linear-gradient(45deg, #152839 65%, rgba(255, 255, 255, 0.5));
}
.iphone-component .iphoneMock .container .iphone .borderColor .backSide .cameras .cam:after {
  content: "";
  position: absolute;
  width: 100%;
  height: 100%;
  border-radius: 50%;
  background-color: #1b1b1b;
  border: 9px solid rgba(0, 0, 0, 0.2);
  box-sizing: border-box;
}
.iphone-component .iphoneMock .container .iphone .borderColor .backSide .cameras .cam .lens {
  position: absolute;
  width: 25%;
  height: 25%;
  border-radius: 50%;
  box-shadow: inset 2px 0 4px -4px #fff;
  background: radial-gradient(ellipse farthest-corner at 8px 2px, #152839, #000);
  z-index: 1;
}
.iphone-component .iphoneMock .container .iphone .borderColor .backSide .cameras .flash,
.iphone-component .iphoneMock .container .iphone .borderColor .backSide .cameras .sensor {
  position: absolute;
  right: 20px;
  width: 22px;
  height: 22px;
  border-radius: 50%;
}
.iphone-component .iphoneMock .container .iphone .borderColor .backSide .cameras .flash {
  top: 5px;
  background: radial-gradient(#fff291, #ffd5fe);
}
.iphone-component .iphoneMock .container .iphone .borderColor .backSide .cameras .sensor {
  bottom: 5px;
  background-color: #000;
}
.iphone-component .iphoneMock .container .iphone .borderColor .backSide .logo {
  width: 80px;
  height: 80px;
}
.iphone-component .iphoneMock .container .iphone .borderColor .backSide .logo svg {
  width: 100%;
  height: 100%;
  color: rgba(0, 0, 0, 0.3);
}
.iphone-component .iphoneMock .container .iphone .borderColor .backSide .logo svg path {
  fill: currentColor;
}

.iphone-component .iphoneMock .container .iphone .borderColor .blackBorder {
  display: flex;
  flex-direction: row;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  width: calc(100% - 14px);
  height: calc(100% - 14px);
  border-radius: 40px;
  background-color: #000;
  position: relative;
  overflow: hidden;
}
.iphone-component .iphoneMock .container .iphone .borderColor .blackBorder:after {
  content: "";
  position: absolute;
  width: 100%;
  height: 100%;
  border-radius: 40px;
  border: 7px solid #000;
  box-sizing: border-box;
  pointer-events: none;
  z-index: 9;
}

.iphone-component .iphoneMock .container .iphone .borderColor .blackBorder .notch {
  display: flex;
  flex-direction: row;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  position: absolute;
  top: 0;
  width: 150px;
  height: 32px;
  border-bottom-left-radius: 17px;
  border-bottom-right-radius: 17px;
  background-color: #000;
  z-index: 9;
}
.iphone-component .iphoneMock .container .iphone .borderColor .blackBorder .notch:before,
.iphone-component .iphoneMock .container .iphone .borderColor .blackBorder .notch:after {
  content: "";
  position: absolute;
  top: 0;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  border: 7px solid transparent;
}
.iphone-component .iphoneMock .container .iphone .borderColor .blackBorder .notch:before {
  left: -17px;
  border-right-color: #000;
  transform: rotate(-50deg);
}
.iphone-component .iphoneMock .container .iphone .borderColor .blackBorder .notch:after {
  right: -17px;
  border-left-color: #000;
  transform: rotate(50deg);
}
.iphone-component .iphoneMock .container .iphone .borderColor .blackBorder .notch .megaphone {
  width: 40px;
  height: 4px;
  border-radius: 20px;
  background-color: #1b1b1b;
  border: 0.7px solid #171717;
  box-shadow: inset 0 -0.3px 1px 0 #8c8c8c;
}
.iphone-component .iphoneMock .container .iphone .borderColor .blackBorder .notch .camera {
  display: flex;
  align-items: center;
  justify-content: center;
  position: absolute;
  right: 35px;
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background-color: #1b1b1b;
}
.iphone-component .iphoneMock .container .iphone .borderColor .blackBorder .notch .camera:before {
  content: "";
  position: absolute;
  width: calc(100% - 4px);
  height: calc(100% - 4px);
  border-radius: 50%;
  background: radial-gradient(#000, #152839 60%);
}
.iphone-component .iphoneMock .container .iphone .borderColor .blackBorder .notch .camera:after {
  content: "";
  position: absolute;
  width: 4px;
  height: 4px;
  margin-top: 2px;
  margin-right: 2px;
  background-color: rgba(255, 255, 255, 0.1);
}

.iphone-component .iphoneMock .container .iphone .borderColor .blackBorder .mainScreen {
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  width: calc(100% - 14px);
  height: calc(100% - 14px);
  border-radius: 32px;
  background-color: #fff;
  position: relative;
  overflow: hidden;
  display: flex;
  flex-direction: column;
}

.iphone-component .iphoneMock .container .iphone .borderColor .blackBorder .mainScreen .statusBar {
  display: flex;
  flex-direction: row;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  height: 20px;
  padding: 5px 20px 0 20px;
  padding-right: 12px;
  position: relative;
  z-index: 1;
  flex-shrink: 0;
}
.iphone-component .iphoneMock .container .iphone .borderColor .blackBorder .mainScreen .statusBar .leftSide {
  color: #fff;
  font-size: 10px;
  text-transform: uppercase;
  font-family: 'Roboto', sans-serif;
}
.iphone-component .iphoneMock .container .iphone .borderColor .blackBorder .mainScreen .statusBar .rightSide {
  display: flex;
  flex-direction: row;
  flex-wrap: wrap;
  align-items: center;
  justify-content: flex-end;
}
.iphone-component .iphoneMock .container .iphone .borderColor .blackBorder .mainScreen .statusBar .rightSide .signal {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 18px;
  height: 10px;
  position: relative;
  overflow: hidden;
}
.iphone-component .iphoneMock .container .iphone .borderColor .blackBorder .mainScreen .statusBar .rightSide .signal:before,
.iphone-component .iphoneMock .container .iphone .borderColor .blackBorder .mainScreen .statusBar .rightSide .signal:after {
  content: "";
  position: absolute;
  bottom: 0;
  width: 3px;
  border-radius: 5px;
  background-color: #fff;
}
.iphone-component .iphoneMock .container .iphone .borderColor .blackBorder .mainScreen .statusBar .rightSide .signal:before {
  right: 0;
  height: 100%;
}
.iphone-component .iphoneMock .container .iphone .borderColor .blackBorder .mainScreen .statusBar .rightSide .signal:after {
  right: 4px;
  height: 80%;
}
.iphone-component .iphoneMock .container .iphone .borderColor .blackBorder .mainScreen .statusBar .rightSide .signal.mid:before {
  opacity: 0.4;
}
.iphone-component .iphoneMock .container .iphone .borderColor .blackBorder .mainScreen .statusBar .rightSide .signal .bar:before,
.iphone-component .iphoneMock .container .iphone .borderColor .blackBorder .mainScreen .statusBar .rightSide .signal .bar:after {
  content: "";
  position: absolute;
  bottom: 0;
  width: 3px;
  border-radius: 5px;
  @apply bg-black;
}
.iphone-component .iphoneMock .container .iphone .borderColor .blackBorder .mainScreen .statusBar .rightSide .signal .bar:before {
  right: 8px;
  height: 60%;
}
.iphone-component .iphoneMock .container .iphone .borderColor .blackBorder .mainScreen .statusBar .rightSide .signal .bar:after {
  right: 12px;
  height: 40%;
}
.iphone-component .iphoneMock .container .iphone .borderColor .blackBorder .mainScreen .statusBar .rightSide .data {
  margin: 0 3px;
  font-size: 10px;

  @apply text-black;
}
.iphone-component .iphoneMock .container .iphone .borderColor .blackBorder .mainScreen .statusBar .rightSide .battery {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 15px;
  height: 8px;
  border-radius: 2px;
  border: 1px solid rgba(255, 255, 255, 0.5);
  position: relative;
}
.iphone-component .iphoneMock .container .iphone .borderColor .blackBorder .mainScreen .statusBar .rightSide .battery:before {
  content: "";
  position: absolute;
  right: -2px;
  width: 2px;
  height: 50%;
  border-top-right-radius: 1px;
  border-bottom-right-radius: 1px;
  @apply bg-black;
}
.iphone-component .iphoneMock .container .iphone .borderColor .blackBorder .mainScreen .statusBar .rightSide .battery:after {
  content: "";
  position: absolute;
  left: 1px;
  width: 100%;
  height: 6px;
  border-radius: 1px;
  max-width: calc(100% - 2px);
  @apply bg-black;
}
.iphone-component .iphoneMock .container .iphone .borderColor .blackBorder .mainScreen .statusBar .rightSide .battery.mid:after {
  width: 65%;
}

.iphone-component__screen-content {
  flex: 1;
  overflow: auto;
  min-height: 0;
  @apply dark:bg-black bg-white;
}

/* Messages app: iOS UI kit style */
.iphone-component__message-app {
  display: flex;
  flex-direction: column;
  height: 100%;
  min-height: 0;
}

.iphone-component__message-app, .statusBar, .iphone-component__message-header {
  @apply bg-white dark:bg-gray-700;
}

.statusBar, .iphone-component__message-header {
  /* background-color: rgba(249, 249, 249, 0.98); */
}

/* Messages nav bar (iOS style) */
.iphone-component__message-header {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-shrink: 0;
  min-height: 44px;
  padding: 0 8px 0 4px;
  @apply mt-2 border-b border-gray-200 dark:border-gray-600;
}

.iphone-component__message-header-back {
  display: flex;
  align-items: center;
  min-width: 80px;
  padding: 8px 6px;
  border: 0;
  background: none;
  font-size: 17px;
  font-weight: 400;
  cursor: default;
  -webkit-tap-highlight-color: transparent;

  @apply gap-2;
}

.iphone-component__message-header-right, .iphone-component__message-header-back {
  color: #007AFF;
}

.iphone-component__message-header-chevron {
  display: inline-block;
  width: 13px;
  height: 13px;
  border-left: 2px solid currentColor;
  border-bottom: 2px solid currentColor;
  transform: rotate(45deg);
  margin-bottom: 2px;
}

.iphone-component__message-header-back-label {
  font-size: 17px;
}

.iphone-component__message-header-title {
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
  margin: 0;
  font-size: 17px;
  font-weight: 600;
  color: #000;
  letter-spacing: -0.41px;
}

.iphone-component__message-header-right {
  min-width: 80px;
  display: flex;
  justify-content: flex-end;
  padding-right: 8px;
}

.iphone-component__message-header-info {
  font-size: 17px;
  font-weight: 400;
  color: #007AFF;
}

.iphone-component__messages--sms {
  padding: 12px 16px 16px;
}

/* Message list + bubble */
.iphone-component__messages {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  justify-content: flex-start;
  flex: 1;
  min-height: 0;
  box-sizing: border-box;
  overflow: auto;
  @apply bg-white dark:bg-gray-800;
}

.iphone-component__message-header-image--rcs, .iphone-component__message-bubble {
  @apply max-w-[80%];
}

.iphone-component__message-bubble {
  padding: 10px 14px;
  overflow-wrap: anywhere;
  background: #34c759; /* iOS green iMessage bubble */
  color: #fff;
  border-radius: 18px 18px 4px 18px; /* tail on bottom-right */
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.1);
  font-family: -apple-system, BlinkMacSystemFont, 'SF Pro Text', sans-serif;
  @apply text-sm;
}

.iphone-component--rcs .iphone-component__message-bubble {
  @apply bg-gray-200 text-black dark:text-white dark:bg-gray-700;
}

.phone-component__footer {
  @apply flex items-center gap-3 w-full absolute bottom-4 left-0 right-0 px-2;
}

.phone-component__footer-plus-button {
  @apply size-8 rounded-full bg-white dark:bg-gray-700 dark:text-white shadow flex items-center justify-center;
}

.phone-component__footer-input {
  @apply flex-1 text-left rounded-full w-full bg-gray-100 dark:bg-gray-700 shadow flex p-2 text-sm text-gray-400;
}

.iphone-component__messages--padding {
  @apply p-3;
}

.iphone-component__cards--rcs > div > div {
  @apply !bg-gray-100 dark:bg-gray-700;
}

.iphone-component__cards--rcs .card-preview--item {
  @apply !p-0;

  img {
    @apply !rounded-b-none;
  }
}

.iphone-component__message-header-image--rcs {
  @apply w-full h-[140px] overflow-hidden rounded-t-md;
}

.iphone-component__message-header-image--rcs + .iphone-component__message-bubble {
  @apply rounded-t-none;
}

.card-preview-content--rcs {
  @apply dark:bg-gray-700 bg-gray-100;
}