CSS animation causing font-size rendering issues

I attempted to create a sentence where specific words are animated (rotated through) - initially it seemed to be working fine. However, upon checking the site on my mobile device, I discovered an issue. When accessing the page from a desktop ( including within dev tools), the animated text appears in the proper size. But when viewed on a mobile device (iPhone), the text shrinks significantly

Bootstrap is also being utilized on the page and I suspected that something might have been overridden. Despite removing most of the bootstrap classes, the problem persists.

.animated span {
  color: #007bff;
  font-size: 0;
  opacity: 0;
  -ms-animation: topToBottom 10s infinite;
  -webkit-animation: topToBottom 10s infinite;
  animation: topToBottom 10s infinite;
}

.animated span:nth-child(2) {
  -ms-animation-delay: 2s;
  -webkit-animation-delay: 2s;
  animation-delay: 2s;
}

.animated span:nth-child(3) {
  -ms-animation-delay: 4s;
  -webkit-animation-delay: 4s;
  animation-delay: 4s;
}

.animated span:nth-child(4) {
  -ms-animation-delay: 6s;
  -webkit-animation-delay: 6s;
  animation-delay: 6s;
}

.animated span:nth-child(5) {
  -ms-animation-delay: 8s;
  -webkit-animation-delay: 8s;
  animation-delay: 8s;
}


@-webkit-keyframes topToBottom {

  0%,
  20% {
    font-size: 2.5rem;
    opacity: 1;
  }

  /* visible for 1s */
  20.01%,
  100% {
    opacity: 0;
    font-size: 0rem;
  }
<h1 class=" cover-heading animated">TribePulse replaces <br />
 <span>status updates</span>
 <span>engagement surveys</span>
 <span>progress reports</span>
 <span>status meetings</span>
 <span>EoD emails</span>
</h1>

Demo on glitch: Upon viewing it on a desktop, all the blue text displays at the correct size. Nevertheless, when seen on a mobile device, the animated text becomes miniscule.

Similar questions

If you have not found the answer to your question or you are interested in this topic, then look at other similar questions below or use the search

Looking to add the Ajax response data into a dropdown selection?

Looking to add select options dynamically, but unsure how to retrieve response values. I am able to fetch all the values in the response, but I struggle with appending them correctly in the select option. I believe the syntax is incorrect. success: funct ...

When jQuery html() is called on an inline-block div, it shifts downwards

Just take a moment to check out this JavaScript Fiddle: http://jsfiddle.net/NtxG9/1/ I'm dealing with two divs here, both sharing the same class and they are set to display as inline-block elements. Whenever I use $('#parent1').html('s ...

Customize the size of innerWidth and innerHeight in your THREEjs project

Is there a way to customize the size of the window where this function launches instead of it automatically calculating the height and width? I've attempted to modify this section of the code, but haven't had any success so far: renderer.setSiz ...

The currency exchange script is malfunctioning and not functioning properly

Is there a solution for accessing the JSON value that is currently eluding me? If anyone has any suggestions, I would greatly appreciate it. function forex() { var to = document.getElementById("to").value; alert(to); var from = document.getE ...

The tooltip indicator fails to display

I'm having an issue with my tooltip. I would like my tooltip to look like this: However, the actual result is like this: Here is the HTML & jQuery code I am using: <td style="padding-left:5px;padding-right:5px;" align="left" data-toggle="to ...

Apply a dynamic inline style to the header of an af:column to set the background color

I am facing a challenge where I need to dynamically change the background color of an af:column header. I have experimented with different solutions: Using the headerClass property in the CSS file for af:column does work, but dynamic changes are not poss ...

Is it possible to use JavaScript to upload and manipulate multiple HTML files, replacing text within them to create new output HTML pages?

Is it possible to modify the following code to accept multiple files, process them, and then return the output? <html> <head> </head> <body> <div> <label for="text">Choose file</label> <inp ...

Is there a way to conceal the scrollbar in the mobile view (on a mobile device or emulator) in a React application without disrupting the scrolling functionality?

I am looking to conceal the scrollbar on mobile devices throughout my app while still allowing users to scroll. I have attempted to hide the scrollbar using CSS properties like scrollbar, scrollbar-thumb, scrollbar-thumb:hover, and scrollbar-track. This ...

Creating movement in an SVG patterned background

Currently in the process of designing a brand new website using NextJS and Tailwind. I am looking to incorporate an infinitely translating background effect that moves towards the bottom right, similar to this example (but with my own unique pattern): htt ...

Floating with Flex in Bootstrap 4: A seamless way to achieve

Is there a way to achieve this floating layout using Bootstrap 4 flex Grid? I've attempted to use the flex order function but encountered some issues. Have a look at my result: <div class="row align-items-start"> <div class="col-sm- ...

Assess the scss styles specific to components following the global min.css in a React application

ISSUE Imagine we have a min.css file that needs to be imported globally: index.js import ReactDOM from "react-dom"; import App from "src/App"; import "library/library.min.css"; ReactDOM.render(<App />, document.getE ...

Tips for automatically adjusting canvas size within a parent container

I am facing a challenge with a canvas element inside a div: <div class="preview"><canvas id="cropped" width="2480" height="2003"></canvas></div> The div block is smaller than the canvas. How ...

Addressing a jquery.ajax relative path problem

I am a newcomer to this topic and I have been researching extensively online for more information. I would like some further insight into the following issue: I am attempting to retrieve a JSON file located one level down from the directory where `index.h ...

I used the `MyWindow=window.open` function to display a pop-up window and then navig

On my webpage (http://localhost:8088/hse/public/explorer), I have implemented two buttons: When these buttons are clicked, a new pop-up window will open at (http://localhost:8088/hse/public/explorer/1) onClick="MyWindow=window.open('http://local ...

Interactive website that transitions to a fresh page as we scroll further

As a beginner in web design, I've noticed a trend of companies using websites that automatically transition to the next page when scrolling down. An example of this is . What is this type of template called and are there any open source designs availa ...

An issue has occurred in Safari/IE because Error x[i].getElementsByTagName("image")[1] is not defined

I have been struggling to incorporate an RSS feed into my HTML page. It seems to function properly on iPad, iPhone, and Chrome, but encounters issues with Internet Explorer and Safari. Specifically, I am receiving an error message that states: x[i].getEle ...

Generating an HTML table by retrieving information from a database with the help of PHP

I have been working on a project that involves extracting data from a SQL database using PHP and then creating an HTML table based on that data. This table is designed to list the items I am selling, along with their costs, weights, and other relevant deta ...

What is the best way to incorporate dynamic elements into a canvas that evolve over time?

Whenever a user interacts with my website by clicking on various parts, I want to display an expanding circle. My idea is to achieve this using a canvas element. Currently, I have successfully implemented the feature where a circle is drawn at the position ...

Dynamic Display Picture Banner - Adjustable Layout

My home page features a full screen image header that I'm working to make responsive. The width of the image is being cut off on various screen sizes. I've attempted adjusting the height and width settings, but I want the image itself to resize ...

Experiencing strange behavior with floating labels in Bootstrap 5.3 on my Google Chrome browser (Version 123.0.6312.86 (Official Build) (64-bit))

Lately, I've observed an unusual behavior with BS 5.3 floating labels. Strangely, the placeholder is being displayed below the label text, which is not the expected behavior. On Google Chrome, the floating labels are appearing like this: https://i.ss ...